diff --git a/.github/workflows/prod.yml b/.github/workflows/prod.yml index 4df597d58..2110d7d46 100644 --- a/.github/workflows/prod.yml +++ b/.github/workflows/prod.yml @@ -27,8 +27,8 @@ jobs: uses: actions/setup-node@v3 with: node-version: ${{ matrix.node-version }} - - run: CI=false yarn workspace dapp build --if-present - - run: yarn workspace services build --if-present + - run: CI=false yarn workspace dapp build + - run: yarn workspace services build - run: cp -r packages/dapp/dist/build/ packages/services/dist/ - id: 'auth' uses: 'google-github-actions/auth@v0' diff --git a/.github/workflows/staging.yml b/.github/workflows/staging.yml index 103589219..0457f45cf 100644 --- a/.github/workflows/staging.yml +++ b/.github/workflows/staging.yml @@ -29,8 +29,8 @@ jobs: uses: actions/setup-node@v3 with: node-version: ${{ matrix.node-version }} - - run: CI=false yarn workspace dapp build --if-present - - run: yarn workspace services build --if-present + - run: CI=false yarn workspace dapp build + - run: yarn workspace services build - run: cp -r packages/dapp/dist/build/ packages/services/dist/ - id: 'auth' uses: 'google-github-actions/auth@v0' diff --git a/.gitignore b/.gitignore index 3c291b74d..01cde5b16 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,3 @@ -generated package-lock.json #env diff --git a/node_modules/@babel/traverse/lib/path/generated/asserts.js b/node_modules/@babel/traverse/lib/path/generated/asserts.js new file mode 100644 index 000000000..bee8a438e --- /dev/null +++ b/node_modules/@babel/traverse/lib/path/generated/asserts.js @@ -0,0 +1,5 @@ +"use strict"; + +var t = require("@babel/types"); + +var _index = require("../index"); \ No newline at end of file diff --git a/node_modules/@babel/traverse/lib/path/generated/validators.js b/node_modules/@babel/traverse/lib/path/generated/validators.js new file mode 100644 index 000000000..bee8a438e --- /dev/null +++ b/node_modules/@babel/traverse/lib/path/generated/validators.js @@ -0,0 +1,5 @@ +"use strict"; + +var t = require("@babel/types"); + +var _index = require("../index"); \ No newline at end of file diff --git a/node_modules/@babel/traverse/lib/path/generated/virtual-types.js b/node_modules/@babel/traverse/lib/path/generated/virtual-types.js new file mode 100644 index 000000000..bf37ed937 --- /dev/null +++ b/node_modules/@babel/traverse/lib/path/generated/virtual-types.js @@ -0,0 +1,3 @@ +"use strict"; + +var t = require("@babel/types"); \ No newline at end of file diff --git a/node_modules/@babel/types/lib/asserts/generated/index.js b/node_modules/@babel/types/lib/asserts/generated/index.js new file mode 100644 index 000000000..53a55168d --- /dev/null +++ b/node_modules/@babel/types/lib/asserts/generated/index.js @@ -0,0 +1,1517 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.assertAccessor = assertAccessor; +exports.assertAnyTypeAnnotation = assertAnyTypeAnnotation; +exports.assertArgumentPlaceholder = assertArgumentPlaceholder; +exports.assertArrayExpression = assertArrayExpression; +exports.assertArrayPattern = assertArrayPattern; +exports.assertArrayTypeAnnotation = assertArrayTypeAnnotation; +exports.assertArrowFunctionExpression = assertArrowFunctionExpression; +exports.assertAssignmentExpression = assertAssignmentExpression; +exports.assertAssignmentPattern = assertAssignmentPattern; +exports.assertAwaitExpression = assertAwaitExpression; +exports.assertBigIntLiteral = assertBigIntLiteral; +exports.assertBinary = assertBinary; +exports.assertBinaryExpression = assertBinaryExpression; +exports.assertBindExpression = assertBindExpression; +exports.assertBlock = assertBlock; +exports.assertBlockParent = assertBlockParent; +exports.assertBlockStatement = assertBlockStatement; +exports.assertBooleanLiteral = assertBooleanLiteral; +exports.assertBooleanLiteralTypeAnnotation = assertBooleanLiteralTypeAnnotation; +exports.assertBooleanTypeAnnotation = assertBooleanTypeAnnotation; +exports.assertBreakStatement = assertBreakStatement; +exports.assertCallExpression = assertCallExpression; +exports.assertCatchClause = assertCatchClause; +exports.assertClass = assertClass; +exports.assertClassAccessorProperty = assertClassAccessorProperty; +exports.assertClassBody = assertClassBody; +exports.assertClassDeclaration = assertClassDeclaration; +exports.assertClassExpression = assertClassExpression; +exports.assertClassImplements = assertClassImplements; +exports.assertClassMethod = assertClassMethod; +exports.assertClassPrivateMethod = assertClassPrivateMethod; +exports.assertClassPrivateProperty = assertClassPrivateProperty; +exports.assertClassProperty = assertClassProperty; +exports.assertCompletionStatement = assertCompletionStatement; +exports.assertConditional = assertConditional; +exports.assertConditionalExpression = assertConditionalExpression; +exports.assertContinueStatement = assertContinueStatement; +exports.assertDebuggerStatement = assertDebuggerStatement; +exports.assertDecimalLiteral = assertDecimalLiteral; +exports.assertDeclaration = assertDeclaration; +exports.assertDeclareClass = assertDeclareClass; +exports.assertDeclareExportAllDeclaration = assertDeclareExportAllDeclaration; +exports.assertDeclareExportDeclaration = assertDeclareExportDeclaration; +exports.assertDeclareFunction = assertDeclareFunction; +exports.assertDeclareInterface = assertDeclareInterface; +exports.assertDeclareModule = assertDeclareModule; +exports.assertDeclareModuleExports = assertDeclareModuleExports; +exports.assertDeclareOpaqueType = assertDeclareOpaqueType; +exports.assertDeclareTypeAlias = assertDeclareTypeAlias; +exports.assertDeclareVariable = assertDeclareVariable; +exports.assertDeclaredPredicate = assertDeclaredPredicate; +exports.assertDecorator = assertDecorator; +exports.assertDirective = assertDirective; +exports.assertDirectiveLiteral = assertDirectiveLiteral; +exports.assertDoExpression = assertDoExpression; +exports.assertDoWhileStatement = assertDoWhileStatement; +exports.assertEmptyStatement = assertEmptyStatement; +exports.assertEmptyTypeAnnotation = assertEmptyTypeAnnotation; +exports.assertEnumBody = assertEnumBody; +exports.assertEnumBooleanBody = assertEnumBooleanBody; +exports.assertEnumBooleanMember = assertEnumBooleanMember; +exports.assertEnumDeclaration = assertEnumDeclaration; +exports.assertEnumDefaultedMember = assertEnumDefaultedMember; +exports.assertEnumMember = assertEnumMember; +exports.assertEnumNumberBody = assertEnumNumberBody; +exports.assertEnumNumberMember = assertEnumNumberMember; +exports.assertEnumStringBody = assertEnumStringBody; +exports.assertEnumStringMember = assertEnumStringMember; +exports.assertEnumSymbolBody = assertEnumSymbolBody; +exports.assertExistsTypeAnnotation = assertExistsTypeAnnotation; +exports.assertExportAllDeclaration = assertExportAllDeclaration; +exports.assertExportDeclaration = assertExportDeclaration; +exports.assertExportDefaultDeclaration = assertExportDefaultDeclaration; +exports.assertExportDefaultSpecifier = assertExportDefaultSpecifier; +exports.assertExportNamedDeclaration = assertExportNamedDeclaration; +exports.assertExportNamespaceSpecifier = assertExportNamespaceSpecifier; +exports.assertExportSpecifier = assertExportSpecifier; +exports.assertExpression = assertExpression; +exports.assertExpressionStatement = assertExpressionStatement; +exports.assertExpressionWrapper = assertExpressionWrapper; +exports.assertFile = assertFile; +exports.assertFlow = assertFlow; +exports.assertFlowBaseAnnotation = assertFlowBaseAnnotation; +exports.assertFlowDeclaration = assertFlowDeclaration; +exports.assertFlowPredicate = assertFlowPredicate; +exports.assertFlowType = assertFlowType; +exports.assertFor = assertFor; +exports.assertForInStatement = assertForInStatement; +exports.assertForOfStatement = assertForOfStatement; +exports.assertForStatement = assertForStatement; +exports.assertForXStatement = assertForXStatement; +exports.assertFunction = assertFunction; +exports.assertFunctionDeclaration = assertFunctionDeclaration; +exports.assertFunctionExpression = assertFunctionExpression; +exports.assertFunctionParent = assertFunctionParent; +exports.assertFunctionTypeAnnotation = assertFunctionTypeAnnotation; +exports.assertFunctionTypeParam = assertFunctionTypeParam; +exports.assertGenericTypeAnnotation = assertGenericTypeAnnotation; +exports.assertIdentifier = assertIdentifier; +exports.assertIfStatement = assertIfStatement; +exports.assertImmutable = assertImmutable; +exports.assertImport = assertImport; +exports.assertImportAttribute = assertImportAttribute; +exports.assertImportDeclaration = assertImportDeclaration; +exports.assertImportDefaultSpecifier = assertImportDefaultSpecifier; +exports.assertImportNamespaceSpecifier = assertImportNamespaceSpecifier; +exports.assertImportSpecifier = assertImportSpecifier; +exports.assertIndexedAccessType = assertIndexedAccessType; +exports.assertInferredPredicate = assertInferredPredicate; +exports.assertInterfaceDeclaration = assertInterfaceDeclaration; +exports.assertInterfaceExtends = assertInterfaceExtends; +exports.assertInterfaceTypeAnnotation = assertInterfaceTypeAnnotation; +exports.assertInterpreterDirective = assertInterpreterDirective; +exports.assertIntersectionTypeAnnotation = assertIntersectionTypeAnnotation; +exports.assertJSX = assertJSX; +exports.assertJSXAttribute = assertJSXAttribute; +exports.assertJSXClosingElement = assertJSXClosingElement; +exports.assertJSXClosingFragment = assertJSXClosingFragment; +exports.assertJSXElement = assertJSXElement; +exports.assertJSXEmptyExpression = assertJSXEmptyExpression; +exports.assertJSXExpressionContainer = assertJSXExpressionContainer; +exports.assertJSXFragment = assertJSXFragment; +exports.assertJSXIdentifier = assertJSXIdentifier; +exports.assertJSXMemberExpression = assertJSXMemberExpression; +exports.assertJSXNamespacedName = assertJSXNamespacedName; +exports.assertJSXOpeningElement = assertJSXOpeningElement; +exports.assertJSXOpeningFragment = assertJSXOpeningFragment; +exports.assertJSXSpreadAttribute = assertJSXSpreadAttribute; +exports.assertJSXSpreadChild = assertJSXSpreadChild; +exports.assertJSXText = assertJSXText; +exports.assertLVal = assertLVal; +exports.assertLabeledStatement = assertLabeledStatement; +exports.assertLiteral = assertLiteral; +exports.assertLogicalExpression = assertLogicalExpression; +exports.assertLoop = assertLoop; +exports.assertMemberExpression = assertMemberExpression; +exports.assertMetaProperty = assertMetaProperty; +exports.assertMethod = assertMethod; +exports.assertMiscellaneous = assertMiscellaneous; +exports.assertMixedTypeAnnotation = assertMixedTypeAnnotation; +exports.assertModuleDeclaration = assertModuleDeclaration; +exports.assertModuleExpression = assertModuleExpression; +exports.assertModuleSpecifier = assertModuleSpecifier; +exports.assertNewExpression = assertNewExpression; +exports.assertNoop = assertNoop; +exports.assertNullLiteral = assertNullLiteral; +exports.assertNullLiteralTypeAnnotation = assertNullLiteralTypeAnnotation; +exports.assertNullableTypeAnnotation = assertNullableTypeAnnotation; +exports.assertNumberLiteral = assertNumberLiteral; +exports.assertNumberLiteralTypeAnnotation = assertNumberLiteralTypeAnnotation; +exports.assertNumberTypeAnnotation = assertNumberTypeAnnotation; +exports.assertNumericLiteral = assertNumericLiteral; +exports.assertObjectExpression = assertObjectExpression; +exports.assertObjectMember = assertObjectMember; +exports.assertObjectMethod = assertObjectMethod; +exports.assertObjectPattern = assertObjectPattern; +exports.assertObjectProperty = assertObjectProperty; +exports.assertObjectTypeAnnotation = assertObjectTypeAnnotation; +exports.assertObjectTypeCallProperty = assertObjectTypeCallProperty; +exports.assertObjectTypeIndexer = assertObjectTypeIndexer; +exports.assertObjectTypeInternalSlot = assertObjectTypeInternalSlot; +exports.assertObjectTypeProperty = assertObjectTypeProperty; +exports.assertObjectTypeSpreadProperty = assertObjectTypeSpreadProperty; +exports.assertOpaqueType = assertOpaqueType; +exports.assertOptionalCallExpression = assertOptionalCallExpression; +exports.assertOptionalIndexedAccessType = assertOptionalIndexedAccessType; +exports.assertOptionalMemberExpression = assertOptionalMemberExpression; +exports.assertParenthesizedExpression = assertParenthesizedExpression; +exports.assertPattern = assertPattern; +exports.assertPatternLike = assertPatternLike; +exports.assertPipelineBareFunction = assertPipelineBareFunction; +exports.assertPipelinePrimaryTopicReference = assertPipelinePrimaryTopicReference; +exports.assertPipelineTopicExpression = assertPipelineTopicExpression; +exports.assertPlaceholder = assertPlaceholder; +exports.assertPrivate = assertPrivate; +exports.assertPrivateName = assertPrivateName; +exports.assertProgram = assertProgram; +exports.assertProperty = assertProperty; +exports.assertPureish = assertPureish; +exports.assertQualifiedTypeIdentifier = assertQualifiedTypeIdentifier; +exports.assertRecordExpression = assertRecordExpression; +exports.assertRegExpLiteral = assertRegExpLiteral; +exports.assertRegexLiteral = assertRegexLiteral; +exports.assertRestElement = assertRestElement; +exports.assertRestProperty = assertRestProperty; +exports.assertReturnStatement = assertReturnStatement; +exports.assertScopable = assertScopable; +exports.assertSequenceExpression = assertSequenceExpression; +exports.assertSpreadElement = assertSpreadElement; +exports.assertSpreadProperty = assertSpreadProperty; +exports.assertStandardized = assertStandardized; +exports.assertStatement = assertStatement; +exports.assertStaticBlock = assertStaticBlock; +exports.assertStringLiteral = assertStringLiteral; +exports.assertStringLiteralTypeAnnotation = assertStringLiteralTypeAnnotation; +exports.assertStringTypeAnnotation = assertStringTypeAnnotation; +exports.assertSuper = assertSuper; +exports.assertSwitchCase = assertSwitchCase; +exports.assertSwitchStatement = assertSwitchStatement; +exports.assertSymbolTypeAnnotation = assertSymbolTypeAnnotation; +exports.assertTSAnyKeyword = assertTSAnyKeyword; +exports.assertTSArrayType = assertTSArrayType; +exports.assertTSAsExpression = assertTSAsExpression; +exports.assertTSBaseType = assertTSBaseType; +exports.assertTSBigIntKeyword = assertTSBigIntKeyword; +exports.assertTSBooleanKeyword = assertTSBooleanKeyword; +exports.assertTSCallSignatureDeclaration = assertTSCallSignatureDeclaration; +exports.assertTSConditionalType = assertTSConditionalType; +exports.assertTSConstructSignatureDeclaration = assertTSConstructSignatureDeclaration; +exports.assertTSConstructorType = assertTSConstructorType; +exports.assertTSDeclareFunction = assertTSDeclareFunction; +exports.assertTSDeclareMethod = assertTSDeclareMethod; +exports.assertTSEntityName = assertTSEntityName; +exports.assertTSEnumDeclaration = assertTSEnumDeclaration; +exports.assertTSEnumMember = assertTSEnumMember; +exports.assertTSExportAssignment = assertTSExportAssignment; +exports.assertTSExpressionWithTypeArguments = assertTSExpressionWithTypeArguments; +exports.assertTSExternalModuleReference = assertTSExternalModuleReference; +exports.assertTSFunctionType = assertTSFunctionType; +exports.assertTSImportEqualsDeclaration = assertTSImportEqualsDeclaration; +exports.assertTSImportType = assertTSImportType; +exports.assertTSIndexSignature = assertTSIndexSignature; +exports.assertTSIndexedAccessType = assertTSIndexedAccessType; +exports.assertTSInferType = assertTSInferType; +exports.assertTSInterfaceBody = assertTSInterfaceBody; +exports.assertTSInterfaceDeclaration = assertTSInterfaceDeclaration; +exports.assertTSIntersectionType = assertTSIntersectionType; +exports.assertTSIntrinsicKeyword = assertTSIntrinsicKeyword; +exports.assertTSLiteralType = assertTSLiteralType; +exports.assertTSMappedType = assertTSMappedType; +exports.assertTSMethodSignature = assertTSMethodSignature; +exports.assertTSModuleBlock = assertTSModuleBlock; +exports.assertTSModuleDeclaration = assertTSModuleDeclaration; +exports.assertTSNamedTupleMember = assertTSNamedTupleMember; +exports.assertTSNamespaceExportDeclaration = assertTSNamespaceExportDeclaration; +exports.assertTSNeverKeyword = assertTSNeverKeyword; +exports.assertTSNonNullExpression = assertTSNonNullExpression; +exports.assertTSNullKeyword = assertTSNullKeyword; +exports.assertTSNumberKeyword = assertTSNumberKeyword; +exports.assertTSObjectKeyword = assertTSObjectKeyword; +exports.assertTSOptionalType = assertTSOptionalType; +exports.assertTSParameterProperty = assertTSParameterProperty; +exports.assertTSParenthesizedType = assertTSParenthesizedType; +exports.assertTSPropertySignature = assertTSPropertySignature; +exports.assertTSQualifiedName = assertTSQualifiedName; +exports.assertTSRestType = assertTSRestType; +exports.assertTSStringKeyword = assertTSStringKeyword; +exports.assertTSSymbolKeyword = assertTSSymbolKeyword; +exports.assertTSThisType = assertTSThisType; +exports.assertTSTupleType = assertTSTupleType; +exports.assertTSType = assertTSType; +exports.assertTSTypeAliasDeclaration = assertTSTypeAliasDeclaration; +exports.assertTSTypeAnnotation = assertTSTypeAnnotation; +exports.assertTSTypeAssertion = assertTSTypeAssertion; +exports.assertTSTypeElement = assertTSTypeElement; +exports.assertTSTypeLiteral = assertTSTypeLiteral; +exports.assertTSTypeOperator = assertTSTypeOperator; +exports.assertTSTypeParameter = assertTSTypeParameter; +exports.assertTSTypeParameterDeclaration = assertTSTypeParameterDeclaration; +exports.assertTSTypeParameterInstantiation = assertTSTypeParameterInstantiation; +exports.assertTSTypePredicate = assertTSTypePredicate; +exports.assertTSTypeQuery = assertTSTypeQuery; +exports.assertTSTypeReference = assertTSTypeReference; +exports.assertTSUndefinedKeyword = assertTSUndefinedKeyword; +exports.assertTSUnionType = assertTSUnionType; +exports.assertTSUnknownKeyword = assertTSUnknownKeyword; +exports.assertTSVoidKeyword = assertTSVoidKeyword; +exports.assertTaggedTemplateExpression = assertTaggedTemplateExpression; +exports.assertTemplateElement = assertTemplateElement; +exports.assertTemplateLiteral = assertTemplateLiteral; +exports.assertTerminatorless = assertTerminatorless; +exports.assertThisExpression = assertThisExpression; +exports.assertThisTypeAnnotation = assertThisTypeAnnotation; +exports.assertThrowStatement = assertThrowStatement; +exports.assertTopicReference = assertTopicReference; +exports.assertTryStatement = assertTryStatement; +exports.assertTupleExpression = assertTupleExpression; +exports.assertTupleTypeAnnotation = assertTupleTypeAnnotation; +exports.assertTypeAlias = assertTypeAlias; +exports.assertTypeAnnotation = assertTypeAnnotation; +exports.assertTypeCastExpression = assertTypeCastExpression; +exports.assertTypeParameter = assertTypeParameter; +exports.assertTypeParameterDeclaration = assertTypeParameterDeclaration; +exports.assertTypeParameterInstantiation = assertTypeParameterInstantiation; +exports.assertTypeScript = assertTypeScript; +exports.assertTypeofTypeAnnotation = assertTypeofTypeAnnotation; +exports.assertUnaryExpression = assertUnaryExpression; +exports.assertUnaryLike = assertUnaryLike; +exports.assertUnionTypeAnnotation = assertUnionTypeAnnotation; +exports.assertUpdateExpression = assertUpdateExpression; +exports.assertUserWhitespacable = assertUserWhitespacable; +exports.assertV8IntrinsicIdentifier = assertV8IntrinsicIdentifier; +exports.assertVariableDeclaration = assertVariableDeclaration; +exports.assertVariableDeclarator = assertVariableDeclarator; +exports.assertVariance = assertVariance; +exports.assertVoidTypeAnnotation = assertVoidTypeAnnotation; +exports.assertWhile = assertWhile; +exports.assertWhileStatement = assertWhileStatement; +exports.assertWithStatement = assertWithStatement; +exports.assertYieldExpression = assertYieldExpression; + +var _is = require("../../validators/is"); + +function assert(type, node, opts) { + if (!(0, _is.default)(type, node, opts)) { + throw new Error(`Expected type "${type}" with option ${JSON.stringify(opts)}, ` + `but instead got "${node.type}".`); + } +} + +function assertArrayExpression(node, opts) { + assert("ArrayExpression", node, opts); +} + +function assertAssignmentExpression(node, opts) { + assert("AssignmentExpression", node, opts); +} + +function assertBinaryExpression(node, opts) { + assert("BinaryExpression", node, opts); +} + +function assertInterpreterDirective(node, opts) { + assert("InterpreterDirective", node, opts); +} + +function assertDirective(node, opts) { + assert("Directive", node, opts); +} + +function assertDirectiveLiteral(node, opts) { + assert("DirectiveLiteral", node, opts); +} + +function assertBlockStatement(node, opts) { + assert("BlockStatement", node, opts); +} + +function assertBreakStatement(node, opts) { + assert("BreakStatement", node, opts); +} + +function assertCallExpression(node, opts) { + assert("CallExpression", node, opts); +} + +function assertCatchClause(node, opts) { + assert("CatchClause", node, opts); +} + +function assertConditionalExpression(node, opts) { + assert("ConditionalExpression", node, opts); +} + +function assertContinueStatement(node, opts) { + assert("ContinueStatement", node, opts); +} + +function assertDebuggerStatement(node, opts) { + assert("DebuggerStatement", node, opts); +} + +function assertDoWhileStatement(node, opts) { + assert("DoWhileStatement", node, opts); +} + +function assertEmptyStatement(node, opts) { + assert("EmptyStatement", node, opts); +} + +function assertExpressionStatement(node, opts) { + assert("ExpressionStatement", node, opts); +} + +function assertFile(node, opts) { + assert("File", node, opts); +} + +function assertForInStatement(node, opts) { + assert("ForInStatement", node, opts); +} + +function assertForStatement(node, opts) { + assert("ForStatement", node, opts); +} + +function assertFunctionDeclaration(node, opts) { + assert("FunctionDeclaration", node, opts); +} + +function assertFunctionExpression(node, opts) { + assert("FunctionExpression", node, opts); +} + +function assertIdentifier(node, opts) { + assert("Identifier", node, opts); +} + +function assertIfStatement(node, opts) { + assert("IfStatement", node, opts); +} + +function assertLabeledStatement(node, opts) { + assert("LabeledStatement", node, opts); +} + +function assertStringLiteral(node, opts) { + assert("StringLiteral", node, opts); +} + +function assertNumericLiteral(node, opts) { + assert("NumericLiteral", node, opts); +} + +function assertNullLiteral(node, opts) { + assert("NullLiteral", node, opts); +} + +function assertBooleanLiteral(node, opts) { + assert("BooleanLiteral", node, opts); +} + +function assertRegExpLiteral(node, opts) { + assert("RegExpLiteral", node, opts); +} + +function assertLogicalExpression(node, opts) { + assert("LogicalExpression", node, opts); +} + +function assertMemberExpression(node, opts) { + assert("MemberExpression", node, opts); +} + +function assertNewExpression(node, opts) { + assert("NewExpression", node, opts); +} + +function assertProgram(node, opts) { + assert("Program", node, opts); +} + +function assertObjectExpression(node, opts) { + assert("ObjectExpression", node, opts); +} + +function assertObjectMethod(node, opts) { + assert("ObjectMethod", node, opts); +} + +function assertObjectProperty(node, opts) { + assert("ObjectProperty", node, opts); +} + +function assertRestElement(node, opts) { + assert("RestElement", node, opts); +} + +function assertReturnStatement(node, opts) { + assert("ReturnStatement", node, opts); +} + +function assertSequenceExpression(node, opts) { + assert("SequenceExpression", node, opts); +} + +function assertParenthesizedExpression(node, opts) { + assert("ParenthesizedExpression", node, opts); +} + +function assertSwitchCase(node, opts) { + assert("SwitchCase", node, opts); +} + +function assertSwitchStatement(node, opts) { + assert("SwitchStatement", node, opts); +} + +function assertThisExpression(node, opts) { + assert("ThisExpression", node, opts); +} + +function assertThrowStatement(node, opts) { + assert("ThrowStatement", node, opts); +} + +function assertTryStatement(node, opts) { + assert("TryStatement", node, opts); +} + +function assertUnaryExpression(node, opts) { + assert("UnaryExpression", node, opts); +} + +function assertUpdateExpression(node, opts) { + assert("UpdateExpression", node, opts); +} + +function assertVariableDeclaration(node, opts) { + assert("VariableDeclaration", node, opts); +} + +function assertVariableDeclarator(node, opts) { + assert("VariableDeclarator", node, opts); +} + +function assertWhileStatement(node, opts) { + assert("WhileStatement", node, opts); +} + +function assertWithStatement(node, opts) { + assert("WithStatement", node, opts); +} + +function assertAssignmentPattern(node, opts) { + assert("AssignmentPattern", node, opts); +} + +function assertArrayPattern(node, opts) { + assert("ArrayPattern", node, opts); +} + +function assertArrowFunctionExpression(node, opts) { + assert("ArrowFunctionExpression", node, opts); +} + +function assertClassBody(node, opts) { + assert("ClassBody", node, opts); +} + +function assertClassExpression(node, opts) { + assert("ClassExpression", node, opts); +} + +function assertClassDeclaration(node, opts) { + assert("ClassDeclaration", node, opts); +} + +function assertExportAllDeclaration(node, opts) { + assert("ExportAllDeclaration", node, opts); +} + +function assertExportDefaultDeclaration(node, opts) { + assert("ExportDefaultDeclaration", node, opts); +} + +function assertExportNamedDeclaration(node, opts) { + assert("ExportNamedDeclaration", node, opts); +} + +function assertExportSpecifier(node, opts) { + assert("ExportSpecifier", node, opts); +} + +function assertForOfStatement(node, opts) { + assert("ForOfStatement", node, opts); +} + +function assertImportDeclaration(node, opts) { + assert("ImportDeclaration", node, opts); +} + +function assertImportDefaultSpecifier(node, opts) { + assert("ImportDefaultSpecifier", node, opts); +} + +function assertImportNamespaceSpecifier(node, opts) { + assert("ImportNamespaceSpecifier", node, opts); +} + +function assertImportSpecifier(node, opts) { + assert("ImportSpecifier", node, opts); +} + +function assertMetaProperty(node, opts) { + assert("MetaProperty", node, opts); +} + +function assertClassMethod(node, opts) { + assert("ClassMethod", node, opts); +} + +function assertObjectPattern(node, opts) { + assert("ObjectPattern", node, opts); +} + +function assertSpreadElement(node, opts) { + assert("SpreadElement", node, opts); +} + +function assertSuper(node, opts) { + assert("Super", node, opts); +} + +function assertTaggedTemplateExpression(node, opts) { + assert("TaggedTemplateExpression", node, opts); +} + +function assertTemplateElement(node, opts) { + assert("TemplateElement", node, opts); +} + +function assertTemplateLiteral(node, opts) { + assert("TemplateLiteral", node, opts); +} + +function assertYieldExpression(node, opts) { + assert("YieldExpression", node, opts); +} + +function assertAwaitExpression(node, opts) { + assert("AwaitExpression", node, opts); +} + +function assertImport(node, opts) { + assert("Import", node, opts); +} + +function assertBigIntLiteral(node, opts) { + assert("BigIntLiteral", node, opts); +} + +function assertExportNamespaceSpecifier(node, opts) { + assert("ExportNamespaceSpecifier", node, opts); +} + +function assertOptionalMemberExpression(node, opts) { + assert("OptionalMemberExpression", node, opts); +} + +function assertOptionalCallExpression(node, opts) { + assert("OptionalCallExpression", node, opts); +} + +function assertClassProperty(node, opts) { + assert("ClassProperty", node, opts); +} + +function assertClassAccessorProperty(node, opts) { + assert("ClassAccessorProperty", node, opts); +} + +function assertClassPrivateProperty(node, opts) { + assert("ClassPrivateProperty", node, opts); +} + +function assertClassPrivateMethod(node, opts) { + assert("ClassPrivateMethod", node, opts); +} + +function assertPrivateName(node, opts) { + assert("PrivateName", node, opts); +} + +function assertStaticBlock(node, opts) { + assert("StaticBlock", node, opts); +} + +function assertAnyTypeAnnotation(node, opts) { + assert("AnyTypeAnnotation", node, opts); +} + +function assertArrayTypeAnnotation(node, opts) { + assert("ArrayTypeAnnotation", node, opts); +} + +function assertBooleanTypeAnnotation(node, opts) { + assert("BooleanTypeAnnotation", node, opts); +} + +function assertBooleanLiteralTypeAnnotation(node, opts) { + assert("BooleanLiteralTypeAnnotation", node, opts); +} + +function assertNullLiteralTypeAnnotation(node, opts) { + assert("NullLiteralTypeAnnotation", node, opts); +} + +function assertClassImplements(node, opts) { + assert("ClassImplements", node, opts); +} + +function assertDeclareClass(node, opts) { + assert("DeclareClass", node, opts); +} + +function assertDeclareFunction(node, opts) { + assert("DeclareFunction", node, opts); +} + +function assertDeclareInterface(node, opts) { + assert("DeclareInterface", node, opts); +} + +function assertDeclareModule(node, opts) { + assert("DeclareModule", node, opts); +} + +function assertDeclareModuleExports(node, opts) { + assert("DeclareModuleExports", node, opts); +} + +function assertDeclareTypeAlias(node, opts) { + assert("DeclareTypeAlias", node, opts); +} + +function assertDeclareOpaqueType(node, opts) { + assert("DeclareOpaqueType", node, opts); +} + +function assertDeclareVariable(node, opts) { + assert("DeclareVariable", node, opts); +} + +function assertDeclareExportDeclaration(node, opts) { + assert("DeclareExportDeclaration", node, opts); +} + +function assertDeclareExportAllDeclaration(node, opts) { + assert("DeclareExportAllDeclaration", node, opts); +} + +function assertDeclaredPredicate(node, opts) { + assert("DeclaredPredicate", node, opts); +} + +function assertExistsTypeAnnotation(node, opts) { + assert("ExistsTypeAnnotation", node, opts); +} + +function assertFunctionTypeAnnotation(node, opts) { + assert("FunctionTypeAnnotation", node, opts); +} + +function assertFunctionTypeParam(node, opts) { + assert("FunctionTypeParam", node, opts); +} + +function assertGenericTypeAnnotation(node, opts) { + assert("GenericTypeAnnotation", node, opts); +} + +function assertInferredPredicate(node, opts) { + assert("InferredPredicate", node, opts); +} + +function assertInterfaceExtends(node, opts) { + assert("InterfaceExtends", node, opts); +} + +function assertInterfaceDeclaration(node, opts) { + assert("InterfaceDeclaration", node, opts); +} + +function assertInterfaceTypeAnnotation(node, opts) { + assert("InterfaceTypeAnnotation", node, opts); +} + +function assertIntersectionTypeAnnotation(node, opts) { + assert("IntersectionTypeAnnotation", node, opts); +} + +function assertMixedTypeAnnotation(node, opts) { + assert("MixedTypeAnnotation", node, opts); +} + +function assertEmptyTypeAnnotation(node, opts) { + assert("EmptyTypeAnnotation", node, opts); +} + +function assertNullableTypeAnnotation(node, opts) { + assert("NullableTypeAnnotation", node, opts); +} + +function assertNumberLiteralTypeAnnotation(node, opts) { + assert("NumberLiteralTypeAnnotation", node, opts); +} + +function assertNumberTypeAnnotation(node, opts) { + assert("NumberTypeAnnotation", node, opts); +} + +function assertObjectTypeAnnotation(node, opts) { + assert("ObjectTypeAnnotation", node, opts); +} + +function assertObjectTypeInternalSlot(node, opts) { + assert("ObjectTypeInternalSlot", node, opts); +} + +function assertObjectTypeCallProperty(node, opts) { + assert("ObjectTypeCallProperty", node, opts); +} + +function assertObjectTypeIndexer(node, opts) { + assert("ObjectTypeIndexer", node, opts); +} + +function assertObjectTypeProperty(node, opts) { + assert("ObjectTypeProperty", node, opts); +} + +function assertObjectTypeSpreadProperty(node, opts) { + assert("ObjectTypeSpreadProperty", node, opts); +} + +function assertOpaqueType(node, opts) { + assert("OpaqueType", node, opts); +} + +function assertQualifiedTypeIdentifier(node, opts) { + assert("QualifiedTypeIdentifier", node, opts); +} + +function assertStringLiteralTypeAnnotation(node, opts) { + assert("StringLiteralTypeAnnotation", node, opts); +} + +function assertStringTypeAnnotation(node, opts) { + assert("StringTypeAnnotation", node, opts); +} + +function assertSymbolTypeAnnotation(node, opts) { + assert("SymbolTypeAnnotation", node, opts); +} + +function assertThisTypeAnnotation(node, opts) { + assert("ThisTypeAnnotation", node, opts); +} + +function assertTupleTypeAnnotation(node, opts) { + assert("TupleTypeAnnotation", node, opts); +} + +function assertTypeofTypeAnnotation(node, opts) { + assert("TypeofTypeAnnotation", node, opts); +} + +function assertTypeAlias(node, opts) { + assert("TypeAlias", node, opts); +} + +function assertTypeAnnotation(node, opts) { + assert("TypeAnnotation", node, opts); +} + +function assertTypeCastExpression(node, opts) { + assert("TypeCastExpression", node, opts); +} + +function assertTypeParameter(node, opts) { + assert("TypeParameter", node, opts); +} + +function assertTypeParameterDeclaration(node, opts) { + assert("TypeParameterDeclaration", node, opts); +} + +function assertTypeParameterInstantiation(node, opts) { + assert("TypeParameterInstantiation", node, opts); +} + +function assertUnionTypeAnnotation(node, opts) { + assert("UnionTypeAnnotation", node, opts); +} + +function assertVariance(node, opts) { + assert("Variance", node, opts); +} + +function assertVoidTypeAnnotation(node, opts) { + assert("VoidTypeAnnotation", node, opts); +} + +function assertEnumDeclaration(node, opts) { + assert("EnumDeclaration", node, opts); +} + +function assertEnumBooleanBody(node, opts) { + assert("EnumBooleanBody", node, opts); +} + +function assertEnumNumberBody(node, opts) { + assert("EnumNumberBody", node, opts); +} + +function assertEnumStringBody(node, opts) { + assert("EnumStringBody", node, opts); +} + +function assertEnumSymbolBody(node, opts) { + assert("EnumSymbolBody", node, opts); +} + +function assertEnumBooleanMember(node, opts) { + assert("EnumBooleanMember", node, opts); +} + +function assertEnumNumberMember(node, opts) { + assert("EnumNumberMember", node, opts); +} + +function assertEnumStringMember(node, opts) { + assert("EnumStringMember", node, opts); +} + +function assertEnumDefaultedMember(node, opts) { + assert("EnumDefaultedMember", node, opts); +} + +function assertIndexedAccessType(node, opts) { + assert("IndexedAccessType", node, opts); +} + +function assertOptionalIndexedAccessType(node, opts) { + assert("OptionalIndexedAccessType", node, opts); +} + +function assertJSXAttribute(node, opts) { + assert("JSXAttribute", node, opts); +} + +function assertJSXClosingElement(node, opts) { + assert("JSXClosingElement", node, opts); +} + +function assertJSXElement(node, opts) { + assert("JSXElement", node, opts); +} + +function assertJSXEmptyExpression(node, opts) { + assert("JSXEmptyExpression", node, opts); +} + +function assertJSXExpressionContainer(node, opts) { + assert("JSXExpressionContainer", node, opts); +} + +function assertJSXSpreadChild(node, opts) { + assert("JSXSpreadChild", node, opts); +} + +function assertJSXIdentifier(node, opts) { + assert("JSXIdentifier", node, opts); +} + +function assertJSXMemberExpression(node, opts) { + assert("JSXMemberExpression", node, opts); +} + +function assertJSXNamespacedName(node, opts) { + assert("JSXNamespacedName", node, opts); +} + +function assertJSXOpeningElement(node, opts) { + assert("JSXOpeningElement", node, opts); +} + +function assertJSXSpreadAttribute(node, opts) { + assert("JSXSpreadAttribute", node, opts); +} + +function assertJSXText(node, opts) { + assert("JSXText", node, opts); +} + +function assertJSXFragment(node, opts) { + assert("JSXFragment", node, opts); +} + +function assertJSXOpeningFragment(node, opts) { + assert("JSXOpeningFragment", node, opts); +} + +function assertJSXClosingFragment(node, opts) { + assert("JSXClosingFragment", node, opts); +} + +function assertNoop(node, opts) { + assert("Noop", node, opts); +} + +function assertPlaceholder(node, opts) { + assert("Placeholder", node, opts); +} + +function assertV8IntrinsicIdentifier(node, opts) { + assert("V8IntrinsicIdentifier", node, opts); +} + +function assertArgumentPlaceholder(node, opts) { + assert("ArgumentPlaceholder", node, opts); +} + +function assertBindExpression(node, opts) { + assert("BindExpression", node, opts); +} + +function assertImportAttribute(node, opts) { + assert("ImportAttribute", node, opts); +} + +function assertDecorator(node, opts) { + assert("Decorator", node, opts); +} + +function assertDoExpression(node, opts) { + assert("DoExpression", node, opts); +} + +function assertExportDefaultSpecifier(node, opts) { + assert("ExportDefaultSpecifier", node, opts); +} + +function assertRecordExpression(node, opts) { + assert("RecordExpression", node, opts); +} + +function assertTupleExpression(node, opts) { + assert("TupleExpression", node, opts); +} + +function assertDecimalLiteral(node, opts) { + assert("DecimalLiteral", node, opts); +} + +function assertModuleExpression(node, opts) { + assert("ModuleExpression", node, opts); +} + +function assertTopicReference(node, opts) { + assert("TopicReference", node, opts); +} + +function assertPipelineTopicExpression(node, opts) { + assert("PipelineTopicExpression", node, opts); +} + +function assertPipelineBareFunction(node, opts) { + assert("PipelineBareFunction", node, opts); +} + +function assertPipelinePrimaryTopicReference(node, opts) { + assert("PipelinePrimaryTopicReference", node, opts); +} + +function assertTSParameterProperty(node, opts) { + assert("TSParameterProperty", node, opts); +} + +function assertTSDeclareFunction(node, opts) { + assert("TSDeclareFunction", node, opts); +} + +function assertTSDeclareMethod(node, opts) { + assert("TSDeclareMethod", node, opts); +} + +function assertTSQualifiedName(node, opts) { + assert("TSQualifiedName", node, opts); +} + +function assertTSCallSignatureDeclaration(node, opts) { + assert("TSCallSignatureDeclaration", node, opts); +} + +function assertTSConstructSignatureDeclaration(node, opts) { + assert("TSConstructSignatureDeclaration", node, opts); +} + +function assertTSPropertySignature(node, opts) { + assert("TSPropertySignature", node, opts); +} + +function assertTSMethodSignature(node, opts) { + assert("TSMethodSignature", node, opts); +} + +function assertTSIndexSignature(node, opts) { + assert("TSIndexSignature", node, opts); +} + +function assertTSAnyKeyword(node, opts) { + assert("TSAnyKeyword", node, opts); +} + +function assertTSBooleanKeyword(node, opts) { + assert("TSBooleanKeyword", node, opts); +} + +function assertTSBigIntKeyword(node, opts) { + assert("TSBigIntKeyword", node, opts); +} + +function assertTSIntrinsicKeyword(node, opts) { + assert("TSIntrinsicKeyword", node, opts); +} + +function assertTSNeverKeyword(node, opts) { + assert("TSNeverKeyword", node, opts); +} + +function assertTSNullKeyword(node, opts) { + assert("TSNullKeyword", node, opts); +} + +function assertTSNumberKeyword(node, opts) { + assert("TSNumberKeyword", node, opts); +} + +function assertTSObjectKeyword(node, opts) { + assert("TSObjectKeyword", node, opts); +} + +function assertTSStringKeyword(node, opts) { + assert("TSStringKeyword", node, opts); +} + +function assertTSSymbolKeyword(node, opts) { + assert("TSSymbolKeyword", node, opts); +} + +function assertTSUndefinedKeyword(node, opts) { + assert("TSUndefinedKeyword", node, opts); +} + +function assertTSUnknownKeyword(node, opts) { + assert("TSUnknownKeyword", node, opts); +} + +function assertTSVoidKeyword(node, opts) { + assert("TSVoidKeyword", node, opts); +} + +function assertTSThisType(node, opts) { + assert("TSThisType", node, opts); +} + +function assertTSFunctionType(node, opts) { + assert("TSFunctionType", node, opts); +} + +function assertTSConstructorType(node, opts) { + assert("TSConstructorType", node, opts); +} + +function assertTSTypeReference(node, opts) { + assert("TSTypeReference", node, opts); +} + +function assertTSTypePredicate(node, opts) { + assert("TSTypePredicate", node, opts); +} + +function assertTSTypeQuery(node, opts) { + assert("TSTypeQuery", node, opts); +} + +function assertTSTypeLiteral(node, opts) { + assert("TSTypeLiteral", node, opts); +} + +function assertTSArrayType(node, opts) { + assert("TSArrayType", node, opts); +} + +function assertTSTupleType(node, opts) { + assert("TSTupleType", node, opts); +} + +function assertTSOptionalType(node, opts) { + assert("TSOptionalType", node, opts); +} + +function assertTSRestType(node, opts) { + assert("TSRestType", node, opts); +} + +function assertTSNamedTupleMember(node, opts) { + assert("TSNamedTupleMember", node, opts); +} + +function assertTSUnionType(node, opts) { + assert("TSUnionType", node, opts); +} + +function assertTSIntersectionType(node, opts) { + assert("TSIntersectionType", node, opts); +} + +function assertTSConditionalType(node, opts) { + assert("TSConditionalType", node, opts); +} + +function assertTSInferType(node, opts) { + assert("TSInferType", node, opts); +} + +function assertTSParenthesizedType(node, opts) { + assert("TSParenthesizedType", node, opts); +} + +function assertTSTypeOperator(node, opts) { + assert("TSTypeOperator", node, opts); +} + +function assertTSIndexedAccessType(node, opts) { + assert("TSIndexedAccessType", node, opts); +} + +function assertTSMappedType(node, opts) { + assert("TSMappedType", node, opts); +} + +function assertTSLiteralType(node, opts) { + assert("TSLiteralType", node, opts); +} + +function assertTSExpressionWithTypeArguments(node, opts) { + assert("TSExpressionWithTypeArguments", node, opts); +} + +function assertTSInterfaceDeclaration(node, opts) { + assert("TSInterfaceDeclaration", node, opts); +} + +function assertTSInterfaceBody(node, opts) { + assert("TSInterfaceBody", node, opts); +} + +function assertTSTypeAliasDeclaration(node, opts) { + assert("TSTypeAliasDeclaration", node, opts); +} + +function assertTSAsExpression(node, opts) { + assert("TSAsExpression", node, opts); +} + +function assertTSTypeAssertion(node, opts) { + assert("TSTypeAssertion", node, opts); +} + +function assertTSEnumDeclaration(node, opts) { + assert("TSEnumDeclaration", node, opts); +} + +function assertTSEnumMember(node, opts) { + assert("TSEnumMember", node, opts); +} + +function assertTSModuleDeclaration(node, opts) { + assert("TSModuleDeclaration", node, opts); +} + +function assertTSModuleBlock(node, opts) { + assert("TSModuleBlock", node, opts); +} + +function assertTSImportType(node, opts) { + assert("TSImportType", node, opts); +} + +function assertTSImportEqualsDeclaration(node, opts) { + assert("TSImportEqualsDeclaration", node, opts); +} + +function assertTSExternalModuleReference(node, opts) { + assert("TSExternalModuleReference", node, opts); +} + +function assertTSNonNullExpression(node, opts) { + assert("TSNonNullExpression", node, opts); +} + +function assertTSExportAssignment(node, opts) { + assert("TSExportAssignment", node, opts); +} + +function assertTSNamespaceExportDeclaration(node, opts) { + assert("TSNamespaceExportDeclaration", node, opts); +} + +function assertTSTypeAnnotation(node, opts) { + assert("TSTypeAnnotation", node, opts); +} + +function assertTSTypeParameterInstantiation(node, opts) { + assert("TSTypeParameterInstantiation", node, opts); +} + +function assertTSTypeParameterDeclaration(node, opts) { + assert("TSTypeParameterDeclaration", node, opts); +} + +function assertTSTypeParameter(node, opts) { + assert("TSTypeParameter", node, opts); +} + +function assertStandardized(node, opts) { + assert("Standardized", node, opts); +} + +function assertExpression(node, opts) { + assert("Expression", node, opts); +} + +function assertBinary(node, opts) { + assert("Binary", node, opts); +} + +function assertScopable(node, opts) { + assert("Scopable", node, opts); +} + +function assertBlockParent(node, opts) { + assert("BlockParent", node, opts); +} + +function assertBlock(node, opts) { + assert("Block", node, opts); +} + +function assertStatement(node, opts) { + assert("Statement", node, opts); +} + +function assertTerminatorless(node, opts) { + assert("Terminatorless", node, opts); +} + +function assertCompletionStatement(node, opts) { + assert("CompletionStatement", node, opts); +} + +function assertConditional(node, opts) { + assert("Conditional", node, opts); +} + +function assertLoop(node, opts) { + assert("Loop", node, opts); +} + +function assertWhile(node, opts) { + assert("While", node, opts); +} + +function assertExpressionWrapper(node, opts) { + assert("ExpressionWrapper", node, opts); +} + +function assertFor(node, opts) { + assert("For", node, opts); +} + +function assertForXStatement(node, opts) { + assert("ForXStatement", node, opts); +} + +function assertFunction(node, opts) { + assert("Function", node, opts); +} + +function assertFunctionParent(node, opts) { + assert("FunctionParent", node, opts); +} + +function assertPureish(node, opts) { + assert("Pureish", node, opts); +} + +function assertDeclaration(node, opts) { + assert("Declaration", node, opts); +} + +function assertPatternLike(node, opts) { + assert("PatternLike", node, opts); +} + +function assertLVal(node, opts) { + assert("LVal", node, opts); +} + +function assertTSEntityName(node, opts) { + assert("TSEntityName", node, opts); +} + +function assertLiteral(node, opts) { + assert("Literal", node, opts); +} + +function assertImmutable(node, opts) { + assert("Immutable", node, opts); +} + +function assertUserWhitespacable(node, opts) { + assert("UserWhitespacable", node, opts); +} + +function assertMethod(node, opts) { + assert("Method", node, opts); +} + +function assertObjectMember(node, opts) { + assert("ObjectMember", node, opts); +} + +function assertProperty(node, opts) { + assert("Property", node, opts); +} + +function assertUnaryLike(node, opts) { + assert("UnaryLike", node, opts); +} + +function assertPattern(node, opts) { + assert("Pattern", node, opts); +} + +function assertClass(node, opts) { + assert("Class", node, opts); +} + +function assertModuleDeclaration(node, opts) { + assert("ModuleDeclaration", node, opts); +} + +function assertExportDeclaration(node, opts) { + assert("ExportDeclaration", node, opts); +} + +function assertModuleSpecifier(node, opts) { + assert("ModuleSpecifier", node, opts); +} + +function assertAccessor(node, opts) { + assert("Accessor", node, opts); +} + +function assertPrivate(node, opts) { + assert("Private", node, opts); +} + +function assertFlow(node, opts) { + assert("Flow", node, opts); +} + +function assertFlowType(node, opts) { + assert("FlowType", node, opts); +} + +function assertFlowBaseAnnotation(node, opts) { + assert("FlowBaseAnnotation", node, opts); +} + +function assertFlowDeclaration(node, opts) { + assert("FlowDeclaration", node, opts); +} + +function assertFlowPredicate(node, opts) { + assert("FlowPredicate", node, opts); +} + +function assertEnumBody(node, opts) { + assert("EnumBody", node, opts); +} + +function assertEnumMember(node, opts) { + assert("EnumMember", node, opts); +} + +function assertJSX(node, opts) { + assert("JSX", node, opts); +} + +function assertMiscellaneous(node, opts) { + assert("Miscellaneous", node, opts); +} + +function assertTypeScript(node, opts) { + assert("TypeScript", node, opts); +} + +function assertTSTypeElement(node, opts) { + assert("TSTypeElement", node, opts); +} + +function assertTSType(node, opts) { + assert("TSType", node, opts); +} + +function assertTSBaseType(node, opts) { + assert("TSBaseType", node, opts); +} + +function assertNumberLiteral(node, opts) { + console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); + assert("NumberLiteral", node, opts); +} + +function assertRegexLiteral(node, opts) { + console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); + assert("RegexLiteral", node, opts); +} + +function assertRestProperty(node, opts) { + console.trace("The node type RestProperty has been renamed to RestElement"); + assert("RestProperty", node, opts); +} + +function assertSpreadProperty(node, opts) { + console.trace("The node type SpreadProperty has been renamed to SpreadElement"); + assert("SpreadProperty", node, opts); +} \ No newline at end of file diff --git a/node_modules/@babel/types/lib/ast-types/generated/index.js b/node_modules/@babel/types/lib/ast-types/generated/index.js new file mode 100644 index 000000000..e69de29bb diff --git a/node_modules/@babel/types/lib/builders/generated/index.js b/node_modules/@babel/types/lib/builders/generated/index.js new file mode 100644 index 000000000..99851ee0b --- /dev/null +++ b/node_modules/@babel/types/lib/builders/generated/index.js @@ -0,0 +1,1266 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.anyTypeAnnotation = anyTypeAnnotation; +exports.argumentPlaceholder = argumentPlaceholder; +exports.arrayExpression = arrayExpression; +exports.arrayPattern = arrayPattern; +exports.arrayTypeAnnotation = arrayTypeAnnotation; +exports.arrowFunctionExpression = arrowFunctionExpression; +exports.assignmentExpression = assignmentExpression; +exports.assignmentPattern = assignmentPattern; +exports.awaitExpression = awaitExpression; +exports.bigIntLiteral = bigIntLiteral; +exports.binaryExpression = binaryExpression; +exports.bindExpression = bindExpression; +exports.blockStatement = blockStatement; +exports.booleanLiteral = booleanLiteral; +exports.booleanLiteralTypeAnnotation = booleanLiteralTypeAnnotation; +exports.booleanTypeAnnotation = booleanTypeAnnotation; +exports.breakStatement = breakStatement; +exports.callExpression = callExpression; +exports.catchClause = catchClause; +exports.classAccessorProperty = classAccessorProperty; +exports.classBody = classBody; +exports.classDeclaration = classDeclaration; +exports.classExpression = classExpression; +exports.classImplements = classImplements; +exports.classMethod = classMethod; +exports.classPrivateMethod = classPrivateMethod; +exports.classPrivateProperty = classPrivateProperty; +exports.classProperty = classProperty; +exports.conditionalExpression = conditionalExpression; +exports.continueStatement = continueStatement; +exports.debuggerStatement = debuggerStatement; +exports.decimalLiteral = decimalLiteral; +exports.declareClass = declareClass; +exports.declareExportAllDeclaration = declareExportAllDeclaration; +exports.declareExportDeclaration = declareExportDeclaration; +exports.declareFunction = declareFunction; +exports.declareInterface = declareInterface; +exports.declareModule = declareModule; +exports.declareModuleExports = declareModuleExports; +exports.declareOpaqueType = declareOpaqueType; +exports.declareTypeAlias = declareTypeAlias; +exports.declareVariable = declareVariable; +exports.declaredPredicate = declaredPredicate; +exports.decorator = decorator; +exports.directive = directive; +exports.directiveLiteral = directiveLiteral; +exports.doExpression = doExpression; +exports.doWhileStatement = doWhileStatement; +exports.emptyStatement = emptyStatement; +exports.emptyTypeAnnotation = emptyTypeAnnotation; +exports.enumBooleanBody = enumBooleanBody; +exports.enumBooleanMember = enumBooleanMember; +exports.enumDeclaration = enumDeclaration; +exports.enumDefaultedMember = enumDefaultedMember; +exports.enumNumberBody = enumNumberBody; +exports.enumNumberMember = enumNumberMember; +exports.enumStringBody = enumStringBody; +exports.enumStringMember = enumStringMember; +exports.enumSymbolBody = enumSymbolBody; +exports.existsTypeAnnotation = existsTypeAnnotation; +exports.exportAllDeclaration = exportAllDeclaration; +exports.exportDefaultDeclaration = exportDefaultDeclaration; +exports.exportDefaultSpecifier = exportDefaultSpecifier; +exports.exportNamedDeclaration = exportNamedDeclaration; +exports.exportNamespaceSpecifier = exportNamespaceSpecifier; +exports.exportSpecifier = exportSpecifier; +exports.expressionStatement = expressionStatement; +exports.file = file; +exports.forInStatement = forInStatement; +exports.forOfStatement = forOfStatement; +exports.forStatement = forStatement; +exports.functionDeclaration = functionDeclaration; +exports.functionExpression = functionExpression; +exports.functionTypeAnnotation = functionTypeAnnotation; +exports.functionTypeParam = functionTypeParam; +exports.genericTypeAnnotation = genericTypeAnnotation; +exports.identifier = identifier; +exports.ifStatement = ifStatement; +exports.import = _import; +exports.importAttribute = importAttribute; +exports.importDeclaration = importDeclaration; +exports.importDefaultSpecifier = importDefaultSpecifier; +exports.importNamespaceSpecifier = importNamespaceSpecifier; +exports.importSpecifier = importSpecifier; +exports.indexedAccessType = indexedAccessType; +exports.inferredPredicate = inferredPredicate; +exports.interfaceDeclaration = interfaceDeclaration; +exports.interfaceExtends = interfaceExtends; +exports.interfaceTypeAnnotation = interfaceTypeAnnotation; +exports.interpreterDirective = interpreterDirective; +exports.intersectionTypeAnnotation = intersectionTypeAnnotation; +exports.jSXAttribute = exports.jsxAttribute = jsxAttribute; +exports.jSXClosingElement = exports.jsxClosingElement = jsxClosingElement; +exports.jSXClosingFragment = exports.jsxClosingFragment = jsxClosingFragment; +exports.jSXElement = exports.jsxElement = jsxElement; +exports.jSXEmptyExpression = exports.jsxEmptyExpression = jsxEmptyExpression; +exports.jSXExpressionContainer = exports.jsxExpressionContainer = jsxExpressionContainer; +exports.jSXFragment = exports.jsxFragment = jsxFragment; +exports.jSXIdentifier = exports.jsxIdentifier = jsxIdentifier; +exports.jSXMemberExpression = exports.jsxMemberExpression = jsxMemberExpression; +exports.jSXNamespacedName = exports.jsxNamespacedName = jsxNamespacedName; +exports.jSXOpeningElement = exports.jsxOpeningElement = jsxOpeningElement; +exports.jSXOpeningFragment = exports.jsxOpeningFragment = jsxOpeningFragment; +exports.jSXSpreadAttribute = exports.jsxSpreadAttribute = jsxSpreadAttribute; +exports.jSXSpreadChild = exports.jsxSpreadChild = jsxSpreadChild; +exports.jSXText = exports.jsxText = jsxText; +exports.labeledStatement = labeledStatement; +exports.logicalExpression = logicalExpression; +exports.memberExpression = memberExpression; +exports.metaProperty = metaProperty; +exports.mixedTypeAnnotation = mixedTypeAnnotation; +exports.moduleExpression = moduleExpression; +exports.newExpression = newExpression; +exports.noop = noop; +exports.nullLiteral = nullLiteral; +exports.nullLiteralTypeAnnotation = nullLiteralTypeAnnotation; +exports.nullableTypeAnnotation = nullableTypeAnnotation; +exports.numberLiteral = NumberLiteral; +exports.numberLiteralTypeAnnotation = numberLiteralTypeAnnotation; +exports.numberTypeAnnotation = numberTypeAnnotation; +exports.numericLiteral = numericLiteral; +exports.objectExpression = objectExpression; +exports.objectMethod = objectMethod; +exports.objectPattern = objectPattern; +exports.objectProperty = objectProperty; +exports.objectTypeAnnotation = objectTypeAnnotation; +exports.objectTypeCallProperty = objectTypeCallProperty; +exports.objectTypeIndexer = objectTypeIndexer; +exports.objectTypeInternalSlot = objectTypeInternalSlot; +exports.objectTypeProperty = objectTypeProperty; +exports.objectTypeSpreadProperty = objectTypeSpreadProperty; +exports.opaqueType = opaqueType; +exports.optionalCallExpression = optionalCallExpression; +exports.optionalIndexedAccessType = optionalIndexedAccessType; +exports.optionalMemberExpression = optionalMemberExpression; +exports.parenthesizedExpression = parenthesizedExpression; +exports.pipelineBareFunction = pipelineBareFunction; +exports.pipelinePrimaryTopicReference = pipelinePrimaryTopicReference; +exports.pipelineTopicExpression = pipelineTopicExpression; +exports.placeholder = placeholder; +exports.privateName = privateName; +exports.program = program; +exports.qualifiedTypeIdentifier = qualifiedTypeIdentifier; +exports.recordExpression = recordExpression; +exports.regExpLiteral = regExpLiteral; +exports.regexLiteral = RegexLiteral; +exports.restElement = restElement; +exports.restProperty = RestProperty; +exports.returnStatement = returnStatement; +exports.sequenceExpression = sequenceExpression; +exports.spreadElement = spreadElement; +exports.spreadProperty = SpreadProperty; +exports.staticBlock = staticBlock; +exports.stringLiteral = stringLiteral; +exports.stringLiteralTypeAnnotation = stringLiteralTypeAnnotation; +exports.stringTypeAnnotation = stringTypeAnnotation; +exports.super = _super; +exports.switchCase = switchCase; +exports.switchStatement = switchStatement; +exports.symbolTypeAnnotation = symbolTypeAnnotation; +exports.taggedTemplateExpression = taggedTemplateExpression; +exports.templateElement = templateElement; +exports.templateLiteral = templateLiteral; +exports.thisExpression = thisExpression; +exports.thisTypeAnnotation = thisTypeAnnotation; +exports.throwStatement = throwStatement; +exports.topicReference = topicReference; +exports.tryStatement = tryStatement; +exports.tSAnyKeyword = exports.tsAnyKeyword = tsAnyKeyword; +exports.tSArrayType = exports.tsArrayType = tsArrayType; +exports.tSAsExpression = exports.tsAsExpression = tsAsExpression; +exports.tSBigIntKeyword = exports.tsBigIntKeyword = tsBigIntKeyword; +exports.tSBooleanKeyword = exports.tsBooleanKeyword = tsBooleanKeyword; +exports.tSCallSignatureDeclaration = exports.tsCallSignatureDeclaration = tsCallSignatureDeclaration; +exports.tSConditionalType = exports.tsConditionalType = tsConditionalType; +exports.tSConstructSignatureDeclaration = exports.tsConstructSignatureDeclaration = tsConstructSignatureDeclaration; +exports.tSConstructorType = exports.tsConstructorType = tsConstructorType; +exports.tSDeclareFunction = exports.tsDeclareFunction = tsDeclareFunction; +exports.tSDeclareMethod = exports.tsDeclareMethod = tsDeclareMethod; +exports.tSEnumDeclaration = exports.tsEnumDeclaration = tsEnumDeclaration; +exports.tSEnumMember = exports.tsEnumMember = tsEnumMember; +exports.tSExportAssignment = exports.tsExportAssignment = tsExportAssignment; +exports.tSExpressionWithTypeArguments = exports.tsExpressionWithTypeArguments = tsExpressionWithTypeArguments; +exports.tSExternalModuleReference = exports.tsExternalModuleReference = tsExternalModuleReference; +exports.tSFunctionType = exports.tsFunctionType = tsFunctionType; +exports.tSImportEqualsDeclaration = exports.tsImportEqualsDeclaration = tsImportEqualsDeclaration; +exports.tSImportType = exports.tsImportType = tsImportType; +exports.tSIndexSignature = exports.tsIndexSignature = tsIndexSignature; +exports.tSIndexedAccessType = exports.tsIndexedAccessType = tsIndexedAccessType; +exports.tSInferType = exports.tsInferType = tsInferType; +exports.tSInterfaceBody = exports.tsInterfaceBody = tsInterfaceBody; +exports.tSInterfaceDeclaration = exports.tsInterfaceDeclaration = tsInterfaceDeclaration; +exports.tSIntersectionType = exports.tsIntersectionType = tsIntersectionType; +exports.tSIntrinsicKeyword = exports.tsIntrinsicKeyword = tsIntrinsicKeyword; +exports.tSLiteralType = exports.tsLiteralType = tsLiteralType; +exports.tSMappedType = exports.tsMappedType = tsMappedType; +exports.tSMethodSignature = exports.tsMethodSignature = tsMethodSignature; +exports.tSModuleBlock = exports.tsModuleBlock = tsModuleBlock; +exports.tSModuleDeclaration = exports.tsModuleDeclaration = tsModuleDeclaration; +exports.tSNamedTupleMember = exports.tsNamedTupleMember = tsNamedTupleMember; +exports.tSNamespaceExportDeclaration = exports.tsNamespaceExportDeclaration = tsNamespaceExportDeclaration; +exports.tSNeverKeyword = exports.tsNeverKeyword = tsNeverKeyword; +exports.tSNonNullExpression = exports.tsNonNullExpression = tsNonNullExpression; +exports.tSNullKeyword = exports.tsNullKeyword = tsNullKeyword; +exports.tSNumberKeyword = exports.tsNumberKeyword = tsNumberKeyword; +exports.tSObjectKeyword = exports.tsObjectKeyword = tsObjectKeyword; +exports.tSOptionalType = exports.tsOptionalType = tsOptionalType; +exports.tSParameterProperty = exports.tsParameterProperty = tsParameterProperty; +exports.tSParenthesizedType = exports.tsParenthesizedType = tsParenthesizedType; +exports.tSPropertySignature = exports.tsPropertySignature = tsPropertySignature; +exports.tSQualifiedName = exports.tsQualifiedName = tsQualifiedName; +exports.tSRestType = exports.tsRestType = tsRestType; +exports.tSStringKeyword = exports.tsStringKeyword = tsStringKeyword; +exports.tSSymbolKeyword = exports.tsSymbolKeyword = tsSymbolKeyword; +exports.tSThisType = exports.tsThisType = tsThisType; +exports.tSTupleType = exports.tsTupleType = tsTupleType; +exports.tSTypeAliasDeclaration = exports.tsTypeAliasDeclaration = tsTypeAliasDeclaration; +exports.tSTypeAnnotation = exports.tsTypeAnnotation = tsTypeAnnotation; +exports.tSTypeAssertion = exports.tsTypeAssertion = tsTypeAssertion; +exports.tSTypeLiteral = exports.tsTypeLiteral = tsTypeLiteral; +exports.tSTypeOperator = exports.tsTypeOperator = tsTypeOperator; +exports.tSTypeParameter = exports.tsTypeParameter = tsTypeParameter; +exports.tSTypeParameterDeclaration = exports.tsTypeParameterDeclaration = tsTypeParameterDeclaration; +exports.tSTypeParameterInstantiation = exports.tsTypeParameterInstantiation = tsTypeParameterInstantiation; +exports.tSTypePredicate = exports.tsTypePredicate = tsTypePredicate; +exports.tSTypeQuery = exports.tsTypeQuery = tsTypeQuery; +exports.tSTypeReference = exports.tsTypeReference = tsTypeReference; +exports.tSUndefinedKeyword = exports.tsUndefinedKeyword = tsUndefinedKeyword; +exports.tSUnionType = exports.tsUnionType = tsUnionType; +exports.tSUnknownKeyword = exports.tsUnknownKeyword = tsUnknownKeyword; +exports.tSVoidKeyword = exports.tsVoidKeyword = tsVoidKeyword; +exports.tupleExpression = tupleExpression; +exports.tupleTypeAnnotation = tupleTypeAnnotation; +exports.typeAlias = typeAlias; +exports.typeAnnotation = typeAnnotation; +exports.typeCastExpression = typeCastExpression; +exports.typeParameter = typeParameter; +exports.typeParameterDeclaration = typeParameterDeclaration; +exports.typeParameterInstantiation = typeParameterInstantiation; +exports.typeofTypeAnnotation = typeofTypeAnnotation; +exports.unaryExpression = unaryExpression; +exports.unionTypeAnnotation = unionTypeAnnotation; +exports.updateExpression = updateExpression; +exports.v8IntrinsicIdentifier = v8IntrinsicIdentifier; +exports.variableDeclaration = variableDeclaration; +exports.variableDeclarator = variableDeclarator; +exports.variance = variance; +exports.voidTypeAnnotation = voidTypeAnnotation; +exports.whileStatement = whileStatement; +exports.withStatement = withStatement; +exports.yieldExpression = yieldExpression; + +var _builder = require("../builder"); + +function arrayExpression(elements) { + return _builder.default.apply("ArrayExpression", arguments); +} + +function assignmentExpression(operator, left, right) { + return _builder.default.apply("AssignmentExpression", arguments); +} + +function binaryExpression(operator, left, right) { + return _builder.default.apply("BinaryExpression", arguments); +} + +function interpreterDirective(value) { + return _builder.default.apply("InterpreterDirective", arguments); +} + +function directive(value) { + return _builder.default.apply("Directive", arguments); +} + +function directiveLiteral(value) { + return _builder.default.apply("DirectiveLiteral", arguments); +} + +function blockStatement(body, directives) { + return _builder.default.apply("BlockStatement", arguments); +} + +function breakStatement(label) { + return _builder.default.apply("BreakStatement", arguments); +} + +function callExpression(callee, _arguments) { + return _builder.default.apply("CallExpression", arguments); +} + +function catchClause(param, body) { + return _builder.default.apply("CatchClause", arguments); +} + +function conditionalExpression(test, consequent, alternate) { + return _builder.default.apply("ConditionalExpression", arguments); +} + +function continueStatement(label) { + return _builder.default.apply("ContinueStatement", arguments); +} + +function debuggerStatement() { + return _builder.default.apply("DebuggerStatement", arguments); +} + +function doWhileStatement(test, body) { + return _builder.default.apply("DoWhileStatement", arguments); +} + +function emptyStatement() { + return _builder.default.apply("EmptyStatement", arguments); +} + +function expressionStatement(expression) { + return _builder.default.apply("ExpressionStatement", arguments); +} + +function file(program, comments, tokens) { + return _builder.default.apply("File", arguments); +} + +function forInStatement(left, right, body) { + return _builder.default.apply("ForInStatement", arguments); +} + +function forStatement(init, test, update, body) { + return _builder.default.apply("ForStatement", arguments); +} + +function functionDeclaration(id, params, body, generator, async) { + return _builder.default.apply("FunctionDeclaration", arguments); +} + +function functionExpression(id, params, body, generator, async) { + return _builder.default.apply("FunctionExpression", arguments); +} + +function identifier(name) { + return _builder.default.apply("Identifier", arguments); +} + +function ifStatement(test, consequent, alternate) { + return _builder.default.apply("IfStatement", arguments); +} + +function labeledStatement(label, body) { + return _builder.default.apply("LabeledStatement", arguments); +} + +function stringLiteral(value) { + return _builder.default.apply("StringLiteral", arguments); +} + +function numericLiteral(value) { + return _builder.default.apply("NumericLiteral", arguments); +} + +function nullLiteral() { + return _builder.default.apply("NullLiteral", arguments); +} + +function booleanLiteral(value) { + return _builder.default.apply("BooleanLiteral", arguments); +} + +function regExpLiteral(pattern, flags) { + return _builder.default.apply("RegExpLiteral", arguments); +} + +function logicalExpression(operator, left, right) { + return _builder.default.apply("LogicalExpression", arguments); +} + +function memberExpression(object, property, computed, optional) { + return _builder.default.apply("MemberExpression", arguments); +} + +function newExpression(callee, _arguments) { + return _builder.default.apply("NewExpression", arguments); +} + +function program(body, directives, sourceType, interpreter) { + return _builder.default.apply("Program", arguments); +} + +function objectExpression(properties) { + return _builder.default.apply("ObjectExpression", arguments); +} + +function objectMethod(kind, key, params, body, computed, generator, async) { + return _builder.default.apply("ObjectMethod", arguments); +} + +function objectProperty(key, value, computed, shorthand, decorators) { + return _builder.default.apply("ObjectProperty", arguments); +} + +function restElement(argument) { + return _builder.default.apply("RestElement", arguments); +} + +function returnStatement(argument) { + return _builder.default.apply("ReturnStatement", arguments); +} + +function sequenceExpression(expressions) { + return _builder.default.apply("SequenceExpression", arguments); +} + +function parenthesizedExpression(expression) { + return _builder.default.apply("ParenthesizedExpression", arguments); +} + +function switchCase(test, consequent) { + return _builder.default.apply("SwitchCase", arguments); +} + +function switchStatement(discriminant, cases) { + return _builder.default.apply("SwitchStatement", arguments); +} + +function thisExpression() { + return _builder.default.apply("ThisExpression", arguments); +} + +function throwStatement(argument) { + return _builder.default.apply("ThrowStatement", arguments); +} + +function tryStatement(block, handler, finalizer) { + return _builder.default.apply("TryStatement", arguments); +} + +function unaryExpression(operator, argument, prefix) { + return _builder.default.apply("UnaryExpression", arguments); +} + +function updateExpression(operator, argument, prefix) { + return _builder.default.apply("UpdateExpression", arguments); +} + +function variableDeclaration(kind, declarations) { + return _builder.default.apply("VariableDeclaration", arguments); +} + +function variableDeclarator(id, init) { + return _builder.default.apply("VariableDeclarator", arguments); +} + +function whileStatement(test, body) { + return _builder.default.apply("WhileStatement", arguments); +} + +function withStatement(object, body) { + return _builder.default.apply("WithStatement", arguments); +} + +function assignmentPattern(left, right) { + return _builder.default.apply("AssignmentPattern", arguments); +} + +function arrayPattern(elements) { + return _builder.default.apply("ArrayPattern", arguments); +} + +function arrowFunctionExpression(params, body, async) { + return _builder.default.apply("ArrowFunctionExpression", arguments); +} + +function classBody(body) { + return _builder.default.apply("ClassBody", arguments); +} + +function classExpression(id, superClass, body, decorators) { + return _builder.default.apply("ClassExpression", arguments); +} + +function classDeclaration(id, superClass, body, decorators) { + return _builder.default.apply("ClassDeclaration", arguments); +} + +function exportAllDeclaration(source) { + return _builder.default.apply("ExportAllDeclaration", arguments); +} + +function exportDefaultDeclaration(declaration) { + return _builder.default.apply("ExportDefaultDeclaration", arguments); +} + +function exportNamedDeclaration(declaration, specifiers, source) { + return _builder.default.apply("ExportNamedDeclaration", arguments); +} + +function exportSpecifier(local, exported) { + return _builder.default.apply("ExportSpecifier", arguments); +} + +function forOfStatement(left, right, body, _await) { + return _builder.default.apply("ForOfStatement", arguments); +} + +function importDeclaration(specifiers, source) { + return _builder.default.apply("ImportDeclaration", arguments); +} + +function importDefaultSpecifier(local) { + return _builder.default.apply("ImportDefaultSpecifier", arguments); +} + +function importNamespaceSpecifier(local) { + return _builder.default.apply("ImportNamespaceSpecifier", arguments); +} + +function importSpecifier(local, imported) { + return _builder.default.apply("ImportSpecifier", arguments); +} + +function metaProperty(meta, property) { + return _builder.default.apply("MetaProperty", arguments); +} + +function classMethod(kind, key, params, body, computed, _static, generator, async) { + return _builder.default.apply("ClassMethod", arguments); +} + +function objectPattern(properties) { + return _builder.default.apply("ObjectPattern", arguments); +} + +function spreadElement(argument) { + return _builder.default.apply("SpreadElement", arguments); +} + +function _super() { + return _builder.default.apply("Super", arguments); +} + +function taggedTemplateExpression(tag, quasi) { + return _builder.default.apply("TaggedTemplateExpression", arguments); +} + +function templateElement(value, tail) { + return _builder.default.apply("TemplateElement", arguments); +} + +function templateLiteral(quasis, expressions) { + return _builder.default.apply("TemplateLiteral", arguments); +} + +function yieldExpression(argument, delegate) { + return _builder.default.apply("YieldExpression", arguments); +} + +function awaitExpression(argument) { + return _builder.default.apply("AwaitExpression", arguments); +} + +function _import() { + return _builder.default.apply("Import", arguments); +} + +function bigIntLiteral(value) { + return _builder.default.apply("BigIntLiteral", arguments); +} + +function exportNamespaceSpecifier(exported) { + return _builder.default.apply("ExportNamespaceSpecifier", arguments); +} + +function optionalMemberExpression(object, property, computed, optional) { + return _builder.default.apply("OptionalMemberExpression", arguments); +} + +function optionalCallExpression(callee, _arguments, optional) { + return _builder.default.apply("OptionalCallExpression", arguments); +} + +function classProperty(key, value, typeAnnotation, decorators, computed, _static) { + return _builder.default.apply("ClassProperty", arguments); +} + +function classAccessorProperty(key, value, typeAnnotation, decorators, computed, _static) { + return _builder.default.apply("ClassAccessorProperty", arguments); +} + +function classPrivateProperty(key, value, decorators, _static) { + return _builder.default.apply("ClassPrivateProperty", arguments); +} + +function classPrivateMethod(kind, key, params, body, _static) { + return _builder.default.apply("ClassPrivateMethod", arguments); +} + +function privateName(id) { + return _builder.default.apply("PrivateName", arguments); +} + +function staticBlock(body) { + return _builder.default.apply("StaticBlock", arguments); +} + +function anyTypeAnnotation() { + return _builder.default.apply("AnyTypeAnnotation", arguments); +} + +function arrayTypeAnnotation(elementType) { + return _builder.default.apply("ArrayTypeAnnotation", arguments); +} + +function booleanTypeAnnotation() { + return _builder.default.apply("BooleanTypeAnnotation", arguments); +} + +function booleanLiteralTypeAnnotation(value) { + return _builder.default.apply("BooleanLiteralTypeAnnotation", arguments); +} + +function nullLiteralTypeAnnotation() { + return _builder.default.apply("NullLiteralTypeAnnotation", arguments); +} + +function classImplements(id, typeParameters) { + return _builder.default.apply("ClassImplements", arguments); +} + +function declareClass(id, typeParameters, _extends, body) { + return _builder.default.apply("DeclareClass", arguments); +} + +function declareFunction(id) { + return _builder.default.apply("DeclareFunction", arguments); +} + +function declareInterface(id, typeParameters, _extends, body) { + return _builder.default.apply("DeclareInterface", arguments); +} + +function declareModule(id, body, kind) { + return _builder.default.apply("DeclareModule", arguments); +} + +function declareModuleExports(typeAnnotation) { + return _builder.default.apply("DeclareModuleExports", arguments); +} + +function declareTypeAlias(id, typeParameters, right) { + return _builder.default.apply("DeclareTypeAlias", arguments); +} + +function declareOpaqueType(id, typeParameters, supertype) { + return _builder.default.apply("DeclareOpaqueType", arguments); +} + +function declareVariable(id) { + return _builder.default.apply("DeclareVariable", arguments); +} + +function declareExportDeclaration(declaration, specifiers, source) { + return _builder.default.apply("DeclareExportDeclaration", arguments); +} + +function declareExportAllDeclaration(source) { + return _builder.default.apply("DeclareExportAllDeclaration", arguments); +} + +function declaredPredicate(value) { + return _builder.default.apply("DeclaredPredicate", arguments); +} + +function existsTypeAnnotation() { + return _builder.default.apply("ExistsTypeAnnotation", arguments); +} + +function functionTypeAnnotation(typeParameters, params, rest, returnType) { + return _builder.default.apply("FunctionTypeAnnotation", arguments); +} + +function functionTypeParam(name, typeAnnotation) { + return _builder.default.apply("FunctionTypeParam", arguments); +} + +function genericTypeAnnotation(id, typeParameters) { + return _builder.default.apply("GenericTypeAnnotation", arguments); +} + +function inferredPredicate() { + return _builder.default.apply("InferredPredicate", arguments); +} + +function interfaceExtends(id, typeParameters) { + return _builder.default.apply("InterfaceExtends", arguments); +} + +function interfaceDeclaration(id, typeParameters, _extends, body) { + return _builder.default.apply("InterfaceDeclaration", arguments); +} + +function interfaceTypeAnnotation(_extends, body) { + return _builder.default.apply("InterfaceTypeAnnotation", arguments); +} + +function intersectionTypeAnnotation(types) { + return _builder.default.apply("IntersectionTypeAnnotation", arguments); +} + +function mixedTypeAnnotation() { + return _builder.default.apply("MixedTypeAnnotation", arguments); +} + +function emptyTypeAnnotation() { + return _builder.default.apply("EmptyTypeAnnotation", arguments); +} + +function nullableTypeAnnotation(typeAnnotation) { + return _builder.default.apply("NullableTypeAnnotation", arguments); +} + +function numberLiteralTypeAnnotation(value) { + return _builder.default.apply("NumberLiteralTypeAnnotation", arguments); +} + +function numberTypeAnnotation() { + return _builder.default.apply("NumberTypeAnnotation", arguments); +} + +function objectTypeAnnotation(properties, indexers, callProperties, internalSlots, exact) { + return _builder.default.apply("ObjectTypeAnnotation", arguments); +} + +function objectTypeInternalSlot(id, value, optional, _static, method) { + return _builder.default.apply("ObjectTypeInternalSlot", arguments); +} + +function objectTypeCallProperty(value) { + return _builder.default.apply("ObjectTypeCallProperty", arguments); +} + +function objectTypeIndexer(id, key, value, variance) { + return _builder.default.apply("ObjectTypeIndexer", arguments); +} + +function objectTypeProperty(key, value, variance) { + return _builder.default.apply("ObjectTypeProperty", arguments); +} + +function objectTypeSpreadProperty(argument) { + return _builder.default.apply("ObjectTypeSpreadProperty", arguments); +} + +function opaqueType(id, typeParameters, supertype, impltype) { + return _builder.default.apply("OpaqueType", arguments); +} + +function qualifiedTypeIdentifier(id, qualification) { + return _builder.default.apply("QualifiedTypeIdentifier", arguments); +} + +function stringLiteralTypeAnnotation(value) { + return _builder.default.apply("StringLiteralTypeAnnotation", arguments); +} + +function stringTypeAnnotation() { + return _builder.default.apply("StringTypeAnnotation", arguments); +} + +function symbolTypeAnnotation() { + return _builder.default.apply("SymbolTypeAnnotation", arguments); +} + +function thisTypeAnnotation() { + return _builder.default.apply("ThisTypeAnnotation", arguments); +} + +function tupleTypeAnnotation(types) { + return _builder.default.apply("TupleTypeAnnotation", arguments); +} + +function typeofTypeAnnotation(argument) { + return _builder.default.apply("TypeofTypeAnnotation", arguments); +} + +function typeAlias(id, typeParameters, right) { + return _builder.default.apply("TypeAlias", arguments); +} + +function typeAnnotation(typeAnnotation) { + return _builder.default.apply("TypeAnnotation", arguments); +} + +function typeCastExpression(expression, typeAnnotation) { + return _builder.default.apply("TypeCastExpression", arguments); +} + +function typeParameter(bound, _default, variance) { + return _builder.default.apply("TypeParameter", arguments); +} + +function typeParameterDeclaration(params) { + return _builder.default.apply("TypeParameterDeclaration", arguments); +} + +function typeParameterInstantiation(params) { + return _builder.default.apply("TypeParameterInstantiation", arguments); +} + +function unionTypeAnnotation(types) { + return _builder.default.apply("UnionTypeAnnotation", arguments); +} + +function variance(kind) { + return _builder.default.apply("Variance", arguments); +} + +function voidTypeAnnotation() { + return _builder.default.apply("VoidTypeAnnotation", arguments); +} + +function enumDeclaration(id, body) { + return _builder.default.apply("EnumDeclaration", arguments); +} + +function enumBooleanBody(members) { + return _builder.default.apply("EnumBooleanBody", arguments); +} + +function enumNumberBody(members) { + return _builder.default.apply("EnumNumberBody", arguments); +} + +function enumStringBody(members) { + return _builder.default.apply("EnumStringBody", arguments); +} + +function enumSymbolBody(members) { + return _builder.default.apply("EnumSymbolBody", arguments); +} + +function enumBooleanMember(id) { + return _builder.default.apply("EnumBooleanMember", arguments); +} + +function enumNumberMember(id, init) { + return _builder.default.apply("EnumNumberMember", arguments); +} + +function enumStringMember(id, init) { + return _builder.default.apply("EnumStringMember", arguments); +} + +function enumDefaultedMember(id) { + return _builder.default.apply("EnumDefaultedMember", arguments); +} + +function indexedAccessType(objectType, indexType) { + return _builder.default.apply("IndexedAccessType", arguments); +} + +function optionalIndexedAccessType(objectType, indexType) { + return _builder.default.apply("OptionalIndexedAccessType", arguments); +} + +function jsxAttribute(name, value) { + return _builder.default.apply("JSXAttribute", arguments); +} + +function jsxClosingElement(name) { + return _builder.default.apply("JSXClosingElement", arguments); +} + +function jsxElement(openingElement, closingElement, children, selfClosing) { + return _builder.default.apply("JSXElement", arguments); +} + +function jsxEmptyExpression() { + return _builder.default.apply("JSXEmptyExpression", arguments); +} + +function jsxExpressionContainer(expression) { + return _builder.default.apply("JSXExpressionContainer", arguments); +} + +function jsxSpreadChild(expression) { + return _builder.default.apply("JSXSpreadChild", arguments); +} + +function jsxIdentifier(name) { + return _builder.default.apply("JSXIdentifier", arguments); +} + +function jsxMemberExpression(object, property) { + return _builder.default.apply("JSXMemberExpression", arguments); +} + +function jsxNamespacedName(namespace, name) { + return _builder.default.apply("JSXNamespacedName", arguments); +} + +function jsxOpeningElement(name, attributes, selfClosing) { + return _builder.default.apply("JSXOpeningElement", arguments); +} + +function jsxSpreadAttribute(argument) { + return _builder.default.apply("JSXSpreadAttribute", arguments); +} + +function jsxText(value) { + return _builder.default.apply("JSXText", arguments); +} + +function jsxFragment(openingFragment, closingFragment, children) { + return _builder.default.apply("JSXFragment", arguments); +} + +function jsxOpeningFragment() { + return _builder.default.apply("JSXOpeningFragment", arguments); +} + +function jsxClosingFragment() { + return _builder.default.apply("JSXClosingFragment", arguments); +} + +function noop() { + return _builder.default.apply("Noop", arguments); +} + +function placeholder(expectedNode, name) { + return _builder.default.apply("Placeholder", arguments); +} + +function v8IntrinsicIdentifier(name) { + return _builder.default.apply("V8IntrinsicIdentifier", arguments); +} + +function argumentPlaceholder() { + return _builder.default.apply("ArgumentPlaceholder", arguments); +} + +function bindExpression(object, callee) { + return _builder.default.apply("BindExpression", arguments); +} + +function importAttribute(key, value) { + return _builder.default.apply("ImportAttribute", arguments); +} + +function decorator(expression) { + return _builder.default.apply("Decorator", arguments); +} + +function doExpression(body, async) { + return _builder.default.apply("DoExpression", arguments); +} + +function exportDefaultSpecifier(exported) { + return _builder.default.apply("ExportDefaultSpecifier", arguments); +} + +function recordExpression(properties) { + return _builder.default.apply("RecordExpression", arguments); +} + +function tupleExpression(elements) { + return _builder.default.apply("TupleExpression", arguments); +} + +function decimalLiteral(value) { + return _builder.default.apply("DecimalLiteral", arguments); +} + +function moduleExpression(body) { + return _builder.default.apply("ModuleExpression", arguments); +} + +function topicReference() { + return _builder.default.apply("TopicReference", arguments); +} + +function pipelineTopicExpression(expression) { + return _builder.default.apply("PipelineTopicExpression", arguments); +} + +function pipelineBareFunction(callee) { + return _builder.default.apply("PipelineBareFunction", arguments); +} + +function pipelinePrimaryTopicReference() { + return _builder.default.apply("PipelinePrimaryTopicReference", arguments); +} + +function tsParameterProperty(parameter) { + return _builder.default.apply("TSParameterProperty", arguments); +} + +function tsDeclareFunction(id, typeParameters, params, returnType) { + return _builder.default.apply("TSDeclareFunction", arguments); +} + +function tsDeclareMethod(decorators, key, typeParameters, params, returnType) { + return _builder.default.apply("TSDeclareMethod", arguments); +} + +function tsQualifiedName(left, right) { + return _builder.default.apply("TSQualifiedName", arguments); +} + +function tsCallSignatureDeclaration(typeParameters, parameters, typeAnnotation) { + return _builder.default.apply("TSCallSignatureDeclaration", arguments); +} + +function tsConstructSignatureDeclaration(typeParameters, parameters, typeAnnotation) { + return _builder.default.apply("TSConstructSignatureDeclaration", arguments); +} + +function tsPropertySignature(key, typeAnnotation, initializer) { + return _builder.default.apply("TSPropertySignature", arguments); +} + +function tsMethodSignature(key, typeParameters, parameters, typeAnnotation) { + return _builder.default.apply("TSMethodSignature", arguments); +} + +function tsIndexSignature(parameters, typeAnnotation) { + return _builder.default.apply("TSIndexSignature", arguments); +} + +function tsAnyKeyword() { + return _builder.default.apply("TSAnyKeyword", arguments); +} + +function tsBooleanKeyword() { + return _builder.default.apply("TSBooleanKeyword", arguments); +} + +function tsBigIntKeyword() { + return _builder.default.apply("TSBigIntKeyword", arguments); +} + +function tsIntrinsicKeyword() { + return _builder.default.apply("TSIntrinsicKeyword", arguments); +} + +function tsNeverKeyword() { + return _builder.default.apply("TSNeverKeyword", arguments); +} + +function tsNullKeyword() { + return _builder.default.apply("TSNullKeyword", arguments); +} + +function tsNumberKeyword() { + return _builder.default.apply("TSNumberKeyword", arguments); +} + +function tsObjectKeyword() { + return _builder.default.apply("TSObjectKeyword", arguments); +} + +function tsStringKeyword() { + return _builder.default.apply("TSStringKeyword", arguments); +} + +function tsSymbolKeyword() { + return _builder.default.apply("TSSymbolKeyword", arguments); +} + +function tsUndefinedKeyword() { + return _builder.default.apply("TSUndefinedKeyword", arguments); +} + +function tsUnknownKeyword() { + return _builder.default.apply("TSUnknownKeyword", arguments); +} + +function tsVoidKeyword() { + return _builder.default.apply("TSVoidKeyword", arguments); +} + +function tsThisType() { + return _builder.default.apply("TSThisType", arguments); +} + +function tsFunctionType(typeParameters, parameters, typeAnnotation) { + return _builder.default.apply("TSFunctionType", arguments); +} + +function tsConstructorType(typeParameters, parameters, typeAnnotation) { + return _builder.default.apply("TSConstructorType", arguments); +} + +function tsTypeReference(typeName, typeParameters) { + return _builder.default.apply("TSTypeReference", arguments); +} + +function tsTypePredicate(parameterName, typeAnnotation, asserts) { + return _builder.default.apply("TSTypePredicate", arguments); +} + +function tsTypeQuery(exprName) { + return _builder.default.apply("TSTypeQuery", arguments); +} + +function tsTypeLiteral(members) { + return _builder.default.apply("TSTypeLiteral", arguments); +} + +function tsArrayType(elementType) { + return _builder.default.apply("TSArrayType", arguments); +} + +function tsTupleType(elementTypes) { + return _builder.default.apply("TSTupleType", arguments); +} + +function tsOptionalType(typeAnnotation) { + return _builder.default.apply("TSOptionalType", arguments); +} + +function tsRestType(typeAnnotation) { + return _builder.default.apply("TSRestType", arguments); +} + +function tsNamedTupleMember(label, elementType, optional) { + return _builder.default.apply("TSNamedTupleMember", arguments); +} + +function tsUnionType(types) { + return _builder.default.apply("TSUnionType", arguments); +} + +function tsIntersectionType(types) { + return _builder.default.apply("TSIntersectionType", arguments); +} + +function tsConditionalType(checkType, extendsType, trueType, falseType) { + return _builder.default.apply("TSConditionalType", arguments); +} + +function tsInferType(typeParameter) { + return _builder.default.apply("TSInferType", arguments); +} + +function tsParenthesizedType(typeAnnotation) { + return _builder.default.apply("TSParenthesizedType", arguments); +} + +function tsTypeOperator(typeAnnotation) { + return _builder.default.apply("TSTypeOperator", arguments); +} + +function tsIndexedAccessType(objectType, indexType) { + return _builder.default.apply("TSIndexedAccessType", arguments); +} + +function tsMappedType(typeParameter, typeAnnotation, nameType) { + return _builder.default.apply("TSMappedType", arguments); +} + +function tsLiteralType(literal) { + return _builder.default.apply("TSLiteralType", arguments); +} + +function tsExpressionWithTypeArguments(expression, typeParameters) { + return _builder.default.apply("TSExpressionWithTypeArguments", arguments); +} + +function tsInterfaceDeclaration(id, typeParameters, _extends, body) { + return _builder.default.apply("TSInterfaceDeclaration", arguments); +} + +function tsInterfaceBody(body) { + return _builder.default.apply("TSInterfaceBody", arguments); +} + +function tsTypeAliasDeclaration(id, typeParameters, typeAnnotation) { + return _builder.default.apply("TSTypeAliasDeclaration", arguments); +} + +function tsAsExpression(expression, typeAnnotation) { + return _builder.default.apply("TSAsExpression", arguments); +} + +function tsTypeAssertion(typeAnnotation, expression) { + return _builder.default.apply("TSTypeAssertion", arguments); +} + +function tsEnumDeclaration(id, members) { + return _builder.default.apply("TSEnumDeclaration", arguments); +} + +function tsEnumMember(id, initializer) { + return _builder.default.apply("TSEnumMember", arguments); +} + +function tsModuleDeclaration(id, body) { + return _builder.default.apply("TSModuleDeclaration", arguments); +} + +function tsModuleBlock(body) { + return _builder.default.apply("TSModuleBlock", arguments); +} + +function tsImportType(argument, qualifier, typeParameters) { + return _builder.default.apply("TSImportType", arguments); +} + +function tsImportEqualsDeclaration(id, moduleReference) { + return _builder.default.apply("TSImportEqualsDeclaration", arguments); +} + +function tsExternalModuleReference(expression) { + return _builder.default.apply("TSExternalModuleReference", arguments); +} + +function tsNonNullExpression(expression) { + return _builder.default.apply("TSNonNullExpression", arguments); +} + +function tsExportAssignment(expression) { + return _builder.default.apply("TSExportAssignment", arguments); +} + +function tsNamespaceExportDeclaration(id) { + return _builder.default.apply("TSNamespaceExportDeclaration", arguments); +} + +function tsTypeAnnotation(typeAnnotation) { + return _builder.default.apply("TSTypeAnnotation", arguments); +} + +function tsTypeParameterInstantiation(params) { + return _builder.default.apply("TSTypeParameterInstantiation", arguments); +} + +function tsTypeParameterDeclaration(params) { + return _builder.default.apply("TSTypeParameterDeclaration", arguments); +} + +function tsTypeParameter(constraint, _default, name) { + return _builder.default.apply("TSTypeParameter", arguments); +} + +function NumberLiteral(value) { + console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); + return _builder.default.apply("NumberLiteral", arguments); +} + +function RegexLiteral(pattern, flags) { + console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); + return _builder.default.apply("RegexLiteral", arguments); +} + +function RestProperty(argument) { + console.trace("The node type RestProperty has been renamed to RestElement"); + return _builder.default.apply("RestProperty", arguments); +} + +function SpreadProperty(argument) { + console.trace("The node type SpreadProperty has been renamed to SpreadElement"); + return _builder.default.apply("SpreadProperty", arguments); +} \ No newline at end of file diff --git a/node_modules/@babel/types/lib/builders/generated/uppercase.js b/node_modules/@babel/types/lib/builders/generated/uppercase.js new file mode 100644 index 000000000..95c9a5258 --- /dev/null +++ b/node_modules/@babel/types/lib/builders/generated/uppercase.js @@ -0,0 +1,1513 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +Object.defineProperty(exports, "AnyTypeAnnotation", { + enumerable: true, + get: function () { + return _index.anyTypeAnnotation; + } +}); +Object.defineProperty(exports, "ArgumentPlaceholder", { + enumerable: true, + get: function () { + return _index.argumentPlaceholder; + } +}); +Object.defineProperty(exports, "ArrayExpression", { + enumerable: true, + get: function () { + return _index.arrayExpression; + } +}); +Object.defineProperty(exports, "ArrayPattern", { + enumerable: true, + get: function () { + return _index.arrayPattern; + } +}); +Object.defineProperty(exports, "ArrayTypeAnnotation", { + enumerable: true, + get: function () { + return _index.arrayTypeAnnotation; + } +}); +Object.defineProperty(exports, "ArrowFunctionExpression", { + enumerable: true, + get: function () { + return _index.arrowFunctionExpression; + } +}); +Object.defineProperty(exports, "AssignmentExpression", { + enumerable: true, + get: function () { + return _index.assignmentExpression; + } +}); +Object.defineProperty(exports, "AssignmentPattern", { + enumerable: true, + get: function () { + return _index.assignmentPattern; + } +}); +Object.defineProperty(exports, "AwaitExpression", { + enumerable: true, + get: function () { + return _index.awaitExpression; + } +}); +Object.defineProperty(exports, "BigIntLiteral", { + enumerable: true, + get: function () { + return _index.bigIntLiteral; + } +}); +Object.defineProperty(exports, "BinaryExpression", { + enumerable: true, + get: function () { + return _index.binaryExpression; + } +}); +Object.defineProperty(exports, "BindExpression", { + enumerable: true, + get: function () { + return _index.bindExpression; + } +}); +Object.defineProperty(exports, "BlockStatement", { + enumerable: true, + get: function () { + return _index.blockStatement; + } +}); +Object.defineProperty(exports, "BooleanLiteral", { + enumerable: true, + get: function () { + return _index.booleanLiteral; + } +}); +Object.defineProperty(exports, "BooleanLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.booleanLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "BooleanTypeAnnotation", { + enumerable: true, + get: function () { + return _index.booleanTypeAnnotation; + } +}); +Object.defineProperty(exports, "BreakStatement", { + enumerable: true, + get: function () { + return _index.breakStatement; + } +}); +Object.defineProperty(exports, "CallExpression", { + enumerable: true, + get: function () { + return _index.callExpression; + } +}); +Object.defineProperty(exports, "CatchClause", { + enumerable: true, + get: function () { + return _index.catchClause; + } +}); +Object.defineProperty(exports, "ClassAccessorProperty", { + enumerable: true, + get: function () { + return _index.classAccessorProperty; + } +}); +Object.defineProperty(exports, "ClassBody", { + enumerable: true, + get: function () { + return _index.classBody; + } +}); +Object.defineProperty(exports, "ClassDeclaration", { + enumerable: true, + get: function () { + return _index.classDeclaration; + } +}); +Object.defineProperty(exports, "ClassExpression", { + enumerable: true, + get: function () { + return _index.classExpression; + } +}); +Object.defineProperty(exports, "ClassImplements", { + enumerable: true, + get: function () { + return _index.classImplements; + } +}); +Object.defineProperty(exports, "ClassMethod", { + enumerable: true, + get: function () { + return _index.classMethod; + } +}); +Object.defineProperty(exports, "ClassPrivateMethod", { + enumerable: true, + get: function () { + return _index.classPrivateMethod; + } +}); +Object.defineProperty(exports, "ClassPrivateProperty", { + enumerable: true, + get: function () { + return _index.classPrivateProperty; + } +}); +Object.defineProperty(exports, "ClassProperty", { + enumerable: true, + get: function () { + return _index.classProperty; + } +}); +Object.defineProperty(exports, "ConditionalExpression", { + enumerable: true, + get: function () { + return _index.conditionalExpression; + } +}); +Object.defineProperty(exports, "ContinueStatement", { + enumerable: true, + get: function () { + return _index.continueStatement; + } +}); +Object.defineProperty(exports, "DebuggerStatement", { + enumerable: true, + get: function () { + return _index.debuggerStatement; + } +}); +Object.defineProperty(exports, "DecimalLiteral", { + enumerable: true, + get: function () { + return _index.decimalLiteral; + } +}); +Object.defineProperty(exports, "DeclareClass", { + enumerable: true, + get: function () { + return _index.declareClass; + } +}); +Object.defineProperty(exports, "DeclareExportAllDeclaration", { + enumerable: true, + get: function () { + return _index.declareExportAllDeclaration; + } +}); +Object.defineProperty(exports, "DeclareExportDeclaration", { + enumerable: true, + get: function () { + return _index.declareExportDeclaration; + } +}); +Object.defineProperty(exports, "DeclareFunction", { + enumerable: true, + get: function () { + return _index.declareFunction; + } +}); +Object.defineProperty(exports, "DeclareInterface", { + enumerable: true, + get: function () { + return _index.declareInterface; + } +}); +Object.defineProperty(exports, "DeclareModule", { + enumerable: true, + get: function () { + return _index.declareModule; + } +}); +Object.defineProperty(exports, "DeclareModuleExports", { + enumerable: true, + get: function () { + return _index.declareModuleExports; + } +}); +Object.defineProperty(exports, "DeclareOpaqueType", { + enumerable: true, + get: function () { + return _index.declareOpaqueType; + } +}); +Object.defineProperty(exports, "DeclareTypeAlias", { + enumerable: true, + get: function () { + return _index.declareTypeAlias; + } +}); +Object.defineProperty(exports, "DeclareVariable", { + enumerable: true, + get: function () { + return _index.declareVariable; + } +}); +Object.defineProperty(exports, "DeclaredPredicate", { + enumerable: true, + get: function () { + return _index.declaredPredicate; + } +}); +Object.defineProperty(exports, "Decorator", { + enumerable: true, + get: function () { + return _index.decorator; + } +}); +Object.defineProperty(exports, "Directive", { + enumerable: true, + get: function () { + return _index.directive; + } +}); +Object.defineProperty(exports, "DirectiveLiteral", { + enumerable: true, + get: function () { + return _index.directiveLiteral; + } +}); +Object.defineProperty(exports, "DoExpression", { + enumerable: true, + get: function () { + return _index.doExpression; + } +}); +Object.defineProperty(exports, "DoWhileStatement", { + enumerable: true, + get: function () { + return _index.doWhileStatement; + } +}); +Object.defineProperty(exports, "EmptyStatement", { + enumerable: true, + get: function () { + return _index.emptyStatement; + } +}); +Object.defineProperty(exports, "EmptyTypeAnnotation", { + enumerable: true, + get: function () { + return _index.emptyTypeAnnotation; + } +}); +Object.defineProperty(exports, "EnumBooleanBody", { + enumerable: true, + get: function () { + return _index.enumBooleanBody; + } +}); +Object.defineProperty(exports, "EnumBooleanMember", { + enumerable: true, + get: function () { + return _index.enumBooleanMember; + } +}); +Object.defineProperty(exports, "EnumDeclaration", { + enumerable: true, + get: function () { + return _index.enumDeclaration; + } +}); +Object.defineProperty(exports, "EnumDefaultedMember", { + enumerable: true, + get: function () { + return _index.enumDefaultedMember; + } +}); +Object.defineProperty(exports, "EnumNumberBody", { + enumerable: true, + get: function () { + return _index.enumNumberBody; + } +}); +Object.defineProperty(exports, "EnumNumberMember", { + enumerable: true, + get: function () { + return _index.enumNumberMember; + } +}); +Object.defineProperty(exports, "EnumStringBody", { + enumerable: true, + get: function () { + return _index.enumStringBody; + } +}); +Object.defineProperty(exports, "EnumStringMember", { + enumerable: true, + get: function () { + return _index.enumStringMember; + } +}); +Object.defineProperty(exports, "EnumSymbolBody", { + enumerable: true, + get: function () { + return _index.enumSymbolBody; + } +}); +Object.defineProperty(exports, "ExistsTypeAnnotation", { + enumerable: true, + get: function () { + return _index.existsTypeAnnotation; + } +}); +Object.defineProperty(exports, "ExportAllDeclaration", { + enumerable: true, + get: function () { + return _index.exportAllDeclaration; + } +}); +Object.defineProperty(exports, "ExportDefaultDeclaration", { + enumerable: true, + get: function () { + return _index.exportDefaultDeclaration; + } +}); +Object.defineProperty(exports, "ExportDefaultSpecifier", { + enumerable: true, + get: function () { + return _index.exportDefaultSpecifier; + } +}); +Object.defineProperty(exports, "ExportNamedDeclaration", { + enumerable: true, + get: function () { + return _index.exportNamedDeclaration; + } +}); +Object.defineProperty(exports, "ExportNamespaceSpecifier", { + enumerable: true, + get: function () { + return _index.exportNamespaceSpecifier; + } +}); +Object.defineProperty(exports, "ExportSpecifier", { + enumerable: true, + get: function () { + return _index.exportSpecifier; + } +}); +Object.defineProperty(exports, "ExpressionStatement", { + enumerable: true, + get: function () { + return _index.expressionStatement; + } +}); +Object.defineProperty(exports, "File", { + enumerable: true, + get: function () { + return _index.file; + } +}); +Object.defineProperty(exports, "ForInStatement", { + enumerable: true, + get: function () { + return _index.forInStatement; + } +}); +Object.defineProperty(exports, "ForOfStatement", { + enumerable: true, + get: function () { + return _index.forOfStatement; + } +}); +Object.defineProperty(exports, "ForStatement", { + enumerable: true, + get: function () { + return _index.forStatement; + } +}); +Object.defineProperty(exports, "FunctionDeclaration", { + enumerable: true, + get: function () { + return _index.functionDeclaration; + } +}); +Object.defineProperty(exports, "FunctionExpression", { + enumerable: true, + get: function () { + return _index.functionExpression; + } +}); +Object.defineProperty(exports, "FunctionTypeAnnotation", { + enumerable: true, + get: function () { + return _index.functionTypeAnnotation; + } +}); +Object.defineProperty(exports, "FunctionTypeParam", { + enumerable: true, + get: function () { + return _index.functionTypeParam; + } +}); +Object.defineProperty(exports, "GenericTypeAnnotation", { + enumerable: true, + get: function () { + return _index.genericTypeAnnotation; + } +}); +Object.defineProperty(exports, "Identifier", { + enumerable: true, + get: function () { + return _index.identifier; + } +}); +Object.defineProperty(exports, "IfStatement", { + enumerable: true, + get: function () { + return _index.ifStatement; + } +}); +Object.defineProperty(exports, "Import", { + enumerable: true, + get: function () { + return _index.import; + } +}); +Object.defineProperty(exports, "ImportAttribute", { + enumerable: true, + get: function () { + return _index.importAttribute; + } +}); +Object.defineProperty(exports, "ImportDeclaration", { + enumerable: true, + get: function () { + return _index.importDeclaration; + } +}); +Object.defineProperty(exports, "ImportDefaultSpecifier", { + enumerable: true, + get: function () { + return _index.importDefaultSpecifier; + } +}); +Object.defineProperty(exports, "ImportNamespaceSpecifier", { + enumerable: true, + get: function () { + return _index.importNamespaceSpecifier; + } +}); +Object.defineProperty(exports, "ImportSpecifier", { + enumerable: true, + get: function () { + return _index.importSpecifier; + } +}); +Object.defineProperty(exports, "IndexedAccessType", { + enumerable: true, + get: function () { + return _index.indexedAccessType; + } +}); +Object.defineProperty(exports, "InferredPredicate", { + enumerable: true, + get: function () { + return _index.inferredPredicate; + } +}); +Object.defineProperty(exports, "InterfaceDeclaration", { + enumerable: true, + get: function () { + return _index.interfaceDeclaration; + } +}); +Object.defineProperty(exports, "InterfaceExtends", { + enumerable: true, + get: function () { + return _index.interfaceExtends; + } +}); +Object.defineProperty(exports, "InterfaceTypeAnnotation", { + enumerable: true, + get: function () { + return _index.interfaceTypeAnnotation; + } +}); +Object.defineProperty(exports, "InterpreterDirective", { + enumerable: true, + get: function () { + return _index.interpreterDirective; + } +}); +Object.defineProperty(exports, "IntersectionTypeAnnotation", { + enumerable: true, + get: function () { + return _index.intersectionTypeAnnotation; + } +}); +Object.defineProperty(exports, "JSXAttribute", { + enumerable: true, + get: function () { + return _index.jsxAttribute; + } +}); +Object.defineProperty(exports, "JSXClosingElement", { + enumerable: true, + get: function () { + return _index.jsxClosingElement; + } +}); +Object.defineProperty(exports, "JSXClosingFragment", { + enumerable: true, + get: function () { + return _index.jsxClosingFragment; + } +}); +Object.defineProperty(exports, "JSXElement", { + enumerable: true, + get: function () { + return _index.jsxElement; + } +}); +Object.defineProperty(exports, "JSXEmptyExpression", { + enumerable: true, + get: function () { + return _index.jsxEmptyExpression; + } +}); +Object.defineProperty(exports, "JSXExpressionContainer", { + enumerable: true, + get: function () { + return _index.jsxExpressionContainer; + } +}); +Object.defineProperty(exports, "JSXFragment", { + enumerable: true, + get: function () { + return _index.jsxFragment; + } +}); +Object.defineProperty(exports, "JSXIdentifier", { + enumerable: true, + get: function () { + return _index.jsxIdentifier; + } +}); +Object.defineProperty(exports, "JSXMemberExpression", { + enumerable: true, + get: function () { + return _index.jsxMemberExpression; + } +}); +Object.defineProperty(exports, "JSXNamespacedName", { + enumerable: true, + get: function () { + return _index.jsxNamespacedName; + } +}); +Object.defineProperty(exports, "JSXOpeningElement", { + enumerable: true, + get: function () { + return _index.jsxOpeningElement; + } +}); +Object.defineProperty(exports, "JSXOpeningFragment", { + enumerable: true, + get: function () { + return _index.jsxOpeningFragment; + } +}); +Object.defineProperty(exports, "JSXSpreadAttribute", { + enumerable: true, + get: function () { + return _index.jsxSpreadAttribute; + } +}); +Object.defineProperty(exports, "JSXSpreadChild", { + enumerable: true, + get: function () { + return _index.jsxSpreadChild; + } +}); +Object.defineProperty(exports, "JSXText", { + enumerable: true, + get: function () { + return _index.jsxText; + } +}); +Object.defineProperty(exports, "LabeledStatement", { + enumerable: true, + get: function () { + return _index.labeledStatement; + } +}); +Object.defineProperty(exports, "LogicalExpression", { + enumerable: true, + get: function () { + return _index.logicalExpression; + } +}); +Object.defineProperty(exports, "MemberExpression", { + enumerable: true, + get: function () { + return _index.memberExpression; + } +}); +Object.defineProperty(exports, "MetaProperty", { + enumerable: true, + get: function () { + return _index.metaProperty; + } +}); +Object.defineProperty(exports, "MixedTypeAnnotation", { + enumerable: true, + get: function () { + return _index.mixedTypeAnnotation; + } +}); +Object.defineProperty(exports, "ModuleExpression", { + enumerable: true, + get: function () { + return _index.moduleExpression; + } +}); +Object.defineProperty(exports, "NewExpression", { + enumerable: true, + get: function () { + return _index.newExpression; + } +}); +Object.defineProperty(exports, "Noop", { + enumerable: true, + get: function () { + return _index.noop; + } +}); +Object.defineProperty(exports, "NullLiteral", { + enumerable: true, + get: function () { + return _index.nullLiteral; + } +}); +Object.defineProperty(exports, "NullLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.nullLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "NullableTypeAnnotation", { + enumerable: true, + get: function () { + return _index.nullableTypeAnnotation; + } +}); +Object.defineProperty(exports, "NumberLiteral", { + enumerable: true, + get: function () { + return _index.numberLiteral; + } +}); +Object.defineProperty(exports, "NumberLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.numberLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "NumberTypeAnnotation", { + enumerable: true, + get: function () { + return _index.numberTypeAnnotation; + } +}); +Object.defineProperty(exports, "NumericLiteral", { + enumerable: true, + get: function () { + return _index.numericLiteral; + } +}); +Object.defineProperty(exports, "ObjectExpression", { + enumerable: true, + get: function () { + return _index.objectExpression; + } +}); +Object.defineProperty(exports, "ObjectMethod", { + enumerable: true, + get: function () { + return _index.objectMethod; + } +}); +Object.defineProperty(exports, "ObjectPattern", { + enumerable: true, + get: function () { + return _index.objectPattern; + } +}); +Object.defineProperty(exports, "ObjectProperty", { + enumerable: true, + get: function () { + return _index.objectProperty; + } +}); +Object.defineProperty(exports, "ObjectTypeAnnotation", { + enumerable: true, + get: function () { + return _index.objectTypeAnnotation; + } +}); +Object.defineProperty(exports, "ObjectTypeCallProperty", { + enumerable: true, + get: function () { + return _index.objectTypeCallProperty; + } +}); +Object.defineProperty(exports, "ObjectTypeIndexer", { + enumerable: true, + get: function () { + return _index.objectTypeIndexer; + } +}); +Object.defineProperty(exports, "ObjectTypeInternalSlot", { + enumerable: true, + get: function () { + return _index.objectTypeInternalSlot; + } +}); +Object.defineProperty(exports, "ObjectTypeProperty", { + enumerable: true, + get: function () { + return _index.objectTypeProperty; + } +}); +Object.defineProperty(exports, "ObjectTypeSpreadProperty", { + enumerable: true, + get: function () { + return _index.objectTypeSpreadProperty; + } +}); +Object.defineProperty(exports, "OpaqueType", { + enumerable: true, + get: function () { + return _index.opaqueType; + } +}); +Object.defineProperty(exports, "OptionalCallExpression", { + enumerable: true, + get: function () { + return _index.optionalCallExpression; + } +}); +Object.defineProperty(exports, "OptionalIndexedAccessType", { + enumerable: true, + get: function () { + return _index.optionalIndexedAccessType; + } +}); +Object.defineProperty(exports, "OptionalMemberExpression", { + enumerable: true, + get: function () { + return _index.optionalMemberExpression; + } +}); +Object.defineProperty(exports, "ParenthesizedExpression", { + enumerable: true, + get: function () { + return _index.parenthesizedExpression; + } +}); +Object.defineProperty(exports, "PipelineBareFunction", { + enumerable: true, + get: function () { + return _index.pipelineBareFunction; + } +}); +Object.defineProperty(exports, "PipelinePrimaryTopicReference", { + enumerable: true, + get: function () { + return _index.pipelinePrimaryTopicReference; + } +}); +Object.defineProperty(exports, "PipelineTopicExpression", { + enumerable: true, + get: function () { + return _index.pipelineTopicExpression; + } +}); +Object.defineProperty(exports, "Placeholder", { + enumerable: true, + get: function () { + return _index.placeholder; + } +}); +Object.defineProperty(exports, "PrivateName", { + enumerable: true, + get: function () { + return _index.privateName; + } +}); +Object.defineProperty(exports, "Program", { + enumerable: true, + get: function () { + return _index.program; + } +}); +Object.defineProperty(exports, "QualifiedTypeIdentifier", { + enumerable: true, + get: function () { + return _index.qualifiedTypeIdentifier; + } +}); +Object.defineProperty(exports, "RecordExpression", { + enumerable: true, + get: function () { + return _index.recordExpression; + } +}); +Object.defineProperty(exports, "RegExpLiteral", { + enumerable: true, + get: function () { + return _index.regExpLiteral; + } +}); +Object.defineProperty(exports, "RegexLiteral", { + enumerable: true, + get: function () { + return _index.regexLiteral; + } +}); +Object.defineProperty(exports, "RestElement", { + enumerable: true, + get: function () { + return _index.restElement; + } +}); +Object.defineProperty(exports, "RestProperty", { + enumerable: true, + get: function () { + return _index.restProperty; + } +}); +Object.defineProperty(exports, "ReturnStatement", { + enumerable: true, + get: function () { + return _index.returnStatement; + } +}); +Object.defineProperty(exports, "SequenceExpression", { + enumerable: true, + get: function () { + return _index.sequenceExpression; + } +}); +Object.defineProperty(exports, "SpreadElement", { + enumerable: true, + get: function () { + return _index.spreadElement; + } +}); +Object.defineProperty(exports, "SpreadProperty", { + enumerable: true, + get: function () { + return _index.spreadProperty; + } +}); +Object.defineProperty(exports, "StaticBlock", { + enumerable: true, + get: function () { + return _index.staticBlock; + } +}); +Object.defineProperty(exports, "StringLiteral", { + enumerable: true, + get: function () { + return _index.stringLiteral; + } +}); +Object.defineProperty(exports, "StringLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.stringLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "StringTypeAnnotation", { + enumerable: true, + get: function () { + return _index.stringTypeAnnotation; + } +}); +Object.defineProperty(exports, "Super", { + enumerable: true, + get: function () { + return _index.super; + } +}); +Object.defineProperty(exports, "SwitchCase", { + enumerable: true, + get: function () { + return _index.switchCase; + } +}); +Object.defineProperty(exports, "SwitchStatement", { + enumerable: true, + get: function () { + return _index.switchStatement; + } +}); +Object.defineProperty(exports, "SymbolTypeAnnotation", { + enumerable: true, + get: function () { + return _index.symbolTypeAnnotation; + } +}); +Object.defineProperty(exports, "TSAnyKeyword", { + enumerable: true, + get: function () { + return _index.tsAnyKeyword; + } +}); +Object.defineProperty(exports, "TSArrayType", { + enumerable: true, + get: function () { + return _index.tsArrayType; + } +}); +Object.defineProperty(exports, "TSAsExpression", { + enumerable: true, + get: function () { + return _index.tsAsExpression; + } +}); +Object.defineProperty(exports, "TSBigIntKeyword", { + enumerable: true, + get: function () { + return _index.tsBigIntKeyword; + } +}); +Object.defineProperty(exports, "TSBooleanKeyword", { + enumerable: true, + get: function () { + return _index.tsBooleanKeyword; + } +}); +Object.defineProperty(exports, "TSCallSignatureDeclaration", { + enumerable: true, + get: function () { + return _index.tsCallSignatureDeclaration; + } +}); +Object.defineProperty(exports, "TSConditionalType", { + enumerable: true, + get: function () { + return _index.tsConditionalType; + } +}); +Object.defineProperty(exports, "TSConstructSignatureDeclaration", { + enumerable: true, + get: function () { + return _index.tsConstructSignatureDeclaration; + } +}); +Object.defineProperty(exports, "TSConstructorType", { + enumerable: true, + get: function () { + return _index.tsConstructorType; + } +}); +Object.defineProperty(exports, "TSDeclareFunction", { + enumerable: true, + get: function () { + return _index.tsDeclareFunction; + } +}); +Object.defineProperty(exports, "TSDeclareMethod", { + enumerable: true, + get: function () { + return _index.tsDeclareMethod; + } +}); +Object.defineProperty(exports, "TSEnumDeclaration", { + enumerable: true, + get: function () { + return _index.tsEnumDeclaration; + } +}); +Object.defineProperty(exports, "TSEnumMember", { + enumerable: true, + get: function () { + return _index.tsEnumMember; + } +}); +Object.defineProperty(exports, "TSExportAssignment", { + enumerable: true, + get: function () { + return _index.tsExportAssignment; + } +}); +Object.defineProperty(exports, "TSExpressionWithTypeArguments", { + enumerable: true, + get: function () { + return _index.tsExpressionWithTypeArguments; + } +}); +Object.defineProperty(exports, "TSExternalModuleReference", { + enumerable: true, + get: function () { + return _index.tsExternalModuleReference; + } +}); +Object.defineProperty(exports, "TSFunctionType", { + enumerable: true, + get: function () { + return _index.tsFunctionType; + } +}); +Object.defineProperty(exports, "TSImportEqualsDeclaration", { + enumerable: true, + get: function () { + return _index.tsImportEqualsDeclaration; + } +}); +Object.defineProperty(exports, "TSImportType", { + enumerable: true, + get: function () { + return _index.tsImportType; + } +}); +Object.defineProperty(exports, "TSIndexSignature", { + enumerable: true, + get: function () { + return _index.tsIndexSignature; + } +}); +Object.defineProperty(exports, "TSIndexedAccessType", { + enumerable: true, + get: function () { + return _index.tsIndexedAccessType; + } +}); +Object.defineProperty(exports, "TSInferType", { + enumerable: true, + get: function () { + return _index.tsInferType; + } +}); +Object.defineProperty(exports, "TSInterfaceBody", { + enumerable: true, + get: function () { + return _index.tsInterfaceBody; + } +}); +Object.defineProperty(exports, "TSInterfaceDeclaration", { + enumerable: true, + get: function () { + return _index.tsInterfaceDeclaration; + } +}); +Object.defineProperty(exports, "TSIntersectionType", { + enumerable: true, + get: function () { + return _index.tsIntersectionType; + } +}); +Object.defineProperty(exports, "TSIntrinsicKeyword", { + enumerable: true, + get: function () { + return _index.tsIntrinsicKeyword; + } +}); +Object.defineProperty(exports, "TSLiteralType", { + enumerable: true, + get: function () { + return _index.tsLiteralType; + } +}); +Object.defineProperty(exports, "TSMappedType", { + enumerable: true, + get: function () { + return _index.tsMappedType; + } +}); +Object.defineProperty(exports, "TSMethodSignature", { + enumerable: true, + get: function () { + return _index.tsMethodSignature; + } +}); +Object.defineProperty(exports, "TSModuleBlock", { + enumerable: true, + get: function () { + return _index.tsModuleBlock; + } +}); +Object.defineProperty(exports, "TSModuleDeclaration", { + enumerable: true, + get: function () { + return _index.tsModuleDeclaration; + } +}); +Object.defineProperty(exports, "TSNamedTupleMember", { + enumerable: true, + get: function () { + return _index.tsNamedTupleMember; + } +}); +Object.defineProperty(exports, "TSNamespaceExportDeclaration", { + enumerable: true, + get: function () { + return _index.tsNamespaceExportDeclaration; + } +}); +Object.defineProperty(exports, "TSNeverKeyword", { + enumerable: true, + get: function () { + return _index.tsNeverKeyword; + } +}); +Object.defineProperty(exports, "TSNonNullExpression", { + enumerable: true, + get: function () { + return _index.tsNonNullExpression; + } +}); +Object.defineProperty(exports, "TSNullKeyword", { + enumerable: true, + get: function () { + return _index.tsNullKeyword; + } +}); +Object.defineProperty(exports, "TSNumberKeyword", { + enumerable: true, + get: function () { + return _index.tsNumberKeyword; + } +}); +Object.defineProperty(exports, "TSObjectKeyword", { + enumerable: true, + get: function () { + return _index.tsObjectKeyword; + } +}); +Object.defineProperty(exports, "TSOptionalType", { + enumerable: true, + get: function () { + return _index.tsOptionalType; + } +}); +Object.defineProperty(exports, "TSParameterProperty", { + enumerable: true, + get: function () { + return _index.tsParameterProperty; + } +}); +Object.defineProperty(exports, "TSParenthesizedType", { + enumerable: true, + get: function () { + return _index.tsParenthesizedType; + } +}); +Object.defineProperty(exports, "TSPropertySignature", { + enumerable: true, + get: function () { + return _index.tsPropertySignature; + } +}); +Object.defineProperty(exports, "TSQualifiedName", { + enumerable: true, + get: function () { + return _index.tsQualifiedName; + } +}); +Object.defineProperty(exports, "TSRestType", { + enumerable: true, + get: function () { + return _index.tsRestType; + } +}); +Object.defineProperty(exports, "TSStringKeyword", { + enumerable: true, + get: function () { + return _index.tsStringKeyword; + } +}); +Object.defineProperty(exports, "TSSymbolKeyword", { + enumerable: true, + get: function () { + return _index.tsSymbolKeyword; + } +}); +Object.defineProperty(exports, "TSThisType", { + enumerable: true, + get: function () { + return _index.tsThisType; + } +}); +Object.defineProperty(exports, "TSTupleType", { + enumerable: true, + get: function () { + return _index.tsTupleType; + } +}); +Object.defineProperty(exports, "TSTypeAliasDeclaration", { + enumerable: true, + get: function () { + return _index.tsTypeAliasDeclaration; + } +}); +Object.defineProperty(exports, "TSTypeAnnotation", { + enumerable: true, + get: function () { + return _index.tsTypeAnnotation; + } +}); +Object.defineProperty(exports, "TSTypeAssertion", { + enumerable: true, + get: function () { + return _index.tsTypeAssertion; + } +}); +Object.defineProperty(exports, "TSTypeLiteral", { + enumerable: true, + get: function () { + return _index.tsTypeLiteral; + } +}); +Object.defineProperty(exports, "TSTypeOperator", { + enumerable: true, + get: function () { + return _index.tsTypeOperator; + } +}); +Object.defineProperty(exports, "TSTypeParameter", { + enumerable: true, + get: function () { + return _index.tsTypeParameter; + } +}); +Object.defineProperty(exports, "TSTypeParameterDeclaration", { + enumerable: true, + get: function () { + return _index.tsTypeParameterDeclaration; + } +}); +Object.defineProperty(exports, "TSTypeParameterInstantiation", { + enumerable: true, + get: function () { + return _index.tsTypeParameterInstantiation; + } +}); +Object.defineProperty(exports, "TSTypePredicate", { + enumerable: true, + get: function () { + return _index.tsTypePredicate; + } +}); +Object.defineProperty(exports, "TSTypeQuery", { + enumerable: true, + get: function () { + return _index.tsTypeQuery; + } +}); +Object.defineProperty(exports, "TSTypeReference", { + enumerable: true, + get: function () { + return _index.tsTypeReference; + } +}); +Object.defineProperty(exports, "TSUndefinedKeyword", { + enumerable: true, + get: function () { + return _index.tsUndefinedKeyword; + } +}); +Object.defineProperty(exports, "TSUnionType", { + enumerable: true, + get: function () { + return _index.tsUnionType; + } +}); +Object.defineProperty(exports, "TSUnknownKeyword", { + enumerable: true, + get: function () { + return _index.tsUnknownKeyword; + } +}); +Object.defineProperty(exports, "TSVoidKeyword", { + enumerable: true, + get: function () { + return _index.tsVoidKeyword; + } +}); +Object.defineProperty(exports, "TaggedTemplateExpression", { + enumerable: true, + get: function () { + return _index.taggedTemplateExpression; + } +}); +Object.defineProperty(exports, "TemplateElement", { + enumerable: true, + get: function () { + return _index.templateElement; + } +}); +Object.defineProperty(exports, "TemplateLiteral", { + enumerable: true, + get: function () { + return _index.templateLiteral; + } +}); +Object.defineProperty(exports, "ThisExpression", { + enumerable: true, + get: function () { + return _index.thisExpression; + } +}); +Object.defineProperty(exports, "ThisTypeAnnotation", { + enumerable: true, + get: function () { + return _index.thisTypeAnnotation; + } +}); +Object.defineProperty(exports, "ThrowStatement", { + enumerable: true, + get: function () { + return _index.throwStatement; + } +}); +Object.defineProperty(exports, "TopicReference", { + enumerable: true, + get: function () { + return _index.topicReference; + } +}); +Object.defineProperty(exports, "TryStatement", { + enumerable: true, + get: function () { + return _index.tryStatement; + } +}); +Object.defineProperty(exports, "TupleExpression", { + enumerable: true, + get: function () { + return _index.tupleExpression; + } +}); +Object.defineProperty(exports, "TupleTypeAnnotation", { + enumerable: true, + get: function () { + return _index.tupleTypeAnnotation; + } +}); +Object.defineProperty(exports, "TypeAlias", { + enumerable: true, + get: function () { + return _index.typeAlias; + } +}); +Object.defineProperty(exports, "TypeAnnotation", { + enumerable: true, + get: function () { + return _index.typeAnnotation; + } +}); +Object.defineProperty(exports, "TypeCastExpression", { + enumerable: true, + get: function () { + return _index.typeCastExpression; + } +}); +Object.defineProperty(exports, "TypeParameter", { + enumerable: true, + get: function () { + return _index.typeParameter; + } +}); +Object.defineProperty(exports, "TypeParameterDeclaration", { + enumerable: true, + get: function () { + return _index.typeParameterDeclaration; + } +}); +Object.defineProperty(exports, "TypeParameterInstantiation", { + enumerable: true, + get: function () { + return _index.typeParameterInstantiation; + } +}); +Object.defineProperty(exports, "TypeofTypeAnnotation", { + enumerable: true, + get: function () { + return _index.typeofTypeAnnotation; + } +}); +Object.defineProperty(exports, "UnaryExpression", { + enumerable: true, + get: function () { + return _index.unaryExpression; + } +}); +Object.defineProperty(exports, "UnionTypeAnnotation", { + enumerable: true, + get: function () { + return _index.unionTypeAnnotation; + } +}); +Object.defineProperty(exports, "UpdateExpression", { + enumerable: true, + get: function () { + return _index.updateExpression; + } +}); +Object.defineProperty(exports, "V8IntrinsicIdentifier", { + enumerable: true, + get: function () { + return _index.v8IntrinsicIdentifier; + } +}); +Object.defineProperty(exports, "VariableDeclaration", { + enumerable: true, + get: function () { + return _index.variableDeclaration; + } +}); +Object.defineProperty(exports, "VariableDeclarator", { + enumerable: true, + get: function () { + return _index.variableDeclarator; + } +}); +Object.defineProperty(exports, "Variance", { + enumerable: true, + get: function () { + return _index.variance; + } +}); +Object.defineProperty(exports, "VoidTypeAnnotation", { + enumerable: true, + get: function () { + return _index.voidTypeAnnotation; + } +}); +Object.defineProperty(exports, "WhileStatement", { + enumerable: true, + get: function () { + return _index.whileStatement; + } +}); +Object.defineProperty(exports, "WithStatement", { + enumerable: true, + get: function () { + return _index.withStatement; + } +}); +Object.defineProperty(exports, "YieldExpression", { + enumerable: true, + get: function () { + return _index.yieldExpression; + } +}); + +var _index = require("./index"); \ No newline at end of file diff --git a/node_modules/@babel/types/lib/constants/generated/index.js b/node_modules/@babel/types/lib/constants/generated/index.js new file mode 100644 index 000000000..1e109e6a4 --- /dev/null +++ b/node_modules/@babel/types/lib/constants/generated/index.js @@ -0,0 +1,107 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.WHILE_TYPES = exports.USERWHITESPACABLE_TYPES = exports.UNARYLIKE_TYPES = exports.TYPESCRIPT_TYPES = exports.TSTYPE_TYPES = exports.TSTYPEELEMENT_TYPES = exports.TSENTITYNAME_TYPES = exports.TSBASETYPE_TYPES = exports.TERMINATORLESS_TYPES = exports.STATEMENT_TYPES = exports.STANDARDIZED_TYPES = exports.SCOPABLE_TYPES = exports.PUREISH_TYPES = exports.PROPERTY_TYPES = exports.PRIVATE_TYPES = exports.PATTERN_TYPES = exports.PATTERNLIKE_TYPES = exports.OBJECTMEMBER_TYPES = exports.MODULESPECIFIER_TYPES = exports.MODULEDECLARATION_TYPES = exports.MISCELLANEOUS_TYPES = exports.METHOD_TYPES = exports.LVAL_TYPES = exports.LOOP_TYPES = exports.LITERAL_TYPES = exports.JSX_TYPES = exports.IMMUTABLE_TYPES = exports.FUNCTION_TYPES = exports.FUNCTIONPARENT_TYPES = exports.FOR_TYPES = exports.FORXSTATEMENT_TYPES = exports.FLOW_TYPES = exports.FLOWTYPE_TYPES = exports.FLOWPREDICATE_TYPES = exports.FLOWDECLARATION_TYPES = exports.FLOWBASEANNOTATION_TYPES = exports.EXPRESSION_TYPES = exports.EXPRESSIONWRAPPER_TYPES = exports.EXPORTDECLARATION_TYPES = exports.ENUMMEMBER_TYPES = exports.ENUMBODY_TYPES = exports.DECLARATION_TYPES = exports.CONDITIONAL_TYPES = exports.COMPLETIONSTATEMENT_TYPES = exports.CLASS_TYPES = exports.BLOCK_TYPES = exports.BLOCKPARENT_TYPES = exports.BINARY_TYPES = exports.ACCESSOR_TYPES = void 0; + +var _definitions = require("../../definitions"); + +const STANDARDIZED_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Standardized"]; +exports.STANDARDIZED_TYPES = STANDARDIZED_TYPES; +const EXPRESSION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Expression"]; +exports.EXPRESSION_TYPES = EXPRESSION_TYPES; +const BINARY_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Binary"]; +exports.BINARY_TYPES = BINARY_TYPES; +const SCOPABLE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Scopable"]; +exports.SCOPABLE_TYPES = SCOPABLE_TYPES; +const BLOCKPARENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["BlockParent"]; +exports.BLOCKPARENT_TYPES = BLOCKPARENT_TYPES; +const BLOCK_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Block"]; +exports.BLOCK_TYPES = BLOCK_TYPES; +const STATEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Statement"]; +exports.STATEMENT_TYPES = STATEMENT_TYPES; +const TERMINATORLESS_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Terminatorless"]; +exports.TERMINATORLESS_TYPES = TERMINATORLESS_TYPES; +const COMPLETIONSTATEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["CompletionStatement"]; +exports.COMPLETIONSTATEMENT_TYPES = COMPLETIONSTATEMENT_TYPES; +const CONDITIONAL_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Conditional"]; +exports.CONDITIONAL_TYPES = CONDITIONAL_TYPES; +const LOOP_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Loop"]; +exports.LOOP_TYPES = LOOP_TYPES; +const WHILE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["While"]; +exports.WHILE_TYPES = WHILE_TYPES; +const EXPRESSIONWRAPPER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ExpressionWrapper"]; +exports.EXPRESSIONWRAPPER_TYPES = EXPRESSIONWRAPPER_TYPES; +const FOR_TYPES = _definitions.FLIPPED_ALIAS_KEYS["For"]; +exports.FOR_TYPES = FOR_TYPES; +const FORXSTATEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ForXStatement"]; +exports.FORXSTATEMENT_TYPES = FORXSTATEMENT_TYPES; +const FUNCTION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Function"]; +exports.FUNCTION_TYPES = FUNCTION_TYPES; +const FUNCTIONPARENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FunctionParent"]; +exports.FUNCTIONPARENT_TYPES = FUNCTIONPARENT_TYPES; +const PUREISH_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Pureish"]; +exports.PUREISH_TYPES = PUREISH_TYPES; +const DECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Declaration"]; +exports.DECLARATION_TYPES = DECLARATION_TYPES; +const PATTERNLIKE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["PatternLike"]; +exports.PATTERNLIKE_TYPES = PATTERNLIKE_TYPES; +const LVAL_TYPES = _definitions.FLIPPED_ALIAS_KEYS["LVal"]; +exports.LVAL_TYPES = LVAL_TYPES; +const TSENTITYNAME_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSEntityName"]; +exports.TSENTITYNAME_TYPES = TSENTITYNAME_TYPES; +const LITERAL_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Literal"]; +exports.LITERAL_TYPES = LITERAL_TYPES; +const IMMUTABLE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Immutable"]; +exports.IMMUTABLE_TYPES = IMMUTABLE_TYPES; +const USERWHITESPACABLE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["UserWhitespacable"]; +exports.USERWHITESPACABLE_TYPES = USERWHITESPACABLE_TYPES; +const METHOD_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Method"]; +exports.METHOD_TYPES = METHOD_TYPES; +const OBJECTMEMBER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ObjectMember"]; +exports.OBJECTMEMBER_TYPES = OBJECTMEMBER_TYPES; +const PROPERTY_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Property"]; +exports.PROPERTY_TYPES = PROPERTY_TYPES; +const UNARYLIKE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["UnaryLike"]; +exports.UNARYLIKE_TYPES = UNARYLIKE_TYPES; +const PATTERN_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Pattern"]; +exports.PATTERN_TYPES = PATTERN_TYPES; +const CLASS_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Class"]; +exports.CLASS_TYPES = CLASS_TYPES; +const MODULEDECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ModuleDeclaration"]; +exports.MODULEDECLARATION_TYPES = MODULEDECLARATION_TYPES; +const EXPORTDECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ExportDeclaration"]; +exports.EXPORTDECLARATION_TYPES = EXPORTDECLARATION_TYPES; +const MODULESPECIFIER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ModuleSpecifier"]; +exports.MODULESPECIFIER_TYPES = MODULESPECIFIER_TYPES; +const ACCESSOR_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Accessor"]; +exports.ACCESSOR_TYPES = ACCESSOR_TYPES; +const PRIVATE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Private"]; +exports.PRIVATE_TYPES = PRIVATE_TYPES; +const FLOW_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Flow"]; +exports.FLOW_TYPES = FLOW_TYPES; +const FLOWTYPE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowType"]; +exports.FLOWTYPE_TYPES = FLOWTYPE_TYPES; +const FLOWBASEANNOTATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowBaseAnnotation"]; +exports.FLOWBASEANNOTATION_TYPES = FLOWBASEANNOTATION_TYPES; +const FLOWDECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowDeclaration"]; +exports.FLOWDECLARATION_TYPES = FLOWDECLARATION_TYPES; +const FLOWPREDICATE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowPredicate"]; +exports.FLOWPREDICATE_TYPES = FLOWPREDICATE_TYPES; +const ENUMBODY_TYPES = _definitions.FLIPPED_ALIAS_KEYS["EnumBody"]; +exports.ENUMBODY_TYPES = ENUMBODY_TYPES; +const ENUMMEMBER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["EnumMember"]; +exports.ENUMMEMBER_TYPES = ENUMMEMBER_TYPES; +const JSX_TYPES = _definitions.FLIPPED_ALIAS_KEYS["JSX"]; +exports.JSX_TYPES = JSX_TYPES; +const MISCELLANEOUS_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Miscellaneous"]; +exports.MISCELLANEOUS_TYPES = MISCELLANEOUS_TYPES; +const TYPESCRIPT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TypeScript"]; +exports.TYPESCRIPT_TYPES = TYPESCRIPT_TYPES; +const TSTYPEELEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSTypeElement"]; +exports.TSTYPEELEMENT_TYPES = TSTYPEELEMENT_TYPES; +const TSTYPE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSType"]; +exports.TSTYPE_TYPES = TSTYPE_TYPES; +const TSBASETYPE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSBaseType"]; +exports.TSBASETYPE_TYPES = TSBASETYPE_TYPES; \ No newline at end of file diff --git a/node_modules/@babel/types/lib/validators/generated/index.js b/node_modules/@babel/types/lib/validators/generated/index.js new file mode 100644 index 000000000..f2956ec01 --- /dev/null +++ b/node_modules/@babel/types/lib/validators/generated/index.js @@ -0,0 +1,4811 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.isAccessor = isAccessor; +exports.isAnyTypeAnnotation = isAnyTypeAnnotation; +exports.isArgumentPlaceholder = isArgumentPlaceholder; +exports.isArrayExpression = isArrayExpression; +exports.isArrayPattern = isArrayPattern; +exports.isArrayTypeAnnotation = isArrayTypeAnnotation; +exports.isArrowFunctionExpression = isArrowFunctionExpression; +exports.isAssignmentExpression = isAssignmentExpression; +exports.isAssignmentPattern = isAssignmentPattern; +exports.isAwaitExpression = isAwaitExpression; +exports.isBigIntLiteral = isBigIntLiteral; +exports.isBinary = isBinary; +exports.isBinaryExpression = isBinaryExpression; +exports.isBindExpression = isBindExpression; +exports.isBlock = isBlock; +exports.isBlockParent = isBlockParent; +exports.isBlockStatement = isBlockStatement; +exports.isBooleanLiteral = isBooleanLiteral; +exports.isBooleanLiteralTypeAnnotation = isBooleanLiteralTypeAnnotation; +exports.isBooleanTypeAnnotation = isBooleanTypeAnnotation; +exports.isBreakStatement = isBreakStatement; +exports.isCallExpression = isCallExpression; +exports.isCatchClause = isCatchClause; +exports.isClass = isClass; +exports.isClassAccessorProperty = isClassAccessorProperty; +exports.isClassBody = isClassBody; +exports.isClassDeclaration = isClassDeclaration; +exports.isClassExpression = isClassExpression; +exports.isClassImplements = isClassImplements; +exports.isClassMethod = isClassMethod; +exports.isClassPrivateMethod = isClassPrivateMethod; +exports.isClassPrivateProperty = isClassPrivateProperty; +exports.isClassProperty = isClassProperty; +exports.isCompletionStatement = isCompletionStatement; +exports.isConditional = isConditional; +exports.isConditionalExpression = isConditionalExpression; +exports.isContinueStatement = isContinueStatement; +exports.isDebuggerStatement = isDebuggerStatement; +exports.isDecimalLiteral = isDecimalLiteral; +exports.isDeclaration = isDeclaration; +exports.isDeclareClass = isDeclareClass; +exports.isDeclareExportAllDeclaration = isDeclareExportAllDeclaration; +exports.isDeclareExportDeclaration = isDeclareExportDeclaration; +exports.isDeclareFunction = isDeclareFunction; +exports.isDeclareInterface = isDeclareInterface; +exports.isDeclareModule = isDeclareModule; +exports.isDeclareModuleExports = isDeclareModuleExports; +exports.isDeclareOpaqueType = isDeclareOpaqueType; +exports.isDeclareTypeAlias = isDeclareTypeAlias; +exports.isDeclareVariable = isDeclareVariable; +exports.isDeclaredPredicate = isDeclaredPredicate; +exports.isDecorator = isDecorator; +exports.isDirective = isDirective; +exports.isDirectiveLiteral = isDirectiveLiteral; +exports.isDoExpression = isDoExpression; +exports.isDoWhileStatement = isDoWhileStatement; +exports.isEmptyStatement = isEmptyStatement; +exports.isEmptyTypeAnnotation = isEmptyTypeAnnotation; +exports.isEnumBody = isEnumBody; +exports.isEnumBooleanBody = isEnumBooleanBody; +exports.isEnumBooleanMember = isEnumBooleanMember; +exports.isEnumDeclaration = isEnumDeclaration; +exports.isEnumDefaultedMember = isEnumDefaultedMember; +exports.isEnumMember = isEnumMember; +exports.isEnumNumberBody = isEnumNumberBody; +exports.isEnumNumberMember = isEnumNumberMember; +exports.isEnumStringBody = isEnumStringBody; +exports.isEnumStringMember = isEnumStringMember; +exports.isEnumSymbolBody = isEnumSymbolBody; +exports.isExistsTypeAnnotation = isExistsTypeAnnotation; +exports.isExportAllDeclaration = isExportAllDeclaration; +exports.isExportDeclaration = isExportDeclaration; +exports.isExportDefaultDeclaration = isExportDefaultDeclaration; +exports.isExportDefaultSpecifier = isExportDefaultSpecifier; +exports.isExportNamedDeclaration = isExportNamedDeclaration; +exports.isExportNamespaceSpecifier = isExportNamespaceSpecifier; +exports.isExportSpecifier = isExportSpecifier; +exports.isExpression = isExpression; +exports.isExpressionStatement = isExpressionStatement; +exports.isExpressionWrapper = isExpressionWrapper; +exports.isFile = isFile; +exports.isFlow = isFlow; +exports.isFlowBaseAnnotation = isFlowBaseAnnotation; +exports.isFlowDeclaration = isFlowDeclaration; +exports.isFlowPredicate = isFlowPredicate; +exports.isFlowType = isFlowType; +exports.isFor = isFor; +exports.isForInStatement = isForInStatement; +exports.isForOfStatement = isForOfStatement; +exports.isForStatement = isForStatement; +exports.isForXStatement = isForXStatement; +exports.isFunction = isFunction; +exports.isFunctionDeclaration = isFunctionDeclaration; +exports.isFunctionExpression = isFunctionExpression; +exports.isFunctionParent = isFunctionParent; +exports.isFunctionTypeAnnotation = isFunctionTypeAnnotation; +exports.isFunctionTypeParam = isFunctionTypeParam; +exports.isGenericTypeAnnotation = isGenericTypeAnnotation; +exports.isIdentifier = isIdentifier; +exports.isIfStatement = isIfStatement; +exports.isImmutable = isImmutable; +exports.isImport = isImport; +exports.isImportAttribute = isImportAttribute; +exports.isImportDeclaration = isImportDeclaration; +exports.isImportDefaultSpecifier = isImportDefaultSpecifier; +exports.isImportNamespaceSpecifier = isImportNamespaceSpecifier; +exports.isImportSpecifier = isImportSpecifier; +exports.isIndexedAccessType = isIndexedAccessType; +exports.isInferredPredicate = isInferredPredicate; +exports.isInterfaceDeclaration = isInterfaceDeclaration; +exports.isInterfaceExtends = isInterfaceExtends; +exports.isInterfaceTypeAnnotation = isInterfaceTypeAnnotation; +exports.isInterpreterDirective = isInterpreterDirective; +exports.isIntersectionTypeAnnotation = isIntersectionTypeAnnotation; +exports.isJSX = isJSX; +exports.isJSXAttribute = isJSXAttribute; +exports.isJSXClosingElement = isJSXClosingElement; +exports.isJSXClosingFragment = isJSXClosingFragment; +exports.isJSXElement = isJSXElement; +exports.isJSXEmptyExpression = isJSXEmptyExpression; +exports.isJSXExpressionContainer = isJSXExpressionContainer; +exports.isJSXFragment = isJSXFragment; +exports.isJSXIdentifier = isJSXIdentifier; +exports.isJSXMemberExpression = isJSXMemberExpression; +exports.isJSXNamespacedName = isJSXNamespacedName; +exports.isJSXOpeningElement = isJSXOpeningElement; +exports.isJSXOpeningFragment = isJSXOpeningFragment; +exports.isJSXSpreadAttribute = isJSXSpreadAttribute; +exports.isJSXSpreadChild = isJSXSpreadChild; +exports.isJSXText = isJSXText; +exports.isLVal = isLVal; +exports.isLabeledStatement = isLabeledStatement; +exports.isLiteral = isLiteral; +exports.isLogicalExpression = isLogicalExpression; +exports.isLoop = isLoop; +exports.isMemberExpression = isMemberExpression; +exports.isMetaProperty = isMetaProperty; +exports.isMethod = isMethod; +exports.isMiscellaneous = isMiscellaneous; +exports.isMixedTypeAnnotation = isMixedTypeAnnotation; +exports.isModuleDeclaration = isModuleDeclaration; +exports.isModuleExpression = isModuleExpression; +exports.isModuleSpecifier = isModuleSpecifier; +exports.isNewExpression = isNewExpression; +exports.isNoop = isNoop; +exports.isNullLiteral = isNullLiteral; +exports.isNullLiteralTypeAnnotation = isNullLiteralTypeAnnotation; +exports.isNullableTypeAnnotation = isNullableTypeAnnotation; +exports.isNumberLiteral = isNumberLiteral; +exports.isNumberLiteralTypeAnnotation = isNumberLiteralTypeAnnotation; +exports.isNumberTypeAnnotation = isNumberTypeAnnotation; +exports.isNumericLiteral = isNumericLiteral; +exports.isObjectExpression = isObjectExpression; +exports.isObjectMember = isObjectMember; +exports.isObjectMethod = isObjectMethod; +exports.isObjectPattern = isObjectPattern; +exports.isObjectProperty = isObjectProperty; +exports.isObjectTypeAnnotation = isObjectTypeAnnotation; +exports.isObjectTypeCallProperty = isObjectTypeCallProperty; +exports.isObjectTypeIndexer = isObjectTypeIndexer; +exports.isObjectTypeInternalSlot = isObjectTypeInternalSlot; +exports.isObjectTypeProperty = isObjectTypeProperty; +exports.isObjectTypeSpreadProperty = isObjectTypeSpreadProperty; +exports.isOpaqueType = isOpaqueType; +exports.isOptionalCallExpression = isOptionalCallExpression; +exports.isOptionalIndexedAccessType = isOptionalIndexedAccessType; +exports.isOptionalMemberExpression = isOptionalMemberExpression; +exports.isParenthesizedExpression = isParenthesizedExpression; +exports.isPattern = isPattern; +exports.isPatternLike = isPatternLike; +exports.isPipelineBareFunction = isPipelineBareFunction; +exports.isPipelinePrimaryTopicReference = isPipelinePrimaryTopicReference; +exports.isPipelineTopicExpression = isPipelineTopicExpression; +exports.isPlaceholder = isPlaceholder; +exports.isPrivate = isPrivate; +exports.isPrivateName = isPrivateName; +exports.isProgram = isProgram; +exports.isProperty = isProperty; +exports.isPureish = isPureish; +exports.isQualifiedTypeIdentifier = isQualifiedTypeIdentifier; +exports.isRecordExpression = isRecordExpression; +exports.isRegExpLiteral = isRegExpLiteral; +exports.isRegexLiteral = isRegexLiteral; +exports.isRestElement = isRestElement; +exports.isRestProperty = isRestProperty; +exports.isReturnStatement = isReturnStatement; +exports.isScopable = isScopable; +exports.isSequenceExpression = isSequenceExpression; +exports.isSpreadElement = isSpreadElement; +exports.isSpreadProperty = isSpreadProperty; +exports.isStandardized = isStandardized; +exports.isStatement = isStatement; +exports.isStaticBlock = isStaticBlock; +exports.isStringLiteral = isStringLiteral; +exports.isStringLiteralTypeAnnotation = isStringLiteralTypeAnnotation; +exports.isStringTypeAnnotation = isStringTypeAnnotation; +exports.isSuper = isSuper; +exports.isSwitchCase = isSwitchCase; +exports.isSwitchStatement = isSwitchStatement; +exports.isSymbolTypeAnnotation = isSymbolTypeAnnotation; +exports.isTSAnyKeyword = isTSAnyKeyword; +exports.isTSArrayType = isTSArrayType; +exports.isTSAsExpression = isTSAsExpression; +exports.isTSBaseType = isTSBaseType; +exports.isTSBigIntKeyword = isTSBigIntKeyword; +exports.isTSBooleanKeyword = isTSBooleanKeyword; +exports.isTSCallSignatureDeclaration = isTSCallSignatureDeclaration; +exports.isTSConditionalType = isTSConditionalType; +exports.isTSConstructSignatureDeclaration = isTSConstructSignatureDeclaration; +exports.isTSConstructorType = isTSConstructorType; +exports.isTSDeclareFunction = isTSDeclareFunction; +exports.isTSDeclareMethod = isTSDeclareMethod; +exports.isTSEntityName = isTSEntityName; +exports.isTSEnumDeclaration = isTSEnumDeclaration; +exports.isTSEnumMember = isTSEnumMember; +exports.isTSExportAssignment = isTSExportAssignment; +exports.isTSExpressionWithTypeArguments = isTSExpressionWithTypeArguments; +exports.isTSExternalModuleReference = isTSExternalModuleReference; +exports.isTSFunctionType = isTSFunctionType; +exports.isTSImportEqualsDeclaration = isTSImportEqualsDeclaration; +exports.isTSImportType = isTSImportType; +exports.isTSIndexSignature = isTSIndexSignature; +exports.isTSIndexedAccessType = isTSIndexedAccessType; +exports.isTSInferType = isTSInferType; +exports.isTSInterfaceBody = isTSInterfaceBody; +exports.isTSInterfaceDeclaration = isTSInterfaceDeclaration; +exports.isTSIntersectionType = isTSIntersectionType; +exports.isTSIntrinsicKeyword = isTSIntrinsicKeyword; +exports.isTSLiteralType = isTSLiteralType; +exports.isTSMappedType = isTSMappedType; +exports.isTSMethodSignature = isTSMethodSignature; +exports.isTSModuleBlock = isTSModuleBlock; +exports.isTSModuleDeclaration = isTSModuleDeclaration; +exports.isTSNamedTupleMember = isTSNamedTupleMember; +exports.isTSNamespaceExportDeclaration = isTSNamespaceExportDeclaration; +exports.isTSNeverKeyword = isTSNeverKeyword; +exports.isTSNonNullExpression = isTSNonNullExpression; +exports.isTSNullKeyword = isTSNullKeyword; +exports.isTSNumberKeyword = isTSNumberKeyword; +exports.isTSObjectKeyword = isTSObjectKeyword; +exports.isTSOptionalType = isTSOptionalType; +exports.isTSParameterProperty = isTSParameterProperty; +exports.isTSParenthesizedType = isTSParenthesizedType; +exports.isTSPropertySignature = isTSPropertySignature; +exports.isTSQualifiedName = isTSQualifiedName; +exports.isTSRestType = isTSRestType; +exports.isTSStringKeyword = isTSStringKeyword; +exports.isTSSymbolKeyword = isTSSymbolKeyword; +exports.isTSThisType = isTSThisType; +exports.isTSTupleType = isTSTupleType; +exports.isTSType = isTSType; +exports.isTSTypeAliasDeclaration = isTSTypeAliasDeclaration; +exports.isTSTypeAnnotation = isTSTypeAnnotation; +exports.isTSTypeAssertion = isTSTypeAssertion; +exports.isTSTypeElement = isTSTypeElement; +exports.isTSTypeLiteral = isTSTypeLiteral; +exports.isTSTypeOperator = isTSTypeOperator; +exports.isTSTypeParameter = isTSTypeParameter; +exports.isTSTypeParameterDeclaration = isTSTypeParameterDeclaration; +exports.isTSTypeParameterInstantiation = isTSTypeParameterInstantiation; +exports.isTSTypePredicate = isTSTypePredicate; +exports.isTSTypeQuery = isTSTypeQuery; +exports.isTSTypeReference = isTSTypeReference; +exports.isTSUndefinedKeyword = isTSUndefinedKeyword; +exports.isTSUnionType = isTSUnionType; +exports.isTSUnknownKeyword = isTSUnknownKeyword; +exports.isTSVoidKeyword = isTSVoidKeyword; +exports.isTaggedTemplateExpression = isTaggedTemplateExpression; +exports.isTemplateElement = isTemplateElement; +exports.isTemplateLiteral = isTemplateLiteral; +exports.isTerminatorless = isTerminatorless; +exports.isThisExpression = isThisExpression; +exports.isThisTypeAnnotation = isThisTypeAnnotation; +exports.isThrowStatement = isThrowStatement; +exports.isTopicReference = isTopicReference; +exports.isTryStatement = isTryStatement; +exports.isTupleExpression = isTupleExpression; +exports.isTupleTypeAnnotation = isTupleTypeAnnotation; +exports.isTypeAlias = isTypeAlias; +exports.isTypeAnnotation = isTypeAnnotation; +exports.isTypeCastExpression = isTypeCastExpression; +exports.isTypeParameter = isTypeParameter; +exports.isTypeParameterDeclaration = isTypeParameterDeclaration; +exports.isTypeParameterInstantiation = isTypeParameterInstantiation; +exports.isTypeScript = isTypeScript; +exports.isTypeofTypeAnnotation = isTypeofTypeAnnotation; +exports.isUnaryExpression = isUnaryExpression; +exports.isUnaryLike = isUnaryLike; +exports.isUnionTypeAnnotation = isUnionTypeAnnotation; +exports.isUpdateExpression = isUpdateExpression; +exports.isUserWhitespacable = isUserWhitespacable; +exports.isV8IntrinsicIdentifier = isV8IntrinsicIdentifier; +exports.isVariableDeclaration = isVariableDeclaration; +exports.isVariableDeclarator = isVariableDeclarator; +exports.isVariance = isVariance; +exports.isVoidTypeAnnotation = isVoidTypeAnnotation; +exports.isWhile = isWhile; +exports.isWhileStatement = isWhileStatement; +exports.isWithStatement = isWithStatement; +exports.isYieldExpression = isYieldExpression; + +var _shallowEqual = require("../../utils/shallowEqual"); + +function isArrayExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrayExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAssignmentExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AssignmentExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBinaryExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BinaryExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterpreterDirective(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterpreterDirective") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDirective(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Directive") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDirectiveLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DirectiveLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBlockStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BlockStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBreakStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BreakStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isCallExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "CallExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isCatchClause(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "CatchClause") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isConditionalExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ConditionalExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isContinueStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ContinueStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDebuggerStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DebuggerStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDoWhileStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DoWhileStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEmptyStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EmptyStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExpressionStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExpressionStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFile(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "File") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForInStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ForInStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ForStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Identifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIfStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "IfStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLabeledStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "LabeledStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStringLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StringLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumericLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumericLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNullLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NullLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBooleanLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BooleanLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRegExpLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RegExpLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLogicalExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "LogicalExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMemberExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "MemberExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNewExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NewExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isProgram(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Program") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRestElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RestElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isReturnStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ReturnStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSequenceExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SequenceExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isParenthesizedExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ParenthesizedExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSwitchCase(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SwitchCase") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSwitchStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SwitchStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isThisExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ThisExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isThrowStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ThrowStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTryStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TryStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUnaryExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "UnaryExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUpdateExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "UpdateExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVariableDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "VariableDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVariableDeclarator(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "VariableDeclarator") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isWhileStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "WhileStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isWithStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "WithStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAssignmentPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AssignmentPattern") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArrayPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrayPattern") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArrowFunctionExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrowFunctionExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportAllDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportAllDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportDefaultDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportDefaultDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportNamedDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportNamedDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForOfStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ForOfStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportDefaultSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportDefaultSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportNamespaceSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportNamespaceSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMetaProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "MetaProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectPattern") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSpreadElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SpreadElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSuper(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Super") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTaggedTemplateExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TaggedTemplateExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTemplateElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TemplateElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTemplateLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TemplateLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isYieldExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "YieldExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAwaitExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AwaitExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImport(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Import") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBigIntLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BigIntLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportNamespaceSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportNamespaceSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOptionalMemberExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OptionalMemberExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOptionalCallExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OptionalCallExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassAccessorProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassAccessorProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassPrivateProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassPrivateProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassPrivateMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassPrivateMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPrivateName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PrivateName") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStaticBlock(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StaticBlock") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAnyTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AnyTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArrayTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrayTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBooleanTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BooleanTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBooleanLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BooleanLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNullLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NullLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassImplements(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassImplements") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareClass(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareClass") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareFunction") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareInterface(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareInterface") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareModule(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareModule") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareModuleExports(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareModuleExports") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareTypeAlias(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareTypeAlias") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareOpaqueType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareOpaqueType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareVariable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareVariable") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareExportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareExportDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareExportAllDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareExportAllDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclaredPredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclaredPredicate") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExistsTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExistsTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionTypeParam(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionTypeParam") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isGenericTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "GenericTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInferredPredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InferredPredicate") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterfaceExtends(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterfaceExtends") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterfaceDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterfaceDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterfaceTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterfaceTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIntersectionTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "IntersectionTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMixedTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "MixedTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEmptyTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EmptyTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNullableTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NullableTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumberLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumberLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumberTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumberTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeInternalSlot(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeInternalSlot") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeCallProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeCallProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeIndexer(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeIndexer") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeSpreadProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeSpreadProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOpaqueType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OpaqueType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isQualifiedTypeIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "QualifiedTypeIdentifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStringLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StringLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStringTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StringTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSymbolTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SymbolTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isThisTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ThisTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTupleTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TupleTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeofTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeofTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeAlias(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeAlias") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeCastExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeCastExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeParameter(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeParameter") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeParameterDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeParameterDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeParameterInstantiation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeParameterInstantiation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUnionTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "UnionTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVariance(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Variance") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVoidTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "VoidTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumBooleanBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumBooleanBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumNumberBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumNumberBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumStringBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumStringBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumSymbolBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumSymbolBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumBooleanMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumBooleanMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumNumberMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumNumberMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumStringMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumStringMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumDefaultedMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumDefaultedMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIndexedAccessType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "IndexedAccessType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOptionalIndexedAccessType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OptionalIndexedAccessType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXAttribute(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXAttribute") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXClosingElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXClosingElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXEmptyExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXEmptyExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXExpressionContainer(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXExpressionContainer") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXSpreadChild(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXSpreadChild") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXIdentifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXMemberExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXMemberExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXNamespacedName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXNamespacedName") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXOpeningElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXOpeningElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXSpreadAttribute(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXSpreadAttribute") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXText(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXText") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXFragment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXFragment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXOpeningFragment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXOpeningFragment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXClosingFragment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXClosingFragment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNoop(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Noop") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPlaceholder(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Placeholder") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isV8IntrinsicIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "V8IntrinsicIdentifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArgumentPlaceholder(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArgumentPlaceholder") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBindExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BindExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportAttribute(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportAttribute") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDecorator(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Decorator") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDoExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DoExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportDefaultSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportDefaultSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRecordExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RecordExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTupleExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TupleExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDecimalLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DecimalLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isModuleExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ModuleExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTopicReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TopicReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPipelineTopicExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PipelineTopicExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPipelineBareFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PipelineBareFunction") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPipelinePrimaryTopicReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PipelinePrimaryTopicReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSParameterProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSParameterProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSDeclareFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSDeclareFunction") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSDeclareMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSDeclareMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSQualifiedName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSQualifiedName") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSCallSignatureDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSCallSignatureDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSConstructSignatureDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSConstructSignatureDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSPropertySignature(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSPropertySignature") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSMethodSignature(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSMethodSignature") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIndexSignature(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIndexSignature") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSAnyKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSAnyKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSBooleanKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSBooleanKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSBigIntKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSBigIntKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIntrinsicKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIntrinsicKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNeverKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNeverKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNullKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNullKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNumberKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNumberKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSObjectKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSObjectKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSStringKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSStringKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSSymbolKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSSymbolKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSUndefinedKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSUndefinedKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSUnknownKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSUnknownKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSVoidKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSVoidKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSThisType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSThisType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSFunctionType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSFunctionType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSConstructorType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSConstructorType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypePredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypePredicate") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeQuery(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeQuery") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSArrayType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSArrayType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTupleType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTupleType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSOptionalType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSOptionalType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSRestType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSRestType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNamedTupleMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNamedTupleMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSUnionType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSUnionType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIntersectionType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIntersectionType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSConditionalType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSConditionalType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSInferType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSInferType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSParenthesizedType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSParenthesizedType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeOperator(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeOperator") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIndexedAccessType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIndexedAccessType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSMappedType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSMappedType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSLiteralType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSLiteralType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSExpressionWithTypeArguments(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSExpressionWithTypeArguments") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSInterfaceDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSInterfaceDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSInterfaceBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSInterfaceBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeAliasDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeAliasDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSAsExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSAsExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeAssertion(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeAssertion") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSEnumDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSEnumDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSEnumMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSEnumMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSModuleDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSModuleDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSModuleBlock(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSModuleBlock") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSImportType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSImportType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSImportEqualsDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSImportEqualsDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSExternalModuleReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSExternalModuleReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNonNullExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNonNullExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSExportAssignment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSExportAssignment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNamespaceExportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNamespaceExportDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeParameterInstantiation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeParameterInstantiation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeParameterDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeParameterDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeParameter(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeParameter") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStandardized(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ArrayExpression" === nodeType || "AssignmentExpression" === nodeType || "BinaryExpression" === nodeType || "InterpreterDirective" === nodeType || "Directive" === nodeType || "DirectiveLiteral" === nodeType || "BlockStatement" === nodeType || "BreakStatement" === nodeType || "CallExpression" === nodeType || "CatchClause" === nodeType || "ConditionalExpression" === nodeType || "ContinueStatement" === nodeType || "DebuggerStatement" === nodeType || "DoWhileStatement" === nodeType || "EmptyStatement" === nodeType || "ExpressionStatement" === nodeType || "File" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "Identifier" === nodeType || "IfStatement" === nodeType || "LabeledStatement" === nodeType || "StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "LogicalExpression" === nodeType || "MemberExpression" === nodeType || "NewExpression" === nodeType || "Program" === nodeType || "ObjectExpression" === nodeType || "ObjectMethod" === nodeType || "ObjectProperty" === nodeType || "RestElement" === nodeType || "ReturnStatement" === nodeType || "SequenceExpression" === nodeType || "ParenthesizedExpression" === nodeType || "SwitchCase" === nodeType || "SwitchStatement" === nodeType || "ThisExpression" === nodeType || "ThrowStatement" === nodeType || "TryStatement" === nodeType || "UnaryExpression" === nodeType || "UpdateExpression" === nodeType || "VariableDeclaration" === nodeType || "VariableDeclarator" === nodeType || "WhileStatement" === nodeType || "WithStatement" === nodeType || "AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassBody" === nodeType || "ClassExpression" === nodeType || "ClassDeclaration" === nodeType || "ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ExportSpecifier" === nodeType || "ForOfStatement" === nodeType || "ImportDeclaration" === nodeType || "ImportDefaultSpecifier" === nodeType || "ImportNamespaceSpecifier" === nodeType || "ImportSpecifier" === nodeType || "MetaProperty" === nodeType || "ClassMethod" === nodeType || "ObjectPattern" === nodeType || "SpreadElement" === nodeType || "Super" === nodeType || "TaggedTemplateExpression" === nodeType || "TemplateElement" === nodeType || "TemplateLiteral" === nodeType || "YieldExpression" === nodeType || "AwaitExpression" === nodeType || "Import" === nodeType || "BigIntLiteral" === nodeType || "ExportNamespaceSpecifier" === nodeType || "OptionalMemberExpression" === nodeType || "OptionalCallExpression" === nodeType || "ClassProperty" === nodeType || "ClassAccessorProperty" === nodeType || "ClassPrivateProperty" === nodeType || "ClassPrivateMethod" === nodeType || "PrivateName" === nodeType || "StaticBlock" === nodeType || nodeType === "Placeholder" && ("Identifier" === node.expectedNode || "StringLiteral" === node.expectedNode || "BlockStatement" === node.expectedNode || "ClassBody" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ArrayExpression" === nodeType || "AssignmentExpression" === nodeType || "BinaryExpression" === nodeType || "CallExpression" === nodeType || "ConditionalExpression" === nodeType || "FunctionExpression" === nodeType || "Identifier" === nodeType || "StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "LogicalExpression" === nodeType || "MemberExpression" === nodeType || "NewExpression" === nodeType || "ObjectExpression" === nodeType || "SequenceExpression" === nodeType || "ParenthesizedExpression" === nodeType || "ThisExpression" === nodeType || "UnaryExpression" === nodeType || "UpdateExpression" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassExpression" === nodeType || "MetaProperty" === nodeType || "Super" === nodeType || "TaggedTemplateExpression" === nodeType || "TemplateLiteral" === nodeType || "YieldExpression" === nodeType || "AwaitExpression" === nodeType || "Import" === nodeType || "BigIntLiteral" === nodeType || "OptionalMemberExpression" === nodeType || "OptionalCallExpression" === nodeType || "TypeCastExpression" === nodeType || "JSXElement" === nodeType || "JSXFragment" === nodeType || "BindExpression" === nodeType || "DoExpression" === nodeType || "RecordExpression" === nodeType || "TupleExpression" === nodeType || "DecimalLiteral" === nodeType || "ModuleExpression" === nodeType || "TopicReference" === nodeType || "PipelineTopicExpression" === nodeType || "PipelineBareFunction" === nodeType || "PipelinePrimaryTopicReference" === nodeType || "TSAsExpression" === nodeType || "TSTypeAssertion" === nodeType || "TSNonNullExpression" === nodeType || nodeType === "Placeholder" && ("Expression" === node.expectedNode || "Identifier" === node.expectedNode || "StringLiteral" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBinary(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BinaryExpression" === nodeType || "LogicalExpression" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isScopable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "CatchClause" === nodeType || "DoWhileStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "Program" === nodeType || "ObjectMethod" === nodeType || "SwitchStatement" === nodeType || "WhileStatement" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassExpression" === nodeType || "ClassDeclaration" === nodeType || "ForOfStatement" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType || "StaticBlock" === nodeType || "TSModuleBlock" === nodeType || nodeType === "Placeholder" && "BlockStatement" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBlockParent(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "CatchClause" === nodeType || "DoWhileStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "Program" === nodeType || "ObjectMethod" === nodeType || "SwitchStatement" === nodeType || "WhileStatement" === nodeType || "ArrowFunctionExpression" === nodeType || "ForOfStatement" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType || "StaticBlock" === nodeType || "TSModuleBlock" === nodeType || nodeType === "Placeholder" && "BlockStatement" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBlock(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "Program" === nodeType || "TSModuleBlock" === nodeType || nodeType === "Placeholder" && "BlockStatement" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "BreakStatement" === nodeType || "ContinueStatement" === nodeType || "DebuggerStatement" === nodeType || "DoWhileStatement" === nodeType || "EmptyStatement" === nodeType || "ExpressionStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "IfStatement" === nodeType || "LabeledStatement" === nodeType || "ReturnStatement" === nodeType || "SwitchStatement" === nodeType || "ThrowStatement" === nodeType || "TryStatement" === nodeType || "VariableDeclaration" === nodeType || "WhileStatement" === nodeType || "WithStatement" === nodeType || "ClassDeclaration" === nodeType || "ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ForOfStatement" === nodeType || "ImportDeclaration" === nodeType || "DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "InterfaceDeclaration" === nodeType || "OpaqueType" === nodeType || "TypeAlias" === nodeType || "EnumDeclaration" === nodeType || "TSDeclareFunction" === nodeType || "TSInterfaceDeclaration" === nodeType || "TSTypeAliasDeclaration" === nodeType || "TSEnumDeclaration" === nodeType || "TSModuleDeclaration" === nodeType || "TSImportEqualsDeclaration" === nodeType || "TSExportAssignment" === nodeType || "TSNamespaceExportDeclaration" === nodeType || nodeType === "Placeholder" && ("Statement" === node.expectedNode || "Declaration" === node.expectedNode || "BlockStatement" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTerminatorless(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BreakStatement" === nodeType || "ContinueStatement" === nodeType || "ReturnStatement" === nodeType || "ThrowStatement" === nodeType || "YieldExpression" === nodeType || "AwaitExpression" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isCompletionStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BreakStatement" === nodeType || "ContinueStatement" === nodeType || "ReturnStatement" === nodeType || "ThrowStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isConditional(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ConditionalExpression" === nodeType || "IfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLoop(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DoWhileStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "WhileStatement" === nodeType || "ForOfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isWhile(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DoWhileStatement" === nodeType || "WhileStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExpressionWrapper(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExpressionStatement" === nodeType || "ParenthesizedExpression" === nodeType || "TypeCastExpression" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFor(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ForInStatement" === nodeType || "ForStatement" === nodeType || "ForOfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForXStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ForInStatement" === nodeType || "ForOfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "ObjectMethod" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionParent(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "ObjectMethod" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType || "StaticBlock" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPureish(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "ArrowFunctionExpression" === nodeType || "BigIntLiteral" === nodeType || "DecimalLiteral" === nodeType || nodeType === "Placeholder" && "StringLiteral" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "VariableDeclaration" === nodeType || "ClassDeclaration" === nodeType || "ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ImportDeclaration" === nodeType || "DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "InterfaceDeclaration" === nodeType || "OpaqueType" === nodeType || "TypeAlias" === nodeType || "EnumDeclaration" === nodeType || "TSDeclareFunction" === nodeType || "TSInterfaceDeclaration" === nodeType || "TSTypeAliasDeclaration" === nodeType || "TSEnumDeclaration" === nodeType || "TSModuleDeclaration" === nodeType || nodeType === "Placeholder" && "Declaration" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPatternLike(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Identifier" === nodeType || "RestElement" === nodeType || "AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ObjectPattern" === nodeType || nodeType === "Placeholder" && ("Pattern" === node.expectedNode || "Identifier" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLVal(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Identifier" === nodeType || "MemberExpression" === nodeType || "RestElement" === nodeType || "AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ObjectPattern" === nodeType || "TSParameterProperty" === nodeType || nodeType === "Placeholder" && ("Pattern" === node.expectedNode || "Identifier" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSEntityName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Identifier" === nodeType || "TSQualifiedName" === nodeType || nodeType === "Placeholder" && "Identifier" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "TemplateLiteral" === nodeType || "BigIntLiteral" === nodeType || "DecimalLiteral" === nodeType || nodeType === "Placeholder" && "StringLiteral" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImmutable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "BigIntLiteral" === nodeType || "JSXAttribute" === nodeType || "JSXClosingElement" === nodeType || "JSXElement" === nodeType || "JSXExpressionContainer" === nodeType || "JSXSpreadChild" === nodeType || "JSXOpeningElement" === nodeType || "JSXText" === nodeType || "JSXFragment" === nodeType || "JSXOpeningFragment" === nodeType || "JSXClosingFragment" === nodeType || "DecimalLiteral" === nodeType || nodeType === "Placeholder" && "StringLiteral" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUserWhitespacable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectMethod" === nodeType || "ObjectProperty" === nodeType || "ObjectTypeInternalSlot" === nodeType || "ObjectTypeCallProperty" === nodeType || "ObjectTypeIndexer" === nodeType || "ObjectTypeProperty" === nodeType || "ObjectTypeSpreadProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectMethod" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectMethod" === nodeType || "ObjectProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectProperty" === nodeType || "ClassProperty" === nodeType || "ClassAccessorProperty" === nodeType || "ClassPrivateProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUnaryLike(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("UnaryExpression" === nodeType || "SpreadElement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ObjectPattern" === nodeType || nodeType === "Placeholder" && "Pattern" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClass(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ClassExpression" === nodeType || "ClassDeclaration" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isModuleDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ImportDeclaration" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isModuleSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExportSpecifier" === nodeType || "ImportDefaultSpecifier" === nodeType || "ImportNamespaceSpecifier" === nodeType || "ImportSpecifier" === nodeType || "ExportNamespaceSpecifier" === nodeType || "ExportDefaultSpecifier" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAccessor(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ClassAccessorProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPrivate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ClassPrivateProperty" === nodeType || "ClassPrivateMethod" === nodeType || "PrivateName" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlow(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AnyTypeAnnotation" === nodeType || "ArrayTypeAnnotation" === nodeType || "BooleanTypeAnnotation" === nodeType || "BooleanLiteralTypeAnnotation" === nodeType || "NullLiteralTypeAnnotation" === nodeType || "ClassImplements" === nodeType || "DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "DeclaredPredicate" === nodeType || "ExistsTypeAnnotation" === nodeType || "FunctionTypeAnnotation" === nodeType || "FunctionTypeParam" === nodeType || "GenericTypeAnnotation" === nodeType || "InferredPredicate" === nodeType || "InterfaceExtends" === nodeType || "InterfaceDeclaration" === nodeType || "InterfaceTypeAnnotation" === nodeType || "IntersectionTypeAnnotation" === nodeType || "MixedTypeAnnotation" === nodeType || "EmptyTypeAnnotation" === nodeType || "NullableTypeAnnotation" === nodeType || "NumberLiteralTypeAnnotation" === nodeType || "NumberTypeAnnotation" === nodeType || "ObjectTypeAnnotation" === nodeType || "ObjectTypeInternalSlot" === nodeType || "ObjectTypeCallProperty" === nodeType || "ObjectTypeIndexer" === nodeType || "ObjectTypeProperty" === nodeType || "ObjectTypeSpreadProperty" === nodeType || "OpaqueType" === nodeType || "QualifiedTypeIdentifier" === nodeType || "StringLiteralTypeAnnotation" === nodeType || "StringTypeAnnotation" === nodeType || "SymbolTypeAnnotation" === nodeType || "ThisTypeAnnotation" === nodeType || "TupleTypeAnnotation" === nodeType || "TypeofTypeAnnotation" === nodeType || "TypeAlias" === nodeType || "TypeAnnotation" === nodeType || "TypeCastExpression" === nodeType || "TypeParameter" === nodeType || "TypeParameterDeclaration" === nodeType || "TypeParameterInstantiation" === nodeType || "UnionTypeAnnotation" === nodeType || "Variance" === nodeType || "VoidTypeAnnotation" === nodeType || "EnumDeclaration" === nodeType || "EnumBooleanBody" === nodeType || "EnumNumberBody" === nodeType || "EnumStringBody" === nodeType || "EnumSymbolBody" === nodeType || "EnumBooleanMember" === nodeType || "EnumNumberMember" === nodeType || "EnumStringMember" === nodeType || "EnumDefaultedMember" === nodeType || "IndexedAccessType" === nodeType || "OptionalIndexedAccessType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AnyTypeAnnotation" === nodeType || "ArrayTypeAnnotation" === nodeType || "BooleanTypeAnnotation" === nodeType || "BooleanLiteralTypeAnnotation" === nodeType || "NullLiteralTypeAnnotation" === nodeType || "ExistsTypeAnnotation" === nodeType || "FunctionTypeAnnotation" === nodeType || "GenericTypeAnnotation" === nodeType || "InterfaceTypeAnnotation" === nodeType || "IntersectionTypeAnnotation" === nodeType || "MixedTypeAnnotation" === nodeType || "EmptyTypeAnnotation" === nodeType || "NullableTypeAnnotation" === nodeType || "NumberLiteralTypeAnnotation" === nodeType || "NumberTypeAnnotation" === nodeType || "ObjectTypeAnnotation" === nodeType || "StringLiteralTypeAnnotation" === nodeType || "StringTypeAnnotation" === nodeType || "SymbolTypeAnnotation" === nodeType || "ThisTypeAnnotation" === nodeType || "TupleTypeAnnotation" === nodeType || "TypeofTypeAnnotation" === nodeType || "UnionTypeAnnotation" === nodeType || "VoidTypeAnnotation" === nodeType || "IndexedAccessType" === nodeType || "OptionalIndexedAccessType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowBaseAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AnyTypeAnnotation" === nodeType || "BooleanTypeAnnotation" === nodeType || "NullLiteralTypeAnnotation" === nodeType || "MixedTypeAnnotation" === nodeType || "EmptyTypeAnnotation" === nodeType || "NumberTypeAnnotation" === nodeType || "StringTypeAnnotation" === nodeType || "SymbolTypeAnnotation" === nodeType || "ThisTypeAnnotation" === nodeType || "VoidTypeAnnotation" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "InterfaceDeclaration" === nodeType || "OpaqueType" === nodeType || "TypeAlias" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowPredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DeclaredPredicate" === nodeType || "InferredPredicate" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("EnumBooleanBody" === nodeType || "EnumNumberBody" === nodeType || "EnumStringBody" === nodeType || "EnumSymbolBody" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("EnumBooleanMember" === nodeType || "EnumNumberMember" === nodeType || "EnumStringMember" === nodeType || "EnumDefaultedMember" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSX(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("JSXAttribute" === nodeType || "JSXClosingElement" === nodeType || "JSXElement" === nodeType || "JSXEmptyExpression" === nodeType || "JSXExpressionContainer" === nodeType || "JSXSpreadChild" === nodeType || "JSXIdentifier" === nodeType || "JSXMemberExpression" === nodeType || "JSXNamespacedName" === nodeType || "JSXOpeningElement" === nodeType || "JSXSpreadAttribute" === nodeType || "JSXText" === nodeType || "JSXFragment" === nodeType || "JSXOpeningFragment" === nodeType || "JSXClosingFragment" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMiscellaneous(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Noop" === nodeType || "Placeholder" === nodeType || "V8IntrinsicIdentifier" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeScript(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSParameterProperty" === nodeType || "TSDeclareFunction" === nodeType || "TSDeclareMethod" === nodeType || "TSQualifiedName" === nodeType || "TSCallSignatureDeclaration" === nodeType || "TSConstructSignatureDeclaration" === nodeType || "TSPropertySignature" === nodeType || "TSMethodSignature" === nodeType || "TSIndexSignature" === nodeType || "TSAnyKeyword" === nodeType || "TSBooleanKeyword" === nodeType || "TSBigIntKeyword" === nodeType || "TSIntrinsicKeyword" === nodeType || "TSNeverKeyword" === nodeType || "TSNullKeyword" === nodeType || "TSNumberKeyword" === nodeType || "TSObjectKeyword" === nodeType || "TSStringKeyword" === nodeType || "TSSymbolKeyword" === nodeType || "TSUndefinedKeyword" === nodeType || "TSUnknownKeyword" === nodeType || "TSVoidKeyword" === nodeType || "TSThisType" === nodeType || "TSFunctionType" === nodeType || "TSConstructorType" === nodeType || "TSTypeReference" === nodeType || "TSTypePredicate" === nodeType || "TSTypeQuery" === nodeType || "TSTypeLiteral" === nodeType || "TSArrayType" === nodeType || "TSTupleType" === nodeType || "TSOptionalType" === nodeType || "TSRestType" === nodeType || "TSNamedTupleMember" === nodeType || "TSUnionType" === nodeType || "TSIntersectionType" === nodeType || "TSConditionalType" === nodeType || "TSInferType" === nodeType || "TSParenthesizedType" === nodeType || "TSTypeOperator" === nodeType || "TSIndexedAccessType" === nodeType || "TSMappedType" === nodeType || "TSLiteralType" === nodeType || "TSExpressionWithTypeArguments" === nodeType || "TSInterfaceDeclaration" === nodeType || "TSInterfaceBody" === nodeType || "TSTypeAliasDeclaration" === nodeType || "TSAsExpression" === nodeType || "TSTypeAssertion" === nodeType || "TSEnumDeclaration" === nodeType || "TSEnumMember" === nodeType || "TSModuleDeclaration" === nodeType || "TSModuleBlock" === nodeType || "TSImportType" === nodeType || "TSImportEqualsDeclaration" === nodeType || "TSExternalModuleReference" === nodeType || "TSNonNullExpression" === nodeType || "TSExportAssignment" === nodeType || "TSNamespaceExportDeclaration" === nodeType || "TSTypeAnnotation" === nodeType || "TSTypeParameterInstantiation" === nodeType || "TSTypeParameterDeclaration" === nodeType || "TSTypeParameter" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSCallSignatureDeclaration" === nodeType || "TSConstructSignatureDeclaration" === nodeType || "TSPropertySignature" === nodeType || "TSMethodSignature" === nodeType || "TSIndexSignature" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSAnyKeyword" === nodeType || "TSBooleanKeyword" === nodeType || "TSBigIntKeyword" === nodeType || "TSIntrinsicKeyword" === nodeType || "TSNeverKeyword" === nodeType || "TSNullKeyword" === nodeType || "TSNumberKeyword" === nodeType || "TSObjectKeyword" === nodeType || "TSStringKeyword" === nodeType || "TSSymbolKeyword" === nodeType || "TSUndefinedKeyword" === nodeType || "TSUnknownKeyword" === nodeType || "TSVoidKeyword" === nodeType || "TSThisType" === nodeType || "TSFunctionType" === nodeType || "TSConstructorType" === nodeType || "TSTypeReference" === nodeType || "TSTypePredicate" === nodeType || "TSTypeQuery" === nodeType || "TSTypeLiteral" === nodeType || "TSArrayType" === nodeType || "TSTupleType" === nodeType || "TSOptionalType" === nodeType || "TSRestType" === nodeType || "TSUnionType" === nodeType || "TSIntersectionType" === nodeType || "TSConditionalType" === nodeType || "TSInferType" === nodeType || "TSParenthesizedType" === nodeType || "TSTypeOperator" === nodeType || "TSIndexedAccessType" === nodeType || "TSMappedType" === nodeType || "TSLiteralType" === nodeType || "TSExpressionWithTypeArguments" === nodeType || "TSImportType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSBaseType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSAnyKeyword" === nodeType || "TSBooleanKeyword" === nodeType || "TSBigIntKeyword" === nodeType || "TSIntrinsicKeyword" === nodeType || "TSNeverKeyword" === nodeType || "TSNullKeyword" === nodeType || "TSNumberKeyword" === nodeType || "TSObjectKeyword" === nodeType || "TSStringKeyword" === nodeType || "TSSymbolKeyword" === nodeType || "TSUndefinedKeyword" === nodeType || "TSUnknownKeyword" === nodeType || "TSVoidKeyword" === nodeType || "TSThisType" === nodeType || "TSLiteralType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumberLiteral(node, opts) { + console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumberLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRegexLiteral(node, opts) { + console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RegexLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRestProperty(node, opts) { + console.trace("The node type RestProperty has been renamed to RestElement"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RestProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSpreadProperty(node, opts) { + console.trace("The node type SpreadProperty has been renamed to SpreadElement"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SpreadProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} \ No newline at end of file diff --git a/node_modules/@graphprotocol/graph-cli/examples/basic-event-handlers/generated/Gravity/Gravity.ts b/node_modules/@graphprotocol/graph-cli/examples/basic-event-handlers/generated/Gravity/Gravity.ts new file mode 100644 index 000000000..e6e0a1b2e --- /dev/null +++ b/node_modules/@graphprotocol/graph-cli/examples/basic-event-handlers/generated/Gravity/Gravity.ts @@ -0,0 +1,343 @@ +// THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. + +import { + ethereum, + JSONValue, + TypedMap, + Entity, + Bytes, + Address, + BigInt +} from "@graphprotocol/graph-ts"; + +export class NewGravatar extends ethereum.Event { + get params(): NewGravatar__Params { + return new NewGravatar__Params(this); + } +} + +export class NewGravatar__Params { + _event: NewGravatar; + + constructor(event: NewGravatar) { + this._event = event; + } + + get id(): BigInt { + return this._event.parameters[0].value.toBigInt(); + } + + get owner(): Address { + return this._event.parameters[1].value.toAddress(); + } + + get displayName(): string { + return this._event.parameters[2].value.toString(); + } + + get imageUrl(): string { + return this._event.parameters[3].value.toString(); + } +} + +export class UpdatedGravatar extends ethereum.Event { + get params(): UpdatedGravatar__Params { + return new UpdatedGravatar__Params(this); + } +} + +export class UpdatedGravatar__Params { + _event: UpdatedGravatar; + + constructor(event: UpdatedGravatar) { + this._event = event; + } + + get id(): BigInt { + return this._event.parameters[0].value.toBigInt(); + } + + get owner(): Address { + return this._event.parameters[1].value.toAddress(); + } + + get displayName(): string { + return this._event.parameters[2].value.toString(); + } + + get imageUrl(): string { + return this._event.parameters[3].value.toString(); + } +} + +export class Gravity__getGravatarResult { + value0: string; + value1: string; + + constructor(value0: string, value1: string) { + this.value0 = value0; + this.value1 = value1; + } + + toMap(): TypedMap { + let map = new TypedMap(); + map.set("value0", ethereum.Value.fromString(this.value0)); + map.set("value1", ethereum.Value.fromString(this.value1)); + return map; + } +} + +export class Gravity__gravatarsResult { + value0: Address; + value1: string; + value2: string; + + constructor(value0: Address, value1: string, value2: string) { + this.value0 = value0; + this.value1 = value1; + this.value2 = value2; + } + + toMap(): TypedMap { + let map = new TypedMap(); + map.set("value0", ethereum.Value.fromAddress(this.value0)); + map.set("value1", ethereum.Value.fromString(this.value1)); + map.set("value2", ethereum.Value.fromString(this.value2)); + return map; + } +} + +export class Gravity extends ethereum.SmartContract { + static bind(address: Address): Gravity { + return new Gravity("Gravity", address); + } + + getGravatar(owner: Address): Gravity__getGravatarResult { + let result = super.call( + "getGravatar", + "getGravatar(address):(string,string)", + [ethereum.Value.fromAddress(owner)] + ); + + return new Gravity__getGravatarResult( + result[0].toString(), + result[1].toString() + ); + } + + try_getGravatar( + owner: Address + ): ethereum.CallResult { + let result = super.tryCall( + "getGravatar", + "getGravatar(address):(string,string)", + [ethereum.Value.fromAddress(owner)] + ); + if (result.reverted) { + return new ethereum.CallResult(); + } + let value = result.value; + return ethereum.CallResult.fromValue( + new Gravity__getGravatarResult(value[0].toString(), value[1].toString()) + ); + } + + gravatarToOwner(param0: BigInt): Address { + let result = super.call( + "gravatarToOwner", + "gravatarToOwner(uint256):(address)", + [ethereum.Value.fromUnsignedBigInt(param0)] + ); + + return result[0].toAddress(); + } + + try_gravatarToOwner(param0: BigInt): ethereum.CallResult
{ + let result = super.tryCall( + "gravatarToOwner", + "gravatarToOwner(uint256):(address)", + [ethereum.Value.fromUnsignedBigInt(param0)] + ); + if (result.reverted) { + return new ethereum.CallResult(); + } + let value = result.value; + return ethereum.CallResult.fromValue(value[0].toAddress()); + } + + ownerToGravatar(param0: Address): BigInt { + let result = super.call( + "ownerToGravatar", + "ownerToGravatar(address):(uint256)", + [ethereum.Value.fromAddress(param0)] + ); + + return result[0].toBigInt(); + } + + try_ownerToGravatar(param0: Address): ethereum.CallResult { + let result = super.tryCall( + "ownerToGravatar", + "ownerToGravatar(address):(uint256)", + [ethereum.Value.fromAddress(param0)] + ); + if (result.reverted) { + return new ethereum.CallResult(); + } + let value = result.value; + return ethereum.CallResult.fromValue(value[0].toBigInt()); + } + + gravatars(param0: BigInt): Gravity__gravatarsResult { + let result = super.call( + "gravatars", + "gravatars(uint256):(address,string,string)", + [ethereum.Value.fromUnsignedBigInt(param0)] + ); + + return new Gravity__gravatarsResult( + result[0].toAddress(), + result[1].toString(), + result[2].toString() + ); + } + + try_gravatars(param0: BigInt): ethereum.CallResult { + let result = super.tryCall( + "gravatars", + "gravatars(uint256):(address,string,string)", + [ethereum.Value.fromUnsignedBigInt(param0)] + ); + if (result.reverted) { + return new ethereum.CallResult(); + } + let value = result.value; + return ethereum.CallResult.fromValue( + new Gravity__gravatarsResult( + value[0].toAddress(), + value[1].toString(), + value[2].toString() + ) + ); + } +} + +export class UpdateGravatarImageCall extends ethereum.Call { + get inputs(): UpdateGravatarImageCall__Inputs { + return new UpdateGravatarImageCall__Inputs(this); + } + + get outputs(): UpdateGravatarImageCall__Outputs { + return new UpdateGravatarImageCall__Outputs(this); + } +} + +export class UpdateGravatarImageCall__Inputs { + _call: UpdateGravatarImageCall; + + constructor(call: UpdateGravatarImageCall) { + this._call = call; + } + + get _imageUrl(): string { + return this._call.inputValues[0].value.toString(); + } +} + +export class UpdateGravatarImageCall__Outputs { + _call: UpdateGravatarImageCall; + + constructor(call: UpdateGravatarImageCall) { + this._call = call; + } +} + +export class SetMythicalGravatarCall extends ethereum.Call { + get inputs(): SetMythicalGravatarCall__Inputs { + return new SetMythicalGravatarCall__Inputs(this); + } + + get outputs(): SetMythicalGravatarCall__Outputs { + return new SetMythicalGravatarCall__Outputs(this); + } +} + +export class SetMythicalGravatarCall__Inputs { + _call: SetMythicalGravatarCall; + + constructor(call: SetMythicalGravatarCall) { + this._call = call; + } +} + +export class SetMythicalGravatarCall__Outputs { + _call: SetMythicalGravatarCall; + + constructor(call: SetMythicalGravatarCall) { + this._call = call; + } +} + +export class UpdateGravatarNameCall extends ethereum.Call { + get inputs(): UpdateGravatarNameCall__Inputs { + return new UpdateGravatarNameCall__Inputs(this); + } + + get outputs(): UpdateGravatarNameCall__Outputs { + return new UpdateGravatarNameCall__Outputs(this); + } +} + +export class UpdateGravatarNameCall__Inputs { + _call: UpdateGravatarNameCall; + + constructor(call: UpdateGravatarNameCall) { + this._call = call; + } + + get _displayName(): string { + return this._call.inputValues[0].value.toString(); + } +} + +export class UpdateGravatarNameCall__Outputs { + _call: UpdateGravatarNameCall; + + constructor(call: UpdateGravatarNameCall) { + this._call = call; + } +} + +export class CreateGravatarCall extends ethereum.Call { + get inputs(): CreateGravatarCall__Inputs { + return new CreateGravatarCall__Inputs(this); + } + + get outputs(): CreateGravatarCall__Outputs { + return new CreateGravatarCall__Outputs(this); + } +} + +export class CreateGravatarCall__Inputs { + _call: CreateGravatarCall; + + constructor(call: CreateGravatarCall) { + this._call = call; + } + + get _displayName(): string { + return this._call.inputValues[0].value.toString(); + } + + get _imageUrl(): string { + return this._call.inputValues[1].value.toString(); + } +} + +export class CreateGravatarCall__Outputs { + _call: CreateGravatarCall; + + constructor(call: CreateGravatarCall) { + this._call = call; + } +} diff --git a/node_modules/@graphprotocol/graph-cli/examples/basic-event-handlers/generated/schema.ts b/node_modules/@graphprotocol/graph-cli/examples/basic-event-handlers/generated/schema.ts new file mode 100644 index 000000000..65669a677 --- /dev/null +++ b/node_modules/@graphprotocol/graph-cli/examples/basic-event-handlers/generated/schema.ts @@ -0,0 +1,133 @@ +// THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. + +import { + TypedMap, + Entity, + Value, + ValueKind, + store, + Address, + Bytes, + BigInt, + BigDecimal +} from "@graphprotocol/graph-ts"; + +export class NewGravatar extends Entity { + constructor(id: string) { + super(); + this.set("id", Value.fromString(id)); + } + + save(): void { + let id = this.get("id"); + assert(id != null, "Cannot save NewGravatar entity without an ID"); + if (id) { + assert( + id.kind == ValueKind.STRING, + "Cannot save NewGravatar entity with non-string ID. " + + 'Considering using .toHex() to convert the "id" to a string.' + ); + store.set("NewGravatar", id.toString(), this); + } + } + + static load(id: string): NewGravatar | null { + return changetype(store.get("NewGravatar", id)); + } + + get id(): string { + let value = this.get("id"); + return value!.toString(); + } + + set id(value: string) { + this.set("id", Value.fromString(value)); + } + + get owner(): Bytes { + let value = this.get("owner"); + return value!.toBytes(); + } + + set owner(value: Bytes) { + this.set("owner", Value.fromBytes(value)); + } + + get displayName(): string { + let value = this.get("displayName"); + return value!.toString(); + } + + set displayName(value: string) { + this.set("displayName", Value.fromString(value)); + } + + get imageUrl(): string { + let value = this.get("imageUrl"); + return value!.toString(); + } + + set imageUrl(value: string) { + this.set("imageUrl", Value.fromString(value)); + } +} + +export class UpdatedGravatar extends Entity { + constructor(id: string) { + super(); + this.set("id", Value.fromString(id)); + } + + save(): void { + let id = this.get("id"); + assert(id != null, "Cannot save UpdatedGravatar entity without an ID"); + if (id) { + assert( + id.kind == ValueKind.STRING, + "Cannot save UpdatedGravatar entity with non-string ID. " + + 'Considering using .toHex() to convert the "id" to a string.' + ); + store.set("UpdatedGravatar", id.toString(), this); + } + } + + static load(id: string): UpdatedGravatar | null { + return changetype(store.get("UpdatedGravatar", id)); + } + + get id(): string { + let value = this.get("id"); + return value!.toString(); + } + + set id(value: string) { + this.set("id", Value.fromString(value)); + } + + get owner(): Bytes { + let value = this.get("owner"); + return value!.toBytes(); + } + + set owner(value: Bytes) { + this.set("owner", Value.fromBytes(value)); + } + + get displayName(): string { + let value = this.get("displayName"); + return value!.toString(); + } + + set displayName(value: string) { + this.set("displayName", Value.fromString(value)); + } + + get imageUrl(): string { + let value = this.get("imageUrl"); + return value!.toString(); + } + + set imageUrl(value: string) { + this.set("imageUrl", Value.fromString(value)); + } +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/channelz.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/channelz.d.ts new file mode 100644 index 000000000..b82dd5917 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/channelz.d.ts @@ -0,0 +1,72 @@ +import type * as grpc from '../index'; +import type { MessageTypeDefinition } from '@grpc/proto-loader'; +import type { ChannelzClient as _grpc_channelz_v1_ChannelzClient, ChannelzDefinition as _grpc_channelz_v1_ChannelzDefinition } from './grpc/channelz/v1/Channelz'; +declare type SubtypeConstructor any, Subtype> = { + new (...args: ConstructorParameters): Subtype; +}; +export interface ProtoGrpcType { + google: { + protobuf: { + Any: MessageTypeDefinition; + BoolValue: MessageTypeDefinition; + BytesValue: MessageTypeDefinition; + DoubleValue: MessageTypeDefinition; + Duration: MessageTypeDefinition; + FloatValue: MessageTypeDefinition; + Int32Value: MessageTypeDefinition; + Int64Value: MessageTypeDefinition; + StringValue: MessageTypeDefinition; + Timestamp: MessageTypeDefinition; + UInt32Value: MessageTypeDefinition; + UInt64Value: MessageTypeDefinition; + }; + }; + grpc: { + channelz: { + v1: { + Address: MessageTypeDefinition; + Channel: MessageTypeDefinition; + ChannelConnectivityState: MessageTypeDefinition; + ChannelData: MessageTypeDefinition; + ChannelRef: MessageTypeDefinition; + ChannelTrace: MessageTypeDefinition; + ChannelTraceEvent: MessageTypeDefinition; + /** + * Channelz is a service exposed by gRPC servers that provides detailed debug + * information. + */ + Channelz: SubtypeConstructor & { + service: _grpc_channelz_v1_ChannelzDefinition; + }; + GetChannelRequest: MessageTypeDefinition; + GetChannelResponse: MessageTypeDefinition; + GetServerRequest: MessageTypeDefinition; + GetServerResponse: MessageTypeDefinition; + GetServerSocketsRequest: MessageTypeDefinition; + GetServerSocketsResponse: MessageTypeDefinition; + GetServersRequest: MessageTypeDefinition; + GetServersResponse: MessageTypeDefinition; + GetSocketRequest: MessageTypeDefinition; + GetSocketResponse: MessageTypeDefinition; + GetSubchannelRequest: MessageTypeDefinition; + GetSubchannelResponse: MessageTypeDefinition; + GetTopChannelsRequest: MessageTypeDefinition; + GetTopChannelsResponse: MessageTypeDefinition; + Security: MessageTypeDefinition; + Server: MessageTypeDefinition; + ServerData: MessageTypeDefinition; + ServerRef: MessageTypeDefinition; + Socket: MessageTypeDefinition; + SocketData: MessageTypeDefinition; + SocketOption: MessageTypeDefinition; + SocketOptionLinger: MessageTypeDefinition; + SocketOptionTcpInfo: MessageTypeDefinition; + SocketOptionTimeout: MessageTypeDefinition; + SocketRef: MessageTypeDefinition; + Subchannel: MessageTypeDefinition; + SubchannelRef: MessageTypeDefinition; + }; + }; + }; +} +export {}; diff --git a/node_modules/@grpc/grpc-js/build/src/generated/channelz.js b/node_modules/@grpc/grpc-js/build/src/generated/channelz.js new file mode 100644 index 000000000..0c2cf6786 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/channelz.js @@ -0,0 +1,3 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=channelz.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/channelz.js.map b/node_modules/@grpc/grpc-js/build/src/generated/channelz.js.map new file mode 100644 index 000000000..af4016bb1 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/channelz.js.map @@ -0,0 +1 @@ +{"version":3,"file":"channelz.js","sourceRoot":"","sources":["../../../src/generated/channelz.ts"],"names":[],"mappings":""} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Any.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Any.d.ts new file mode 100644 index 000000000..413260e08 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Any.d.ts @@ -0,0 +1,10 @@ +/// +import type { AnyExtension } from '@grpc/proto-loader'; +export declare type Any = AnyExtension | { + type_url: string; + value: Buffer | Uint8Array | string; +}; +export interface Any__Output { + 'type_url': (string); + 'value': (Buffer); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Any.js b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Any.js new file mode 100644 index 000000000..f9651f898 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Any.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: null +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=Any.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Any.js.map b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Any.js.map new file mode 100644 index 000000000..2e75474ab --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Any.js.map @@ -0,0 +1 @@ +{"version":3,"file":"Any.js","sourceRoot":"","sources":["../../../../../src/generated/google/protobuf/Any.ts"],"names":[],"mappings":";AAAA,sBAAsB"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/BoolValue.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/BoolValue.d.ts new file mode 100644 index 000000000..b7235a769 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/BoolValue.d.ts @@ -0,0 +1,6 @@ +export interface BoolValue { + 'value'?: (boolean); +} +export interface BoolValue__Output { + 'value': (boolean); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/BoolValue.js b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/BoolValue.js new file mode 100644 index 000000000..f893f74ce --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/BoolValue.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: null +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=BoolValue.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/BoolValue.js.map b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/BoolValue.js.map new file mode 100644 index 000000000..357385344 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/BoolValue.js.map @@ -0,0 +1 @@ +{"version":3,"file":"BoolValue.js","sourceRoot":"","sources":["../../../../../src/generated/google/protobuf/BoolValue.ts"],"names":[],"mappings":";AAAA,sBAAsB"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/BytesValue.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/BytesValue.d.ts new file mode 100644 index 000000000..2c77f9d3d --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/BytesValue.d.ts @@ -0,0 +1,7 @@ +/// +export interface BytesValue { + 'value'?: (Buffer | Uint8Array | string); +} +export interface BytesValue__Output { + 'value': (Buffer); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/BytesValue.js b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/BytesValue.js new file mode 100644 index 000000000..4cac93e9a --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/BytesValue.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: null +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=BytesValue.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/BytesValue.js.map b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/BytesValue.js.map new file mode 100644 index 000000000..a589ea5bd --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/BytesValue.js.map @@ -0,0 +1 @@ +{"version":3,"file":"BytesValue.js","sourceRoot":"","sources":["../../../../../src/generated/google/protobuf/BytesValue.ts"],"names":[],"mappings":";AAAA,sBAAsB"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/DoubleValue.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/DoubleValue.d.ts new file mode 100644 index 000000000..e4e2204b2 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/DoubleValue.d.ts @@ -0,0 +1,6 @@ +export interface DoubleValue { + 'value'?: (number | string); +} +export interface DoubleValue__Output { + 'value': (number); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/DoubleValue.js b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/DoubleValue.js new file mode 100644 index 000000000..133e011f5 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/DoubleValue.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: null +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=DoubleValue.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/DoubleValue.js.map b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/DoubleValue.js.map new file mode 100644 index 000000000..7f28720db --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/DoubleValue.js.map @@ -0,0 +1 @@ +{"version":3,"file":"DoubleValue.js","sourceRoot":"","sources":["../../../../../src/generated/google/protobuf/DoubleValue.ts"],"names":[],"mappings":";AAAA,sBAAsB"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Duration.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Duration.d.ts new file mode 100644 index 000000000..c9681840a --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Duration.d.ts @@ -0,0 +1,10 @@ +/// +import type { Long } from '@grpc/proto-loader'; +export interface Duration { + 'seconds'?: (number | string | Long); + 'nanos'?: (number); +} +export interface Duration__Output { + 'seconds': (string); + 'nanos': (number); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Duration.js b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Duration.js new file mode 100644 index 000000000..b071b702a --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Duration.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: null +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=Duration.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Duration.js.map b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Duration.js.map new file mode 100644 index 000000000..3fc8fe846 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Duration.js.map @@ -0,0 +1 @@ +{"version":3,"file":"Duration.js","sourceRoot":"","sources":["../../../../../src/generated/google/protobuf/Duration.ts"],"names":[],"mappings":";AAAA,sBAAsB"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/FloatValue.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/FloatValue.d.ts new file mode 100644 index 000000000..33bd60b7d --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/FloatValue.d.ts @@ -0,0 +1,6 @@ +export interface FloatValue { + 'value'?: (number | string); +} +export interface FloatValue__Output { + 'value': (number); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/FloatValue.js b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/FloatValue.js new file mode 100644 index 000000000..17290a2c5 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/FloatValue.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: null +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=FloatValue.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/FloatValue.js.map b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/FloatValue.js.map new file mode 100644 index 000000000..bf27b781c --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/FloatValue.js.map @@ -0,0 +1 @@ +{"version":3,"file":"FloatValue.js","sourceRoot":"","sources":["../../../../../src/generated/google/protobuf/FloatValue.ts"],"names":[],"mappings":";AAAA,sBAAsB"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Int32Value.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Int32Value.d.ts new file mode 100644 index 000000000..895fb9d7d --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Int32Value.d.ts @@ -0,0 +1,6 @@ +export interface Int32Value { + 'value'?: (number); +} +export interface Int32Value__Output { + 'value': (number); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Int32Value.js b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Int32Value.js new file mode 100644 index 000000000..dc4634387 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Int32Value.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: null +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=Int32Value.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Int32Value.js.map b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Int32Value.js.map new file mode 100644 index 000000000..157e73a4e --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Int32Value.js.map @@ -0,0 +1 @@ +{"version":3,"file":"Int32Value.js","sourceRoot":"","sources":["../../../../../src/generated/google/protobuf/Int32Value.ts"],"names":[],"mappings":";AAAA,sBAAsB"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Int64Value.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Int64Value.d.ts new file mode 100644 index 000000000..0ae70e582 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Int64Value.d.ts @@ -0,0 +1,8 @@ +/// +import type { Long } from '@grpc/proto-loader'; +export interface Int64Value { + 'value'?: (number | string | Long); +} +export interface Int64Value__Output { + 'value': (string); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Int64Value.js b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Int64Value.js new file mode 100644 index 000000000..a77bc96b3 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Int64Value.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: null +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=Int64Value.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Int64Value.js.map b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Int64Value.js.map new file mode 100644 index 000000000..b8894b10a --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Int64Value.js.map @@ -0,0 +1 @@ +{"version":3,"file":"Int64Value.js","sourceRoot":"","sources":["../../../../../src/generated/google/protobuf/Int64Value.ts"],"names":[],"mappings":";AAAA,sBAAsB"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/StringValue.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/StringValue.d.ts new file mode 100644 index 000000000..74230c9a9 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/StringValue.d.ts @@ -0,0 +1,6 @@ +export interface StringValue { + 'value'?: (string); +} +export interface StringValue__Output { + 'value': (string); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/StringValue.js b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/StringValue.js new file mode 100644 index 000000000..0836e97c8 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/StringValue.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: null +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=StringValue.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/StringValue.js.map b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/StringValue.js.map new file mode 100644 index 000000000..bc05ddc86 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/StringValue.js.map @@ -0,0 +1 @@ +{"version":3,"file":"StringValue.js","sourceRoot":"","sources":["../../../../../src/generated/google/protobuf/StringValue.ts"],"names":[],"mappings":";AAAA,sBAAsB"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Timestamp.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Timestamp.d.ts new file mode 100644 index 000000000..97d99c4e7 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Timestamp.d.ts @@ -0,0 +1,10 @@ +/// +import type { Long } from '@grpc/proto-loader'; +export interface Timestamp { + 'seconds'?: (number | string | Long); + 'nanos'?: (number); +} +export interface Timestamp__Output { + 'seconds': (string); + 'nanos': (number); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Timestamp.js b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Timestamp.js new file mode 100644 index 000000000..dcca213be --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Timestamp.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: null +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=Timestamp.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Timestamp.js.map b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Timestamp.js.map new file mode 100644 index 000000000..e90342ef7 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/Timestamp.js.map @@ -0,0 +1 @@ +{"version":3,"file":"Timestamp.js","sourceRoot":"","sources":["../../../../../src/generated/google/protobuf/Timestamp.ts"],"names":[],"mappings":";AAAA,sBAAsB"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/UInt32Value.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/UInt32Value.d.ts new file mode 100644 index 000000000..d7e185f68 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/UInt32Value.d.ts @@ -0,0 +1,6 @@ +export interface UInt32Value { + 'value'?: (number); +} +export interface UInt32Value__Output { + 'value': (number); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/UInt32Value.js b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/UInt32Value.js new file mode 100644 index 000000000..889cd2e99 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/UInt32Value.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: null +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=UInt32Value.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/UInt32Value.js.map b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/UInt32Value.js.map new file mode 100644 index 000000000..2a0420f0a --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/UInt32Value.js.map @@ -0,0 +1 @@ +{"version":3,"file":"UInt32Value.js","sourceRoot":"","sources":["../../../../../src/generated/google/protobuf/UInt32Value.ts"],"names":[],"mappings":";AAAA,sBAAsB"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/UInt64Value.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/UInt64Value.d.ts new file mode 100644 index 000000000..9db01b945 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/UInt64Value.d.ts @@ -0,0 +1,8 @@ +/// +import type { Long } from '@grpc/proto-loader'; +export interface UInt64Value { + 'value'?: (number | string | Long); +} +export interface UInt64Value__Output { + 'value': (string); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/UInt64Value.js b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/UInt64Value.js new file mode 100644 index 000000000..2a06a6917 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/UInt64Value.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: null +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=UInt64Value.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/UInt64Value.js.map b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/UInt64Value.js.map new file mode 100644 index 000000000..4ea43ca11 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/UInt64Value.js.map @@ -0,0 +1 @@ +{"version":3,"file":"UInt64Value.js","sourceRoot":"","sources":["../../../../../src/generated/google/protobuf/UInt64Value.ts"],"names":[],"mappings":";AAAA,sBAAsB"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Address.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Address.d.ts new file mode 100644 index 000000000..067636795 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Address.d.ts @@ -0,0 +1,80 @@ +/// +import type { Any as _google_protobuf_Any, Any__Output as _google_protobuf_Any__Output } from '../../../google/protobuf/Any'; +/** + * An address type not included above. + */ +export interface _grpc_channelz_v1_Address_OtherAddress { + /** + * The human readable version of the value. This value should be set. + */ + 'name'?: (string); + /** + * The actual address message. + */ + 'value'?: (_google_protobuf_Any | null); +} +/** + * An address type not included above. + */ +export interface _grpc_channelz_v1_Address_OtherAddress__Output { + /** + * The human readable version of the value. This value should be set. + */ + 'name': (string); + /** + * The actual address message. + */ + 'value': (_google_protobuf_Any__Output | null); +} +export interface _grpc_channelz_v1_Address_TcpIpAddress { + /** + * Either the IPv4 or IPv6 address in bytes. Will be either 4 bytes or 16 + * bytes in length. + */ + 'ip_address'?: (Buffer | Uint8Array | string); + /** + * 0-64k, or -1 if not appropriate. + */ + 'port'?: (number); +} +export interface _grpc_channelz_v1_Address_TcpIpAddress__Output { + /** + * Either the IPv4 or IPv6 address in bytes. Will be either 4 bytes or 16 + * bytes in length. + */ + 'ip_address': (Buffer); + /** + * 0-64k, or -1 if not appropriate. + */ + 'port': (number); +} +/** + * A Unix Domain Socket address. + */ +export interface _grpc_channelz_v1_Address_UdsAddress { + 'filename'?: (string); +} +/** + * A Unix Domain Socket address. + */ +export interface _grpc_channelz_v1_Address_UdsAddress__Output { + 'filename': (string); +} +/** + * Address represents the address used to create the socket. + */ +export interface Address { + 'tcpip_address'?: (_grpc_channelz_v1_Address_TcpIpAddress | null); + 'uds_address'?: (_grpc_channelz_v1_Address_UdsAddress | null); + 'other_address'?: (_grpc_channelz_v1_Address_OtherAddress | null); + 'address'?: "tcpip_address" | "uds_address" | "other_address"; +} +/** + * Address represents the address used to create the socket. + */ +export interface Address__Output { + 'tcpip_address'?: (_grpc_channelz_v1_Address_TcpIpAddress__Output | null); + 'uds_address'?: (_grpc_channelz_v1_Address_UdsAddress__Output | null); + 'other_address'?: (_grpc_channelz_v1_Address_OtherAddress__Output | null); + 'address': "tcpip_address" | "uds_address" | "other_address"; +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Address.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Address.js new file mode 100644 index 000000000..6f15b91c8 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Address.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=Address.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Address.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Address.js.map new file mode 100644 index 000000000..554d6dac7 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Address.js.map @@ -0,0 +1 @@ +{"version":3,"file":"Address.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/Address.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Channel.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Channel.d.ts new file mode 100644 index 000000000..3bd11ca42 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Channel.d.ts @@ -0,0 +1,64 @@ +import type { ChannelRef as _grpc_channelz_v1_ChannelRef, ChannelRef__Output as _grpc_channelz_v1_ChannelRef__Output } from '../../../grpc/channelz/v1/ChannelRef'; +import type { ChannelData as _grpc_channelz_v1_ChannelData, ChannelData__Output as _grpc_channelz_v1_ChannelData__Output } from '../../../grpc/channelz/v1/ChannelData'; +import type { SubchannelRef as _grpc_channelz_v1_SubchannelRef, SubchannelRef__Output as _grpc_channelz_v1_SubchannelRef__Output } from '../../../grpc/channelz/v1/SubchannelRef'; +import type { SocketRef as _grpc_channelz_v1_SocketRef, SocketRef__Output as _grpc_channelz_v1_SocketRef__Output } from '../../../grpc/channelz/v1/SocketRef'; +/** + * Channel is a logical grouping of channels, subchannels, and sockets. + */ +export interface Channel { + /** + * The identifier for this channel. This should bet set. + */ + 'ref'?: (_grpc_channelz_v1_ChannelRef | null); + /** + * Data specific to this channel. + */ + 'data'?: (_grpc_channelz_v1_ChannelData | null); + /** + * There are no ordering guarantees on the order of channel refs. + * There may not be cycles in the ref graph. + * A channel ref may be present in more than one channel or subchannel. + */ + 'channel_ref'?: (_grpc_channelz_v1_ChannelRef)[]; + /** + * At most one of 'channel_ref+subchannel_ref' and 'socket' is set. + * There are no ordering guarantees on the order of subchannel refs. + * There may not be cycles in the ref graph. + * A sub channel ref may be present in more than one channel or subchannel. + */ + 'subchannel_ref'?: (_grpc_channelz_v1_SubchannelRef)[]; + /** + * There are no ordering guarantees on the order of sockets. + */ + 'socket_ref'?: (_grpc_channelz_v1_SocketRef)[]; +} +/** + * Channel is a logical grouping of channels, subchannels, and sockets. + */ +export interface Channel__Output { + /** + * The identifier for this channel. This should bet set. + */ + 'ref': (_grpc_channelz_v1_ChannelRef__Output | null); + /** + * Data specific to this channel. + */ + 'data': (_grpc_channelz_v1_ChannelData__Output | null); + /** + * There are no ordering guarantees on the order of channel refs. + * There may not be cycles in the ref graph. + * A channel ref may be present in more than one channel or subchannel. + */ + 'channel_ref': (_grpc_channelz_v1_ChannelRef__Output)[]; + /** + * At most one of 'channel_ref+subchannel_ref' and 'socket' is set. + * There are no ordering guarantees on the order of subchannel refs. + * There may not be cycles in the ref graph. + * A sub channel ref may be present in more than one channel or subchannel. + */ + 'subchannel_ref': (_grpc_channelz_v1_SubchannelRef__Output)[]; + /** + * There are no ordering guarantees on the order of sockets. + */ + 'socket_ref': (_grpc_channelz_v1_SocketRef__Output)[]; +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Channel.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Channel.js new file mode 100644 index 000000000..d9bc55a33 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Channel.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=Channel.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Channel.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Channel.js.map new file mode 100644 index 000000000..5dd6b69e4 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Channel.js.map @@ -0,0 +1 @@ +{"version":3,"file":"Channel.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/Channel.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelConnectivityState.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelConnectivityState.d.ts new file mode 100644 index 000000000..05002ce12 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelConnectivityState.d.ts @@ -0,0 +1,22 @@ +export declare enum _grpc_channelz_v1_ChannelConnectivityState_State { + UNKNOWN = 0, + IDLE = 1, + CONNECTING = 2, + READY = 3, + TRANSIENT_FAILURE = 4, + SHUTDOWN = 5 +} +/** + * These come from the specified states in this document: + * https://github.com/grpc/grpc/blob/master/doc/connectivity-semantics-and-api.md + */ +export interface ChannelConnectivityState { + 'state'?: (_grpc_channelz_v1_ChannelConnectivityState_State | keyof typeof _grpc_channelz_v1_ChannelConnectivityState_State); +} +/** + * These come from the specified states in this document: + * https://github.com/grpc/grpc/blob/master/doc/connectivity-semantics-and-api.md + */ +export interface ChannelConnectivityState__Output { + 'state': (keyof typeof _grpc_channelz_v1_ChannelConnectivityState_State); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelConnectivityState.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelConnectivityState.js new file mode 100644 index 000000000..092c58f1d --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelConnectivityState.js @@ -0,0 +1,15 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +exports._grpc_channelz_v1_ChannelConnectivityState_State = void 0; +// Original file: proto/channelz.proto +var _grpc_channelz_v1_ChannelConnectivityState_State; +(function (_grpc_channelz_v1_ChannelConnectivityState_State) { + _grpc_channelz_v1_ChannelConnectivityState_State[_grpc_channelz_v1_ChannelConnectivityState_State["UNKNOWN"] = 0] = "UNKNOWN"; + _grpc_channelz_v1_ChannelConnectivityState_State[_grpc_channelz_v1_ChannelConnectivityState_State["IDLE"] = 1] = "IDLE"; + _grpc_channelz_v1_ChannelConnectivityState_State[_grpc_channelz_v1_ChannelConnectivityState_State["CONNECTING"] = 2] = "CONNECTING"; + _grpc_channelz_v1_ChannelConnectivityState_State[_grpc_channelz_v1_ChannelConnectivityState_State["READY"] = 3] = "READY"; + _grpc_channelz_v1_ChannelConnectivityState_State[_grpc_channelz_v1_ChannelConnectivityState_State["TRANSIENT_FAILURE"] = 4] = "TRANSIENT_FAILURE"; + _grpc_channelz_v1_ChannelConnectivityState_State[_grpc_channelz_v1_ChannelConnectivityState_State["SHUTDOWN"] = 5] = "SHUTDOWN"; +})(_grpc_channelz_v1_ChannelConnectivityState_State = exports._grpc_channelz_v1_ChannelConnectivityState_State || (exports._grpc_channelz_v1_ChannelConnectivityState_State = {})); +//# sourceMappingURL=ChannelConnectivityState.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelConnectivityState.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelConnectivityState.js.map new file mode 100644 index 000000000..6dec7a413 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelConnectivityState.js.map @@ -0,0 +1 @@ +{"version":3,"file":"ChannelConnectivityState.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/ChannelConnectivityState.ts"],"names":[],"mappings":";AAAA,sCAAsC;;;AAGtC,sCAAsC;AAEtC,IAAY,gDAOX;AAPD,WAAY,gDAAgD;IAC1D,6HAAW,CAAA;IACX,uHAAQ,CAAA;IACR,mIAAc,CAAA;IACd,yHAAS,CAAA;IACT,iJAAqB,CAAA;IACrB,+HAAY,CAAA;AACd,CAAC,EAPW,gDAAgD,GAAhD,wDAAgD,KAAhD,wDAAgD,QAO3D"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelData.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelData.d.ts new file mode 100644 index 000000000..e9ac29146 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelData.d.ts @@ -0,0 +1,73 @@ +/// +import type { ChannelConnectivityState as _grpc_channelz_v1_ChannelConnectivityState, ChannelConnectivityState__Output as _grpc_channelz_v1_ChannelConnectivityState__Output } from '../../../grpc/channelz/v1/ChannelConnectivityState'; +import type { ChannelTrace as _grpc_channelz_v1_ChannelTrace, ChannelTrace__Output as _grpc_channelz_v1_ChannelTrace__Output } from '../../../grpc/channelz/v1/ChannelTrace'; +import type { Timestamp as _google_protobuf_Timestamp, Timestamp__Output as _google_protobuf_Timestamp__Output } from '../../../google/protobuf/Timestamp'; +import type { Long } from '@grpc/proto-loader'; +/** + * Channel data is data related to a specific Channel or Subchannel. + */ +export interface ChannelData { + /** + * The connectivity state of the channel or subchannel. Implementations + * should always set this. + */ + 'state'?: (_grpc_channelz_v1_ChannelConnectivityState | null); + /** + * The target this channel originally tried to connect to. May be absent + */ + 'target'?: (string); + /** + * A trace of recent events on the channel. May be absent. + */ + 'trace'?: (_grpc_channelz_v1_ChannelTrace | null); + /** + * The number of calls started on the channel + */ + 'calls_started'?: (number | string | Long); + /** + * The number of calls that have completed with an OK status + */ + 'calls_succeeded'?: (number | string | Long); + /** + * The number of calls that have completed with a non-OK status + */ + 'calls_failed'?: (number | string | Long); + /** + * The last time a call was started on the channel. + */ + 'last_call_started_timestamp'?: (_google_protobuf_Timestamp | null); +} +/** + * Channel data is data related to a specific Channel or Subchannel. + */ +export interface ChannelData__Output { + /** + * The connectivity state of the channel or subchannel. Implementations + * should always set this. + */ + 'state': (_grpc_channelz_v1_ChannelConnectivityState__Output | null); + /** + * The target this channel originally tried to connect to. May be absent + */ + 'target': (string); + /** + * A trace of recent events on the channel. May be absent. + */ + 'trace': (_grpc_channelz_v1_ChannelTrace__Output | null); + /** + * The number of calls started on the channel + */ + 'calls_started': (string); + /** + * The number of calls that have completed with an OK status + */ + 'calls_succeeded': (string); + /** + * The number of calls that have completed with a non-OK status + */ + 'calls_failed': (string); + /** + * The last time a call was started on the channel. + */ + 'last_call_started_timestamp': (_google_protobuf_Timestamp__Output | null); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelData.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelData.js new file mode 100644 index 000000000..dffbd45cd --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelData.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=ChannelData.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelData.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelData.js.map new file mode 100644 index 000000000..bb2b4c471 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelData.js.map @@ -0,0 +1 @@ +{"version":3,"file":"ChannelData.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/ChannelData.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelRef.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelRef.d.ts new file mode 100644 index 000000000..dce3c239c --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelRef.d.ts @@ -0,0 +1,28 @@ +/// +import type { Long } from '@grpc/proto-loader'; +/** + * ChannelRef is a reference to a Channel. + */ +export interface ChannelRef { + /** + * The globally unique id for this channel. Must be a positive number. + */ + 'channel_id'?: (number | string | Long); + /** + * An optional name associated with the channel. + */ + 'name'?: (string); +} +/** + * ChannelRef is a reference to a Channel. + */ +export interface ChannelRef__Output { + /** + * The globally unique id for this channel. Must be a positive number. + */ + 'channel_id': (string); + /** + * An optional name associated with the channel. + */ + 'name': (string); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelRef.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelRef.js new file mode 100644 index 000000000..d239819ec --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelRef.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=ChannelRef.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelRef.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelRef.js.map new file mode 100644 index 000000000..1030dedb9 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelRef.js.map @@ -0,0 +1 @@ +{"version":3,"file":"ChannelRef.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/ChannelRef.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelTrace.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelTrace.d.ts new file mode 100644 index 000000000..fa5f63f45 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelTrace.d.ts @@ -0,0 +1,42 @@ +/// +import type { Timestamp as _google_protobuf_Timestamp, Timestamp__Output as _google_protobuf_Timestamp__Output } from '../../../google/protobuf/Timestamp'; +import type { ChannelTraceEvent as _grpc_channelz_v1_ChannelTraceEvent, ChannelTraceEvent__Output as _grpc_channelz_v1_ChannelTraceEvent__Output } from '../../../grpc/channelz/v1/ChannelTraceEvent'; +import type { Long } from '@grpc/proto-loader'; +/** + * ChannelTrace represents the recent events that have occurred on the channel. + */ +export interface ChannelTrace { + /** + * Number of events ever logged in this tracing object. This can differ from + * events.size() because events can be overwritten or garbage collected by + * implementations. + */ + 'num_events_logged'?: (number | string | Long); + /** + * Time that this channel was created. + */ + 'creation_timestamp'?: (_google_protobuf_Timestamp | null); + /** + * List of events that have occurred on this channel. + */ + 'events'?: (_grpc_channelz_v1_ChannelTraceEvent)[]; +} +/** + * ChannelTrace represents the recent events that have occurred on the channel. + */ +export interface ChannelTrace__Output { + /** + * Number of events ever logged in this tracing object. This can differ from + * events.size() because events can be overwritten or garbage collected by + * implementations. + */ + 'num_events_logged': (string); + /** + * Time that this channel was created. + */ + 'creation_timestamp': (_google_protobuf_Timestamp__Output | null); + /** + * List of events that have occurred on this channel. + */ + 'events': (_grpc_channelz_v1_ChannelTraceEvent__Output)[]; +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelTrace.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelTrace.js new file mode 100644 index 000000000..112069c0e --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelTrace.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=ChannelTrace.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelTrace.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelTrace.js.map new file mode 100644 index 000000000..2f665dc2c --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelTrace.js.map @@ -0,0 +1 @@ +{"version":3,"file":"ChannelTrace.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/ChannelTrace.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelTraceEvent.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelTraceEvent.d.ts new file mode 100644 index 000000000..fd4003fcc --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelTraceEvent.d.ts @@ -0,0 +1,66 @@ +import type { Timestamp as _google_protobuf_Timestamp, Timestamp__Output as _google_protobuf_Timestamp__Output } from '../../../google/protobuf/Timestamp'; +import type { ChannelRef as _grpc_channelz_v1_ChannelRef, ChannelRef__Output as _grpc_channelz_v1_ChannelRef__Output } from '../../../grpc/channelz/v1/ChannelRef'; +import type { SubchannelRef as _grpc_channelz_v1_SubchannelRef, SubchannelRef__Output as _grpc_channelz_v1_SubchannelRef__Output } from '../../../grpc/channelz/v1/SubchannelRef'; +/** + * The supported severity levels of trace events. + */ +export declare enum _grpc_channelz_v1_ChannelTraceEvent_Severity { + CT_UNKNOWN = 0, + CT_INFO = 1, + CT_WARNING = 2, + CT_ERROR = 3 +} +/** + * A trace event is an interesting thing that happened to a channel or + * subchannel, such as creation, address resolution, subchannel creation, etc. + */ +export interface ChannelTraceEvent { + /** + * High level description of the event. + */ + 'description'?: (string); + /** + * the severity of the trace event + */ + 'severity'?: (_grpc_channelz_v1_ChannelTraceEvent_Severity | keyof typeof _grpc_channelz_v1_ChannelTraceEvent_Severity); + /** + * When this event occurred. + */ + 'timestamp'?: (_google_protobuf_Timestamp | null); + 'channel_ref'?: (_grpc_channelz_v1_ChannelRef | null); + 'subchannel_ref'?: (_grpc_channelz_v1_SubchannelRef | null); + /** + * ref of referenced channel or subchannel. + * Optional, only present if this event refers to a child object. For example, + * this field would be filled if this trace event was for a subchannel being + * created. + */ + 'child_ref'?: "channel_ref" | "subchannel_ref"; +} +/** + * A trace event is an interesting thing that happened to a channel or + * subchannel, such as creation, address resolution, subchannel creation, etc. + */ +export interface ChannelTraceEvent__Output { + /** + * High level description of the event. + */ + 'description': (string); + /** + * the severity of the trace event + */ + 'severity': (keyof typeof _grpc_channelz_v1_ChannelTraceEvent_Severity); + /** + * When this event occurred. + */ + 'timestamp': (_google_protobuf_Timestamp__Output | null); + 'channel_ref'?: (_grpc_channelz_v1_ChannelRef__Output | null); + 'subchannel_ref'?: (_grpc_channelz_v1_SubchannelRef__Output | null); + /** + * ref of referenced channel or subchannel. + * Optional, only present if this event refers to a child object. For example, + * this field would be filled if this trace event was for a subchannel being + * created. + */ + 'child_ref': "channel_ref" | "subchannel_ref"; +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelTraceEvent.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelTraceEvent.js new file mode 100644 index 000000000..16d91c688 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelTraceEvent.js @@ -0,0 +1,16 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +exports._grpc_channelz_v1_ChannelTraceEvent_Severity = void 0; +// Original file: proto/channelz.proto +/** + * The supported severity levels of trace events. + */ +var _grpc_channelz_v1_ChannelTraceEvent_Severity; +(function (_grpc_channelz_v1_ChannelTraceEvent_Severity) { + _grpc_channelz_v1_ChannelTraceEvent_Severity[_grpc_channelz_v1_ChannelTraceEvent_Severity["CT_UNKNOWN"] = 0] = "CT_UNKNOWN"; + _grpc_channelz_v1_ChannelTraceEvent_Severity[_grpc_channelz_v1_ChannelTraceEvent_Severity["CT_INFO"] = 1] = "CT_INFO"; + _grpc_channelz_v1_ChannelTraceEvent_Severity[_grpc_channelz_v1_ChannelTraceEvent_Severity["CT_WARNING"] = 2] = "CT_WARNING"; + _grpc_channelz_v1_ChannelTraceEvent_Severity[_grpc_channelz_v1_ChannelTraceEvent_Severity["CT_ERROR"] = 3] = "CT_ERROR"; +})(_grpc_channelz_v1_ChannelTraceEvent_Severity = exports._grpc_channelz_v1_ChannelTraceEvent_Severity || (exports._grpc_channelz_v1_ChannelTraceEvent_Severity = {})); +//# sourceMappingURL=ChannelTraceEvent.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelTraceEvent.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelTraceEvent.js.map new file mode 100644 index 000000000..758c60b5f --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ChannelTraceEvent.js.map @@ -0,0 +1 @@ +{"version":3,"file":"ChannelTraceEvent.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/ChannelTraceEvent.ts"],"names":[],"mappings":";AAAA,sCAAsC;;;AAMtC,sCAAsC;AAEtC;;GAEG;AACH,IAAY,4CAKX;AALD,WAAY,4CAA4C;IACtD,2HAAc,CAAA;IACd,qHAAW,CAAA;IACX,2HAAc,CAAA;IACd,uHAAY,CAAA;AACd,CAAC,EALW,4CAA4C,GAA5C,oDAA4C,KAA5C,oDAA4C,QAKvD"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Channelz.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Channelz.d.ts new file mode 100644 index 000000000..3e9eb9867 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Channelz.d.ts @@ -0,0 +1,159 @@ +import type * as grpc from '../../../../index'; +import type { MethodDefinition } from '@grpc/proto-loader'; +import type { GetChannelRequest as _grpc_channelz_v1_GetChannelRequest, GetChannelRequest__Output as _grpc_channelz_v1_GetChannelRequest__Output } from '../../../grpc/channelz/v1/GetChannelRequest'; +import type { GetChannelResponse as _grpc_channelz_v1_GetChannelResponse, GetChannelResponse__Output as _grpc_channelz_v1_GetChannelResponse__Output } from '../../../grpc/channelz/v1/GetChannelResponse'; +import type { GetServerRequest as _grpc_channelz_v1_GetServerRequest, GetServerRequest__Output as _grpc_channelz_v1_GetServerRequest__Output } from '../../../grpc/channelz/v1/GetServerRequest'; +import type { GetServerResponse as _grpc_channelz_v1_GetServerResponse, GetServerResponse__Output as _grpc_channelz_v1_GetServerResponse__Output } from '../../../grpc/channelz/v1/GetServerResponse'; +import type { GetServerSocketsRequest as _grpc_channelz_v1_GetServerSocketsRequest, GetServerSocketsRequest__Output as _grpc_channelz_v1_GetServerSocketsRequest__Output } from '../../../grpc/channelz/v1/GetServerSocketsRequest'; +import type { GetServerSocketsResponse as _grpc_channelz_v1_GetServerSocketsResponse, GetServerSocketsResponse__Output as _grpc_channelz_v1_GetServerSocketsResponse__Output } from '../../../grpc/channelz/v1/GetServerSocketsResponse'; +import type { GetServersRequest as _grpc_channelz_v1_GetServersRequest, GetServersRequest__Output as _grpc_channelz_v1_GetServersRequest__Output } from '../../../grpc/channelz/v1/GetServersRequest'; +import type { GetServersResponse as _grpc_channelz_v1_GetServersResponse, GetServersResponse__Output as _grpc_channelz_v1_GetServersResponse__Output } from '../../../grpc/channelz/v1/GetServersResponse'; +import type { GetSocketRequest as _grpc_channelz_v1_GetSocketRequest, GetSocketRequest__Output as _grpc_channelz_v1_GetSocketRequest__Output } from '../../../grpc/channelz/v1/GetSocketRequest'; +import type { GetSocketResponse as _grpc_channelz_v1_GetSocketResponse, GetSocketResponse__Output as _grpc_channelz_v1_GetSocketResponse__Output } from '../../../grpc/channelz/v1/GetSocketResponse'; +import type { GetSubchannelRequest as _grpc_channelz_v1_GetSubchannelRequest, GetSubchannelRequest__Output as _grpc_channelz_v1_GetSubchannelRequest__Output } from '../../../grpc/channelz/v1/GetSubchannelRequest'; +import type { GetSubchannelResponse as _grpc_channelz_v1_GetSubchannelResponse, GetSubchannelResponse__Output as _grpc_channelz_v1_GetSubchannelResponse__Output } from '../../../grpc/channelz/v1/GetSubchannelResponse'; +import type { GetTopChannelsRequest as _grpc_channelz_v1_GetTopChannelsRequest, GetTopChannelsRequest__Output as _grpc_channelz_v1_GetTopChannelsRequest__Output } from '../../../grpc/channelz/v1/GetTopChannelsRequest'; +import type { GetTopChannelsResponse as _grpc_channelz_v1_GetTopChannelsResponse, GetTopChannelsResponse__Output as _grpc_channelz_v1_GetTopChannelsResponse__Output } from '../../../grpc/channelz/v1/GetTopChannelsResponse'; +/** + * Channelz is a service exposed by gRPC servers that provides detailed debug + * information. + */ +export interface ChannelzClient extends grpc.Client { + /** + * Returns a single Channel, or else a NOT_FOUND code. + */ + GetChannel(argument: _grpc_channelz_v1_GetChannelRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetChannelResponse__Output>): grpc.ClientUnaryCall; + GetChannel(argument: _grpc_channelz_v1_GetChannelRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetChannelResponse__Output>): grpc.ClientUnaryCall; + GetChannel(argument: _grpc_channelz_v1_GetChannelRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetChannelResponse__Output>): grpc.ClientUnaryCall; + GetChannel(argument: _grpc_channelz_v1_GetChannelRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetChannelResponse__Output>): grpc.ClientUnaryCall; + /** + * Returns a single Server, or else a NOT_FOUND code. + */ + GetServer(argument: _grpc_channelz_v1_GetServerRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerResponse__Output>): grpc.ClientUnaryCall; + GetServer(argument: _grpc_channelz_v1_GetServerRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerResponse__Output>): grpc.ClientUnaryCall; + GetServer(argument: _grpc_channelz_v1_GetServerRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerResponse__Output>): grpc.ClientUnaryCall; + GetServer(argument: _grpc_channelz_v1_GetServerRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerResponse__Output>): grpc.ClientUnaryCall; + /** + * Returns a single Server, or else a NOT_FOUND code. + */ + getServer(argument: _grpc_channelz_v1_GetServerRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerResponse__Output>): grpc.ClientUnaryCall; + getServer(argument: _grpc_channelz_v1_GetServerRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerResponse__Output>): grpc.ClientUnaryCall; + getServer(argument: _grpc_channelz_v1_GetServerRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerResponse__Output>): grpc.ClientUnaryCall; + getServer(argument: _grpc_channelz_v1_GetServerRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerResponse__Output>): grpc.ClientUnaryCall; + /** + * Gets all server sockets that exist in the process. + */ + GetServerSockets(argument: _grpc_channelz_v1_GetServerSocketsRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerSocketsResponse__Output>): grpc.ClientUnaryCall; + GetServerSockets(argument: _grpc_channelz_v1_GetServerSocketsRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerSocketsResponse__Output>): grpc.ClientUnaryCall; + GetServerSockets(argument: _grpc_channelz_v1_GetServerSocketsRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerSocketsResponse__Output>): grpc.ClientUnaryCall; + GetServerSockets(argument: _grpc_channelz_v1_GetServerSocketsRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerSocketsResponse__Output>): grpc.ClientUnaryCall; + /** + * Gets all server sockets that exist in the process. + */ + getServerSockets(argument: _grpc_channelz_v1_GetServerSocketsRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerSocketsResponse__Output>): grpc.ClientUnaryCall; + getServerSockets(argument: _grpc_channelz_v1_GetServerSocketsRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerSocketsResponse__Output>): grpc.ClientUnaryCall; + getServerSockets(argument: _grpc_channelz_v1_GetServerSocketsRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerSocketsResponse__Output>): grpc.ClientUnaryCall; + getServerSockets(argument: _grpc_channelz_v1_GetServerSocketsRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerSocketsResponse__Output>): grpc.ClientUnaryCall; + /** + * Gets all servers that exist in the process. + */ + GetServers(argument: _grpc_channelz_v1_GetServersRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServersResponse__Output>): grpc.ClientUnaryCall; + GetServers(argument: _grpc_channelz_v1_GetServersRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetServersResponse__Output>): grpc.ClientUnaryCall; + GetServers(argument: _grpc_channelz_v1_GetServersRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServersResponse__Output>): grpc.ClientUnaryCall; + GetServers(argument: _grpc_channelz_v1_GetServersRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetServersResponse__Output>): grpc.ClientUnaryCall; + /** + * Gets all servers that exist in the process. + */ + getServers(argument: _grpc_channelz_v1_GetServersRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServersResponse__Output>): grpc.ClientUnaryCall; + getServers(argument: _grpc_channelz_v1_GetServersRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetServersResponse__Output>): grpc.ClientUnaryCall; + getServers(argument: _grpc_channelz_v1_GetServersRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServersResponse__Output>): grpc.ClientUnaryCall; + getServers(argument: _grpc_channelz_v1_GetServersRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetServersResponse__Output>): grpc.ClientUnaryCall; + /** + * Returns a single Socket or else a NOT_FOUND code. + */ + GetSocket(argument: _grpc_channelz_v1_GetSocketRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetSocketResponse__Output>): grpc.ClientUnaryCall; + GetSocket(argument: _grpc_channelz_v1_GetSocketRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetSocketResponse__Output>): grpc.ClientUnaryCall; + GetSocket(argument: _grpc_channelz_v1_GetSocketRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetSocketResponse__Output>): grpc.ClientUnaryCall; + GetSocket(argument: _grpc_channelz_v1_GetSocketRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetSocketResponse__Output>): grpc.ClientUnaryCall; + /** + * Returns a single Socket or else a NOT_FOUND code. + */ + getSocket(argument: _grpc_channelz_v1_GetSocketRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetSocketResponse__Output>): grpc.ClientUnaryCall; + getSocket(argument: _grpc_channelz_v1_GetSocketRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetSocketResponse__Output>): grpc.ClientUnaryCall; + getSocket(argument: _grpc_channelz_v1_GetSocketRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetSocketResponse__Output>): grpc.ClientUnaryCall; + getSocket(argument: _grpc_channelz_v1_GetSocketRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetSocketResponse__Output>): grpc.ClientUnaryCall; + /** + * Returns a single Subchannel, or else a NOT_FOUND code. + */ + GetSubchannel(argument: _grpc_channelz_v1_GetSubchannelRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetSubchannelResponse__Output>): grpc.ClientUnaryCall; + GetSubchannel(argument: _grpc_channelz_v1_GetSubchannelRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetSubchannelResponse__Output>): grpc.ClientUnaryCall; + GetSubchannel(argument: _grpc_channelz_v1_GetSubchannelRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetSubchannelResponse__Output>): grpc.ClientUnaryCall; + GetSubchannel(argument: _grpc_channelz_v1_GetSubchannelRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetSubchannelResponse__Output>): grpc.ClientUnaryCall; + /** + * Returns a single Subchannel, or else a NOT_FOUND code. + */ + getSubchannel(argument: _grpc_channelz_v1_GetSubchannelRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetSubchannelResponse__Output>): grpc.ClientUnaryCall; + getSubchannel(argument: _grpc_channelz_v1_GetSubchannelRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetSubchannelResponse__Output>): grpc.ClientUnaryCall; + getSubchannel(argument: _grpc_channelz_v1_GetSubchannelRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetSubchannelResponse__Output>): grpc.ClientUnaryCall; + getSubchannel(argument: _grpc_channelz_v1_GetSubchannelRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetSubchannelResponse__Output>): grpc.ClientUnaryCall; + /** + * Gets all root channels (i.e. channels the application has directly + * created). This does not include subchannels nor non-top level channels. + */ + GetTopChannels(argument: _grpc_channelz_v1_GetTopChannelsRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetTopChannelsResponse__Output>): grpc.ClientUnaryCall; + GetTopChannels(argument: _grpc_channelz_v1_GetTopChannelsRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetTopChannelsResponse__Output>): grpc.ClientUnaryCall; + GetTopChannels(argument: _grpc_channelz_v1_GetTopChannelsRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetTopChannelsResponse__Output>): grpc.ClientUnaryCall; + GetTopChannels(argument: _grpc_channelz_v1_GetTopChannelsRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetTopChannelsResponse__Output>): grpc.ClientUnaryCall; + /** + * Gets all root channels (i.e. channels the application has directly + * created). This does not include subchannels nor non-top level channels. + */ + getTopChannels(argument: _grpc_channelz_v1_GetTopChannelsRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetTopChannelsResponse__Output>): grpc.ClientUnaryCall; + getTopChannels(argument: _grpc_channelz_v1_GetTopChannelsRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetTopChannelsResponse__Output>): grpc.ClientUnaryCall; + getTopChannels(argument: _grpc_channelz_v1_GetTopChannelsRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetTopChannelsResponse__Output>): grpc.ClientUnaryCall; + getTopChannels(argument: _grpc_channelz_v1_GetTopChannelsRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetTopChannelsResponse__Output>): grpc.ClientUnaryCall; +} +/** + * Channelz is a service exposed by gRPC servers that provides detailed debug + * information. + */ +export interface ChannelzHandlers extends grpc.UntypedServiceImplementation { + /** + * Returns a single Channel, or else a NOT_FOUND code. + */ + GetChannel: grpc.handleUnaryCall<_grpc_channelz_v1_GetChannelRequest__Output, _grpc_channelz_v1_GetChannelResponse>; + /** + * Returns a single Server, or else a NOT_FOUND code. + */ + GetServer: grpc.handleUnaryCall<_grpc_channelz_v1_GetServerRequest__Output, _grpc_channelz_v1_GetServerResponse>; + /** + * Gets all server sockets that exist in the process. + */ + GetServerSockets: grpc.handleUnaryCall<_grpc_channelz_v1_GetServerSocketsRequest__Output, _grpc_channelz_v1_GetServerSocketsResponse>; + /** + * Gets all servers that exist in the process. + */ + GetServers: grpc.handleUnaryCall<_grpc_channelz_v1_GetServersRequest__Output, _grpc_channelz_v1_GetServersResponse>; + /** + * Returns a single Socket or else a NOT_FOUND code. + */ + GetSocket: grpc.handleUnaryCall<_grpc_channelz_v1_GetSocketRequest__Output, _grpc_channelz_v1_GetSocketResponse>; + /** + * Returns a single Subchannel, or else a NOT_FOUND code. + */ + GetSubchannel: grpc.handleUnaryCall<_grpc_channelz_v1_GetSubchannelRequest__Output, _grpc_channelz_v1_GetSubchannelResponse>; + /** + * Gets all root channels (i.e. channels the application has directly + * created). This does not include subchannels nor non-top level channels. + */ + GetTopChannels: grpc.handleUnaryCall<_grpc_channelz_v1_GetTopChannelsRequest__Output, _grpc_channelz_v1_GetTopChannelsResponse>; +} +export interface ChannelzDefinition extends grpc.ServiceDefinition { + GetChannel: MethodDefinition<_grpc_channelz_v1_GetChannelRequest, _grpc_channelz_v1_GetChannelResponse, _grpc_channelz_v1_GetChannelRequest__Output, _grpc_channelz_v1_GetChannelResponse__Output>; + GetServer: MethodDefinition<_grpc_channelz_v1_GetServerRequest, _grpc_channelz_v1_GetServerResponse, _grpc_channelz_v1_GetServerRequest__Output, _grpc_channelz_v1_GetServerResponse__Output>; + GetServerSockets: MethodDefinition<_grpc_channelz_v1_GetServerSocketsRequest, _grpc_channelz_v1_GetServerSocketsResponse, _grpc_channelz_v1_GetServerSocketsRequest__Output, _grpc_channelz_v1_GetServerSocketsResponse__Output>; + GetServers: MethodDefinition<_grpc_channelz_v1_GetServersRequest, _grpc_channelz_v1_GetServersResponse, _grpc_channelz_v1_GetServersRequest__Output, _grpc_channelz_v1_GetServersResponse__Output>; + GetSocket: MethodDefinition<_grpc_channelz_v1_GetSocketRequest, _grpc_channelz_v1_GetSocketResponse, _grpc_channelz_v1_GetSocketRequest__Output, _grpc_channelz_v1_GetSocketResponse__Output>; + GetSubchannel: MethodDefinition<_grpc_channelz_v1_GetSubchannelRequest, _grpc_channelz_v1_GetSubchannelResponse, _grpc_channelz_v1_GetSubchannelRequest__Output, _grpc_channelz_v1_GetSubchannelResponse__Output>; + GetTopChannels: MethodDefinition<_grpc_channelz_v1_GetTopChannelsRequest, _grpc_channelz_v1_GetTopChannelsResponse, _grpc_channelz_v1_GetTopChannelsRequest__Output, _grpc_channelz_v1_GetTopChannelsResponse__Output>; +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Channelz.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Channelz.js new file mode 100644 index 000000000..9fdf9fc57 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Channelz.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=Channelz.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Channelz.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Channelz.js.map new file mode 100644 index 000000000..86fafec2e --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Channelz.js.map @@ -0,0 +1 @@ +{"version":3,"file":"Channelz.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/Channelz.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetChannelRequest.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetChannelRequest.d.ts new file mode 100644 index 000000000..3a266f41c --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetChannelRequest.d.ts @@ -0,0 +1,14 @@ +/// +import type { Long } from '@grpc/proto-loader'; +export interface GetChannelRequest { + /** + * channel_id is the identifier of the specific channel to get. + */ + 'channel_id'?: (number | string | Long); +} +export interface GetChannelRequest__Output { + /** + * channel_id is the identifier of the specific channel to get. + */ + 'channel_id': (string); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetChannelRequest.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetChannelRequest.js new file mode 100644 index 000000000..10948d408 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetChannelRequest.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=GetChannelRequest.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetChannelRequest.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetChannelRequest.js.map new file mode 100644 index 000000000..0ae3f26a6 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetChannelRequest.js.map @@ -0,0 +1 @@ +{"version":3,"file":"GetChannelRequest.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/GetChannelRequest.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetChannelResponse.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetChannelResponse.d.ts new file mode 100644 index 000000000..2fbab92ba --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetChannelResponse.d.ts @@ -0,0 +1,15 @@ +import type { Channel as _grpc_channelz_v1_Channel, Channel__Output as _grpc_channelz_v1_Channel__Output } from '../../../grpc/channelz/v1/Channel'; +export interface GetChannelResponse { + /** + * The Channel that corresponds to the requested channel_id. This field + * should be set. + */ + 'channel'?: (_grpc_channelz_v1_Channel | null); +} +export interface GetChannelResponse__Output { + /** + * The Channel that corresponds to the requested channel_id. This field + * should be set. + */ + 'channel': (_grpc_channelz_v1_Channel__Output | null); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetChannelResponse.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetChannelResponse.js new file mode 100644 index 000000000..02a4426a7 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetChannelResponse.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=GetChannelResponse.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetChannelResponse.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetChannelResponse.js.map new file mode 100644 index 000000000..a3cfefbae --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetChannelResponse.js.map @@ -0,0 +1 @@ +{"version":3,"file":"GetChannelResponse.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/GetChannelResponse.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerRequest.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerRequest.d.ts new file mode 100644 index 000000000..9dd14276d --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerRequest.d.ts @@ -0,0 +1,14 @@ +/// +import type { Long } from '@grpc/proto-loader'; +export interface GetServerRequest { + /** + * server_id is the identifier of the specific server to get. + */ + 'server_id'?: (number | string | Long); +} +export interface GetServerRequest__Output { + /** + * server_id is the identifier of the specific server to get. + */ + 'server_id': (string); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerRequest.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerRequest.js new file mode 100644 index 000000000..77717b4c4 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerRequest.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=GetServerRequest.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerRequest.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerRequest.js.map new file mode 100644 index 000000000..86fbba64a --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerRequest.js.map @@ -0,0 +1 @@ +{"version":3,"file":"GetServerRequest.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/GetServerRequest.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerResponse.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerResponse.d.ts new file mode 100644 index 000000000..2da13dd91 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerResponse.d.ts @@ -0,0 +1,15 @@ +import type { Server as _grpc_channelz_v1_Server, Server__Output as _grpc_channelz_v1_Server__Output } from '../../../grpc/channelz/v1/Server'; +export interface GetServerResponse { + /** + * The Server that corresponds to the requested server_id. This field + * should be set. + */ + 'server'?: (_grpc_channelz_v1_Server | null); +} +export interface GetServerResponse__Output { + /** + * The Server that corresponds to the requested server_id. This field + * should be set. + */ + 'server': (_grpc_channelz_v1_Server__Output | null); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerResponse.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerResponse.js new file mode 100644 index 000000000..130eb1b71 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerResponse.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=GetServerResponse.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerResponse.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerResponse.js.map new file mode 100644 index 000000000..f4b16ff95 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerResponse.js.map @@ -0,0 +1 @@ +{"version":3,"file":"GetServerResponse.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/GetServerResponse.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerSocketsRequest.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerSocketsRequest.d.ts new file mode 100644 index 000000000..bd9da7d93 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerSocketsRequest.d.ts @@ -0,0 +1,36 @@ +/// +import type { Long } from '@grpc/proto-loader'; +export interface GetServerSocketsRequest { + 'server_id'?: (number | string | Long); + /** + * start_socket_id indicates that only sockets at or above this id should be + * included in the results. + * To request the first page, this must be set to 0. To request + * subsequent pages, the client generates this value by adding 1 to + * the highest seen result ID. + */ + 'start_socket_id'?: (number | string | Long); + /** + * If non-zero, the server will return a page of results containing + * at most this many items. If zero, the server will choose a + * reasonable page size. Must never be negative. + */ + 'max_results'?: (number | string | Long); +} +export interface GetServerSocketsRequest__Output { + 'server_id': (string); + /** + * start_socket_id indicates that only sockets at or above this id should be + * included in the results. + * To request the first page, this must be set to 0. To request + * subsequent pages, the client generates this value by adding 1 to + * the highest seen result ID. + */ + 'start_socket_id': (string); + /** + * If non-zero, the server will return a page of results containing + * at most this many items. If zero, the server will choose a + * reasonable page size. Must never be negative. + */ + 'max_results': (string); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerSocketsRequest.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerSocketsRequest.js new file mode 100644 index 000000000..1a1518376 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerSocketsRequest.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=GetServerSocketsRequest.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerSocketsRequest.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerSocketsRequest.js.map new file mode 100644 index 000000000..458dd9822 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerSocketsRequest.js.map @@ -0,0 +1 @@ +{"version":3,"file":"GetServerSocketsRequest.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/GetServerSocketsRequest.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerSocketsResponse.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerSocketsResponse.d.ts new file mode 100644 index 000000000..4c329aebd --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerSocketsResponse.d.ts @@ -0,0 +1,29 @@ +import type { SocketRef as _grpc_channelz_v1_SocketRef, SocketRef__Output as _grpc_channelz_v1_SocketRef__Output } from '../../../grpc/channelz/v1/SocketRef'; +export interface GetServerSocketsResponse { + /** + * list of socket refs that the connection detail service knows about. Sorted in + * ascending socket_id order. + * Must contain at least 1 result, otherwise 'end' must be true. + */ + 'socket_ref'?: (_grpc_channelz_v1_SocketRef)[]; + /** + * If set, indicates that the list of sockets is the final list. Requesting + * more sockets will only return more if they are created after this RPC + * completes. + */ + 'end'?: (boolean); +} +export interface GetServerSocketsResponse__Output { + /** + * list of socket refs that the connection detail service knows about. Sorted in + * ascending socket_id order. + * Must contain at least 1 result, otherwise 'end' must be true. + */ + 'socket_ref': (_grpc_channelz_v1_SocketRef__Output)[]; + /** + * If set, indicates that the list of sockets is the final list. Requesting + * more sockets will only return more if they are created after this RPC + * completes. + */ + 'end': (boolean); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerSocketsResponse.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerSocketsResponse.js new file mode 100644 index 000000000..29e424fe8 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerSocketsResponse.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=GetServerSocketsResponse.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerSocketsResponse.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerSocketsResponse.js.map new file mode 100644 index 000000000..dc99923ea --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServerSocketsResponse.js.map @@ -0,0 +1 @@ +{"version":3,"file":"GetServerSocketsResponse.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/GetServerSocketsResponse.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServersRequest.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServersRequest.d.ts new file mode 100644 index 000000000..5912874e6 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServersRequest.d.ts @@ -0,0 +1,34 @@ +/// +import type { Long } from '@grpc/proto-loader'; +export interface GetServersRequest { + /** + * start_server_id indicates that only servers at or above this id should be + * included in the results. + * To request the first page, this must be set to 0. To request + * subsequent pages, the client generates this value by adding 1 to + * the highest seen result ID. + */ + 'start_server_id'?: (number | string | Long); + /** + * If non-zero, the server will return a page of results containing + * at most this many items. If zero, the server will choose a + * reasonable page size. Must never be negative. + */ + 'max_results'?: (number | string | Long); +} +export interface GetServersRequest__Output { + /** + * start_server_id indicates that only servers at or above this id should be + * included in the results. + * To request the first page, this must be set to 0. To request + * subsequent pages, the client generates this value by adding 1 to + * the highest seen result ID. + */ + 'start_server_id': (string); + /** + * If non-zero, the server will return a page of results containing + * at most this many items. If zero, the server will choose a + * reasonable page size. Must never be negative. + */ + 'max_results': (string); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServersRequest.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServersRequest.js new file mode 100644 index 000000000..737181344 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServersRequest.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=GetServersRequest.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServersRequest.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServersRequest.js.map new file mode 100644 index 000000000..db7c710a6 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServersRequest.js.map @@ -0,0 +1 @@ +{"version":3,"file":"GetServersRequest.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/GetServersRequest.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServersResponse.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServersResponse.d.ts new file mode 100644 index 000000000..d3840cd60 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServersResponse.d.ts @@ -0,0 +1,29 @@ +import type { Server as _grpc_channelz_v1_Server, Server__Output as _grpc_channelz_v1_Server__Output } from '../../../grpc/channelz/v1/Server'; +export interface GetServersResponse { + /** + * list of servers that the connection detail service knows about. Sorted in + * ascending server_id order. + * Must contain at least 1 result, otherwise 'end' must be true. + */ + 'server'?: (_grpc_channelz_v1_Server)[]; + /** + * If set, indicates that the list of servers is the final list. Requesting + * more servers will only return more if they are created after this RPC + * completes. + */ + 'end'?: (boolean); +} +export interface GetServersResponse__Output { + /** + * list of servers that the connection detail service knows about. Sorted in + * ascending server_id order. + * Must contain at least 1 result, otherwise 'end' must be true. + */ + 'server': (_grpc_channelz_v1_Server__Output)[]; + /** + * If set, indicates that the list of servers is the final list. Requesting + * more servers will only return more if they are created after this RPC + * completes. + */ + 'end': (boolean); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServersResponse.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServersResponse.js new file mode 100644 index 000000000..512429870 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServersResponse.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=GetServersResponse.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServersResponse.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServersResponse.js.map new file mode 100644 index 000000000..74e4bbae7 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetServersResponse.js.map @@ -0,0 +1 @@ +{"version":3,"file":"GetServersResponse.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/GetServersResponse.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSocketRequest.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSocketRequest.d.ts new file mode 100644 index 000000000..cc9325e7b --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSocketRequest.d.ts @@ -0,0 +1,26 @@ +/// +import type { Long } from '@grpc/proto-loader'; +export interface GetSocketRequest { + /** + * socket_id is the identifier of the specific socket to get. + */ + 'socket_id'?: (number | string | Long); + /** + * If true, the response will contain only high level information + * that is inexpensive to obtain. Fields thay may be omitted are + * documented. + */ + 'summary'?: (boolean); +} +export interface GetSocketRequest__Output { + /** + * socket_id is the identifier of the specific socket to get. + */ + 'socket_id': (string); + /** + * If true, the response will contain only high level information + * that is inexpensive to obtain. Fields thay may be omitted are + * documented. + */ + 'summary': (boolean); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSocketRequest.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSocketRequest.js new file mode 100644 index 000000000..40ad25b38 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSocketRequest.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=GetSocketRequest.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSocketRequest.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSocketRequest.js.map new file mode 100644 index 000000000..3b4c1803a --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSocketRequest.js.map @@ -0,0 +1 @@ +{"version":3,"file":"GetSocketRequest.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/GetSocketRequest.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSocketResponse.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSocketResponse.d.ts new file mode 100644 index 000000000..a9795d387 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSocketResponse.d.ts @@ -0,0 +1,15 @@ +import type { Socket as _grpc_channelz_v1_Socket, Socket__Output as _grpc_channelz_v1_Socket__Output } from '../../../grpc/channelz/v1/Socket'; +export interface GetSocketResponse { + /** + * The Socket that corresponds to the requested socket_id. This field + * should be set. + */ + 'socket'?: (_grpc_channelz_v1_Socket | null); +} +export interface GetSocketResponse__Output { + /** + * The Socket that corresponds to the requested socket_id. This field + * should be set. + */ + 'socket': (_grpc_channelz_v1_Socket__Output | null); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSocketResponse.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSocketResponse.js new file mode 100644 index 000000000..ace0ef252 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSocketResponse.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=GetSocketResponse.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSocketResponse.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSocketResponse.js.map new file mode 100644 index 000000000..90fada320 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSocketResponse.js.map @@ -0,0 +1 @@ +{"version":3,"file":"GetSocketResponse.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/GetSocketResponse.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSubchannelRequest.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSubchannelRequest.d.ts new file mode 100644 index 000000000..49c409085 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSubchannelRequest.d.ts @@ -0,0 +1,14 @@ +/// +import type { Long } from '@grpc/proto-loader'; +export interface GetSubchannelRequest { + /** + * subchannel_id is the identifier of the specific subchannel to get. + */ + 'subchannel_id'?: (number | string | Long); +} +export interface GetSubchannelRequest__Output { + /** + * subchannel_id is the identifier of the specific subchannel to get. + */ + 'subchannel_id': (string); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSubchannelRequest.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSubchannelRequest.js new file mode 100644 index 000000000..90f45ea08 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSubchannelRequest.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=GetSubchannelRequest.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSubchannelRequest.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSubchannelRequest.js.map new file mode 100644 index 000000000..b8f8f62ca --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSubchannelRequest.js.map @@ -0,0 +1 @@ +{"version":3,"file":"GetSubchannelRequest.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/GetSubchannelRequest.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSubchannelResponse.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSubchannelResponse.d.ts new file mode 100644 index 000000000..455639f4f --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSubchannelResponse.d.ts @@ -0,0 +1,15 @@ +import type { Subchannel as _grpc_channelz_v1_Subchannel, Subchannel__Output as _grpc_channelz_v1_Subchannel__Output } from '../../../grpc/channelz/v1/Subchannel'; +export interface GetSubchannelResponse { + /** + * The Subchannel that corresponds to the requested subchannel_id. This + * field should be set. + */ + 'subchannel'?: (_grpc_channelz_v1_Subchannel | null); +} +export interface GetSubchannelResponse__Output { + /** + * The Subchannel that corresponds to the requested subchannel_id. This + * field should be set. + */ + 'subchannel': (_grpc_channelz_v1_Subchannel__Output | null); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSubchannelResponse.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSubchannelResponse.js new file mode 100644 index 000000000..52d41116d --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSubchannelResponse.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=GetSubchannelResponse.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSubchannelResponse.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSubchannelResponse.js.map new file mode 100644 index 000000000..b39861fd2 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetSubchannelResponse.js.map @@ -0,0 +1 @@ +{"version":3,"file":"GetSubchannelResponse.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/GetSubchannelResponse.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetTopChannelsRequest.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetTopChannelsRequest.d.ts new file mode 100644 index 000000000..42cc4decf --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetTopChannelsRequest.d.ts @@ -0,0 +1,34 @@ +/// +import type { Long } from '@grpc/proto-loader'; +export interface GetTopChannelsRequest { + /** + * start_channel_id indicates that only channels at or above this id should be + * included in the results. + * To request the first page, this should be set to 0. To request + * subsequent pages, the client generates this value by adding 1 to + * the highest seen result ID. + */ + 'start_channel_id'?: (number | string | Long); + /** + * If non-zero, the server will return a page of results containing + * at most this many items. If zero, the server will choose a + * reasonable page size. Must never be negative. + */ + 'max_results'?: (number | string | Long); +} +export interface GetTopChannelsRequest__Output { + /** + * start_channel_id indicates that only channels at or above this id should be + * included in the results. + * To request the first page, this should be set to 0. To request + * subsequent pages, the client generates this value by adding 1 to + * the highest seen result ID. + */ + 'start_channel_id': (string); + /** + * If non-zero, the server will return a page of results containing + * at most this many items. If zero, the server will choose a + * reasonable page size. Must never be negative. + */ + 'max_results': (string); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetTopChannelsRequest.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetTopChannelsRequest.js new file mode 100644 index 000000000..8b3e023da --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetTopChannelsRequest.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=GetTopChannelsRequest.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetTopChannelsRequest.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetTopChannelsRequest.js.map new file mode 100644 index 000000000..c4ffc68e5 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetTopChannelsRequest.js.map @@ -0,0 +1 @@ +{"version":3,"file":"GetTopChannelsRequest.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/GetTopChannelsRequest.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetTopChannelsResponse.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetTopChannelsResponse.d.ts new file mode 100644 index 000000000..03f282f17 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetTopChannelsResponse.d.ts @@ -0,0 +1,29 @@ +import type { Channel as _grpc_channelz_v1_Channel, Channel__Output as _grpc_channelz_v1_Channel__Output } from '../../../grpc/channelz/v1/Channel'; +export interface GetTopChannelsResponse { + /** + * list of channels that the connection detail service knows about. Sorted in + * ascending channel_id order. + * Must contain at least 1 result, otherwise 'end' must be true. + */ + 'channel'?: (_grpc_channelz_v1_Channel)[]; + /** + * If set, indicates that the list of channels is the final list. Requesting + * more channels can only return more if they are created after this RPC + * completes. + */ + 'end'?: (boolean); +} +export interface GetTopChannelsResponse__Output { + /** + * list of channels that the connection detail service knows about. Sorted in + * ascending channel_id order. + * Must contain at least 1 result, otherwise 'end' must be true. + */ + 'channel': (_grpc_channelz_v1_Channel__Output)[]; + /** + * If set, indicates that the list of channels is the final list. Requesting + * more channels can only return more if they are created after this RPC + * completes. + */ + 'end': (boolean); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetTopChannelsResponse.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetTopChannelsResponse.js new file mode 100644 index 000000000..44f1c91d7 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetTopChannelsResponse.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=GetTopChannelsResponse.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetTopChannelsResponse.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetTopChannelsResponse.js.map new file mode 100644 index 000000000..b691e5e91 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/GetTopChannelsResponse.js.map @@ -0,0 +1 @@ +{"version":3,"file":"GetTopChannelsResponse.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/GetTopChannelsResponse.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Security.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Security.d.ts new file mode 100644 index 000000000..a78e8f83e --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Security.d.ts @@ -0,0 +1,80 @@ +/// +import type { Any as _google_protobuf_Any, Any__Output as _google_protobuf_Any__Output } from '../../../google/protobuf/Any'; +export interface _grpc_channelz_v1_Security_OtherSecurity { + /** + * The human readable version of the value. + */ + 'name'?: (string); + /** + * The actual security details message. + */ + 'value'?: (_google_protobuf_Any | null); +} +export interface _grpc_channelz_v1_Security_OtherSecurity__Output { + /** + * The human readable version of the value. + */ + 'name': (string); + /** + * The actual security details message. + */ + 'value': (_google_protobuf_Any__Output | null); +} +export interface _grpc_channelz_v1_Security_Tls { + /** + * The cipher suite name in the RFC 4346 format: + * https://tools.ietf.org/html/rfc4346#appendix-C + */ + 'standard_name'?: (string); + /** + * Some other way to describe the cipher suite if + * the RFC 4346 name is not available. + */ + 'other_name'?: (string); + /** + * the certificate used by this endpoint. + */ + 'local_certificate'?: (Buffer | Uint8Array | string); + /** + * the certificate used by the remote endpoint. + */ + 'remote_certificate'?: (Buffer | Uint8Array | string); + 'cipher_suite'?: "standard_name" | "other_name"; +} +export interface _grpc_channelz_v1_Security_Tls__Output { + /** + * The cipher suite name in the RFC 4346 format: + * https://tools.ietf.org/html/rfc4346#appendix-C + */ + 'standard_name'?: (string); + /** + * Some other way to describe the cipher suite if + * the RFC 4346 name is not available. + */ + 'other_name'?: (string); + /** + * the certificate used by this endpoint. + */ + 'local_certificate': (Buffer); + /** + * the certificate used by the remote endpoint. + */ + 'remote_certificate': (Buffer); + 'cipher_suite': "standard_name" | "other_name"; +} +/** + * Security represents details about how secure the socket is. + */ +export interface Security { + 'tls'?: (_grpc_channelz_v1_Security_Tls | null); + 'other'?: (_grpc_channelz_v1_Security_OtherSecurity | null); + 'model'?: "tls" | "other"; +} +/** + * Security represents details about how secure the socket is. + */ +export interface Security__Output { + 'tls'?: (_grpc_channelz_v1_Security_Tls__Output | null); + 'other'?: (_grpc_channelz_v1_Security_OtherSecurity__Output | null); + 'model': "tls" | "other"; +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Security.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Security.js new file mode 100644 index 000000000..022b36773 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Security.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=Security.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Security.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Security.js.map new file mode 100644 index 000000000..3243c97b0 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Security.js.map @@ -0,0 +1 @@ +{"version":3,"file":"Security.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/Security.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Server.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Server.d.ts new file mode 100644 index 000000000..8d984afbe --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Server.d.ts @@ -0,0 +1,41 @@ +import type { ServerRef as _grpc_channelz_v1_ServerRef, ServerRef__Output as _grpc_channelz_v1_ServerRef__Output } from '../../../grpc/channelz/v1/ServerRef'; +import type { ServerData as _grpc_channelz_v1_ServerData, ServerData__Output as _grpc_channelz_v1_ServerData__Output } from '../../../grpc/channelz/v1/ServerData'; +import type { SocketRef as _grpc_channelz_v1_SocketRef, SocketRef__Output as _grpc_channelz_v1_SocketRef__Output } from '../../../grpc/channelz/v1/SocketRef'; +/** + * Server represents a single server. There may be multiple servers in a single + * program. + */ +export interface Server { + /** + * The identifier for a Server. This should be set. + */ + 'ref'?: (_grpc_channelz_v1_ServerRef | null); + /** + * The associated data of the Server. + */ + 'data'?: (_grpc_channelz_v1_ServerData | null); + /** + * The sockets that the server is listening on. There are no ordering + * guarantees. This may be absent. + */ + 'listen_socket'?: (_grpc_channelz_v1_SocketRef)[]; +} +/** + * Server represents a single server. There may be multiple servers in a single + * program. + */ +export interface Server__Output { + /** + * The identifier for a Server. This should be set. + */ + 'ref': (_grpc_channelz_v1_ServerRef__Output | null); + /** + * The associated data of the Server. + */ + 'data': (_grpc_channelz_v1_ServerData__Output | null); + /** + * The sockets that the server is listening on. There are no ordering + * guarantees. This may be absent. + */ + 'listen_socket': (_grpc_channelz_v1_SocketRef__Output)[]; +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Server.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Server.js new file mode 100644 index 000000000..b230e4dee --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Server.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=Server.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Server.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Server.js.map new file mode 100644 index 000000000..522934de0 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Server.js.map @@ -0,0 +1 @@ +{"version":3,"file":"Server.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/Server.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ServerData.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ServerData.d.ts new file mode 100644 index 000000000..708d6ff13 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ServerData.d.ts @@ -0,0 +1,54 @@ +/// +import type { ChannelTrace as _grpc_channelz_v1_ChannelTrace, ChannelTrace__Output as _grpc_channelz_v1_ChannelTrace__Output } from '../../../grpc/channelz/v1/ChannelTrace'; +import type { Timestamp as _google_protobuf_Timestamp, Timestamp__Output as _google_protobuf_Timestamp__Output } from '../../../google/protobuf/Timestamp'; +import type { Long } from '@grpc/proto-loader'; +/** + * ServerData is data for a specific Server. + */ +export interface ServerData { + /** + * A trace of recent events on the server. May be absent. + */ + 'trace'?: (_grpc_channelz_v1_ChannelTrace | null); + /** + * The number of incoming calls started on the server + */ + 'calls_started'?: (number | string | Long); + /** + * The number of incoming calls that have completed with an OK status + */ + 'calls_succeeded'?: (number | string | Long); + /** + * The number of incoming calls that have a completed with a non-OK status + */ + 'calls_failed'?: (number | string | Long); + /** + * The last time a call was started on the server. + */ + 'last_call_started_timestamp'?: (_google_protobuf_Timestamp | null); +} +/** + * ServerData is data for a specific Server. + */ +export interface ServerData__Output { + /** + * A trace of recent events on the server. May be absent. + */ + 'trace': (_grpc_channelz_v1_ChannelTrace__Output | null); + /** + * The number of incoming calls started on the server + */ + 'calls_started': (string); + /** + * The number of incoming calls that have completed with an OK status + */ + 'calls_succeeded': (string); + /** + * The number of incoming calls that have a completed with a non-OK status + */ + 'calls_failed': (string); + /** + * The last time a call was started on the server. + */ + 'last_call_started_timestamp': (_google_protobuf_Timestamp__Output | null); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ServerData.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ServerData.js new file mode 100644 index 000000000..53d92a68c --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ServerData.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=ServerData.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ServerData.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ServerData.js.map new file mode 100644 index 000000000..b78c5b429 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ServerData.js.map @@ -0,0 +1 @@ +{"version":3,"file":"ServerData.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/ServerData.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ServerRef.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ServerRef.d.ts new file mode 100644 index 000000000..1dea55163 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ServerRef.d.ts @@ -0,0 +1,28 @@ +/// +import type { Long } from '@grpc/proto-loader'; +/** + * ServerRef is a reference to a Server. + */ +export interface ServerRef { + /** + * A globally unique identifier for this server. Must be a positive number. + */ + 'server_id'?: (number | string | Long); + /** + * An optional name associated with the server. + */ + 'name'?: (string); +} +/** + * ServerRef is a reference to a Server. + */ +export interface ServerRef__Output { + /** + * A globally unique identifier for this server. Must be a positive number. + */ + 'server_id': (string); + /** + * An optional name associated with the server. + */ + 'name': (string); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ServerRef.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ServerRef.js new file mode 100644 index 000000000..9a623c7f9 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ServerRef.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=ServerRef.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ServerRef.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ServerRef.js.map new file mode 100644 index 000000000..75f5aad28 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/ServerRef.js.map @@ -0,0 +1 @@ +{"version":3,"file":"ServerRef.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/ServerRef.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Socket.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Socket.d.ts new file mode 100644 index 000000000..91d4ad8b8 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Socket.d.ts @@ -0,0 +1,66 @@ +import type { SocketRef as _grpc_channelz_v1_SocketRef, SocketRef__Output as _grpc_channelz_v1_SocketRef__Output } from '../../../grpc/channelz/v1/SocketRef'; +import type { SocketData as _grpc_channelz_v1_SocketData, SocketData__Output as _grpc_channelz_v1_SocketData__Output } from '../../../grpc/channelz/v1/SocketData'; +import type { Address as _grpc_channelz_v1_Address, Address__Output as _grpc_channelz_v1_Address__Output } from '../../../grpc/channelz/v1/Address'; +import type { Security as _grpc_channelz_v1_Security, Security__Output as _grpc_channelz_v1_Security__Output } from '../../../grpc/channelz/v1/Security'; +/** + * Information about an actual connection. Pronounced "sock-ay". + */ +export interface Socket { + /** + * The identifier for the Socket. + */ + 'ref'?: (_grpc_channelz_v1_SocketRef | null); + /** + * Data specific to this Socket. + */ + 'data'?: (_grpc_channelz_v1_SocketData | null); + /** + * The locally bound address. + */ + 'local'?: (_grpc_channelz_v1_Address | null); + /** + * The remote bound address. May be absent. + */ + 'remote'?: (_grpc_channelz_v1_Address | null); + /** + * Security details for this socket. May be absent if not available, or + * there is no security on the socket. + */ + 'security'?: (_grpc_channelz_v1_Security | null); + /** + * Optional, represents the name of the remote endpoint, if different than + * the original target name. + */ + 'remote_name'?: (string); +} +/** + * Information about an actual connection. Pronounced "sock-ay". + */ +export interface Socket__Output { + /** + * The identifier for the Socket. + */ + 'ref': (_grpc_channelz_v1_SocketRef__Output | null); + /** + * Data specific to this Socket. + */ + 'data': (_grpc_channelz_v1_SocketData__Output | null); + /** + * The locally bound address. + */ + 'local': (_grpc_channelz_v1_Address__Output | null); + /** + * The remote bound address. May be absent. + */ + 'remote': (_grpc_channelz_v1_Address__Output | null); + /** + * Security details for this socket. May be absent if not available, or + * there is no security on the socket. + */ + 'security': (_grpc_channelz_v1_Security__Output | null); + /** + * Optional, represents the name of the remote endpoint, if different than + * the original target name. + */ + 'remote_name': (string); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Socket.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Socket.js new file mode 100644 index 000000000..c1e50047b --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Socket.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=Socket.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Socket.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Socket.js.map new file mode 100644 index 000000000..d49d9df3c --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Socket.js.map @@ -0,0 +1 @@ +{"version":3,"file":"Socket.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/Socket.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketData.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketData.d.ts new file mode 100644 index 000000000..e310bb5cd --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketData.d.ts @@ -0,0 +1,147 @@ +/// +import type { Timestamp as _google_protobuf_Timestamp, Timestamp__Output as _google_protobuf_Timestamp__Output } from '../../../google/protobuf/Timestamp'; +import type { Int64Value as _google_protobuf_Int64Value, Int64Value__Output as _google_protobuf_Int64Value__Output } from '../../../google/protobuf/Int64Value'; +import type { SocketOption as _grpc_channelz_v1_SocketOption, SocketOption__Output as _grpc_channelz_v1_SocketOption__Output } from '../../../grpc/channelz/v1/SocketOption'; +import type { Long } from '@grpc/proto-loader'; +/** + * SocketData is data associated for a specific Socket. The fields present + * are specific to the implementation, so there may be minor differences in + * the semantics. (e.g. flow control windows) + */ +export interface SocketData { + /** + * The number of streams that have been started. + */ + 'streams_started'?: (number | string | Long); + /** + * The number of streams that have ended successfully: + * On client side, received frame with eos bit set; + * On server side, sent frame with eos bit set. + */ + 'streams_succeeded'?: (number | string | Long); + /** + * The number of streams that have ended unsuccessfully: + * On client side, ended without receiving frame with eos bit set; + * On server side, ended without sending frame with eos bit set. + */ + 'streams_failed'?: (number | string | Long); + /** + * The number of grpc messages successfully sent on this socket. + */ + 'messages_sent'?: (number | string | Long); + /** + * The number of grpc messages received on this socket. + */ + 'messages_received'?: (number | string | Long); + /** + * The number of keep alives sent. This is typically implemented with HTTP/2 + * ping messages. + */ + 'keep_alives_sent'?: (number | string | Long); + /** + * The last time a stream was created by this endpoint. Usually unset for + * servers. + */ + 'last_local_stream_created_timestamp'?: (_google_protobuf_Timestamp | null); + /** + * The last time a stream was created by the remote endpoint. Usually unset + * for clients. + */ + 'last_remote_stream_created_timestamp'?: (_google_protobuf_Timestamp | null); + /** + * The last time a message was sent by this endpoint. + */ + 'last_message_sent_timestamp'?: (_google_protobuf_Timestamp | null); + /** + * The last time a message was received by this endpoint. + */ + 'last_message_received_timestamp'?: (_google_protobuf_Timestamp | null); + /** + * The amount of window, granted to the local endpoint by the remote endpoint. + * This may be slightly out of date due to network latency. This does NOT + * include stream level or TCP level flow control info. + */ + 'local_flow_control_window'?: (_google_protobuf_Int64Value | null); + /** + * The amount of window, granted to the remote endpoint by the local endpoint. + * This may be slightly out of date due to network latency. This does NOT + * include stream level or TCP level flow control info. + */ + 'remote_flow_control_window'?: (_google_protobuf_Int64Value | null); + /** + * Socket options set on this socket. May be absent if 'summary' is set + * on GetSocketRequest. + */ + 'option'?: (_grpc_channelz_v1_SocketOption)[]; +} +/** + * SocketData is data associated for a specific Socket. The fields present + * are specific to the implementation, so there may be minor differences in + * the semantics. (e.g. flow control windows) + */ +export interface SocketData__Output { + /** + * The number of streams that have been started. + */ + 'streams_started': (string); + /** + * The number of streams that have ended successfully: + * On client side, received frame with eos bit set; + * On server side, sent frame with eos bit set. + */ + 'streams_succeeded': (string); + /** + * The number of streams that have ended unsuccessfully: + * On client side, ended without receiving frame with eos bit set; + * On server side, ended without sending frame with eos bit set. + */ + 'streams_failed': (string); + /** + * The number of grpc messages successfully sent on this socket. + */ + 'messages_sent': (string); + /** + * The number of grpc messages received on this socket. + */ + 'messages_received': (string); + /** + * The number of keep alives sent. This is typically implemented with HTTP/2 + * ping messages. + */ + 'keep_alives_sent': (string); + /** + * The last time a stream was created by this endpoint. Usually unset for + * servers. + */ + 'last_local_stream_created_timestamp': (_google_protobuf_Timestamp__Output | null); + /** + * The last time a stream was created by the remote endpoint. Usually unset + * for clients. + */ + 'last_remote_stream_created_timestamp': (_google_protobuf_Timestamp__Output | null); + /** + * The last time a message was sent by this endpoint. + */ + 'last_message_sent_timestamp': (_google_protobuf_Timestamp__Output | null); + /** + * The last time a message was received by this endpoint. + */ + 'last_message_received_timestamp': (_google_protobuf_Timestamp__Output | null); + /** + * The amount of window, granted to the local endpoint by the remote endpoint. + * This may be slightly out of date due to network latency. This does NOT + * include stream level or TCP level flow control info. + */ + 'local_flow_control_window': (_google_protobuf_Int64Value__Output | null); + /** + * The amount of window, granted to the remote endpoint by the local endpoint. + * This may be slightly out of date due to network latency. This does NOT + * include stream level or TCP level flow control info. + */ + 'remote_flow_control_window': (_google_protobuf_Int64Value__Output | null); + /** + * Socket options set on this socket. May be absent if 'summary' is set + * on GetSocketRequest. + */ + 'option': (_grpc_channelz_v1_SocketOption__Output)[]; +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketData.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketData.js new file mode 100644 index 000000000..40638de80 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketData.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=SocketData.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketData.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketData.js.map new file mode 100644 index 000000000..c17becd86 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketData.js.map @@ -0,0 +1 @@ +{"version":3,"file":"SocketData.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/SocketData.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOption.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOption.d.ts new file mode 100644 index 000000000..53c23a2aa --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOption.d.ts @@ -0,0 +1,43 @@ +import type { Any as _google_protobuf_Any, Any__Output as _google_protobuf_Any__Output } from '../../../google/protobuf/Any'; +/** + * SocketOption represents socket options for a socket. Specifically, these + * are the options returned by getsockopt(). + */ +export interface SocketOption { + /** + * The full name of the socket option. Typically this will be the upper case + * name, such as "SO_REUSEPORT". + */ + 'name'?: (string); + /** + * The human readable value of this socket option. At least one of value or + * additional will be set. + */ + 'value'?: (string); + /** + * Additional data associated with the socket option. At least one of value + * or additional will be set. + */ + 'additional'?: (_google_protobuf_Any | null); +} +/** + * SocketOption represents socket options for a socket. Specifically, these + * are the options returned by getsockopt(). + */ +export interface SocketOption__Output { + /** + * The full name of the socket option. Typically this will be the upper case + * name, such as "SO_REUSEPORT". + */ + 'name': (string); + /** + * The human readable value of this socket option. At least one of value or + * additional will be set. + */ + 'value': (string); + /** + * Additional data associated with the socket option. At least one of value + * or additional will be set. + */ + 'additional': (_google_protobuf_Any__Output | null); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOption.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOption.js new file mode 100644 index 000000000..c4599624f --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOption.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=SocketOption.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOption.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOption.js.map new file mode 100644 index 000000000..6b8bf592e --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOption.js.map @@ -0,0 +1 @@ +{"version":3,"file":"SocketOption.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/SocketOption.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionLinger.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionLinger.d.ts new file mode 100644 index 000000000..d0fd4b09f --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionLinger.d.ts @@ -0,0 +1,29 @@ +import type { Duration as _google_protobuf_Duration, Duration__Output as _google_protobuf_Duration__Output } from '../../../google/protobuf/Duration'; +/** + * For use with SocketOption's additional field. This is primarily used for + * SO_LINGER. + */ +export interface SocketOptionLinger { + /** + * active maps to `struct linger.l_onoff` + */ + 'active'?: (boolean); + /** + * duration maps to `struct linger.l_linger` + */ + 'duration'?: (_google_protobuf_Duration | null); +} +/** + * For use with SocketOption's additional field. This is primarily used for + * SO_LINGER. + */ +export interface SocketOptionLinger__Output { + /** + * active maps to `struct linger.l_onoff` + */ + 'active': (boolean); + /** + * duration maps to `struct linger.l_linger` + */ + 'duration': (_google_protobuf_Duration__Output | null); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionLinger.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionLinger.js new file mode 100644 index 000000000..01028c88f --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionLinger.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=SocketOptionLinger.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionLinger.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionLinger.js.map new file mode 100644 index 000000000..a5283ab1a --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionLinger.js.map @@ -0,0 +1 @@ +{"version":3,"file":"SocketOptionLinger.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/SocketOptionLinger.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionTcpInfo.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionTcpInfo.d.ts new file mode 100644 index 000000000..d2457e145 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionTcpInfo.d.ts @@ -0,0 +1,70 @@ +/** + * For use with SocketOption's additional field. Tcp info for + * SOL_TCP and TCP_INFO. + */ +export interface SocketOptionTcpInfo { + 'tcpi_state'?: (number); + 'tcpi_ca_state'?: (number); + 'tcpi_retransmits'?: (number); + 'tcpi_probes'?: (number); + 'tcpi_backoff'?: (number); + 'tcpi_options'?: (number); + 'tcpi_snd_wscale'?: (number); + 'tcpi_rcv_wscale'?: (number); + 'tcpi_rto'?: (number); + 'tcpi_ato'?: (number); + 'tcpi_snd_mss'?: (number); + 'tcpi_rcv_mss'?: (number); + 'tcpi_unacked'?: (number); + 'tcpi_sacked'?: (number); + 'tcpi_lost'?: (number); + 'tcpi_retrans'?: (number); + 'tcpi_fackets'?: (number); + 'tcpi_last_data_sent'?: (number); + 'tcpi_last_ack_sent'?: (number); + 'tcpi_last_data_recv'?: (number); + 'tcpi_last_ack_recv'?: (number); + 'tcpi_pmtu'?: (number); + 'tcpi_rcv_ssthresh'?: (number); + 'tcpi_rtt'?: (number); + 'tcpi_rttvar'?: (number); + 'tcpi_snd_ssthresh'?: (number); + 'tcpi_snd_cwnd'?: (number); + 'tcpi_advmss'?: (number); + 'tcpi_reordering'?: (number); +} +/** + * For use with SocketOption's additional field. Tcp info for + * SOL_TCP and TCP_INFO. + */ +export interface SocketOptionTcpInfo__Output { + 'tcpi_state': (number); + 'tcpi_ca_state': (number); + 'tcpi_retransmits': (number); + 'tcpi_probes': (number); + 'tcpi_backoff': (number); + 'tcpi_options': (number); + 'tcpi_snd_wscale': (number); + 'tcpi_rcv_wscale': (number); + 'tcpi_rto': (number); + 'tcpi_ato': (number); + 'tcpi_snd_mss': (number); + 'tcpi_rcv_mss': (number); + 'tcpi_unacked': (number); + 'tcpi_sacked': (number); + 'tcpi_lost': (number); + 'tcpi_retrans': (number); + 'tcpi_fackets': (number); + 'tcpi_last_data_sent': (number); + 'tcpi_last_ack_sent': (number); + 'tcpi_last_data_recv': (number); + 'tcpi_last_ack_recv': (number); + 'tcpi_pmtu': (number); + 'tcpi_rcv_ssthresh': (number); + 'tcpi_rtt': (number); + 'tcpi_rttvar': (number); + 'tcpi_snd_ssthresh': (number); + 'tcpi_snd_cwnd': (number); + 'tcpi_advmss': (number); + 'tcpi_reordering': (number); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionTcpInfo.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionTcpInfo.js new file mode 100644 index 000000000..b663a2e40 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionTcpInfo.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=SocketOptionTcpInfo.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionTcpInfo.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionTcpInfo.js.map new file mode 100644 index 000000000..cb68a3220 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionTcpInfo.js.map @@ -0,0 +1 @@ +{"version":3,"file":"SocketOptionTcpInfo.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/SocketOptionTcpInfo.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionTimeout.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionTimeout.d.ts new file mode 100644 index 000000000..b102a34eb --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionTimeout.d.ts @@ -0,0 +1,15 @@ +import type { Duration as _google_protobuf_Duration, Duration__Output as _google_protobuf_Duration__Output } from '../../../google/protobuf/Duration'; +/** + * For use with SocketOption's additional field. This is primarily used for + * SO_RCVTIMEO and SO_SNDTIMEO + */ +export interface SocketOptionTimeout { + 'duration'?: (_google_protobuf_Duration | null); +} +/** + * For use with SocketOption's additional field. This is primarily used for + * SO_RCVTIMEO and SO_SNDTIMEO + */ +export interface SocketOptionTimeout__Output { + 'duration': (_google_protobuf_Duration__Output | null); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionTimeout.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionTimeout.js new file mode 100644 index 000000000..bcef7f539 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionTimeout.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=SocketOptionTimeout.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionTimeout.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionTimeout.js.map new file mode 100644 index 000000000..73c80853e --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketOptionTimeout.js.map @@ -0,0 +1 @@ +{"version":3,"file":"SocketOptionTimeout.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/SocketOptionTimeout.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketRef.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketRef.d.ts new file mode 100644 index 000000000..55eca7273 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketRef.d.ts @@ -0,0 +1,28 @@ +/// +import type { Long } from '@grpc/proto-loader'; +/** + * SocketRef is a reference to a Socket. + */ +export interface SocketRef { + /** + * The globally unique id for this socket. Must be a positive number. + */ + 'socket_id'?: (number | string | Long); + /** + * An optional name associated with the socket. + */ + 'name'?: (string); +} +/** + * SocketRef is a reference to a Socket. + */ +export interface SocketRef__Output { + /** + * The globally unique id for this socket. Must be a positive number. + */ + 'socket_id': (string); + /** + * An optional name associated with the socket. + */ + 'name': (string); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketRef.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketRef.js new file mode 100644 index 000000000..a73587ff6 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketRef.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=SocketRef.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketRef.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketRef.js.map new file mode 100644 index 000000000..d970f9c3a --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SocketRef.js.map @@ -0,0 +1 @@ +{"version":3,"file":"SocketRef.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/SocketRef.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Subchannel.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Subchannel.d.ts new file mode 100644 index 000000000..1222cb5f9 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Subchannel.d.ts @@ -0,0 +1,66 @@ +import type { SubchannelRef as _grpc_channelz_v1_SubchannelRef, SubchannelRef__Output as _grpc_channelz_v1_SubchannelRef__Output } from '../../../grpc/channelz/v1/SubchannelRef'; +import type { ChannelData as _grpc_channelz_v1_ChannelData, ChannelData__Output as _grpc_channelz_v1_ChannelData__Output } from '../../../grpc/channelz/v1/ChannelData'; +import type { ChannelRef as _grpc_channelz_v1_ChannelRef, ChannelRef__Output as _grpc_channelz_v1_ChannelRef__Output } from '../../../grpc/channelz/v1/ChannelRef'; +import type { SocketRef as _grpc_channelz_v1_SocketRef, SocketRef__Output as _grpc_channelz_v1_SocketRef__Output } from '../../../grpc/channelz/v1/SocketRef'; +/** + * Subchannel is a logical grouping of channels, subchannels, and sockets. + * A subchannel is load balanced over by it's ancestor + */ +export interface Subchannel { + /** + * The identifier for this channel. + */ + 'ref'?: (_grpc_channelz_v1_SubchannelRef | null); + /** + * Data specific to this channel. + */ + 'data'?: (_grpc_channelz_v1_ChannelData | null); + /** + * There are no ordering guarantees on the order of channel refs. + * There may not be cycles in the ref graph. + * A channel ref may be present in more than one channel or subchannel. + */ + 'channel_ref'?: (_grpc_channelz_v1_ChannelRef)[]; + /** + * At most one of 'channel_ref+subchannel_ref' and 'socket' is set. + * There are no ordering guarantees on the order of subchannel refs. + * There may not be cycles in the ref graph. + * A sub channel ref may be present in more than one channel or subchannel. + */ + 'subchannel_ref'?: (_grpc_channelz_v1_SubchannelRef)[]; + /** + * There are no ordering guarantees on the order of sockets. + */ + 'socket_ref'?: (_grpc_channelz_v1_SocketRef)[]; +} +/** + * Subchannel is a logical grouping of channels, subchannels, and sockets. + * A subchannel is load balanced over by it's ancestor + */ +export interface Subchannel__Output { + /** + * The identifier for this channel. + */ + 'ref': (_grpc_channelz_v1_SubchannelRef__Output | null); + /** + * Data specific to this channel. + */ + 'data': (_grpc_channelz_v1_ChannelData__Output | null); + /** + * There are no ordering guarantees on the order of channel refs. + * There may not be cycles in the ref graph. + * A channel ref may be present in more than one channel or subchannel. + */ + 'channel_ref': (_grpc_channelz_v1_ChannelRef__Output)[]; + /** + * At most one of 'channel_ref+subchannel_ref' and 'socket' is set. + * There are no ordering guarantees on the order of subchannel refs. + * There may not be cycles in the ref graph. + * A sub channel ref may be present in more than one channel or subchannel. + */ + 'subchannel_ref': (_grpc_channelz_v1_SubchannelRef__Output)[]; + /** + * There are no ordering guarantees on the order of sockets. + */ + 'socket_ref': (_grpc_channelz_v1_SocketRef__Output)[]; +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Subchannel.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Subchannel.js new file mode 100644 index 000000000..6a5e543ff --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Subchannel.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=Subchannel.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Subchannel.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Subchannel.js.map new file mode 100644 index 000000000..6441346f0 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/Subchannel.js.map @@ -0,0 +1 @@ +{"version":3,"file":"Subchannel.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/Subchannel.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SubchannelRef.d.ts b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SubchannelRef.d.ts new file mode 100644 index 000000000..6560a16be --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SubchannelRef.d.ts @@ -0,0 +1,28 @@ +/// +import type { Long } from '@grpc/proto-loader'; +/** + * SubchannelRef is a reference to a Subchannel. + */ +export interface SubchannelRef { + /** + * The globally unique id for this subchannel. Must be a positive number. + */ + 'subchannel_id'?: (number | string | Long); + /** + * An optional name associated with the subchannel. + */ + 'name'?: (string); +} +/** + * SubchannelRef is a reference to a Subchannel. + */ +export interface SubchannelRef__Output { + /** + * The globally unique id for this subchannel. Must be a positive number. + */ + 'subchannel_id': (string); + /** + * An optional name associated with the subchannel. + */ + 'name': (string); +} diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SubchannelRef.js b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SubchannelRef.js new file mode 100644 index 000000000..68520f955 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SubchannelRef.js @@ -0,0 +1,4 @@ +"use strict"; +// Original file: proto/channelz.proto +Object.defineProperty(exports, "__esModule", { value: true }); +//# sourceMappingURL=SubchannelRef.js.map \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SubchannelRef.js.map b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SubchannelRef.js.map new file mode 100644 index 000000000..1e4b00935 --- /dev/null +++ b/node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/SubchannelRef.js.map @@ -0,0 +1 @@ +{"version":3,"file":"SubchannelRef.js","sourceRoot":"","sources":["../../../../../../src/generated/grpc/channelz/v1/SubchannelRef.ts"],"names":[],"mappings":";AAAA,sCAAsC"} \ No newline at end of file diff --git a/node_modules/@grpc/grpc-js/src/generated/channelz.ts b/node_modules/@grpc/grpc-js/src/generated/channelz.ts new file mode 100644 index 000000000..367cf27f6 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/channelz.ts @@ -0,0 +1,73 @@ +import type * as grpc from '../index'; +import type { MessageTypeDefinition } from '@grpc/proto-loader'; + +import type { ChannelzClient as _grpc_channelz_v1_ChannelzClient, ChannelzDefinition as _grpc_channelz_v1_ChannelzDefinition } from './grpc/channelz/v1/Channelz'; + +type SubtypeConstructor any, Subtype> = { + new(...args: ConstructorParameters): Subtype; +}; + +export interface ProtoGrpcType { + google: { + protobuf: { + Any: MessageTypeDefinition + BoolValue: MessageTypeDefinition + BytesValue: MessageTypeDefinition + DoubleValue: MessageTypeDefinition + Duration: MessageTypeDefinition + FloatValue: MessageTypeDefinition + Int32Value: MessageTypeDefinition + Int64Value: MessageTypeDefinition + StringValue: MessageTypeDefinition + Timestamp: MessageTypeDefinition + UInt32Value: MessageTypeDefinition + UInt64Value: MessageTypeDefinition + } + } + grpc: { + channelz: { + v1: { + Address: MessageTypeDefinition + Channel: MessageTypeDefinition + ChannelConnectivityState: MessageTypeDefinition + ChannelData: MessageTypeDefinition + ChannelRef: MessageTypeDefinition + ChannelTrace: MessageTypeDefinition + ChannelTraceEvent: MessageTypeDefinition + /** + * Channelz is a service exposed by gRPC servers that provides detailed debug + * information. + */ + Channelz: SubtypeConstructor & { service: _grpc_channelz_v1_ChannelzDefinition } + GetChannelRequest: MessageTypeDefinition + GetChannelResponse: MessageTypeDefinition + GetServerRequest: MessageTypeDefinition + GetServerResponse: MessageTypeDefinition + GetServerSocketsRequest: MessageTypeDefinition + GetServerSocketsResponse: MessageTypeDefinition + GetServersRequest: MessageTypeDefinition + GetServersResponse: MessageTypeDefinition + GetSocketRequest: MessageTypeDefinition + GetSocketResponse: MessageTypeDefinition + GetSubchannelRequest: MessageTypeDefinition + GetSubchannelResponse: MessageTypeDefinition + GetTopChannelsRequest: MessageTypeDefinition + GetTopChannelsResponse: MessageTypeDefinition + Security: MessageTypeDefinition + Server: MessageTypeDefinition + ServerData: MessageTypeDefinition + ServerRef: MessageTypeDefinition + Socket: MessageTypeDefinition + SocketData: MessageTypeDefinition + SocketOption: MessageTypeDefinition + SocketOptionLinger: MessageTypeDefinition + SocketOptionTcpInfo: MessageTypeDefinition + SocketOptionTimeout: MessageTypeDefinition + SocketRef: MessageTypeDefinition + Subchannel: MessageTypeDefinition + SubchannelRef: MessageTypeDefinition + } + } + } +} + diff --git a/node_modules/@grpc/grpc-js/src/generated/google/protobuf/Any.ts b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/Any.ts new file mode 100644 index 000000000..fcaa6724e --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/Any.ts @@ -0,0 +1,13 @@ +// Original file: null + +import type { AnyExtension } from '@grpc/proto-loader'; + +export type Any = AnyExtension | { + type_url: string; + value: Buffer | Uint8Array | string; +} + +export interface Any__Output { + 'type_url': (string); + 'value': (Buffer); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/google/protobuf/BoolValue.ts b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/BoolValue.ts new file mode 100644 index 000000000..86507eaf1 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/BoolValue.ts @@ -0,0 +1,10 @@ +// Original file: null + + +export interface BoolValue { + 'value'?: (boolean); +} + +export interface BoolValue__Output { + 'value': (boolean); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/google/protobuf/BytesValue.ts b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/BytesValue.ts new file mode 100644 index 000000000..9cec76f71 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/BytesValue.ts @@ -0,0 +1,10 @@ +// Original file: null + + +export interface BytesValue { + 'value'?: (Buffer | Uint8Array | string); +} + +export interface BytesValue__Output { + 'value': (Buffer); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/google/protobuf/DoubleValue.ts b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/DoubleValue.ts new file mode 100644 index 000000000..d70b303c2 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/DoubleValue.ts @@ -0,0 +1,10 @@ +// Original file: null + + +export interface DoubleValue { + 'value'?: (number | string); +} + +export interface DoubleValue__Output { + 'value': (number); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/google/protobuf/Duration.ts b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/Duration.ts new file mode 100644 index 000000000..8595377a0 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/Duration.ts @@ -0,0 +1,13 @@ +// Original file: null + +import type { Long } from '@grpc/proto-loader'; + +export interface Duration { + 'seconds'?: (number | string | Long); + 'nanos'?: (number); +} + +export interface Duration__Output { + 'seconds': (string); + 'nanos': (number); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/google/protobuf/FloatValue.ts b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/FloatValue.ts new file mode 100644 index 000000000..54a655fbb --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/FloatValue.ts @@ -0,0 +1,10 @@ +// Original file: null + + +export interface FloatValue { + 'value'?: (number | string); +} + +export interface FloatValue__Output { + 'value': (number); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/google/protobuf/Int32Value.ts b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/Int32Value.ts new file mode 100644 index 000000000..ec4eeb7ec --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/Int32Value.ts @@ -0,0 +1,10 @@ +// Original file: null + + +export interface Int32Value { + 'value'?: (number); +} + +export interface Int32Value__Output { + 'value': (number); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/google/protobuf/Int64Value.ts b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/Int64Value.ts new file mode 100644 index 000000000..f7375196d --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/Int64Value.ts @@ -0,0 +1,11 @@ +// Original file: null + +import type { Long } from '@grpc/proto-loader'; + +export interface Int64Value { + 'value'?: (number | string | Long); +} + +export interface Int64Value__Output { + 'value': (string); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/google/protobuf/StringValue.ts b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/StringValue.ts new file mode 100644 index 000000000..673090e3f --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/StringValue.ts @@ -0,0 +1,10 @@ +// Original file: null + + +export interface StringValue { + 'value'?: (string); +} + +export interface StringValue__Output { + 'value': (string); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/google/protobuf/Timestamp.ts b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/Timestamp.ts new file mode 100644 index 000000000..ceaa32b5f --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/Timestamp.ts @@ -0,0 +1,13 @@ +// Original file: null + +import type { Long } from '@grpc/proto-loader'; + +export interface Timestamp { + 'seconds'?: (number | string | Long); + 'nanos'?: (number); +} + +export interface Timestamp__Output { + 'seconds': (string); + 'nanos': (number); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/google/protobuf/UInt32Value.ts b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/UInt32Value.ts new file mode 100644 index 000000000..973ab34a5 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/UInt32Value.ts @@ -0,0 +1,10 @@ +// Original file: null + + +export interface UInt32Value { + 'value'?: (number); +} + +export interface UInt32Value__Output { + 'value': (number); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/google/protobuf/UInt64Value.ts b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/UInt64Value.ts new file mode 100644 index 000000000..7a85c39ce --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/google/protobuf/UInt64Value.ts @@ -0,0 +1,11 @@ +// Original file: null + +import type { Long } from '@grpc/proto-loader'; + +export interface UInt64Value { + 'value'?: (number | string | Long); +} + +export interface UInt64Value__Output { + 'value': (string); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Address.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Address.ts new file mode 100644 index 000000000..259cfeabe --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Address.ts @@ -0,0 +1,89 @@ +// Original file: proto/channelz.proto + +import type { Any as _google_protobuf_Any, Any__Output as _google_protobuf_Any__Output } from '../../../google/protobuf/Any'; + +/** + * An address type not included above. + */ +export interface _grpc_channelz_v1_Address_OtherAddress { + /** + * The human readable version of the value. This value should be set. + */ + 'name'?: (string); + /** + * The actual address message. + */ + 'value'?: (_google_protobuf_Any | null); +} + +/** + * An address type not included above. + */ +export interface _grpc_channelz_v1_Address_OtherAddress__Output { + /** + * The human readable version of the value. This value should be set. + */ + 'name': (string); + /** + * The actual address message. + */ + 'value': (_google_protobuf_Any__Output | null); +} + +export interface _grpc_channelz_v1_Address_TcpIpAddress { + /** + * Either the IPv4 or IPv6 address in bytes. Will be either 4 bytes or 16 + * bytes in length. + */ + 'ip_address'?: (Buffer | Uint8Array | string); + /** + * 0-64k, or -1 if not appropriate. + */ + 'port'?: (number); +} + +export interface _grpc_channelz_v1_Address_TcpIpAddress__Output { + /** + * Either the IPv4 or IPv6 address in bytes. Will be either 4 bytes or 16 + * bytes in length. + */ + 'ip_address': (Buffer); + /** + * 0-64k, or -1 if not appropriate. + */ + 'port': (number); +} + +/** + * A Unix Domain Socket address. + */ +export interface _grpc_channelz_v1_Address_UdsAddress { + 'filename'?: (string); +} + +/** + * A Unix Domain Socket address. + */ +export interface _grpc_channelz_v1_Address_UdsAddress__Output { + 'filename': (string); +} + +/** + * Address represents the address used to create the socket. + */ +export interface Address { + 'tcpip_address'?: (_grpc_channelz_v1_Address_TcpIpAddress | null); + 'uds_address'?: (_grpc_channelz_v1_Address_UdsAddress | null); + 'other_address'?: (_grpc_channelz_v1_Address_OtherAddress | null); + 'address'?: "tcpip_address"|"uds_address"|"other_address"; +} + +/** + * Address represents the address used to create the socket. + */ +export interface Address__Output { + 'tcpip_address'?: (_grpc_channelz_v1_Address_TcpIpAddress__Output | null); + 'uds_address'?: (_grpc_channelz_v1_Address_UdsAddress__Output | null); + 'other_address'?: (_grpc_channelz_v1_Address_OtherAddress__Output | null); + 'address': "tcpip_address"|"uds_address"|"other_address"; +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Channel.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Channel.ts new file mode 100644 index 000000000..93b4a261d --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Channel.ts @@ -0,0 +1,68 @@ +// Original file: proto/channelz.proto + +import type { ChannelRef as _grpc_channelz_v1_ChannelRef, ChannelRef__Output as _grpc_channelz_v1_ChannelRef__Output } from '../../../grpc/channelz/v1/ChannelRef'; +import type { ChannelData as _grpc_channelz_v1_ChannelData, ChannelData__Output as _grpc_channelz_v1_ChannelData__Output } from '../../../grpc/channelz/v1/ChannelData'; +import type { SubchannelRef as _grpc_channelz_v1_SubchannelRef, SubchannelRef__Output as _grpc_channelz_v1_SubchannelRef__Output } from '../../../grpc/channelz/v1/SubchannelRef'; +import type { SocketRef as _grpc_channelz_v1_SocketRef, SocketRef__Output as _grpc_channelz_v1_SocketRef__Output } from '../../../grpc/channelz/v1/SocketRef'; + +/** + * Channel is a logical grouping of channels, subchannels, and sockets. + */ +export interface Channel { + /** + * The identifier for this channel. This should bet set. + */ + 'ref'?: (_grpc_channelz_v1_ChannelRef | null); + /** + * Data specific to this channel. + */ + 'data'?: (_grpc_channelz_v1_ChannelData | null); + /** + * There are no ordering guarantees on the order of channel refs. + * There may not be cycles in the ref graph. + * A channel ref may be present in more than one channel or subchannel. + */ + 'channel_ref'?: (_grpc_channelz_v1_ChannelRef)[]; + /** + * At most one of 'channel_ref+subchannel_ref' and 'socket' is set. + * There are no ordering guarantees on the order of subchannel refs. + * There may not be cycles in the ref graph. + * A sub channel ref may be present in more than one channel or subchannel. + */ + 'subchannel_ref'?: (_grpc_channelz_v1_SubchannelRef)[]; + /** + * There are no ordering guarantees on the order of sockets. + */ + 'socket_ref'?: (_grpc_channelz_v1_SocketRef)[]; +} + +/** + * Channel is a logical grouping of channels, subchannels, and sockets. + */ +export interface Channel__Output { + /** + * The identifier for this channel. This should bet set. + */ + 'ref': (_grpc_channelz_v1_ChannelRef__Output | null); + /** + * Data specific to this channel. + */ + 'data': (_grpc_channelz_v1_ChannelData__Output | null); + /** + * There are no ordering guarantees on the order of channel refs. + * There may not be cycles in the ref graph. + * A channel ref may be present in more than one channel or subchannel. + */ + 'channel_ref': (_grpc_channelz_v1_ChannelRef__Output)[]; + /** + * At most one of 'channel_ref+subchannel_ref' and 'socket' is set. + * There are no ordering guarantees on the order of subchannel refs. + * There may not be cycles in the ref graph. + * A sub channel ref may be present in more than one channel or subchannel. + */ + 'subchannel_ref': (_grpc_channelz_v1_SubchannelRef__Output)[]; + /** + * There are no ordering guarantees on the order of sockets. + */ + 'socket_ref': (_grpc_channelz_v1_SocketRef__Output)[]; +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ChannelConnectivityState.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ChannelConnectivityState.ts new file mode 100644 index 000000000..be34ab98d --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ChannelConnectivityState.ts @@ -0,0 +1,29 @@ +// Original file: proto/channelz.proto + + +// Original file: proto/channelz.proto + +export enum _grpc_channelz_v1_ChannelConnectivityState_State { + UNKNOWN = 0, + IDLE = 1, + CONNECTING = 2, + READY = 3, + TRANSIENT_FAILURE = 4, + SHUTDOWN = 5, +} + +/** + * These come from the specified states in this document: + * https://github.com/grpc/grpc/blob/master/doc/connectivity-semantics-and-api.md + */ +export interface ChannelConnectivityState { + 'state'?: (_grpc_channelz_v1_ChannelConnectivityState_State | keyof typeof _grpc_channelz_v1_ChannelConnectivityState_State); +} + +/** + * These come from the specified states in this document: + * https://github.com/grpc/grpc/blob/master/doc/connectivity-semantics-and-api.md + */ +export interface ChannelConnectivityState__Output { + 'state': (keyof typeof _grpc_channelz_v1_ChannelConnectivityState_State); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ChannelData.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ChannelData.ts new file mode 100644 index 000000000..6d6824af4 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ChannelData.ts @@ -0,0 +1,76 @@ +// Original file: proto/channelz.proto + +import type { ChannelConnectivityState as _grpc_channelz_v1_ChannelConnectivityState, ChannelConnectivityState__Output as _grpc_channelz_v1_ChannelConnectivityState__Output } from '../../../grpc/channelz/v1/ChannelConnectivityState'; +import type { ChannelTrace as _grpc_channelz_v1_ChannelTrace, ChannelTrace__Output as _grpc_channelz_v1_ChannelTrace__Output } from '../../../grpc/channelz/v1/ChannelTrace'; +import type { Timestamp as _google_protobuf_Timestamp, Timestamp__Output as _google_protobuf_Timestamp__Output } from '../../../google/protobuf/Timestamp'; +import type { Long } from '@grpc/proto-loader'; + +/** + * Channel data is data related to a specific Channel or Subchannel. + */ +export interface ChannelData { + /** + * The connectivity state of the channel or subchannel. Implementations + * should always set this. + */ + 'state'?: (_grpc_channelz_v1_ChannelConnectivityState | null); + /** + * The target this channel originally tried to connect to. May be absent + */ + 'target'?: (string); + /** + * A trace of recent events on the channel. May be absent. + */ + 'trace'?: (_grpc_channelz_v1_ChannelTrace | null); + /** + * The number of calls started on the channel + */ + 'calls_started'?: (number | string | Long); + /** + * The number of calls that have completed with an OK status + */ + 'calls_succeeded'?: (number | string | Long); + /** + * The number of calls that have completed with a non-OK status + */ + 'calls_failed'?: (number | string | Long); + /** + * The last time a call was started on the channel. + */ + 'last_call_started_timestamp'?: (_google_protobuf_Timestamp | null); +} + +/** + * Channel data is data related to a specific Channel or Subchannel. + */ +export interface ChannelData__Output { + /** + * The connectivity state of the channel or subchannel. Implementations + * should always set this. + */ + 'state': (_grpc_channelz_v1_ChannelConnectivityState__Output | null); + /** + * The target this channel originally tried to connect to. May be absent + */ + 'target': (string); + /** + * A trace of recent events on the channel. May be absent. + */ + 'trace': (_grpc_channelz_v1_ChannelTrace__Output | null); + /** + * The number of calls started on the channel + */ + 'calls_started': (string); + /** + * The number of calls that have completed with an OK status + */ + 'calls_succeeded': (string); + /** + * The number of calls that have completed with a non-OK status + */ + 'calls_failed': (string); + /** + * The last time a call was started on the channel. + */ + 'last_call_started_timestamp': (_google_protobuf_Timestamp__Output | null); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ChannelRef.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ChannelRef.ts new file mode 100644 index 000000000..231d00876 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ChannelRef.ts @@ -0,0 +1,31 @@ +// Original file: proto/channelz.proto + +import type { Long } from '@grpc/proto-loader'; + +/** + * ChannelRef is a reference to a Channel. + */ +export interface ChannelRef { + /** + * The globally unique id for this channel. Must be a positive number. + */ + 'channel_id'?: (number | string | Long); + /** + * An optional name associated with the channel. + */ + 'name'?: (string); +} + +/** + * ChannelRef is a reference to a Channel. + */ +export interface ChannelRef__Output { + /** + * The globally unique id for this channel. Must be a positive number. + */ + 'channel_id': (string); + /** + * An optional name associated with the channel. + */ + 'name': (string); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ChannelTrace.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ChannelTrace.ts new file mode 100644 index 000000000..7dbc8d924 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ChannelTrace.ts @@ -0,0 +1,45 @@ +// Original file: proto/channelz.proto + +import type { Timestamp as _google_protobuf_Timestamp, Timestamp__Output as _google_protobuf_Timestamp__Output } from '../../../google/protobuf/Timestamp'; +import type { ChannelTraceEvent as _grpc_channelz_v1_ChannelTraceEvent, ChannelTraceEvent__Output as _grpc_channelz_v1_ChannelTraceEvent__Output } from '../../../grpc/channelz/v1/ChannelTraceEvent'; +import type { Long } from '@grpc/proto-loader'; + +/** + * ChannelTrace represents the recent events that have occurred on the channel. + */ +export interface ChannelTrace { + /** + * Number of events ever logged in this tracing object. This can differ from + * events.size() because events can be overwritten or garbage collected by + * implementations. + */ + 'num_events_logged'?: (number | string | Long); + /** + * Time that this channel was created. + */ + 'creation_timestamp'?: (_google_protobuf_Timestamp | null); + /** + * List of events that have occurred on this channel. + */ + 'events'?: (_grpc_channelz_v1_ChannelTraceEvent)[]; +} + +/** + * ChannelTrace represents the recent events that have occurred on the channel. + */ +export interface ChannelTrace__Output { + /** + * Number of events ever logged in this tracing object. This can differ from + * events.size() because events can be overwritten or garbage collected by + * implementations. + */ + 'num_events_logged': (string); + /** + * Time that this channel was created. + */ + 'creation_timestamp': (_google_protobuf_Timestamp__Output | null); + /** + * List of events that have occurred on this channel. + */ + 'events': (_grpc_channelz_v1_ChannelTraceEvent__Output)[]; +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ChannelTraceEvent.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ChannelTraceEvent.ts new file mode 100644 index 000000000..24b97fbcd --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ChannelTraceEvent.ts @@ -0,0 +1,73 @@ +// Original file: proto/channelz.proto + +import type { Timestamp as _google_protobuf_Timestamp, Timestamp__Output as _google_protobuf_Timestamp__Output } from '../../../google/protobuf/Timestamp'; +import type { ChannelRef as _grpc_channelz_v1_ChannelRef, ChannelRef__Output as _grpc_channelz_v1_ChannelRef__Output } from '../../../grpc/channelz/v1/ChannelRef'; +import type { SubchannelRef as _grpc_channelz_v1_SubchannelRef, SubchannelRef__Output as _grpc_channelz_v1_SubchannelRef__Output } from '../../../grpc/channelz/v1/SubchannelRef'; + +// Original file: proto/channelz.proto + +/** + * The supported severity levels of trace events. + */ +export enum _grpc_channelz_v1_ChannelTraceEvent_Severity { + CT_UNKNOWN = 0, + CT_INFO = 1, + CT_WARNING = 2, + CT_ERROR = 3, +} + +/** + * A trace event is an interesting thing that happened to a channel or + * subchannel, such as creation, address resolution, subchannel creation, etc. + */ +export interface ChannelTraceEvent { + /** + * High level description of the event. + */ + 'description'?: (string); + /** + * the severity of the trace event + */ + 'severity'?: (_grpc_channelz_v1_ChannelTraceEvent_Severity | keyof typeof _grpc_channelz_v1_ChannelTraceEvent_Severity); + /** + * When this event occurred. + */ + 'timestamp'?: (_google_protobuf_Timestamp | null); + 'channel_ref'?: (_grpc_channelz_v1_ChannelRef | null); + 'subchannel_ref'?: (_grpc_channelz_v1_SubchannelRef | null); + /** + * ref of referenced channel or subchannel. + * Optional, only present if this event refers to a child object. For example, + * this field would be filled if this trace event was for a subchannel being + * created. + */ + 'child_ref'?: "channel_ref"|"subchannel_ref"; +} + +/** + * A trace event is an interesting thing that happened to a channel or + * subchannel, such as creation, address resolution, subchannel creation, etc. + */ +export interface ChannelTraceEvent__Output { + /** + * High level description of the event. + */ + 'description': (string); + /** + * the severity of the trace event + */ + 'severity': (keyof typeof _grpc_channelz_v1_ChannelTraceEvent_Severity); + /** + * When this event occurred. + */ + 'timestamp': (_google_protobuf_Timestamp__Output | null); + 'channel_ref'?: (_grpc_channelz_v1_ChannelRef__Output | null); + 'subchannel_ref'?: (_grpc_channelz_v1_SubchannelRef__Output | null); + /** + * ref of referenced channel or subchannel. + * Optional, only present if this event refers to a child object. For example, + * this field would be filled if this trace event was for a subchannel being + * created. + */ + 'child_ref': "channel_ref"|"subchannel_ref"; +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Channelz.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Channelz.ts new file mode 100644 index 000000000..4c8c18aa7 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Channelz.ts @@ -0,0 +1,178 @@ +// Original file: proto/channelz.proto + +import type * as grpc from '../../../../index' +import type { MethodDefinition } from '@grpc/proto-loader' +import type { GetChannelRequest as _grpc_channelz_v1_GetChannelRequest, GetChannelRequest__Output as _grpc_channelz_v1_GetChannelRequest__Output } from '../../../grpc/channelz/v1/GetChannelRequest'; +import type { GetChannelResponse as _grpc_channelz_v1_GetChannelResponse, GetChannelResponse__Output as _grpc_channelz_v1_GetChannelResponse__Output } from '../../../grpc/channelz/v1/GetChannelResponse'; +import type { GetServerRequest as _grpc_channelz_v1_GetServerRequest, GetServerRequest__Output as _grpc_channelz_v1_GetServerRequest__Output } from '../../../grpc/channelz/v1/GetServerRequest'; +import type { GetServerResponse as _grpc_channelz_v1_GetServerResponse, GetServerResponse__Output as _grpc_channelz_v1_GetServerResponse__Output } from '../../../grpc/channelz/v1/GetServerResponse'; +import type { GetServerSocketsRequest as _grpc_channelz_v1_GetServerSocketsRequest, GetServerSocketsRequest__Output as _grpc_channelz_v1_GetServerSocketsRequest__Output } from '../../../grpc/channelz/v1/GetServerSocketsRequest'; +import type { GetServerSocketsResponse as _grpc_channelz_v1_GetServerSocketsResponse, GetServerSocketsResponse__Output as _grpc_channelz_v1_GetServerSocketsResponse__Output } from '../../../grpc/channelz/v1/GetServerSocketsResponse'; +import type { GetServersRequest as _grpc_channelz_v1_GetServersRequest, GetServersRequest__Output as _grpc_channelz_v1_GetServersRequest__Output } from '../../../grpc/channelz/v1/GetServersRequest'; +import type { GetServersResponse as _grpc_channelz_v1_GetServersResponse, GetServersResponse__Output as _grpc_channelz_v1_GetServersResponse__Output } from '../../../grpc/channelz/v1/GetServersResponse'; +import type { GetSocketRequest as _grpc_channelz_v1_GetSocketRequest, GetSocketRequest__Output as _grpc_channelz_v1_GetSocketRequest__Output } from '../../../grpc/channelz/v1/GetSocketRequest'; +import type { GetSocketResponse as _grpc_channelz_v1_GetSocketResponse, GetSocketResponse__Output as _grpc_channelz_v1_GetSocketResponse__Output } from '../../../grpc/channelz/v1/GetSocketResponse'; +import type { GetSubchannelRequest as _grpc_channelz_v1_GetSubchannelRequest, GetSubchannelRequest__Output as _grpc_channelz_v1_GetSubchannelRequest__Output } from '../../../grpc/channelz/v1/GetSubchannelRequest'; +import type { GetSubchannelResponse as _grpc_channelz_v1_GetSubchannelResponse, GetSubchannelResponse__Output as _grpc_channelz_v1_GetSubchannelResponse__Output } from '../../../grpc/channelz/v1/GetSubchannelResponse'; +import type { GetTopChannelsRequest as _grpc_channelz_v1_GetTopChannelsRequest, GetTopChannelsRequest__Output as _grpc_channelz_v1_GetTopChannelsRequest__Output } from '../../../grpc/channelz/v1/GetTopChannelsRequest'; +import type { GetTopChannelsResponse as _grpc_channelz_v1_GetTopChannelsResponse, GetTopChannelsResponse__Output as _grpc_channelz_v1_GetTopChannelsResponse__Output } from '../../../grpc/channelz/v1/GetTopChannelsResponse'; + +/** + * Channelz is a service exposed by gRPC servers that provides detailed debug + * information. + */ +export interface ChannelzClient extends grpc.Client { + /** + * Returns a single Channel, or else a NOT_FOUND code. + */ + GetChannel(argument: _grpc_channelz_v1_GetChannelRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetChannelResponse__Output>): grpc.ClientUnaryCall; + GetChannel(argument: _grpc_channelz_v1_GetChannelRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetChannelResponse__Output>): grpc.ClientUnaryCall; + GetChannel(argument: _grpc_channelz_v1_GetChannelRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetChannelResponse__Output>): grpc.ClientUnaryCall; + GetChannel(argument: _grpc_channelz_v1_GetChannelRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetChannelResponse__Output>): grpc.ClientUnaryCall; + + /** + * Returns a single Server, or else a NOT_FOUND code. + */ + GetServer(argument: _grpc_channelz_v1_GetServerRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerResponse__Output>): grpc.ClientUnaryCall; + GetServer(argument: _grpc_channelz_v1_GetServerRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerResponse__Output>): grpc.ClientUnaryCall; + GetServer(argument: _grpc_channelz_v1_GetServerRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerResponse__Output>): grpc.ClientUnaryCall; + GetServer(argument: _grpc_channelz_v1_GetServerRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerResponse__Output>): grpc.ClientUnaryCall; + /** + * Returns a single Server, or else a NOT_FOUND code. + */ + getServer(argument: _grpc_channelz_v1_GetServerRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerResponse__Output>): grpc.ClientUnaryCall; + getServer(argument: _grpc_channelz_v1_GetServerRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerResponse__Output>): grpc.ClientUnaryCall; + getServer(argument: _grpc_channelz_v1_GetServerRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerResponse__Output>): grpc.ClientUnaryCall; + getServer(argument: _grpc_channelz_v1_GetServerRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerResponse__Output>): grpc.ClientUnaryCall; + + /** + * Gets all server sockets that exist in the process. + */ + GetServerSockets(argument: _grpc_channelz_v1_GetServerSocketsRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerSocketsResponse__Output>): grpc.ClientUnaryCall; + GetServerSockets(argument: _grpc_channelz_v1_GetServerSocketsRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerSocketsResponse__Output>): grpc.ClientUnaryCall; + GetServerSockets(argument: _grpc_channelz_v1_GetServerSocketsRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerSocketsResponse__Output>): grpc.ClientUnaryCall; + GetServerSockets(argument: _grpc_channelz_v1_GetServerSocketsRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerSocketsResponse__Output>): grpc.ClientUnaryCall; + /** + * Gets all server sockets that exist in the process. + */ + getServerSockets(argument: _grpc_channelz_v1_GetServerSocketsRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerSocketsResponse__Output>): grpc.ClientUnaryCall; + getServerSockets(argument: _grpc_channelz_v1_GetServerSocketsRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerSocketsResponse__Output>): grpc.ClientUnaryCall; + getServerSockets(argument: _grpc_channelz_v1_GetServerSocketsRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerSocketsResponse__Output>): grpc.ClientUnaryCall; + getServerSockets(argument: _grpc_channelz_v1_GetServerSocketsRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetServerSocketsResponse__Output>): grpc.ClientUnaryCall; + + /** + * Gets all servers that exist in the process. + */ + GetServers(argument: _grpc_channelz_v1_GetServersRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServersResponse__Output>): grpc.ClientUnaryCall; + GetServers(argument: _grpc_channelz_v1_GetServersRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetServersResponse__Output>): grpc.ClientUnaryCall; + GetServers(argument: _grpc_channelz_v1_GetServersRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServersResponse__Output>): grpc.ClientUnaryCall; + GetServers(argument: _grpc_channelz_v1_GetServersRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetServersResponse__Output>): grpc.ClientUnaryCall; + /** + * Gets all servers that exist in the process. + */ + getServers(argument: _grpc_channelz_v1_GetServersRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServersResponse__Output>): grpc.ClientUnaryCall; + getServers(argument: _grpc_channelz_v1_GetServersRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetServersResponse__Output>): grpc.ClientUnaryCall; + getServers(argument: _grpc_channelz_v1_GetServersRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetServersResponse__Output>): grpc.ClientUnaryCall; + getServers(argument: _grpc_channelz_v1_GetServersRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetServersResponse__Output>): grpc.ClientUnaryCall; + + /** + * Returns a single Socket or else a NOT_FOUND code. + */ + GetSocket(argument: _grpc_channelz_v1_GetSocketRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetSocketResponse__Output>): grpc.ClientUnaryCall; + GetSocket(argument: _grpc_channelz_v1_GetSocketRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetSocketResponse__Output>): grpc.ClientUnaryCall; + GetSocket(argument: _grpc_channelz_v1_GetSocketRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetSocketResponse__Output>): grpc.ClientUnaryCall; + GetSocket(argument: _grpc_channelz_v1_GetSocketRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetSocketResponse__Output>): grpc.ClientUnaryCall; + /** + * Returns a single Socket or else a NOT_FOUND code. + */ + getSocket(argument: _grpc_channelz_v1_GetSocketRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetSocketResponse__Output>): grpc.ClientUnaryCall; + getSocket(argument: _grpc_channelz_v1_GetSocketRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetSocketResponse__Output>): grpc.ClientUnaryCall; + getSocket(argument: _grpc_channelz_v1_GetSocketRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetSocketResponse__Output>): grpc.ClientUnaryCall; + getSocket(argument: _grpc_channelz_v1_GetSocketRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetSocketResponse__Output>): grpc.ClientUnaryCall; + + /** + * Returns a single Subchannel, or else a NOT_FOUND code. + */ + GetSubchannel(argument: _grpc_channelz_v1_GetSubchannelRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetSubchannelResponse__Output>): grpc.ClientUnaryCall; + GetSubchannel(argument: _grpc_channelz_v1_GetSubchannelRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetSubchannelResponse__Output>): grpc.ClientUnaryCall; + GetSubchannel(argument: _grpc_channelz_v1_GetSubchannelRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetSubchannelResponse__Output>): grpc.ClientUnaryCall; + GetSubchannel(argument: _grpc_channelz_v1_GetSubchannelRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetSubchannelResponse__Output>): grpc.ClientUnaryCall; + /** + * Returns a single Subchannel, or else a NOT_FOUND code. + */ + getSubchannel(argument: _grpc_channelz_v1_GetSubchannelRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetSubchannelResponse__Output>): grpc.ClientUnaryCall; + getSubchannel(argument: _grpc_channelz_v1_GetSubchannelRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetSubchannelResponse__Output>): grpc.ClientUnaryCall; + getSubchannel(argument: _grpc_channelz_v1_GetSubchannelRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetSubchannelResponse__Output>): grpc.ClientUnaryCall; + getSubchannel(argument: _grpc_channelz_v1_GetSubchannelRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetSubchannelResponse__Output>): grpc.ClientUnaryCall; + + /** + * Gets all root channels (i.e. channels the application has directly + * created). This does not include subchannels nor non-top level channels. + */ + GetTopChannels(argument: _grpc_channelz_v1_GetTopChannelsRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetTopChannelsResponse__Output>): grpc.ClientUnaryCall; + GetTopChannels(argument: _grpc_channelz_v1_GetTopChannelsRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetTopChannelsResponse__Output>): grpc.ClientUnaryCall; + GetTopChannels(argument: _grpc_channelz_v1_GetTopChannelsRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetTopChannelsResponse__Output>): grpc.ClientUnaryCall; + GetTopChannels(argument: _grpc_channelz_v1_GetTopChannelsRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetTopChannelsResponse__Output>): grpc.ClientUnaryCall; + /** + * Gets all root channels (i.e. channels the application has directly + * created). This does not include subchannels nor non-top level channels. + */ + getTopChannels(argument: _grpc_channelz_v1_GetTopChannelsRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetTopChannelsResponse__Output>): grpc.ClientUnaryCall; + getTopChannels(argument: _grpc_channelz_v1_GetTopChannelsRequest, metadata: grpc.Metadata, callback: grpc.requestCallback<_grpc_channelz_v1_GetTopChannelsResponse__Output>): grpc.ClientUnaryCall; + getTopChannels(argument: _grpc_channelz_v1_GetTopChannelsRequest, options: grpc.CallOptions, callback: grpc.requestCallback<_grpc_channelz_v1_GetTopChannelsResponse__Output>): grpc.ClientUnaryCall; + getTopChannels(argument: _grpc_channelz_v1_GetTopChannelsRequest, callback: grpc.requestCallback<_grpc_channelz_v1_GetTopChannelsResponse__Output>): grpc.ClientUnaryCall; + +} + +/** + * Channelz is a service exposed by gRPC servers that provides detailed debug + * information. + */ +export interface ChannelzHandlers extends grpc.UntypedServiceImplementation { + /** + * Returns a single Channel, or else a NOT_FOUND code. + */ + GetChannel: grpc.handleUnaryCall<_grpc_channelz_v1_GetChannelRequest__Output, _grpc_channelz_v1_GetChannelResponse>; + + /** + * Returns a single Server, or else a NOT_FOUND code. + */ + GetServer: grpc.handleUnaryCall<_grpc_channelz_v1_GetServerRequest__Output, _grpc_channelz_v1_GetServerResponse>; + + /** + * Gets all server sockets that exist in the process. + */ + GetServerSockets: grpc.handleUnaryCall<_grpc_channelz_v1_GetServerSocketsRequest__Output, _grpc_channelz_v1_GetServerSocketsResponse>; + + /** + * Gets all servers that exist in the process. + */ + GetServers: grpc.handleUnaryCall<_grpc_channelz_v1_GetServersRequest__Output, _grpc_channelz_v1_GetServersResponse>; + + /** + * Returns a single Socket or else a NOT_FOUND code. + */ + GetSocket: grpc.handleUnaryCall<_grpc_channelz_v1_GetSocketRequest__Output, _grpc_channelz_v1_GetSocketResponse>; + + /** + * Returns a single Subchannel, or else a NOT_FOUND code. + */ + GetSubchannel: grpc.handleUnaryCall<_grpc_channelz_v1_GetSubchannelRequest__Output, _grpc_channelz_v1_GetSubchannelResponse>; + + /** + * Gets all root channels (i.e. channels the application has directly + * created). This does not include subchannels nor non-top level channels. + */ + GetTopChannels: grpc.handleUnaryCall<_grpc_channelz_v1_GetTopChannelsRequest__Output, _grpc_channelz_v1_GetTopChannelsResponse>; + +} + +export interface ChannelzDefinition extends grpc.ServiceDefinition { + GetChannel: MethodDefinition<_grpc_channelz_v1_GetChannelRequest, _grpc_channelz_v1_GetChannelResponse, _grpc_channelz_v1_GetChannelRequest__Output, _grpc_channelz_v1_GetChannelResponse__Output> + GetServer: MethodDefinition<_grpc_channelz_v1_GetServerRequest, _grpc_channelz_v1_GetServerResponse, _grpc_channelz_v1_GetServerRequest__Output, _grpc_channelz_v1_GetServerResponse__Output> + GetServerSockets: MethodDefinition<_grpc_channelz_v1_GetServerSocketsRequest, _grpc_channelz_v1_GetServerSocketsResponse, _grpc_channelz_v1_GetServerSocketsRequest__Output, _grpc_channelz_v1_GetServerSocketsResponse__Output> + GetServers: MethodDefinition<_grpc_channelz_v1_GetServersRequest, _grpc_channelz_v1_GetServersResponse, _grpc_channelz_v1_GetServersRequest__Output, _grpc_channelz_v1_GetServersResponse__Output> + GetSocket: MethodDefinition<_grpc_channelz_v1_GetSocketRequest, _grpc_channelz_v1_GetSocketResponse, _grpc_channelz_v1_GetSocketRequest__Output, _grpc_channelz_v1_GetSocketResponse__Output> + GetSubchannel: MethodDefinition<_grpc_channelz_v1_GetSubchannelRequest, _grpc_channelz_v1_GetSubchannelResponse, _grpc_channelz_v1_GetSubchannelRequest__Output, _grpc_channelz_v1_GetSubchannelResponse__Output> + GetTopChannels: MethodDefinition<_grpc_channelz_v1_GetTopChannelsRequest, _grpc_channelz_v1_GetTopChannelsResponse, _grpc_channelz_v1_GetTopChannelsRequest__Output, _grpc_channelz_v1_GetTopChannelsResponse__Output> +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetChannelRequest.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetChannelRequest.ts new file mode 100644 index 000000000..437e2d60a --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetChannelRequest.ts @@ -0,0 +1,17 @@ +// Original file: proto/channelz.proto + +import type { Long } from '@grpc/proto-loader'; + +export interface GetChannelRequest { + /** + * channel_id is the identifier of the specific channel to get. + */ + 'channel_id'?: (number | string | Long); +} + +export interface GetChannelRequest__Output { + /** + * channel_id is the identifier of the specific channel to get. + */ + 'channel_id': (string); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetChannelResponse.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetChannelResponse.ts new file mode 100644 index 000000000..2e967a458 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetChannelResponse.ts @@ -0,0 +1,19 @@ +// Original file: proto/channelz.proto + +import type { Channel as _grpc_channelz_v1_Channel, Channel__Output as _grpc_channelz_v1_Channel__Output } from '../../../grpc/channelz/v1/Channel'; + +export interface GetChannelResponse { + /** + * The Channel that corresponds to the requested channel_id. This field + * should be set. + */ + 'channel'?: (_grpc_channelz_v1_Channel | null); +} + +export interface GetChannelResponse__Output { + /** + * The Channel that corresponds to the requested channel_id. This field + * should be set. + */ + 'channel': (_grpc_channelz_v1_Channel__Output | null); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetServerRequest.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetServerRequest.ts new file mode 100644 index 000000000..f5d4a298f --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetServerRequest.ts @@ -0,0 +1,17 @@ +// Original file: proto/channelz.proto + +import type { Long } from '@grpc/proto-loader'; + +export interface GetServerRequest { + /** + * server_id is the identifier of the specific server to get. + */ + 'server_id'?: (number | string | Long); +} + +export interface GetServerRequest__Output { + /** + * server_id is the identifier of the specific server to get. + */ + 'server_id': (string); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetServerResponse.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetServerResponse.ts new file mode 100644 index 000000000..fe0078209 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetServerResponse.ts @@ -0,0 +1,19 @@ +// Original file: proto/channelz.proto + +import type { Server as _grpc_channelz_v1_Server, Server__Output as _grpc_channelz_v1_Server__Output } from '../../../grpc/channelz/v1/Server'; + +export interface GetServerResponse { + /** + * The Server that corresponds to the requested server_id. This field + * should be set. + */ + 'server'?: (_grpc_channelz_v1_Server | null); +} + +export interface GetServerResponse__Output { + /** + * The Server that corresponds to the requested server_id. This field + * should be set. + */ + 'server': (_grpc_channelz_v1_Server__Output | null); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetServerSocketsRequest.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetServerSocketsRequest.ts new file mode 100644 index 000000000..c33056edc --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetServerSocketsRequest.ts @@ -0,0 +1,39 @@ +// Original file: proto/channelz.proto + +import type { Long } from '@grpc/proto-loader'; + +export interface GetServerSocketsRequest { + 'server_id'?: (number | string | Long); + /** + * start_socket_id indicates that only sockets at or above this id should be + * included in the results. + * To request the first page, this must be set to 0. To request + * subsequent pages, the client generates this value by adding 1 to + * the highest seen result ID. + */ + 'start_socket_id'?: (number | string | Long); + /** + * If non-zero, the server will return a page of results containing + * at most this many items. If zero, the server will choose a + * reasonable page size. Must never be negative. + */ + 'max_results'?: (number | string | Long); +} + +export interface GetServerSocketsRequest__Output { + 'server_id': (string); + /** + * start_socket_id indicates that only sockets at or above this id should be + * included in the results. + * To request the first page, this must be set to 0. To request + * subsequent pages, the client generates this value by adding 1 to + * the highest seen result ID. + */ + 'start_socket_id': (string); + /** + * If non-zero, the server will return a page of results containing + * at most this many items. If zero, the server will choose a + * reasonable page size. Must never be negative. + */ + 'max_results': (string); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetServerSocketsResponse.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetServerSocketsResponse.ts new file mode 100644 index 000000000..112f277e3 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetServerSocketsResponse.ts @@ -0,0 +1,33 @@ +// Original file: proto/channelz.proto + +import type { SocketRef as _grpc_channelz_v1_SocketRef, SocketRef__Output as _grpc_channelz_v1_SocketRef__Output } from '../../../grpc/channelz/v1/SocketRef'; + +export interface GetServerSocketsResponse { + /** + * list of socket refs that the connection detail service knows about. Sorted in + * ascending socket_id order. + * Must contain at least 1 result, otherwise 'end' must be true. + */ + 'socket_ref'?: (_grpc_channelz_v1_SocketRef)[]; + /** + * If set, indicates that the list of sockets is the final list. Requesting + * more sockets will only return more if they are created after this RPC + * completes. + */ + 'end'?: (boolean); +} + +export interface GetServerSocketsResponse__Output { + /** + * list of socket refs that the connection detail service knows about. Sorted in + * ascending socket_id order. + * Must contain at least 1 result, otherwise 'end' must be true. + */ + 'socket_ref': (_grpc_channelz_v1_SocketRef__Output)[]; + /** + * If set, indicates that the list of sockets is the final list. Requesting + * more sockets will only return more if they are created after this RPC + * completes. + */ + 'end': (boolean); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetServersRequest.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetServersRequest.ts new file mode 100644 index 000000000..2defea62d --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetServersRequest.ts @@ -0,0 +1,37 @@ +// Original file: proto/channelz.proto + +import type { Long } from '@grpc/proto-loader'; + +export interface GetServersRequest { + /** + * start_server_id indicates that only servers at or above this id should be + * included in the results. + * To request the first page, this must be set to 0. To request + * subsequent pages, the client generates this value by adding 1 to + * the highest seen result ID. + */ + 'start_server_id'?: (number | string | Long); + /** + * If non-zero, the server will return a page of results containing + * at most this many items. If zero, the server will choose a + * reasonable page size. Must never be negative. + */ + 'max_results'?: (number | string | Long); +} + +export interface GetServersRequest__Output { + /** + * start_server_id indicates that only servers at or above this id should be + * included in the results. + * To request the first page, this must be set to 0. To request + * subsequent pages, the client generates this value by adding 1 to + * the highest seen result ID. + */ + 'start_server_id': (string); + /** + * If non-zero, the server will return a page of results containing + * at most this many items. If zero, the server will choose a + * reasonable page size. Must never be negative. + */ + 'max_results': (string); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetServersResponse.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetServersResponse.ts new file mode 100644 index 000000000..b07893b8c --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetServersResponse.ts @@ -0,0 +1,33 @@ +// Original file: proto/channelz.proto + +import type { Server as _grpc_channelz_v1_Server, Server__Output as _grpc_channelz_v1_Server__Output } from '../../../grpc/channelz/v1/Server'; + +export interface GetServersResponse { + /** + * list of servers that the connection detail service knows about. Sorted in + * ascending server_id order. + * Must contain at least 1 result, otherwise 'end' must be true. + */ + 'server'?: (_grpc_channelz_v1_Server)[]; + /** + * If set, indicates that the list of servers is the final list. Requesting + * more servers will only return more if they are created after this RPC + * completes. + */ + 'end'?: (boolean); +} + +export interface GetServersResponse__Output { + /** + * list of servers that the connection detail service knows about. Sorted in + * ascending server_id order. + * Must contain at least 1 result, otherwise 'end' must be true. + */ + 'server': (_grpc_channelz_v1_Server__Output)[]; + /** + * If set, indicates that the list of servers is the final list. Requesting + * more servers will only return more if they are created after this RPC + * completes. + */ + 'end': (boolean); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetSocketRequest.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetSocketRequest.ts new file mode 100644 index 000000000..b3dc1608e --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetSocketRequest.ts @@ -0,0 +1,29 @@ +// Original file: proto/channelz.proto + +import type { Long } from '@grpc/proto-loader'; + +export interface GetSocketRequest { + /** + * socket_id is the identifier of the specific socket to get. + */ + 'socket_id'?: (number | string | Long); + /** + * If true, the response will contain only high level information + * that is inexpensive to obtain. Fields thay may be omitted are + * documented. + */ + 'summary'?: (boolean); +} + +export interface GetSocketRequest__Output { + /** + * socket_id is the identifier of the specific socket to get. + */ + 'socket_id': (string); + /** + * If true, the response will contain only high level information + * that is inexpensive to obtain. Fields thay may be omitted are + * documented. + */ + 'summary': (boolean); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetSocketResponse.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetSocketResponse.ts new file mode 100644 index 000000000..b6304b7f0 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetSocketResponse.ts @@ -0,0 +1,19 @@ +// Original file: proto/channelz.proto + +import type { Socket as _grpc_channelz_v1_Socket, Socket__Output as _grpc_channelz_v1_Socket__Output } from '../../../grpc/channelz/v1/Socket'; + +export interface GetSocketResponse { + /** + * The Socket that corresponds to the requested socket_id. This field + * should be set. + */ + 'socket'?: (_grpc_channelz_v1_Socket | null); +} + +export interface GetSocketResponse__Output { + /** + * The Socket that corresponds to the requested socket_id. This field + * should be set. + */ + 'socket': (_grpc_channelz_v1_Socket__Output | null); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetSubchannelRequest.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetSubchannelRequest.ts new file mode 100644 index 000000000..f481a81d2 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetSubchannelRequest.ts @@ -0,0 +1,17 @@ +// Original file: proto/channelz.proto + +import type { Long } from '@grpc/proto-loader'; + +export interface GetSubchannelRequest { + /** + * subchannel_id is the identifier of the specific subchannel to get. + */ + 'subchannel_id'?: (number | string | Long); +} + +export interface GetSubchannelRequest__Output { + /** + * subchannel_id is the identifier of the specific subchannel to get. + */ + 'subchannel_id': (string); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetSubchannelResponse.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetSubchannelResponse.ts new file mode 100644 index 000000000..57d2bf2dc --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetSubchannelResponse.ts @@ -0,0 +1,19 @@ +// Original file: proto/channelz.proto + +import type { Subchannel as _grpc_channelz_v1_Subchannel, Subchannel__Output as _grpc_channelz_v1_Subchannel__Output } from '../../../grpc/channelz/v1/Subchannel'; + +export interface GetSubchannelResponse { + /** + * The Subchannel that corresponds to the requested subchannel_id. This + * field should be set. + */ + 'subchannel'?: (_grpc_channelz_v1_Subchannel | null); +} + +export interface GetSubchannelResponse__Output { + /** + * The Subchannel that corresponds to the requested subchannel_id. This + * field should be set. + */ + 'subchannel': (_grpc_channelz_v1_Subchannel__Output | null); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetTopChannelsRequest.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetTopChannelsRequest.ts new file mode 100644 index 000000000..a122d7a85 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetTopChannelsRequest.ts @@ -0,0 +1,37 @@ +// Original file: proto/channelz.proto + +import type { Long } from '@grpc/proto-loader'; + +export interface GetTopChannelsRequest { + /** + * start_channel_id indicates that only channels at or above this id should be + * included in the results. + * To request the first page, this should be set to 0. To request + * subsequent pages, the client generates this value by adding 1 to + * the highest seen result ID. + */ + 'start_channel_id'?: (number | string | Long); + /** + * If non-zero, the server will return a page of results containing + * at most this many items. If zero, the server will choose a + * reasonable page size. Must never be negative. + */ + 'max_results'?: (number | string | Long); +} + +export interface GetTopChannelsRequest__Output { + /** + * start_channel_id indicates that only channels at or above this id should be + * included in the results. + * To request the first page, this should be set to 0. To request + * subsequent pages, the client generates this value by adding 1 to + * the highest seen result ID. + */ + 'start_channel_id': (string); + /** + * If non-zero, the server will return a page of results containing + * at most this many items. If zero, the server will choose a + * reasonable page size. Must never be negative. + */ + 'max_results': (string); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetTopChannelsResponse.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetTopChannelsResponse.ts new file mode 100644 index 000000000..d96e63673 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/GetTopChannelsResponse.ts @@ -0,0 +1,33 @@ +// Original file: proto/channelz.proto + +import type { Channel as _grpc_channelz_v1_Channel, Channel__Output as _grpc_channelz_v1_Channel__Output } from '../../../grpc/channelz/v1/Channel'; + +export interface GetTopChannelsResponse { + /** + * list of channels that the connection detail service knows about. Sorted in + * ascending channel_id order. + * Must contain at least 1 result, otherwise 'end' must be true. + */ + 'channel'?: (_grpc_channelz_v1_Channel)[]; + /** + * If set, indicates that the list of channels is the final list. Requesting + * more channels can only return more if they are created after this RPC + * completes. + */ + 'end'?: (boolean); +} + +export interface GetTopChannelsResponse__Output { + /** + * list of channels that the connection detail service knows about. Sorted in + * ascending channel_id order. + * Must contain at least 1 result, otherwise 'end' must be true. + */ + 'channel': (_grpc_channelz_v1_Channel__Output)[]; + /** + * If set, indicates that the list of channels is the final list. Requesting + * more channels can only return more if they are created after this RPC + * completes. + */ + 'end': (boolean); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Security.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Security.ts new file mode 100644 index 000000000..e555d698e --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Security.ts @@ -0,0 +1,87 @@ +// Original file: proto/channelz.proto + +import type { Any as _google_protobuf_Any, Any__Output as _google_protobuf_Any__Output } from '../../../google/protobuf/Any'; + +export interface _grpc_channelz_v1_Security_OtherSecurity { + /** + * The human readable version of the value. + */ + 'name'?: (string); + /** + * The actual security details message. + */ + 'value'?: (_google_protobuf_Any | null); +} + +export interface _grpc_channelz_v1_Security_OtherSecurity__Output { + /** + * The human readable version of the value. + */ + 'name': (string); + /** + * The actual security details message. + */ + 'value': (_google_protobuf_Any__Output | null); +} + +export interface _grpc_channelz_v1_Security_Tls { + /** + * The cipher suite name in the RFC 4346 format: + * https://tools.ietf.org/html/rfc4346#appendix-C + */ + 'standard_name'?: (string); + /** + * Some other way to describe the cipher suite if + * the RFC 4346 name is not available. + */ + 'other_name'?: (string); + /** + * the certificate used by this endpoint. + */ + 'local_certificate'?: (Buffer | Uint8Array | string); + /** + * the certificate used by the remote endpoint. + */ + 'remote_certificate'?: (Buffer | Uint8Array | string); + 'cipher_suite'?: "standard_name"|"other_name"; +} + +export interface _grpc_channelz_v1_Security_Tls__Output { + /** + * The cipher suite name in the RFC 4346 format: + * https://tools.ietf.org/html/rfc4346#appendix-C + */ + 'standard_name'?: (string); + /** + * Some other way to describe the cipher suite if + * the RFC 4346 name is not available. + */ + 'other_name'?: (string); + /** + * the certificate used by this endpoint. + */ + 'local_certificate': (Buffer); + /** + * the certificate used by the remote endpoint. + */ + 'remote_certificate': (Buffer); + 'cipher_suite': "standard_name"|"other_name"; +} + +/** + * Security represents details about how secure the socket is. + */ +export interface Security { + 'tls'?: (_grpc_channelz_v1_Security_Tls | null); + 'other'?: (_grpc_channelz_v1_Security_OtherSecurity | null); + 'model'?: "tls"|"other"; +} + +/** + * Security represents details about how secure the socket is. + */ +export interface Security__Output { + 'tls'?: (_grpc_channelz_v1_Security_Tls__Output | null); + 'other'?: (_grpc_channelz_v1_Security_OtherSecurity__Output | null); + 'model': "tls"|"other"; +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Server.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Server.ts new file mode 100644 index 000000000..958343358 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Server.ts @@ -0,0 +1,45 @@ +// Original file: proto/channelz.proto + +import type { ServerRef as _grpc_channelz_v1_ServerRef, ServerRef__Output as _grpc_channelz_v1_ServerRef__Output } from '../../../grpc/channelz/v1/ServerRef'; +import type { ServerData as _grpc_channelz_v1_ServerData, ServerData__Output as _grpc_channelz_v1_ServerData__Output } from '../../../grpc/channelz/v1/ServerData'; +import type { SocketRef as _grpc_channelz_v1_SocketRef, SocketRef__Output as _grpc_channelz_v1_SocketRef__Output } from '../../../grpc/channelz/v1/SocketRef'; + +/** + * Server represents a single server. There may be multiple servers in a single + * program. + */ +export interface Server { + /** + * The identifier for a Server. This should be set. + */ + 'ref'?: (_grpc_channelz_v1_ServerRef | null); + /** + * The associated data of the Server. + */ + 'data'?: (_grpc_channelz_v1_ServerData | null); + /** + * The sockets that the server is listening on. There are no ordering + * guarantees. This may be absent. + */ + 'listen_socket'?: (_grpc_channelz_v1_SocketRef)[]; +} + +/** + * Server represents a single server. There may be multiple servers in a single + * program. + */ +export interface Server__Output { + /** + * The identifier for a Server. This should be set. + */ + 'ref': (_grpc_channelz_v1_ServerRef__Output | null); + /** + * The associated data of the Server. + */ + 'data': (_grpc_channelz_v1_ServerData__Output | null); + /** + * The sockets that the server is listening on. There are no ordering + * guarantees. This may be absent. + */ + 'listen_socket': (_grpc_channelz_v1_SocketRef__Output)[]; +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ServerData.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ServerData.ts new file mode 100644 index 000000000..ce48e36f5 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ServerData.ts @@ -0,0 +1,57 @@ +// Original file: proto/channelz.proto + +import type { ChannelTrace as _grpc_channelz_v1_ChannelTrace, ChannelTrace__Output as _grpc_channelz_v1_ChannelTrace__Output } from '../../../grpc/channelz/v1/ChannelTrace'; +import type { Timestamp as _google_protobuf_Timestamp, Timestamp__Output as _google_protobuf_Timestamp__Output } from '../../../google/protobuf/Timestamp'; +import type { Long } from '@grpc/proto-loader'; + +/** + * ServerData is data for a specific Server. + */ +export interface ServerData { + /** + * A trace of recent events on the server. May be absent. + */ + 'trace'?: (_grpc_channelz_v1_ChannelTrace | null); + /** + * The number of incoming calls started on the server + */ + 'calls_started'?: (number | string | Long); + /** + * The number of incoming calls that have completed with an OK status + */ + 'calls_succeeded'?: (number | string | Long); + /** + * The number of incoming calls that have a completed with a non-OK status + */ + 'calls_failed'?: (number | string | Long); + /** + * The last time a call was started on the server. + */ + 'last_call_started_timestamp'?: (_google_protobuf_Timestamp | null); +} + +/** + * ServerData is data for a specific Server. + */ +export interface ServerData__Output { + /** + * A trace of recent events on the server. May be absent. + */ + 'trace': (_grpc_channelz_v1_ChannelTrace__Output | null); + /** + * The number of incoming calls started on the server + */ + 'calls_started': (string); + /** + * The number of incoming calls that have completed with an OK status + */ + 'calls_succeeded': (string); + /** + * The number of incoming calls that have a completed with a non-OK status + */ + 'calls_failed': (string); + /** + * The last time a call was started on the server. + */ + 'last_call_started_timestamp': (_google_protobuf_Timestamp__Output | null); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ServerRef.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ServerRef.ts new file mode 100644 index 000000000..389183bdc --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/ServerRef.ts @@ -0,0 +1,31 @@ +// Original file: proto/channelz.proto + +import type { Long } from '@grpc/proto-loader'; + +/** + * ServerRef is a reference to a Server. + */ +export interface ServerRef { + /** + * A globally unique identifier for this server. Must be a positive number. + */ + 'server_id'?: (number | string | Long); + /** + * An optional name associated with the server. + */ + 'name'?: (string); +} + +/** + * ServerRef is a reference to a Server. + */ +export interface ServerRef__Output { + /** + * A globally unique identifier for this server. Must be a positive number. + */ + 'server_id': (string); + /** + * An optional name associated with the server. + */ + 'name': (string); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Socket.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Socket.ts new file mode 100644 index 000000000..5829afe98 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Socket.ts @@ -0,0 +1,70 @@ +// Original file: proto/channelz.proto + +import type { SocketRef as _grpc_channelz_v1_SocketRef, SocketRef__Output as _grpc_channelz_v1_SocketRef__Output } from '../../../grpc/channelz/v1/SocketRef'; +import type { SocketData as _grpc_channelz_v1_SocketData, SocketData__Output as _grpc_channelz_v1_SocketData__Output } from '../../../grpc/channelz/v1/SocketData'; +import type { Address as _grpc_channelz_v1_Address, Address__Output as _grpc_channelz_v1_Address__Output } from '../../../grpc/channelz/v1/Address'; +import type { Security as _grpc_channelz_v1_Security, Security__Output as _grpc_channelz_v1_Security__Output } from '../../../grpc/channelz/v1/Security'; + +/** + * Information about an actual connection. Pronounced "sock-ay". + */ +export interface Socket { + /** + * The identifier for the Socket. + */ + 'ref'?: (_grpc_channelz_v1_SocketRef | null); + /** + * Data specific to this Socket. + */ + 'data'?: (_grpc_channelz_v1_SocketData | null); + /** + * The locally bound address. + */ + 'local'?: (_grpc_channelz_v1_Address | null); + /** + * The remote bound address. May be absent. + */ + 'remote'?: (_grpc_channelz_v1_Address | null); + /** + * Security details for this socket. May be absent if not available, or + * there is no security on the socket. + */ + 'security'?: (_grpc_channelz_v1_Security | null); + /** + * Optional, represents the name of the remote endpoint, if different than + * the original target name. + */ + 'remote_name'?: (string); +} + +/** + * Information about an actual connection. Pronounced "sock-ay". + */ +export interface Socket__Output { + /** + * The identifier for the Socket. + */ + 'ref': (_grpc_channelz_v1_SocketRef__Output | null); + /** + * Data specific to this Socket. + */ + 'data': (_grpc_channelz_v1_SocketData__Output | null); + /** + * The locally bound address. + */ + 'local': (_grpc_channelz_v1_Address__Output | null); + /** + * The remote bound address. May be absent. + */ + 'remote': (_grpc_channelz_v1_Address__Output | null); + /** + * Security details for this socket. May be absent if not available, or + * there is no security on the socket. + */ + 'security': (_grpc_channelz_v1_Security__Output | null); + /** + * Optional, represents the name of the remote endpoint, if different than + * the original target name. + */ + 'remote_name': (string); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SocketData.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SocketData.ts new file mode 100644 index 000000000..c62d4d10c --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SocketData.ts @@ -0,0 +1,150 @@ +// Original file: proto/channelz.proto + +import type { Timestamp as _google_protobuf_Timestamp, Timestamp__Output as _google_protobuf_Timestamp__Output } from '../../../google/protobuf/Timestamp'; +import type { Int64Value as _google_protobuf_Int64Value, Int64Value__Output as _google_protobuf_Int64Value__Output } from '../../../google/protobuf/Int64Value'; +import type { SocketOption as _grpc_channelz_v1_SocketOption, SocketOption__Output as _grpc_channelz_v1_SocketOption__Output } from '../../../grpc/channelz/v1/SocketOption'; +import type { Long } from '@grpc/proto-loader'; + +/** + * SocketData is data associated for a specific Socket. The fields present + * are specific to the implementation, so there may be minor differences in + * the semantics. (e.g. flow control windows) + */ +export interface SocketData { + /** + * The number of streams that have been started. + */ + 'streams_started'?: (number | string | Long); + /** + * The number of streams that have ended successfully: + * On client side, received frame with eos bit set; + * On server side, sent frame with eos bit set. + */ + 'streams_succeeded'?: (number | string | Long); + /** + * The number of streams that have ended unsuccessfully: + * On client side, ended without receiving frame with eos bit set; + * On server side, ended without sending frame with eos bit set. + */ + 'streams_failed'?: (number | string | Long); + /** + * The number of grpc messages successfully sent on this socket. + */ + 'messages_sent'?: (number | string | Long); + /** + * The number of grpc messages received on this socket. + */ + 'messages_received'?: (number | string | Long); + /** + * The number of keep alives sent. This is typically implemented with HTTP/2 + * ping messages. + */ + 'keep_alives_sent'?: (number | string | Long); + /** + * The last time a stream was created by this endpoint. Usually unset for + * servers. + */ + 'last_local_stream_created_timestamp'?: (_google_protobuf_Timestamp | null); + /** + * The last time a stream was created by the remote endpoint. Usually unset + * for clients. + */ + 'last_remote_stream_created_timestamp'?: (_google_protobuf_Timestamp | null); + /** + * The last time a message was sent by this endpoint. + */ + 'last_message_sent_timestamp'?: (_google_protobuf_Timestamp | null); + /** + * The last time a message was received by this endpoint. + */ + 'last_message_received_timestamp'?: (_google_protobuf_Timestamp | null); + /** + * The amount of window, granted to the local endpoint by the remote endpoint. + * This may be slightly out of date due to network latency. This does NOT + * include stream level or TCP level flow control info. + */ + 'local_flow_control_window'?: (_google_protobuf_Int64Value | null); + /** + * The amount of window, granted to the remote endpoint by the local endpoint. + * This may be slightly out of date due to network latency. This does NOT + * include stream level or TCP level flow control info. + */ + 'remote_flow_control_window'?: (_google_protobuf_Int64Value | null); + /** + * Socket options set on this socket. May be absent if 'summary' is set + * on GetSocketRequest. + */ + 'option'?: (_grpc_channelz_v1_SocketOption)[]; +} + +/** + * SocketData is data associated for a specific Socket. The fields present + * are specific to the implementation, so there may be minor differences in + * the semantics. (e.g. flow control windows) + */ +export interface SocketData__Output { + /** + * The number of streams that have been started. + */ + 'streams_started': (string); + /** + * The number of streams that have ended successfully: + * On client side, received frame with eos bit set; + * On server side, sent frame with eos bit set. + */ + 'streams_succeeded': (string); + /** + * The number of streams that have ended unsuccessfully: + * On client side, ended without receiving frame with eos bit set; + * On server side, ended without sending frame with eos bit set. + */ + 'streams_failed': (string); + /** + * The number of grpc messages successfully sent on this socket. + */ + 'messages_sent': (string); + /** + * The number of grpc messages received on this socket. + */ + 'messages_received': (string); + /** + * The number of keep alives sent. This is typically implemented with HTTP/2 + * ping messages. + */ + 'keep_alives_sent': (string); + /** + * The last time a stream was created by this endpoint. Usually unset for + * servers. + */ + 'last_local_stream_created_timestamp': (_google_protobuf_Timestamp__Output | null); + /** + * The last time a stream was created by the remote endpoint. Usually unset + * for clients. + */ + 'last_remote_stream_created_timestamp': (_google_protobuf_Timestamp__Output | null); + /** + * The last time a message was sent by this endpoint. + */ + 'last_message_sent_timestamp': (_google_protobuf_Timestamp__Output | null); + /** + * The last time a message was received by this endpoint. + */ + 'last_message_received_timestamp': (_google_protobuf_Timestamp__Output | null); + /** + * The amount of window, granted to the local endpoint by the remote endpoint. + * This may be slightly out of date due to network latency. This does NOT + * include stream level or TCP level flow control info. + */ + 'local_flow_control_window': (_google_protobuf_Int64Value__Output | null); + /** + * The amount of window, granted to the remote endpoint by the local endpoint. + * This may be slightly out of date due to network latency. This does NOT + * include stream level or TCP level flow control info. + */ + 'remote_flow_control_window': (_google_protobuf_Int64Value__Output | null); + /** + * Socket options set on this socket. May be absent if 'summary' is set + * on GetSocketRequest. + */ + 'option': (_grpc_channelz_v1_SocketOption__Output)[]; +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SocketOption.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SocketOption.ts new file mode 100644 index 000000000..115b36aae --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SocketOption.ts @@ -0,0 +1,47 @@ +// Original file: proto/channelz.proto + +import type { Any as _google_protobuf_Any, Any__Output as _google_protobuf_Any__Output } from '../../../google/protobuf/Any'; + +/** + * SocketOption represents socket options for a socket. Specifically, these + * are the options returned by getsockopt(). + */ +export interface SocketOption { + /** + * The full name of the socket option. Typically this will be the upper case + * name, such as "SO_REUSEPORT". + */ + 'name'?: (string); + /** + * The human readable value of this socket option. At least one of value or + * additional will be set. + */ + 'value'?: (string); + /** + * Additional data associated with the socket option. At least one of value + * or additional will be set. + */ + 'additional'?: (_google_protobuf_Any | null); +} + +/** + * SocketOption represents socket options for a socket. Specifically, these + * are the options returned by getsockopt(). + */ +export interface SocketOption__Output { + /** + * The full name of the socket option. Typically this will be the upper case + * name, such as "SO_REUSEPORT". + */ + 'name': (string); + /** + * The human readable value of this socket option. At least one of value or + * additional will be set. + */ + 'value': (string); + /** + * Additional data associated with the socket option. At least one of value + * or additional will be set. + */ + 'additional': (_google_protobuf_Any__Output | null); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SocketOptionLinger.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SocketOptionLinger.ts new file mode 100644 index 000000000..d83fa3238 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SocketOptionLinger.ts @@ -0,0 +1,33 @@ +// Original file: proto/channelz.proto + +import type { Duration as _google_protobuf_Duration, Duration__Output as _google_protobuf_Duration__Output } from '../../../google/protobuf/Duration'; + +/** + * For use with SocketOption's additional field. This is primarily used for + * SO_LINGER. + */ +export interface SocketOptionLinger { + /** + * active maps to `struct linger.l_onoff` + */ + 'active'?: (boolean); + /** + * duration maps to `struct linger.l_linger` + */ + 'duration'?: (_google_protobuf_Duration | null); +} + +/** + * For use with SocketOption's additional field. This is primarily used for + * SO_LINGER. + */ +export interface SocketOptionLinger__Output { + /** + * active maps to `struct linger.l_onoff` + */ + 'active': (boolean); + /** + * duration maps to `struct linger.l_linger` + */ + 'duration': (_google_protobuf_Duration__Output | null); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SocketOptionTcpInfo.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SocketOptionTcpInfo.ts new file mode 100644 index 000000000..2f8affe80 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SocketOptionTcpInfo.ts @@ -0,0 +1,74 @@ +// Original file: proto/channelz.proto + + +/** + * For use with SocketOption's additional field. Tcp info for + * SOL_TCP and TCP_INFO. + */ +export interface SocketOptionTcpInfo { + 'tcpi_state'?: (number); + 'tcpi_ca_state'?: (number); + 'tcpi_retransmits'?: (number); + 'tcpi_probes'?: (number); + 'tcpi_backoff'?: (number); + 'tcpi_options'?: (number); + 'tcpi_snd_wscale'?: (number); + 'tcpi_rcv_wscale'?: (number); + 'tcpi_rto'?: (number); + 'tcpi_ato'?: (number); + 'tcpi_snd_mss'?: (number); + 'tcpi_rcv_mss'?: (number); + 'tcpi_unacked'?: (number); + 'tcpi_sacked'?: (number); + 'tcpi_lost'?: (number); + 'tcpi_retrans'?: (number); + 'tcpi_fackets'?: (number); + 'tcpi_last_data_sent'?: (number); + 'tcpi_last_ack_sent'?: (number); + 'tcpi_last_data_recv'?: (number); + 'tcpi_last_ack_recv'?: (number); + 'tcpi_pmtu'?: (number); + 'tcpi_rcv_ssthresh'?: (number); + 'tcpi_rtt'?: (number); + 'tcpi_rttvar'?: (number); + 'tcpi_snd_ssthresh'?: (number); + 'tcpi_snd_cwnd'?: (number); + 'tcpi_advmss'?: (number); + 'tcpi_reordering'?: (number); +} + +/** + * For use with SocketOption's additional field. Tcp info for + * SOL_TCP and TCP_INFO. + */ +export interface SocketOptionTcpInfo__Output { + 'tcpi_state': (number); + 'tcpi_ca_state': (number); + 'tcpi_retransmits': (number); + 'tcpi_probes': (number); + 'tcpi_backoff': (number); + 'tcpi_options': (number); + 'tcpi_snd_wscale': (number); + 'tcpi_rcv_wscale': (number); + 'tcpi_rto': (number); + 'tcpi_ato': (number); + 'tcpi_snd_mss': (number); + 'tcpi_rcv_mss': (number); + 'tcpi_unacked': (number); + 'tcpi_sacked': (number); + 'tcpi_lost': (number); + 'tcpi_retrans': (number); + 'tcpi_fackets': (number); + 'tcpi_last_data_sent': (number); + 'tcpi_last_ack_sent': (number); + 'tcpi_last_data_recv': (number); + 'tcpi_last_ack_recv': (number); + 'tcpi_pmtu': (number); + 'tcpi_rcv_ssthresh': (number); + 'tcpi_rtt': (number); + 'tcpi_rttvar': (number); + 'tcpi_snd_ssthresh': (number); + 'tcpi_snd_cwnd': (number); + 'tcpi_advmss': (number); + 'tcpi_reordering': (number); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SocketOptionTimeout.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SocketOptionTimeout.ts new file mode 100644 index 000000000..185839b2c --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SocketOptionTimeout.ts @@ -0,0 +1,19 @@ +// Original file: proto/channelz.proto + +import type { Duration as _google_protobuf_Duration, Duration__Output as _google_protobuf_Duration__Output } from '../../../google/protobuf/Duration'; + +/** + * For use with SocketOption's additional field. This is primarily used for + * SO_RCVTIMEO and SO_SNDTIMEO + */ +export interface SocketOptionTimeout { + 'duration'?: (_google_protobuf_Duration | null); +} + +/** + * For use with SocketOption's additional field. This is primarily used for + * SO_RCVTIMEO and SO_SNDTIMEO + */ +export interface SocketOptionTimeout__Output { + 'duration': (_google_protobuf_Duration__Output | null); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SocketRef.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SocketRef.ts new file mode 100644 index 000000000..52fdb2bd3 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SocketRef.ts @@ -0,0 +1,31 @@ +// Original file: proto/channelz.proto + +import type { Long } from '@grpc/proto-loader'; + +/** + * SocketRef is a reference to a Socket. + */ +export interface SocketRef { + /** + * The globally unique id for this socket. Must be a positive number. + */ + 'socket_id'?: (number | string | Long); + /** + * An optional name associated with the socket. + */ + 'name'?: (string); +} + +/** + * SocketRef is a reference to a Socket. + */ +export interface SocketRef__Output { + /** + * The globally unique id for this socket. Must be a positive number. + */ + 'socket_id': (string); + /** + * An optional name associated with the socket. + */ + 'name': (string); +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Subchannel.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Subchannel.ts new file mode 100644 index 000000000..7122fac83 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/Subchannel.ts @@ -0,0 +1,70 @@ +// Original file: proto/channelz.proto + +import type { SubchannelRef as _grpc_channelz_v1_SubchannelRef, SubchannelRef__Output as _grpc_channelz_v1_SubchannelRef__Output } from '../../../grpc/channelz/v1/SubchannelRef'; +import type { ChannelData as _grpc_channelz_v1_ChannelData, ChannelData__Output as _grpc_channelz_v1_ChannelData__Output } from '../../../grpc/channelz/v1/ChannelData'; +import type { ChannelRef as _grpc_channelz_v1_ChannelRef, ChannelRef__Output as _grpc_channelz_v1_ChannelRef__Output } from '../../../grpc/channelz/v1/ChannelRef'; +import type { SocketRef as _grpc_channelz_v1_SocketRef, SocketRef__Output as _grpc_channelz_v1_SocketRef__Output } from '../../../grpc/channelz/v1/SocketRef'; + +/** + * Subchannel is a logical grouping of channels, subchannels, and sockets. + * A subchannel is load balanced over by it's ancestor + */ +export interface Subchannel { + /** + * The identifier for this channel. + */ + 'ref'?: (_grpc_channelz_v1_SubchannelRef | null); + /** + * Data specific to this channel. + */ + 'data'?: (_grpc_channelz_v1_ChannelData | null); + /** + * There are no ordering guarantees on the order of channel refs. + * There may not be cycles in the ref graph. + * A channel ref may be present in more than one channel or subchannel. + */ + 'channel_ref'?: (_grpc_channelz_v1_ChannelRef)[]; + /** + * At most one of 'channel_ref+subchannel_ref' and 'socket' is set. + * There are no ordering guarantees on the order of subchannel refs. + * There may not be cycles in the ref graph. + * A sub channel ref may be present in more than one channel or subchannel. + */ + 'subchannel_ref'?: (_grpc_channelz_v1_SubchannelRef)[]; + /** + * There are no ordering guarantees on the order of sockets. + */ + 'socket_ref'?: (_grpc_channelz_v1_SocketRef)[]; +} + +/** + * Subchannel is a logical grouping of channels, subchannels, and sockets. + * A subchannel is load balanced over by it's ancestor + */ +export interface Subchannel__Output { + /** + * The identifier for this channel. + */ + 'ref': (_grpc_channelz_v1_SubchannelRef__Output | null); + /** + * Data specific to this channel. + */ + 'data': (_grpc_channelz_v1_ChannelData__Output | null); + /** + * There are no ordering guarantees on the order of channel refs. + * There may not be cycles in the ref graph. + * A channel ref may be present in more than one channel or subchannel. + */ + 'channel_ref': (_grpc_channelz_v1_ChannelRef__Output)[]; + /** + * At most one of 'channel_ref+subchannel_ref' and 'socket' is set. + * There are no ordering guarantees on the order of subchannel refs. + * There may not be cycles in the ref graph. + * A sub channel ref may be present in more than one channel or subchannel. + */ + 'subchannel_ref': (_grpc_channelz_v1_SubchannelRef__Output)[]; + /** + * There are no ordering guarantees on the order of sockets. + */ + 'socket_ref': (_grpc_channelz_v1_SocketRef__Output)[]; +} diff --git a/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SubchannelRef.ts b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SubchannelRef.ts new file mode 100644 index 000000000..b6911c773 --- /dev/null +++ b/node_modules/@grpc/grpc-js/src/generated/grpc/channelz/v1/SubchannelRef.ts @@ -0,0 +1,31 @@ +// Original file: proto/channelz.proto + +import type { Long } from '@grpc/proto-loader'; + +/** + * SubchannelRef is a reference to a Subchannel. + */ +export interface SubchannelRef { + /** + * The globally unique id for this subchannel. Must be a positive number. + */ + 'subchannel_id'?: (number | string | Long); + /** + * An optional name associated with the subchannel. + */ + 'name'?: (string); +} + +/** + * SubchannelRef is a reference to a Subchannel. + */ +export interface SubchannelRef__Output { + /** + * The globally unique id for this subchannel. Must be a positive number. + */ + 'subchannel_id': (string); + /** + * An optional name associated with the subchannel. + */ + 'name': (string); +} diff --git a/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/traverse/lib/path/generated/asserts.js b/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/traverse/lib/path/generated/asserts.js new file mode 100644 index 000000000..bee8a438e --- /dev/null +++ b/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/traverse/lib/path/generated/asserts.js @@ -0,0 +1,5 @@ +"use strict"; + +var t = require("@babel/types"); + +var _index = require("../index"); \ No newline at end of file diff --git a/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/traverse/lib/path/generated/validators.js b/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/traverse/lib/path/generated/validators.js new file mode 100644 index 000000000..bee8a438e --- /dev/null +++ b/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/traverse/lib/path/generated/validators.js @@ -0,0 +1,5 @@ +"use strict"; + +var t = require("@babel/types"); + +var _index = require("../index"); \ No newline at end of file diff --git a/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/traverse/lib/path/generated/virtual-types.js b/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/traverse/lib/path/generated/virtual-types.js new file mode 100644 index 000000000..bf37ed937 --- /dev/null +++ b/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/traverse/lib/path/generated/virtual-types.js @@ -0,0 +1,3 @@ +"use strict"; + +var t = require("@babel/types"); \ No newline at end of file diff --git a/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/types/lib/asserts/generated/index.js b/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/types/lib/asserts/generated/index.js new file mode 100644 index 000000000..53a55168d --- /dev/null +++ b/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/types/lib/asserts/generated/index.js @@ -0,0 +1,1517 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.assertAccessor = assertAccessor; +exports.assertAnyTypeAnnotation = assertAnyTypeAnnotation; +exports.assertArgumentPlaceholder = assertArgumentPlaceholder; +exports.assertArrayExpression = assertArrayExpression; +exports.assertArrayPattern = assertArrayPattern; +exports.assertArrayTypeAnnotation = assertArrayTypeAnnotation; +exports.assertArrowFunctionExpression = assertArrowFunctionExpression; +exports.assertAssignmentExpression = assertAssignmentExpression; +exports.assertAssignmentPattern = assertAssignmentPattern; +exports.assertAwaitExpression = assertAwaitExpression; +exports.assertBigIntLiteral = assertBigIntLiteral; +exports.assertBinary = assertBinary; +exports.assertBinaryExpression = assertBinaryExpression; +exports.assertBindExpression = assertBindExpression; +exports.assertBlock = assertBlock; +exports.assertBlockParent = assertBlockParent; +exports.assertBlockStatement = assertBlockStatement; +exports.assertBooleanLiteral = assertBooleanLiteral; +exports.assertBooleanLiteralTypeAnnotation = assertBooleanLiteralTypeAnnotation; +exports.assertBooleanTypeAnnotation = assertBooleanTypeAnnotation; +exports.assertBreakStatement = assertBreakStatement; +exports.assertCallExpression = assertCallExpression; +exports.assertCatchClause = assertCatchClause; +exports.assertClass = assertClass; +exports.assertClassAccessorProperty = assertClassAccessorProperty; +exports.assertClassBody = assertClassBody; +exports.assertClassDeclaration = assertClassDeclaration; +exports.assertClassExpression = assertClassExpression; +exports.assertClassImplements = assertClassImplements; +exports.assertClassMethod = assertClassMethod; +exports.assertClassPrivateMethod = assertClassPrivateMethod; +exports.assertClassPrivateProperty = assertClassPrivateProperty; +exports.assertClassProperty = assertClassProperty; +exports.assertCompletionStatement = assertCompletionStatement; +exports.assertConditional = assertConditional; +exports.assertConditionalExpression = assertConditionalExpression; +exports.assertContinueStatement = assertContinueStatement; +exports.assertDebuggerStatement = assertDebuggerStatement; +exports.assertDecimalLiteral = assertDecimalLiteral; +exports.assertDeclaration = assertDeclaration; +exports.assertDeclareClass = assertDeclareClass; +exports.assertDeclareExportAllDeclaration = assertDeclareExportAllDeclaration; +exports.assertDeclareExportDeclaration = assertDeclareExportDeclaration; +exports.assertDeclareFunction = assertDeclareFunction; +exports.assertDeclareInterface = assertDeclareInterface; +exports.assertDeclareModule = assertDeclareModule; +exports.assertDeclareModuleExports = assertDeclareModuleExports; +exports.assertDeclareOpaqueType = assertDeclareOpaqueType; +exports.assertDeclareTypeAlias = assertDeclareTypeAlias; +exports.assertDeclareVariable = assertDeclareVariable; +exports.assertDeclaredPredicate = assertDeclaredPredicate; +exports.assertDecorator = assertDecorator; +exports.assertDirective = assertDirective; +exports.assertDirectiveLiteral = assertDirectiveLiteral; +exports.assertDoExpression = assertDoExpression; +exports.assertDoWhileStatement = assertDoWhileStatement; +exports.assertEmptyStatement = assertEmptyStatement; +exports.assertEmptyTypeAnnotation = assertEmptyTypeAnnotation; +exports.assertEnumBody = assertEnumBody; +exports.assertEnumBooleanBody = assertEnumBooleanBody; +exports.assertEnumBooleanMember = assertEnumBooleanMember; +exports.assertEnumDeclaration = assertEnumDeclaration; +exports.assertEnumDefaultedMember = assertEnumDefaultedMember; +exports.assertEnumMember = assertEnumMember; +exports.assertEnumNumberBody = assertEnumNumberBody; +exports.assertEnumNumberMember = assertEnumNumberMember; +exports.assertEnumStringBody = assertEnumStringBody; +exports.assertEnumStringMember = assertEnumStringMember; +exports.assertEnumSymbolBody = assertEnumSymbolBody; +exports.assertExistsTypeAnnotation = assertExistsTypeAnnotation; +exports.assertExportAllDeclaration = assertExportAllDeclaration; +exports.assertExportDeclaration = assertExportDeclaration; +exports.assertExportDefaultDeclaration = assertExportDefaultDeclaration; +exports.assertExportDefaultSpecifier = assertExportDefaultSpecifier; +exports.assertExportNamedDeclaration = assertExportNamedDeclaration; +exports.assertExportNamespaceSpecifier = assertExportNamespaceSpecifier; +exports.assertExportSpecifier = assertExportSpecifier; +exports.assertExpression = assertExpression; +exports.assertExpressionStatement = assertExpressionStatement; +exports.assertExpressionWrapper = assertExpressionWrapper; +exports.assertFile = assertFile; +exports.assertFlow = assertFlow; +exports.assertFlowBaseAnnotation = assertFlowBaseAnnotation; +exports.assertFlowDeclaration = assertFlowDeclaration; +exports.assertFlowPredicate = assertFlowPredicate; +exports.assertFlowType = assertFlowType; +exports.assertFor = assertFor; +exports.assertForInStatement = assertForInStatement; +exports.assertForOfStatement = assertForOfStatement; +exports.assertForStatement = assertForStatement; +exports.assertForXStatement = assertForXStatement; +exports.assertFunction = assertFunction; +exports.assertFunctionDeclaration = assertFunctionDeclaration; +exports.assertFunctionExpression = assertFunctionExpression; +exports.assertFunctionParent = assertFunctionParent; +exports.assertFunctionTypeAnnotation = assertFunctionTypeAnnotation; +exports.assertFunctionTypeParam = assertFunctionTypeParam; +exports.assertGenericTypeAnnotation = assertGenericTypeAnnotation; +exports.assertIdentifier = assertIdentifier; +exports.assertIfStatement = assertIfStatement; +exports.assertImmutable = assertImmutable; +exports.assertImport = assertImport; +exports.assertImportAttribute = assertImportAttribute; +exports.assertImportDeclaration = assertImportDeclaration; +exports.assertImportDefaultSpecifier = assertImportDefaultSpecifier; +exports.assertImportNamespaceSpecifier = assertImportNamespaceSpecifier; +exports.assertImportSpecifier = assertImportSpecifier; +exports.assertIndexedAccessType = assertIndexedAccessType; +exports.assertInferredPredicate = assertInferredPredicate; +exports.assertInterfaceDeclaration = assertInterfaceDeclaration; +exports.assertInterfaceExtends = assertInterfaceExtends; +exports.assertInterfaceTypeAnnotation = assertInterfaceTypeAnnotation; +exports.assertInterpreterDirective = assertInterpreterDirective; +exports.assertIntersectionTypeAnnotation = assertIntersectionTypeAnnotation; +exports.assertJSX = assertJSX; +exports.assertJSXAttribute = assertJSXAttribute; +exports.assertJSXClosingElement = assertJSXClosingElement; +exports.assertJSXClosingFragment = assertJSXClosingFragment; +exports.assertJSXElement = assertJSXElement; +exports.assertJSXEmptyExpression = assertJSXEmptyExpression; +exports.assertJSXExpressionContainer = assertJSXExpressionContainer; +exports.assertJSXFragment = assertJSXFragment; +exports.assertJSXIdentifier = assertJSXIdentifier; +exports.assertJSXMemberExpression = assertJSXMemberExpression; +exports.assertJSXNamespacedName = assertJSXNamespacedName; +exports.assertJSXOpeningElement = assertJSXOpeningElement; +exports.assertJSXOpeningFragment = assertJSXOpeningFragment; +exports.assertJSXSpreadAttribute = assertJSXSpreadAttribute; +exports.assertJSXSpreadChild = assertJSXSpreadChild; +exports.assertJSXText = assertJSXText; +exports.assertLVal = assertLVal; +exports.assertLabeledStatement = assertLabeledStatement; +exports.assertLiteral = assertLiteral; +exports.assertLogicalExpression = assertLogicalExpression; +exports.assertLoop = assertLoop; +exports.assertMemberExpression = assertMemberExpression; +exports.assertMetaProperty = assertMetaProperty; +exports.assertMethod = assertMethod; +exports.assertMiscellaneous = assertMiscellaneous; +exports.assertMixedTypeAnnotation = assertMixedTypeAnnotation; +exports.assertModuleDeclaration = assertModuleDeclaration; +exports.assertModuleExpression = assertModuleExpression; +exports.assertModuleSpecifier = assertModuleSpecifier; +exports.assertNewExpression = assertNewExpression; +exports.assertNoop = assertNoop; +exports.assertNullLiteral = assertNullLiteral; +exports.assertNullLiteralTypeAnnotation = assertNullLiteralTypeAnnotation; +exports.assertNullableTypeAnnotation = assertNullableTypeAnnotation; +exports.assertNumberLiteral = assertNumberLiteral; +exports.assertNumberLiteralTypeAnnotation = assertNumberLiteralTypeAnnotation; +exports.assertNumberTypeAnnotation = assertNumberTypeAnnotation; +exports.assertNumericLiteral = assertNumericLiteral; +exports.assertObjectExpression = assertObjectExpression; +exports.assertObjectMember = assertObjectMember; +exports.assertObjectMethod = assertObjectMethod; +exports.assertObjectPattern = assertObjectPattern; +exports.assertObjectProperty = assertObjectProperty; +exports.assertObjectTypeAnnotation = assertObjectTypeAnnotation; +exports.assertObjectTypeCallProperty = assertObjectTypeCallProperty; +exports.assertObjectTypeIndexer = assertObjectTypeIndexer; +exports.assertObjectTypeInternalSlot = assertObjectTypeInternalSlot; +exports.assertObjectTypeProperty = assertObjectTypeProperty; +exports.assertObjectTypeSpreadProperty = assertObjectTypeSpreadProperty; +exports.assertOpaqueType = assertOpaqueType; +exports.assertOptionalCallExpression = assertOptionalCallExpression; +exports.assertOptionalIndexedAccessType = assertOptionalIndexedAccessType; +exports.assertOptionalMemberExpression = assertOptionalMemberExpression; +exports.assertParenthesizedExpression = assertParenthesizedExpression; +exports.assertPattern = assertPattern; +exports.assertPatternLike = assertPatternLike; +exports.assertPipelineBareFunction = assertPipelineBareFunction; +exports.assertPipelinePrimaryTopicReference = assertPipelinePrimaryTopicReference; +exports.assertPipelineTopicExpression = assertPipelineTopicExpression; +exports.assertPlaceholder = assertPlaceholder; +exports.assertPrivate = assertPrivate; +exports.assertPrivateName = assertPrivateName; +exports.assertProgram = assertProgram; +exports.assertProperty = assertProperty; +exports.assertPureish = assertPureish; +exports.assertQualifiedTypeIdentifier = assertQualifiedTypeIdentifier; +exports.assertRecordExpression = assertRecordExpression; +exports.assertRegExpLiteral = assertRegExpLiteral; +exports.assertRegexLiteral = assertRegexLiteral; +exports.assertRestElement = assertRestElement; +exports.assertRestProperty = assertRestProperty; +exports.assertReturnStatement = assertReturnStatement; +exports.assertScopable = assertScopable; +exports.assertSequenceExpression = assertSequenceExpression; +exports.assertSpreadElement = assertSpreadElement; +exports.assertSpreadProperty = assertSpreadProperty; +exports.assertStandardized = assertStandardized; +exports.assertStatement = assertStatement; +exports.assertStaticBlock = assertStaticBlock; +exports.assertStringLiteral = assertStringLiteral; +exports.assertStringLiteralTypeAnnotation = assertStringLiteralTypeAnnotation; +exports.assertStringTypeAnnotation = assertStringTypeAnnotation; +exports.assertSuper = assertSuper; +exports.assertSwitchCase = assertSwitchCase; +exports.assertSwitchStatement = assertSwitchStatement; +exports.assertSymbolTypeAnnotation = assertSymbolTypeAnnotation; +exports.assertTSAnyKeyword = assertTSAnyKeyword; +exports.assertTSArrayType = assertTSArrayType; +exports.assertTSAsExpression = assertTSAsExpression; +exports.assertTSBaseType = assertTSBaseType; +exports.assertTSBigIntKeyword = assertTSBigIntKeyword; +exports.assertTSBooleanKeyword = assertTSBooleanKeyword; +exports.assertTSCallSignatureDeclaration = assertTSCallSignatureDeclaration; +exports.assertTSConditionalType = assertTSConditionalType; +exports.assertTSConstructSignatureDeclaration = assertTSConstructSignatureDeclaration; +exports.assertTSConstructorType = assertTSConstructorType; +exports.assertTSDeclareFunction = assertTSDeclareFunction; +exports.assertTSDeclareMethod = assertTSDeclareMethod; +exports.assertTSEntityName = assertTSEntityName; +exports.assertTSEnumDeclaration = assertTSEnumDeclaration; +exports.assertTSEnumMember = assertTSEnumMember; +exports.assertTSExportAssignment = assertTSExportAssignment; +exports.assertTSExpressionWithTypeArguments = assertTSExpressionWithTypeArguments; +exports.assertTSExternalModuleReference = assertTSExternalModuleReference; +exports.assertTSFunctionType = assertTSFunctionType; +exports.assertTSImportEqualsDeclaration = assertTSImportEqualsDeclaration; +exports.assertTSImportType = assertTSImportType; +exports.assertTSIndexSignature = assertTSIndexSignature; +exports.assertTSIndexedAccessType = assertTSIndexedAccessType; +exports.assertTSInferType = assertTSInferType; +exports.assertTSInterfaceBody = assertTSInterfaceBody; +exports.assertTSInterfaceDeclaration = assertTSInterfaceDeclaration; +exports.assertTSIntersectionType = assertTSIntersectionType; +exports.assertTSIntrinsicKeyword = assertTSIntrinsicKeyword; +exports.assertTSLiteralType = assertTSLiteralType; +exports.assertTSMappedType = assertTSMappedType; +exports.assertTSMethodSignature = assertTSMethodSignature; +exports.assertTSModuleBlock = assertTSModuleBlock; +exports.assertTSModuleDeclaration = assertTSModuleDeclaration; +exports.assertTSNamedTupleMember = assertTSNamedTupleMember; +exports.assertTSNamespaceExportDeclaration = assertTSNamespaceExportDeclaration; +exports.assertTSNeverKeyword = assertTSNeverKeyword; +exports.assertTSNonNullExpression = assertTSNonNullExpression; +exports.assertTSNullKeyword = assertTSNullKeyword; +exports.assertTSNumberKeyword = assertTSNumberKeyword; +exports.assertTSObjectKeyword = assertTSObjectKeyword; +exports.assertTSOptionalType = assertTSOptionalType; +exports.assertTSParameterProperty = assertTSParameterProperty; +exports.assertTSParenthesizedType = assertTSParenthesizedType; +exports.assertTSPropertySignature = assertTSPropertySignature; +exports.assertTSQualifiedName = assertTSQualifiedName; +exports.assertTSRestType = assertTSRestType; +exports.assertTSStringKeyword = assertTSStringKeyword; +exports.assertTSSymbolKeyword = assertTSSymbolKeyword; +exports.assertTSThisType = assertTSThisType; +exports.assertTSTupleType = assertTSTupleType; +exports.assertTSType = assertTSType; +exports.assertTSTypeAliasDeclaration = assertTSTypeAliasDeclaration; +exports.assertTSTypeAnnotation = assertTSTypeAnnotation; +exports.assertTSTypeAssertion = assertTSTypeAssertion; +exports.assertTSTypeElement = assertTSTypeElement; +exports.assertTSTypeLiteral = assertTSTypeLiteral; +exports.assertTSTypeOperator = assertTSTypeOperator; +exports.assertTSTypeParameter = assertTSTypeParameter; +exports.assertTSTypeParameterDeclaration = assertTSTypeParameterDeclaration; +exports.assertTSTypeParameterInstantiation = assertTSTypeParameterInstantiation; +exports.assertTSTypePredicate = assertTSTypePredicate; +exports.assertTSTypeQuery = assertTSTypeQuery; +exports.assertTSTypeReference = assertTSTypeReference; +exports.assertTSUndefinedKeyword = assertTSUndefinedKeyword; +exports.assertTSUnionType = assertTSUnionType; +exports.assertTSUnknownKeyword = assertTSUnknownKeyword; +exports.assertTSVoidKeyword = assertTSVoidKeyword; +exports.assertTaggedTemplateExpression = assertTaggedTemplateExpression; +exports.assertTemplateElement = assertTemplateElement; +exports.assertTemplateLiteral = assertTemplateLiteral; +exports.assertTerminatorless = assertTerminatorless; +exports.assertThisExpression = assertThisExpression; +exports.assertThisTypeAnnotation = assertThisTypeAnnotation; +exports.assertThrowStatement = assertThrowStatement; +exports.assertTopicReference = assertTopicReference; +exports.assertTryStatement = assertTryStatement; +exports.assertTupleExpression = assertTupleExpression; +exports.assertTupleTypeAnnotation = assertTupleTypeAnnotation; +exports.assertTypeAlias = assertTypeAlias; +exports.assertTypeAnnotation = assertTypeAnnotation; +exports.assertTypeCastExpression = assertTypeCastExpression; +exports.assertTypeParameter = assertTypeParameter; +exports.assertTypeParameterDeclaration = assertTypeParameterDeclaration; +exports.assertTypeParameterInstantiation = assertTypeParameterInstantiation; +exports.assertTypeScript = assertTypeScript; +exports.assertTypeofTypeAnnotation = assertTypeofTypeAnnotation; +exports.assertUnaryExpression = assertUnaryExpression; +exports.assertUnaryLike = assertUnaryLike; +exports.assertUnionTypeAnnotation = assertUnionTypeAnnotation; +exports.assertUpdateExpression = assertUpdateExpression; +exports.assertUserWhitespacable = assertUserWhitespacable; +exports.assertV8IntrinsicIdentifier = assertV8IntrinsicIdentifier; +exports.assertVariableDeclaration = assertVariableDeclaration; +exports.assertVariableDeclarator = assertVariableDeclarator; +exports.assertVariance = assertVariance; +exports.assertVoidTypeAnnotation = assertVoidTypeAnnotation; +exports.assertWhile = assertWhile; +exports.assertWhileStatement = assertWhileStatement; +exports.assertWithStatement = assertWithStatement; +exports.assertYieldExpression = assertYieldExpression; + +var _is = require("../../validators/is"); + +function assert(type, node, opts) { + if (!(0, _is.default)(type, node, opts)) { + throw new Error(`Expected type "${type}" with option ${JSON.stringify(opts)}, ` + `but instead got "${node.type}".`); + } +} + +function assertArrayExpression(node, opts) { + assert("ArrayExpression", node, opts); +} + +function assertAssignmentExpression(node, opts) { + assert("AssignmentExpression", node, opts); +} + +function assertBinaryExpression(node, opts) { + assert("BinaryExpression", node, opts); +} + +function assertInterpreterDirective(node, opts) { + assert("InterpreterDirective", node, opts); +} + +function assertDirective(node, opts) { + assert("Directive", node, opts); +} + +function assertDirectiveLiteral(node, opts) { + assert("DirectiveLiteral", node, opts); +} + +function assertBlockStatement(node, opts) { + assert("BlockStatement", node, opts); +} + +function assertBreakStatement(node, opts) { + assert("BreakStatement", node, opts); +} + +function assertCallExpression(node, opts) { + assert("CallExpression", node, opts); +} + +function assertCatchClause(node, opts) { + assert("CatchClause", node, opts); +} + +function assertConditionalExpression(node, opts) { + assert("ConditionalExpression", node, opts); +} + +function assertContinueStatement(node, opts) { + assert("ContinueStatement", node, opts); +} + +function assertDebuggerStatement(node, opts) { + assert("DebuggerStatement", node, opts); +} + +function assertDoWhileStatement(node, opts) { + assert("DoWhileStatement", node, opts); +} + +function assertEmptyStatement(node, opts) { + assert("EmptyStatement", node, opts); +} + +function assertExpressionStatement(node, opts) { + assert("ExpressionStatement", node, opts); +} + +function assertFile(node, opts) { + assert("File", node, opts); +} + +function assertForInStatement(node, opts) { + assert("ForInStatement", node, opts); +} + +function assertForStatement(node, opts) { + assert("ForStatement", node, opts); +} + +function assertFunctionDeclaration(node, opts) { + assert("FunctionDeclaration", node, opts); +} + +function assertFunctionExpression(node, opts) { + assert("FunctionExpression", node, opts); +} + +function assertIdentifier(node, opts) { + assert("Identifier", node, opts); +} + +function assertIfStatement(node, opts) { + assert("IfStatement", node, opts); +} + +function assertLabeledStatement(node, opts) { + assert("LabeledStatement", node, opts); +} + +function assertStringLiteral(node, opts) { + assert("StringLiteral", node, opts); +} + +function assertNumericLiteral(node, opts) { + assert("NumericLiteral", node, opts); +} + +function assertNullLiteral(node, opts) { + assert("NullLiteral", node, opts); +} + +function assertBooleanLiteral(node, opts) { + assert("BooleanLiteral", node, opts); +} + +function assertRegExpLiteral(node, opts) { + assert("RegExpLiteral", node, opts); +} + +function assertLogicalExpression(node, opts) { + assert("LogicalExpression", node, opts); +} + +function assertMemberExpression(node, opts) { + assert("MemberExpression", node, opts); +} + +function assertNewExpression(node, opts) { + assert("NewExpression", node, opts); +} + +function assertProgram(node, opts) { + assert("Program", node, opts); +} + +function assertObjectExpression(node, opts) { + assert("ObjectExpression", node, opts); +} + +function assertObjectMethod(node, opts) { + assert("ObjectMethod", node, opts); +} + +function assertObjectProperty(node, opts) { + assert("ObjectProperty", node, opts); +} + +function assertRestElement(node, opts) { + assert("RestElement", node, opts); +} + +function assertReturnStatement(node, opts) { + assert("ReturnStatement", node, opts); +} + +function assertSequenceExpression(node, opts) { + assert("SequenceExpression", node, opts); +} + +function assertParenthesizedExpression(node, opts) { + assert("ParenthesizedExpression", node, opts); +} + +function assertSwitchCase(node, opts) { + assert("SwitchCase", node, opts); +} + +function assertSwitchStatement(node, opts) { + assert("SwitchStatement", node, opts); +} + +function assertThisExpression(node, opts) { + assert("ThisExpression", node, opts); +} + +function assertThrowStatement(node, opts) { + assert("ThrowStatement", node, opts); +} + +function assertTryStatement(node, opts) { + assert("TryStatement", node, opts); +} + +function assertUnaryExpression(node, opts) { + assert("UnaryExpression", node, opts); +} + +function assertUpdateExpression(node, opts) { + assert("UpdateExpression", node, opts); +} + +function assertVariableDeclaration(node, opts) { + assert("VariableDeclaration", node, opts); +} + +function assertVariableDeclarator(node, opts) { + assert("VariableDeclarator", node, opts); +} + +function assertWhileStatement(node, opts) { + assert("WhileStatement", node, opts); +} + +function assertWithStatement(node, opts) { + assert("WithStatement", node, opts); +} + +function assertAssignmentPattern(node, opts) { + assert("AssignmentPattern", node, opts); +} + +function assertArrayPattern(node, opts) { + assert("ArrayPattern", node, opts); +} + +function assertArrowFunctionExpression(node, opts) { + assert("ArrowFunctionExpression", node, opts); +} + +function assertClassBody(node, opts) { + assert("ClassBody", node, opts); +} + +function assertClassExpression(node, opts) { + assert("ClassExpression", node, opts); +} + +function assertClassDeclaration(node, opts) { + assert("ClassDeclaration", node, opts); +} + +function assertExportAllDeclaration(node, opts) { + assert("ExportAllDeclaration", node, opts); +} + +function assertExportDefaultDeclaration(node, opts) { + assert("ExportDefaultDeclaration", node, opts); +} + +function assertExportNamedDeclaration(node, opts) { + assert("ExportNamedDeclaration", node, opts); +} + +function assertExportSpecifier(node, opts) { + assert("ExportSpecifier", node, opts); +} + +function assertForOfStatement(node, opts) { + assert("ForOfStatement", node, opts); +} + +function assertImportDeclaration(node, opts) { + assert("ImportDeclaration", node, opts); +} + +function assertImportDefaultSpecifier(node, opts) { + assert("ImportDefaultSpecifier", node, opts); +} + +function assertImportNamespaceSpecifier(node, opts) { + assert("ImportNamespaceSpecifier", node, opts); +} + +function assertImportSpecifier(node, opts) { + assert("ImportSpecifier", node, opts); +} + +function assertMetaProperty(node, opts) { + assert("MetaProperty", node, opts); +} + +function assertClassMethod(node, opts) { + assert("ClassMethod", node, opts); +} + +function assertObjectPattern(node, opts) { + assert("ObjectPattern", node, opts); +} + +function assertSpreadElement(node, opts) { + assert("SpreadElement", node, opts); +} + +function assertSuper(node, opts) { + assert("Super", node, opts); +} + +function assertTaggedTemplateExpression(node, opts) { + assert("TaggedTemplateExpression", node, opts); +} + +function assertTemplateElement(node, opts) { + assert("TemplateElement", node, opts); +} + +function assertTemplateLiteral(node, opts) { + assert("TemplateLiteral", node, opts); +} + +function assertYieldExpression(node, opts) { + assert("YieldExpression", node, opts); +} + +function assertAwaitExpression(node, opts) { + assert("AwaitExpression", node, opts); +} + +function assertImport(node, opts) { + assert("Import", node, opts); +} + +function assertBigIntLiteral(node, opts) { + assert("BigIntLiteral", node, opts); +} + +function assertExportNamespaceSpecifier(node, opts) { + assert("ExportNamespaceSpecifier", node, opts); +} + +function assertOptionalMemberExpression(node, opts) { + assert("OptionalMemberExpression", node, opts); +} + +function assertOptionalCallExpression(node, opts) { + assert("OptionalCallExpression", node, opts); +} + +function assertClassProperty(node, opts) { + assert("ClassProperty", node, opts); +} + +function assertClassAccessorProperty(node, opts) { + assert("ClassAccessorProperty", node, opts); +} + +function assertClassPrivateProperty(node, opts) { + assert("ClassPrivateProperty", node, opts); +} + +function assertClassPrivateMethod(node, opts) { + assert("ClassPrivateMethod", node, opts); +} + +function assertPrivateName(node, opts) { + assert("PrivateName", node, opts); +} + +function assertStaticBlock(node, opts) { + assert("StaticBlock", node, opts); +} + +function assertAnyTypeAnnotation(node, opts) { + assert("AnyTypeAnnotation", node, opts); +} + +function assertArrayTypeAnnotation(node, opts) { + assert("ArrayTypeAnnotation", node, opts); +} + +function assertBooleanTypeAnnotation(node, opts) { + assert("BooleanTypeAnnotation", node, opts); +} + +function assertBooleanLiteralTypeAnnotation(node, opts) { + assert("BooleanLiteralTypeAnnotation", node, opts); +} + +function assertNullLiteralTypeAnnotation(node, opts) { + assert("NullLiteralTypeAnnotation", node, opts); +} + +function assertClassImplements(node, opts) { + assert("ClassImplements", node, opts); +} + +function assertDeclareClass(node, opts) { + assert("DeclareClass", node, opts); +} + +function assertDeclareFunction(node, opts) { + assert("DeclareFunction", node, opts); +} + +function assertDeclareInterface(node, opts) { + assert("DeclareInterface", node, opts); +} + +function assertDeclareModule(node, opts) { + assert("DeclareModule", node, opts); +} + +function assertDeclareModuleExports(node, opts) { + assert("DeclareModuleExports", node, opts); +} + +function assertDeclareTypeAlias(node, opts) { + assert("DeclareTypeAlias", node, opts); +} + +function assertDeclareOpaqueType(node, opts) { + assert("DeclareOpaqueType", node, opts); +} + +function assertDeclareVariable(node, opts) { + assert("DeclareVariable", node, opts); +} + +function assertDeclareExportDeclaration(node, opts) { + assert("DeclareExportDeclaration", node, opts); +} + +function assertDeclareExportAllDeclaration(node, opts) { + assert("DeclareExportAllDeclaration", node, opts); +} + +function assertDeclaredPredicate(node, opts) { + assert("DeclaredPredicate", node, opts); +} + +function assertExistsTypeAnnotation(node, opts) { + assert("ExistsTypeAnnotation", node, opts); +} + +function assertFunctionTypeAnnotation(node, opts) { + assert("FunctionTypeAnnotation", node, opts); +} + +function assertFunctionTypeParam(node, opts) { + assert("FunctionTypeParam", node, opts); +} + +function assertGenericTypeAnnotation(node, opts) { + assert("GenericTypeAnnotation", node, opts); +} + +function assertInferredPredicate(node, opts) { + assert("InferredPredicate", node, opts); +} + +function assertInterfaceExtends(node, opts) { + assert("InterfaceExtends", node, opts); +} + +function assertInterfaceDeclaration(node, opts) { + assert("InterfaceDeclaration", node, opts); +} + +function assertInterfaceTypeAnnotation(node, opts) { + assert("InterfaceTypeAnnotation", node, opts); +} + +function assertIntersectionTypeAnnotation(node, opts) { + assert("IntersectionTypeAnnotation", node, opts); +} + +function assertMixedTypeAnnotation(node, opts) { + assert("MixedTypeAnnotation", node, opts); +} + +function assertEmptyTypeAnnotation(node, opts) { + assert("EmptyTypeAnnotation", node, opts); +} + +function assertNullableTypeAnnotation(node, opts) { + assert("NullableTypeAnnotation", node, opts); +} + +function assertNumberLiteralTypeAnnotation(node, opts) { + assert("NumberLiteralTypeAnnotation", node, opts); +} + +function assertNumberTypeAnnotation(node, opts) { + assert("NumberTypeAnnotation", node, opts); +} + +function assertObjectTypeAnnotation(node, opts) { + assert("ObjectTypeAnnotation", node, opts); +} + +function assertObjectTypeInternalSlot(node, opts) { + assert("ObjectTypeInternalSlot", node, opts); +} + +function assertObjectTypeCallProperty(node, opts) { + assert("ObjectTypeCallProperty", node, opts); +} + +function assertObjectTypeIndexer(node, opts) { + assert("ObjectTypeIndexer", node, opts); +} + +function assertObjectTypeProperty(node, opts) { + assert("ObjectTypeProperty", node, opts); +} + +function assertObjectTypeSpreadProperty(node, opts) { + assert("ObjectTypeSpreadProperty", node, opts); +} + +function assertOpaqueType(node, opts) { + assert("OpaqueType", node, opts); +} + +function assertQualifiedTypeIdentifier(node, opts) { + assert("QualifiedTypeIdentifier", node, opts); +} + +function assertStringLiteralTypeAnnotation(node, opts) { + assert("StringLiteralTypeAnnotation", node, opts); +} + +function assertStringTypeAnnotation(node, opts) { + assert("StringTypeAnnotation", node, opts); +} + +function assertSymbolTypeAnnotation(node, opts) { + assert("SymbolTypeAnnotation", node, opts); +} + +function assertThisTypeAnnotation(node, opts) { + assert("ThisTypeAnnotation", node, opts); +} + +function assertTupleTypeAnnotation(node, opts) { + assert("TupleTypeAnnotation", node, opts); +} + +function assertTypeofTypeAnnotation(node, opts) { + assert("TypeofTypeAnnotation", node, opts); +} + +function assertTypeAlias(node, opts) { + assert("TypeAlias", node, opts); +} + +function assertTypeAnnotation(node, opts) { + assert("TypeAnnotation", node, opts); +} + +function assertTypeCastExpression(node, opts) { + assert("TypeCastExpression", node, opts); +} + +function assertTypeParameter(node, opts) { + assert("TypeParameter", node, opts); +} + +function assertTypeParameterDeclaration(node, opts) { + assert("TypeParameterDeclaration", node, opts); +} + +function assertTypeParameterInstantiation(node, opts) { + assert("TypeParameterInstantiation", node, opts); +} + +function assertUnionTypeAnnotation(node, opts) { + assert("UnionTypeAnnotation", node, opts); +} + +function assertVariance(node, opts) { + assert("Variance", node, opts); +} + +function assertVoidTypeAnnotation(node, opts) { + assert("VoidTypeAnnotation", node, opts); +} + +function assertEnumDeclaration(node, opts) { + assert("EnumDeclaration", node, opts); +} + +function assertEnumBooleanBody(node, opts) { + assert("EnumBooleanBody", node, opts); +} + +function assertEnumNumberBody(node, opts) { + assert("EnumNumberBody", node, opts); +} + +function assertEnumStringBody(node, opts) { + assert("EnumStringBody", node, opts); +} + +function assertEnumSymbolBody(node, opts) { + assert("EnumSymbolBody", node, opts); +} + +function assertEnumBooleanMember(node, opts) { + assert("EnumBooleanMember", node, opts); +} + +function assertEnumNumberMember(node, opts) { + assert("EnumNumberMember", node, opts); +} + +function assertEnumStringMember(node, opts) { + assert("EnumStringMember", node, opts); +} + +function assertEnumDefaultedMember(node, opts) { + assert("EnumDefaultedMember", node, opts); +} + +function assertIndexedAccessType(node, opts) { + assert("IndexedAccessType", node, opts); +} + +function assertOptionalIndexedAccessType(node, opts) { + assert("OptionalIndexedAccessType", node, opts); +} + +function assertJSXAttribute(node, opts) { + assert("JSXAttribute", node, opts); +} + +function assertJSXClosingElement(node, opts) { + assert("JSXClosingElement", node, opts); +} + +function assertJSXElement(node, opts) { + assert("JSXElement", node, opts); +} + +function assertJSXEmptyExpression(node, opts) { + assert("JSXEmptyExpression", node, opts); +} + +function assertJSXExpressionContainer(node, opts) { + assert("JSXExpressionContainer", node, opts); +} + +function assertJSXSpreadChild(node, opts) { + assert("JSXSpreadChild", node, opts); +} + +function assertJSXIdentifier(node, opts) { + assert("JSXIdentifier", node, opts); +} + +function assertJSXMemberExpression(node, opts) { + assert("JSXMemberExpression", node, opts); +} + +function assertJSXNamespacedName(node, opts) { + assert("JSXNamespacedName", node, opts); +} + +function assertJSXOpeningElement(node, opts) { + assert("JSXOpeningElement", node, opts); +} + +function assertJSXSpreadAttribute(node, opts) { + assert("JSXSpreadAttribute", node, opts); +} + +function assertJSXText(node, opts) { + assert("JSXText", node, opts); +} + +function assertJSXFragment(node, opts) { + assert("JSXFragment", node, opts); +} + +function assertJSXOpeningFragment(node, opts) { + assert("JSXOpeningFragment", node, opts); +} + +function assertJSXClosingFragment(node, opts) { + assert("JSXClosingFragment", node, opts); +} + +function assertNoop(node, opts) { + assert("Noop", node, opts); +} + +function assertPlaceholder(node, opts) { + assert("Placeholder", node, opts); +} + +function assertV8IntrinsicIdentifier(node, opts) { + assert("V8IntrinsicIdentifier", node, opts); +} + +function assertArgumentPlaceholder(node, opts) { + assert("ArgumentPlaceholder", node, opts); +} + +function assertBindExpression(node, opts) { + assert("BindExpression", node, opts); +} + +function assertImportAttribute(node, opts) { + assert("ImportAttribute", node, opts); +} + +function assertDecorator(node, opts) { + assert("Decorator", node, opts); +} + +function assertDoExpression(node, opts) { + assert("DoExpression", node, opts); +} + +function assertExportDefaultSpecifier(node, opts) { + assert("ExportDefaultSpecifier", node, opts); +} + +function assertRecordExpression(node, opts) { + assert("RecordExpression", node, opts); +} + +function assertTupleExpression(node, opts) { + assert("TupleExpression", node, opts); +} + +function assertDecimalLiteral(node, opts) { + assert("DecimalLiteral", node, opts); +} + +function assertModuleExpression(node, opts) { + assert("ModuleExpression", node, opts); +} + +function assertTopicReference(node, opts) { + assert("TopicReference", node, opts); +} + +function assertPipelineTopicExpression(node, opts) { + assert("PipelineTopicExpression", node, opts); +} + +function assertPipelineBareFunction(node, opts) { + assert("PipelineBareFunction", node, opts); +} + +function assertPipelinePrimaryTopicReference(node, opts) { + assert("PipelinePrimaryTopicReference", node, opts); +} + +function assertTSParameterProperty(node, opts) { + assert("TSParameterProperty", node, opts); +} + +function assertTSDeclareFunction(node, opts) { + assert("TSDeclareFunction", node, opts); +} + +function assertTSDeclareMethod(node, opts) { + assert("TSDeclareMethod", node, opts); +} + +function assertTSQualifiedName(node, opts) { + assert("TSQualifiedName", node, opts); +} + +function assertTSCallSignatureDeclaration(node, opts) { + assert("TSCallSignatureDeclaration", node, opts); +} + +function assertTSConstructSignatureDeclaration(node, opts) { + assert("TSConstructSignatureDeclaration", node, opts); +} + +function assertTSPropertySignature(node, opts) { + assert("TSPropertySignature", node, opts); +} + +function assertTSMethodSignature(node, opts) { + assert("TSMethodSignature", node, opts); +} + +function assertTSIndexSignature(node, opts) { + assert("TSIndexSignature", node, opts); +} + +function assertTSAnyKeyword(node, opts) { + assert("TSAnyKeyword", node, opts); +} + +function assertTSBooleanKeyword(node, opts) { + assert("TSBooleanKeyword", node, opts); +} + +function assertTSBigIntKeyword(node, opts) { + assert("TSBigIntKeyword", node, opts); +} + +function assertTSIntrinsicKeyword(node, opts) { + assert("TSIntrinsicKeyword", node, opts); +} + +function assertTSNeverKeyword(node, opts) { + assert("TSNeverKeyword", node, opts); +} + +function assertTSNullKeyword(node, opts) { + assert("TSNullKeyword", node, opts); +} + +function assertTSNumberKeyword(node, opts) { + assert("TSNumberKeyword", node, opts); +} + +function assertTSObjectKeyword(node, opts) { + assert("TSObjectKeyword", node, opts); +} + +function assertTSStringKeyword(node, opts) { + assert("TSStringKeyword", node, opts); +} + +function assertTSSymbolKeyword(node, opts) { + assert("TSSymbolKeyword", node, opts); +} + +function assertTSUndefinedKeyword(node, opts) { + assert("TSUndefinedKeyword", node, opts); +} + +function assertTSUnknownKeyword(node, opts) { + assert("TSUnknownKeyword", node, opts); +} + +function assertTSVoidKeyword(node, opts) { + assert("TSVoidKeyword", node, opts); +} + +function assertTSThisType(node, opts) { + assert("TSThisType", node, opts); +} + +function assertTSFunctionType(node, opts) { + assert("TSFunctionType", node, opts); +} + +function assertTSConstructorType(node, opts) { + assert("TSConstructorType", node, opts); +} + +function assertTSTypeReference(node, opts) { + assert("TSTypeReference", node, opts); +} + +function assertTSTypePredicate(node, opts) { + assert("TSTypePredicate", node, opts); +} + +function assertTSTypeQuery(node, opts) { + assert("TSTypeQuery", node, opts); +} + +function assertTSTypeLiteral(node, opts) { + assert("TSTypeLiteral", node, opts); +} + +function assertTSArrayType(node, opts) { + assert("TSArrayType", node, opts); +} + +function assertTSTupleType(node, opts) { + assert("TSTupleType", node, opts); +} + +function assertTSOptionalType(node, opts) { + assert("TSOptionalType", node, opts); +} + +function assertTSRestType(node, opts) { + assert("TSRestType", node, opts); +} + +function assertTSNamedTupleMember(node, opts) { + assert("TSNamedTupleMember", node, opts); +} + +function assertTSUnionType(node, opts) { + assert("TSUnionType", node, opts); +} + +function assertTSIntersectionType(node, opts) { + assert("TSIntersectionType", node, opts); +} + +function assertTSConditionalType(node, opts) { + assert("TSConditionalType", node, opts); +} + +function assertTSInferType(node, opts) { + assert("TSInferType", node, opts); +} + +function assertTSParenthesizedType(node, opts) { + assert("TSParenthesizedType", node, opts); +} + +function assertTSTypeOperator(node, opts) { + assert("TSTypeOperator", node, opts); +} + +function assertTSIndexedAccessType(node, opts) { + assert("TSIndexedAccessType", node, opts); +} + +function assertTSMappedType(node, opts) { + assert("TSMappedType", node, opts); +} + +function assertTSLiteralType(node, opts) { + assert("TSLiteralType", node, opts); +} + +function assertTSExpressionWithTypeArguments(node, opts) { + assert("TSExpressionWithTypeArguments", node, opts); +} + +function assertTSInterfaceDeclaration(node, opts) { + assert("TSInterfaceDeclaration", node, opts); +} + +function assertTSInterfaceBody(node, opts) { + assert("TSInterfaceBody", node, opts); +} + +function assertTSTypeAliasDeclaration(node, opts) { + assert("TSTypeAliasDeclaration", node, opts); +} + +function assertTSAsExpression(node, opts) { + assert("TSAsExpression", node, opts); +} + +function assertTSTypeAssertion(node, opts) { + assert("TSTypeAssertion", node, opts); +} + +function assertTSEnumDeclaration(node, opts) { + assert("TSEnumDeclaration", node, opts); +} + +function assertTSEnumMember(node, opts) { + assert("TSEnumMember", node, opts); +} + +function assertTSModuleDeclaration(node, opts) { + assert("TSModuleDeclaration", node, opts); +} + +function assertTSModuleBlock(node, opts) { + assert("TSModuleBlock", node, opts); +} + +function assertTSImportType(node, opts) { + assert("TSImportType", node, opts); +} + +function assertTSImportEqualsDeclaration(node, opts) { + assert("TSImportEqualsDeclaration", node, opts); +} + +function assertTSExternalModuleReference(node, opts) { + assert("TSExternalModuleReference", node, opts); +} + +function assertTSNonNullExpression(node, opts) { + assert("TSNonNullExpression", node, opts); +} + +function assertTSExportAssignment(node, opts) { + assert("TSExportAssignment", node, opts); +} + +function assertTSNamespaceExportDeclaration(node, opts) { + assert("TSNamespaceExportDeclaration", node, opts); +} + +function assertTSTypeAnnotation(node, opts) { + assert("TSTypeAnnotation", node, opts); +} + +function assertTSTypeParameterInstantiation(node, opts) { + assert("TSTypeParameterInstantiation", node, opts); +} + +function assertTSTypeParameterDeclaration(node, opts) { + assert("TSTypeParameterDeclaration", node, opts); +} + +function assertTSTypeParameter(node, opts) { + assert("TSTypeParameter", node, opts); +} + +function assertStandardized(node, opts) { + assert("Standardized", node, opts); +} + +function assertExpression(node, opts) { + assert("Expression", node, opts); +} + +function assertBinary(node, opts) { + assert("Binary", node, opts); +} + +function assertScopable(node, opts) { + assert("Scopable", node, opts); +} + +function assertBlockParent(node, opts) { + assert("BlockParent", node, opts); +} + +function assertBlock(node, opts) { + assert("Block", node, opts); +} + +function assertStatement(node, opts) { + assert("Statement", node, opts); +} + +function assertTerminatorless(node, opts) { + assert("Terminatorless", node, opts); +} + +function assertCompletionStatement(node, opts) { + assert("CompletionStatement", node, opts); +} + +function assertConditional(node, opts) { + assert("Conditional", node, opts); +} + +function assertLoop(node, opts) { + assert("Loop", node, opts); +} + +function assertWhile(node, opts) { + assert("While", node, opts); +} + +function assertExpressionWrapper(node, opts) { + assert("ExpressionWrapper", node, opts); +} + +function assertFor(node, opts) { + assert("For", node, opts); +} + +function assertForXStatement(node, opts) { + assert("ForXStatement", node, opts); +} + +function assertFunction(node, opts) { + assert("Function", node, opts); +} + +function assertFunctionParent(node, opts) { + assert("FunctionParent", node, opts); +} + +function assertPureish(node, opts) { + assert("Pureish", node, opts); +} + +function assertDeclaration(node, opts) { + assert("Declaration", node, opts); +} + +function assertPatternLike(node, opts) { + assert("PatternLike", node, opts); +} + +function assertLVal(node, opts) { + assert("LVal", node, opts); +} + +function assertTSEntityName(node, opts) { + assert("TSEntityName", node, opts); +} + +function assertLiteral(node, opts) { + assert("Literal", node, opts); +} + +function assertImmutable(node, opts) { + assert("Immutable", node, opts); +} + +function assertUserWhitespacable(node, opts) { + assert("UserWhitespacable", node, opts); +} + +function assertMethod(node, opts) { + assert("Method", node, opts); +} + +function assertObjectMember(node, opts) { + assert("ObjectMember", node, opts); +} + +function assertProperty(node, opts) { + assert("Property", node, opts); +} + +function assertUnaryLike(node, opts) { + assert("UnaryLike", node, opts); +} + +function assertPattern(node, opts) { + assert("Pattern", node, opts); +} + +function assertClass(node, opts) { + assert("Class", node, opts); +} + +function assertModuleDeclaration(node, opts) { + assert("ModuleDeclaration", node, opts); +} + +function assertExportDeclaration(node, opts) { + assert("ExportDeclaration", node, opts); +} + +function assertModuleSpecifier(node, opts) { + assert("ModuleSpecifier", node, opts); +} + +function assertAccessor(node, opts) { + assert("Accessor", node, opts); +} + +function assertPrivate(node, opts) { + assert("Private", node, opts); +} + +function assertFlow(node, opts) { + assert("Flow", node, opts); +} + +function assertFlowType(node, opts) { + assert("FlowType", node, opts); +} + +function assertFlowBaseAnnotation(node, opts) { + assert("FlowBaseAnnotation", node, opts); +} + +function assertFlowDeclaration(node, opts) { + assert("FlowDeclaration", node, opts); +} + +function assertFlowPredicate(node, opts) { + assert("FlowPredicate", node, opts); +} + +function assertEnumBody(node, opts) { + assert("EnumBody", node, opts); +} + +function assertEnumMember(node, opts) { + assert("EnumMember", node, opts); +} + +function assertJSX(node, opts) { + assert("JSX", node, opts); +} + +function assertMiscellaneous(node, opts) { + assert("Miscellaneous", node, opts); +} + +function assertTypeScript(node, opts) { + assert("TypeScript", node, opts); +} + +function assertTSTypeElement(node, opts) { + assert("TSTypeElement", node, opts); +} + +function assertTSType(node, opts) { + assert("TSType", node, opts); +} + +function assertTSBaseType(node, opts) { + assert("TSBaseType", node, opts); +} + +function assertNumberLiteral(node, opts) { + console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); + assert("NumberLiteral", node, opts); +} + +function assertRegexLiteral(node, opts) { + console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); + assert("RegexLiteral", node, opts); +} + +function assertRestProperty(node, opts) { + console.trace("The node type RestProperty has been renamed to RestElement"); + assert("RestProperty", node, opts); +} + +function assertSpreadProperty(node, opts) { + console.trace("The node type SpreadProperty has been renamed to SpreadElement"); + assert("SpreadProperty", node, opts); +} \ No newline at end of file diff --git a/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/types/lib/ast-types/generated/index.js b/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/types/lib/ast-types/generated/index.js new file mode 100644 index 000000000..e69de29bb diff --git a/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/types/lib/builders/generated/index.js b/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/types/lib/builders/generated/index.js new file mode 100644 index 000000000..99851ee0b --- /dev/null +++ b/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/types/lib/builders/generated/index.js @@ -0,0 +1,1266 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.anyTypeAnnotation = anyTypeAnnotation; +exports.argumentPlaceholder = argumentPlaceholder; +exports.arrayExpression = arrayExpression; +exports.arrayPattern = arrayPattern; +exports.arrayTypeAnnotation = arrayTypeAnnotation; +exports.arrowFunctionExpression = arrowFunctionExpression; +exports.assignmentExpression = assignmentExpression; +exports.assignmentPattern = assignmentPattern; +exports.awaitExpression = awaitExpression; +exports.bigIntLiteral = bigIntLiteral; +exports.binaryExpression = binaryExpression; +exports.bindExpression = bindExpression; +exports.blockStatement = blockStatement; +exports.booleanLiteral = booleanLiteral; +exports.booleanLiteralTypeAnnotation = booleanLiteralTypeAnnotation; +exports.booleanTypeAnnotation = booleanTypeAnnotation; +exports.breakStatement = breakStatement; +exports.callExpression = callExpression; +exports.catchClause = catchClause; +exports.classAccessorProperty = classAccessorProperty; +exports.classBody = classBody; +exports.classDeclaration = classDeclaration; +exports.classExpression = classExpression; +exports.classImplements = classImplements; +exports.classMethod = classMethod; +exports.classPrivateMethod = classPrivateMethod; +exports.classPrivateProperty = classPrivateProperty; +exports.classProperty = classProperty; +exports.conditionalExpression = conditionalExpression; +exports.continueStatement = continueStatement; +exports.debuggerStatement = debuggerStatement; +exports.decimalLiteral = decimalLiteral; +exports.declareClass = declareClass; +exports.declareExportAllDeclaration = declareExportAllDeclaration; +exports.declareExportDeclaration = declareExportDeclaration; +exports.declareFunction = declareFunction; +exports.declareInterface = declareInterface; +exports.declareModule = declareModule; +exports.declareModuleExports = declareModuleExports; +exports.declareOpaqueType = declareOpaqueType; +exports.declareTypeAlias = declareTypeAlias; +exports.declareVariable = declareVariable; +exports.declaredPredicate = declaredPredicate; +exports.decorator = decorator; +exports.directive = directive; +exports.directiveLiteral = directiveLiteral; +exports.doExpression = doExpression; +exports.doWhileStatement = doWhileStatement; +exports.emptyStatement = emptyStatement; +exports.emptyTypeAnnotation = emptyTypeAnnotation; +exports.enumBooleanBody = enumBooleanBody; +exports.enumBooleanMember = enumBooleanMember; +exports.enumDeclaration = enumDeclaration; +exports.enumDefaultedMember = enumDefaultedMember; +exports.enumNumberBody = enumNumberBody; +exports.enumNumberMember = enumNumberMember; +exports.enumStringBody = enumStringBody; +exports.enumStringMember = enumStringMember; +exports.enumSymbolBody = enumSymbolBody; +exports.existsTypeAnnotation = existsTypeAnnotation; +exports.exportAllDeclaration = exportAllDeclaration; +exports.exportDefaultDeclaration = exportDefaultDeclaration; +exports.exportDefaultSpecifier = exportDefaultSpecifier; +exports.exportNamedDeclaration = exportNamedDeclaration; +exports.exportNamespaceSpecifier = exportNamespaceSpecifier; +exports.exportSpecifier = exportSpecifier; +exports.expressionStatement = expressionStatement; +exports.file = file; +exports.forInStatement = forInStatement; +exports.forOfStatement = forOfStatement; +exports.forStatement = forStatement; +exports.functionDeclaration = functionDeclaration; +exports.functionExpression = functionExpression; +exports.functionTypeAnnotation = functionTypeAnnotation; +exports.functionTypeParam = functionTypeParam; +exports.genericTypeAnnotation = genericTypeAnnotation; +exports.identifier = identifier; +exports.ifStatement = ifStatement; +exports.import = _import; +exports.importAttribute = importAttribute; +exports.importDeclaration = importDeclaration; +exports.importDefaultSpecifier = importDefaultSpecifier; +exports.importNamespaceSpecifier = importNamespaceSpecifier; +exports.importSpecifier = importSpecifier; +exports.indexedAccessType = indexedAccessType; +exports.inferredPredicate = inferredPredicate; +exports.interfaceDeclaration = interfaceDeclaration; +exports.interfaceExtends = interfaceExtends; +exports.interfaceTypeAnnotation = interfaceTypeAnnotation; +exports.interpreterDirective = interpreterDirective; +exports.intersectionTypeAnnotation = intersectionTypeAnnotation; +exports.jSXAttribute = exports.jsxAttribute = jsxAttribute; +exports.jSXClosingElement = exports.jsxClosingElement = jsxClosingElement; +exports.jSXClosingFragment = exports.jsxClosingFragment = jsxClosingFragment; +exports.jSXElement = exports.jsxElement = jsxElement; +exports.jSXEmptyExpression = exports.jsxEmptyExpression = jsxEmptyExpression; +exports.jSXExpressionContainer = exports.jsxExpressionContainer = jsxExpressionContainer; +exports.jSXFragment = exports.jsxFragment = jsxFragment; +exports.jSXIdentifier = exports.jsxIdentifier = jsxIdentifier; +exports.jSXMemberExpression = exports.jsxMemberExpression = jsxMemberExpression; +exports.jSXNamespacedName = exports.jsxNamespacedName = jsxNamespacedName; +exports.jSXOpeningElement = exports.jsxOpeningElement = jsxOpeningElement; +exports.jSXOpeningFragment = exports.jsxOpeningFragment = jsxOpeningFragment; +exports.jSXSpreadAttribute = exports.jsxSpreadAttribute = jsxSpreadAttribute; +exports.jSXSpreadChild = exports.jsxSpreadChild = jsxSpreadChild; +exports.jSXText = exports.jsxText = jsxText; +exports.labeledStatement = labeledStatement; +exports.logicalExpression = logicalExpression; +exports.memberExpression = memberExpression; +exports.metaProperty = metaProperty; +exports.mixedTypeAnnotation = mixedTypeAnnotation; +exports.moduleExpression = moduleExpression; +exports.newExpression = newExpression; +exports.noop = noop; +exports.nullLiteral = nullLiteral; +exports.nullLiteralTypeAnnotation = nullLiteralTypeAnnotation; +exports.nullableTypeAnnotation = nullableTypeAnnotation; +exports.numberLiteral = NumberLiteral; +exports.numberLiteralTypeAnnotation = numberLiteralTypeAnnotation; +exports.numberTypeAnnotation = numberTypeAnnotation; +exports.numericLiteral = numericLiteral; +exports.objectExpression = objectExpression; +exports.objectMethod = objectMethod; +exports.objectPattern = objectPattern; +exports.objectProperty = objectProperty; +exports.objectTypeAnnotation = objectTypeAnnotation; +exports.objectTypeCallProperty = objectTypeCallProperty; +exports.objectTypeIndexer = objectTypeIndexer; +exports.objectTypeInternalSlot = objectTypeInternalSlot; +exports.objectTypeProperty = objectTypeProperty; +exports.objectTypeSpreadProperty = objectTypeSpreadProperty; +exports.opaqueType = opaqueType; +exports.optionalCallExpression = optionalCallExpression; +exports.optionalIndexedAccessType = optionalIndexedAccessType; +exports.optionalMemberExpression = optionalMemberExpression; +exports.parenthesizedExpression = parenthesizedExpression; +exports.pipelineBareFunction = pipelineBareFunction; +exports.pipelinePrimaryTopicReference = pipelinePrimaryTopicReference; +exports.pipelineTopicExpression = pipelineTopicExpression; +exports.placeholder = placeholder; +exports.privateName = privateName; +exports.program = program; +exports.qualifiedTypeIdentifier = qualifiedTypeIdentifier; +exports.recordExpression = recordExpression; +exports.regExpLiteral = regExpLiteral; +exports.regexLiteral = RegexLiteral; +exports.restElement = restElement; +exports.restProperty = RestProperty; +exports.returnStatement = returnStatement; +exports.sequenceExpression = sequenceExpression; +exports.spreadElement = spreadElement; +exports.spreadProperty = SpreadProperty; +exports.staticBlock = staticBlock; +exports.stringLiteral = stringLiteral; +exports.stringLiteralTypeAnnotation = stringLiteralTypeAnnotation; +exports.stringTypeAnnotation = stringTypeAnnotation; +exports.super = _super; +exports.switchCase = switchCase; +exports.switchStatement = switchStatement; +exports.symbolTypeAnnotation = symbolTypeAnnotation; +exports.taggedTemplateExpression = taggedTemplateExpression; +exports.templateElement = templateElement; +exports.templateLiteral = templateLiteral; +exports.thisExpression = thisExpression; +exports.thisTypeAnnotation = thisTypeAnnotation; +exports.throwStatement = throwStatement; +exports.topicReference = topicReference; +exports.tryStatement = tryStatement; +exports.tSAnyKeyword = exports.tsAnyKeyword = tsAnyKeyword; +exports.tSArrayType = exports.tsArrayType = tsArrayType; +exports.tSAsExpression = exports.tsAsExpression = tsAsExpression; +exports.tSBigIntKeyword = exports.tsBigIntKeyword = tsBigIntKeyword; +exports.tSBooleanKeyword = exports.tsBooleanKeyword = tsBooleanKeyword; +exports.tSCallSignatureDeclaration = exports.tsCallSignatureDeclaration = tsCallSignatureDeclaration; +exports.tSConditionalType = exports.tsConditionalType = tsConditionalType; +exports.tSConstructSignatureDeclaration = exports.tsConstructSignatureDeclaration = tsConstructSignatureDeclaration; +exports.tSConstructorType = exports.tsConstructorType = tsConstructorType; +exports.tSDeclareFunction = exports.tsDeclareFunction = tsDeclareFunction; +exports.tSDeclareMethod = exports.tsDeclareMethod = tsDeclareMethod; +exports.tSEnumDeclaration = exports.tsEnumDeclaration = tsEnumDeclaration; +exports.tSEnumMember = exports.tsEnumMember = tsEnumMember; +exports.tSExportAssignment = exports.tsExportAssignment = tsExportAssignment; +exports.tSExpressionWithTypeArguments = exports.tsExpressionWithTypeArguments = tsExpressionWithTypeArguments; +exports.tSExternalModuleReference = exports.tsExternalModuleReference = tsExternalModuleReference; +exports.tSFunctionType = exports.tsFunctionType = tsFunctionType; +exports.tSImportEqualsDeclaration = exports.tsImportEqualsDeclaration = tsImportEqualsDeclaration; +exports.tSImportType = exports.tsImportType = tsImportType; +exports.tSIndexSignature = exports.tsIndexSignature = tsIndexSignature; +exports.tSIndexedAccessType = exports.tsIndexedAccessType = tsIndexedAccessType; +exports.tSInferType = exports.tsInferType = tsInferType; +exports.tSInterfaceBody = exports.tsInterfaceBody = tsInterfaceBody; +exports.tSInterfaceDeclaration = exports.tsInterfaceDeclaration = tsInterfaceDeclaration; +exports.tSIntersectionType = exports.tsIntersectionType = tsIntersectionType; +exports.tSIntrinsicKeyword = exports.tsIntrinsicKeyword = tsIntrinsicKeyword; +exports.tSLiteralType = exports.tsLiteralType = tsLiteralType; +exports.tSMappedType = exports.tsMappedType = tsMappedType; +exports.tSMethodSignature = exports.tsMethodSignature = tsMethodSignature; +exports.tSModuleBlock = exports.tsModuleBlock = tsModuleBlock; +exports.tSModuleDeclaration = exports.tsModuleDeclaration = tsModuleDeclaration; +exports.tSNamedTupleMember = exports.tsNamedTupleMember = tsNamedTupleMember; +exports.tSNamespaceExportDeclaration = exports.tsNamespaceExportDeclaration = tsNamespaceExportDeclaration; +exports.tSNeverKeyword = exports.tsNeverKeyword = tsNeverKeyword; +exports.tSNonNullExpression = exports.tsNonNullExpression = tsNonNullExpression; +exports.tSNullKeyword = exports.tsNullKeyword = tsNullKeyword; +exports.tSNumberKeyword = exports.tsNumberKeyword = tsNumberKeyword; +exports.tSObjectKeyword = exports.tsObjectKeyword = tsObjectKeyword; +exports.tSOptionalType = exports.tsOptionalType = tsOptionalType; +exports.tSParameterProperty = exports.tsParameterProperty = tsParameterProperty; +exports.tSParenthesizedType = exports.tsParenthesizedType = tsParenthesizedType; +exports.tSPropertySignature = exports.tsPropertySignature = tsPropertySignature; +exports.tSQualifiedName = exports.tsQualifiedName = tsQualifiedName; +exports.tSRestType = exports.tsRestType = tsRestType; +exports.tSStringKeyword = exports.tsStringKeyword = tsStringKeyword; +exports.tSSymbolKeyword = exports.tsSymbolKeyword = tsSymbolKeyword; +exports.tSThisType = exports.tsThisType = tsThisType; +exports.tSTupleType = exports.tsTupleType = tsTupleType; +exports.tSTypeAliasDeclaration = exports.tsTypeAliasDeclaration = tsTypeAliasDeclaration; +exports.tSTypeAnnotation = exports.tsTypeAnnotation = tsTypeAnnotation; +exports.tSTypeAssertion = exports.tsTypeAssertion = tsTypeAssertion; +exports.tSTypeLiteral = exports.tsTypeLiteral = tsTypeLiteral; +exports.tSTypeOperator = exports.tsTypeOperator = tsTypeOperator; +exports.tSTypeParameter = exports.tsTypeParameter = tsTypeParameter; +exports.tSTypeParameterDeclaration = exports.tsTypeParameterDeclaration = tsTypeParameterDeclaration; +exports.tSTypeParameterInstantiation = exports.tsTypeParameterInstantiation = tsTypeParameterInstantiation; +exports.tSTypePredicate = exports.tsTypePredicate = tsTypePredicate; +exports.tSTypeQuery = exports.tsTypeQuery = tsTypeQuery; +exports.tSTypeReference = exports.tsTypeReference = tsTypeReference; +exports.tSUndefinedKeyword = exports.tsUndefinedKeyword = tsUndefinedKeyword; +exports.tSUnionType = exports.tsUnionType = tsUnionType; +exports.tSUnknownKeyword = exports.tsUnknownKeyword = tsUnknownKeyword; +exports.tSVoidKeyword = exports.tsVoidKeyword = tsVoidKeyword; +exports.tupleExpression = tupleExpression; +exports.tupleTypeAnnotation = tupleTypeAnnotation; +exports.typeAlias = typeAlias; +exports.typeAnnotation = typeAnnotation; +exports.typeCastExpression = typeCastExpression; +exports.typeParameter = typeParameter; +exports.typeParameterDeclaration = typeParameterDeclaration; +exports.typeParameterInstantiation = typeParameterInstantiation; +exports.typeofTypeAnnotation = typeofTypeAnnotation; +exports.unaryExpression = unaryExpression; +exports.unionTypeAnnotation = unionTypeAnnotation; +exports.updateExpression = updateExpression; +exports.v8IntrinsicIdentifier = v8IntrinsicIdentifier; +exports.variableDeclaration = variableDeclaration; +exports.variableDeclarator = variableDeclarator; +exports.variance = variance; +exports.voidTypeAnnotation = voidTypeAnnotation; +exports.whileStatement = whileStatement; +exports.withStatement = withStatement; +exports.yieldExpression = yieldExpression; + +var _builder = require("../builder"); + +function arrayExpression(elements) { + return _builder.default.apply("ArrayExpression", arguments); +} + +function assignmentExpression(operator, left, right) { + return _builder.default.apply("AssignmentExpression", arguments); +} + +function binaryExpression(operator, left, right) { + return _builder.default.apply("BinaryExpression", arguments); +} + +function interpreterDirective(value) { + return _builder.default.apply("InterpreterDirective", arguments); +} + +function directive(value) { + return _builder.default.apply("Directive", arguments); +} + +function directiveLiteral(value) { + return _builder.default.apply("DirectiveLiteral", arguments); +} + +function blockStatement(body, directives) { + return _builder.default.apply("BlockStatement", arguments); +} + +function breakStatement(label) { + return _builder.default.apply("BreakStatement", arguments); +} + +function callExpression(callee, _arguments) { + return _builder.default.apply("CallExpression", arguments); +} + +function catchClause(param, body) { + return _builder.default.apply("CatchClause", arguments); +} + +function conditionalExpression(test, consequent, alternate) { + return _builder.default.apply("ConditionalExpression", arguments); +} + +function continueStatement(label) { + return _builder.default.apply("ContinueStatement", arguments); +} + +function debuggerStatement() { + return _builder.default.apply("DebuggerStatement", arguments); +} + +function doWhileStatement(test, body) { + return _builder.default.apply("DoWhileStatement", arguments); +} + +function emptyStatement() { + return _builder.default.apply("EmptyStatement", arguments); +} + +function expressionStatement(expression) { + return _builder.default.apply("ExpressionStatement", arguments); +} + +function file(program, comments, tokens) { + return _builder.default.apply("File", arguments); +} + +function forInStatement(left, right, body) { + return _builder.default.apply("ForInStatement", arguments); +} + +function forStatement(init, test, update, body) { + return _builder.default.apply("ForStatement", arguments); +} + +function functionDeclaration(id, params, body, generator, async) { + return _builder.default.apply("FunctionDeclaration", arguments); +} + +function functionExpression(id, params, body, generator, async) { + return _builder.default.apply("FunctionExpression", arguments); +} + +function identifier(name) { + return _builder.default.apply("Identifier", arguments); +} + +function ifStatement(test, consequent, alternate) { + return _builder.default.apply("IfStatement", arguments); +} + +function labeledStatement(label, body) { + return _builder.default.apply("LabeledStatement", arguments); +} + +function stringLiteral(value) { + return _builder.default.apply("StringLiteral", arguments); +} + +function numericLiteral(value) { + return _builder.default.apply("NumericLiteral", arguments); +} + +function nullLiteral() { + return _builder.default.apply("NullLiteral", arguments); +} + +function booleanLiteral(value) { + return _builder.default.apply("BooleanLiteral", arguments); +} + +function regExpLiteral(pattern, flags) { + return _builder.default.apply("RegExpLiteral", arguments); +} + +function logicalExpression(operator, left, right) { + return _builder.default.apply("LogicalExpression", arguments); +} + +function memberExpression(object, property, computed, optional) { + return _builder.default.apply("MemberExpression", arguments); +} + +function newExpression(callee, _arguments) { + return _builder.default.apply("NewExpression", arguments); +} + +function program(body, directives, sourceType, interpreter) { + return _builder.default.apply("Program", arguments); +} + +function objectExpression(properties) { + return _builder.default.apply("ObjectExpression", arguments); +} + +function objectMethod(kind, key, params, body, computed, generator, async) { + return _builder.default.apply("ObjectMethod", arguments); +} + +function objectProperty(key, value, computed, shorthand, decorators) { + return _builder.default.apply("ObjectProperty", arguments); +} + +function restElement(argument) { + return _builder.default.apply("RestElement", arguments); +} + +function returnStatement(argument) { + return _builder.default.apply("ReturnStatement", arguments); +} + +function sequenceExpression(expressions) { + return _builder.default.apply("SequenceExpression", arguments); +} + +function parenthesizedExpression(expression) { + return _builder.default.apply("ParenthesizedExpression", arguments); +} + +function switchCase(test, consequent) { + return _builder.default.apply("SwitchCase", arguments); +} + +function switchStatement(discriminant, cases) { + return _builder.default.apply("SwitchStatement", arguments); +} + +function thisExpression() { + return _builder.default.apply("ThisExpression", arguments); +} + +function throwStatement(argument) { + return _builder.default.apply("ThrowStatement", arguments); +} + +function tryStatement(block, handler, finalizer) { + return _builder.default.apply("TryStatement", arguments); +} + +function unaryExpression(operator, argument, prefix) { + return _builder.default.apply("UnaryExpression", arguments); +} + +function updateExpression(operator, argument, prefix) { + return _builder.default.apply("UpdateExpression", arguments); +} + +function variableDeclaration(kind, declarations) { + return _builder.default.apply("VariableDeclaration", arguments); +} + +function variableDeclarator(id, init) { + return _builder.default.apply("VariableDeclarator", arguments); +} + +function whileStatement(test, body) { + return _builder.default.apply("WhileStatement", arguments); +} + +function withStatement(object, body) { + return _builder.default.apply("WithStatement", arguments); +} + +function assignmentPattern(left, right) { + return _builder.default.apply("AssignmentPattern", arguments); +} + +function arrayPattern(elements) { + return _builder.default.apply("ArrayPattern", arguments); +} + +function arrowFunctionExpression(params, body, async) { + return _builder.default.apply("ArrowFunctionExpression", arguments); +} + +function classBody(body) { + return _builder.default.apply("ClassBody", arguments); +} + +function classExpression(id, superClass, body, decorators) { + return _builder.default.apply("ClassExpression", arguments); +} + +function classDeclaration(id, superClass, body, decorators) { + return _builder.default.apply("ClassDeclaration", arguments); +} + +function exportAllDeclaration(source) { + return _builder.default.apply("ExportAllDeclaration", arguments); +} + +function exportDefaultDeclaration(declaration) { + return _builder.default.apply("ExportDefaultDeclaration", arguments); +} + +function exportNamedDeclaration(declaration, specifiers, source) { + return _builder.default.apply("ExportNamedDeclaration", arguments); +} + +function exportSpecifier(local, exported) { + return _builder.default.apply("ExportSpecifier", arguments); +} + +function forOfStatement(left, right, body, _await) { + return _builder.default.apply("ForOfStatement", arguments); +} + +function importDeclaration(specifiers, source) { + return _builder.default.apply("ImportDeclaration", arguments); +} + +function importDefaultSpecifier(local) { + return _builder.default.apply("ImportDefaultSpecifier", arguments); +} + +function importNamespaceSpecifier(local) { + return _builder.default.apply("ImportNamespaceSpecifier", arguments); +} + +function importSpecifier(local, imported) { + return _builder.default.apply("ImportSpecifier", arguments); +} + +function metaProperty(meta, property) { + return _builder.default.apply("MetaProperty", arguments); +} + +function classMethod(kind, key, params, body, computed, _static, generator, async) { + return _builder.default.apply("ClassMethod", arguments); +} + +function objectPattern(properties) { + return _builder.default.apply("ObjectPattern", arguments); +} + +function spreadElement(argument) { + return _builder.default.apply("SpreadElement", arguments); +} + +function _super() { + return _builder.default.apply("Super", arguments); +} + +function taggedTemplateExpression(tag, quasi) { + return _builder.default.apply("TaggedTemplateExpression", arguments); +} + +function templateElement(value, tail) { + return _builder.default.apply("TemplateElement", arguments); +} + +function templateLiteral(quasis, expressions) { + return _builder.default.apply("TemplateLiteral", arguments); +} + +function yieldExpression(argument, delegate) { + return _builder.default.apply("YieldExpression", arguments); +} + +function awaitExpression(argument) { + return _builder.default.apply("AwaitExpression", arguments); +} + +function _import() { + return _builder.default.apply("Import", arguments); +} + +function bigIntLiteral(value) { + return _builder.default.apply("BigIntLiteral", arguments); +} + +function exportNamespaceSpecifier(exported) { + return _builder.default.apply("ExportNamespaceSpecifier", arguments); +} + +function optionalMemberExpression(object, property, computed, optional) { + return _builder.default.apply("OptionalMemberExpression", arguments); +} + +function optionalCallExpression(callee, _arguments, optional) { + return _builder.default.apply("OptionalCallExpression", arguments); +} + +function classProperty(key, value, typeAnnotation, decorators, computed, _static) { + return _builder.default.apply("ClassProperty", arguments); +} + +function classAccessorProperty(key, value, typeAnnotation, decorators, computed, _static) { + return _builder.default.apply("ClassAccessorProperty", arguments); +} + +function classPrivateProperty(key, value, decorators, _static) { + return _builder.default.apply("ClassPrivateProperty", arguments); +} + +function classPrivateMethod(kind, key, params, body, _static) { + return _builder.default.apply("ClassPrivateMethod", arguments); +} + +function privateName(id) { + return _builder.default.apply("PrivateName", arguments); +} + +function staticBlock(body) { + return _builder.default.apply("StaticBlock", arguments); +} + +function anyTypeAnnotation() { + return _builder.default.apply("AnyTypeAnnotation", arguments); +} + +function arrayTypeAnnotation(elementType) { + return _builder.default.apply("ArrayTypeAnnotation", arguments); +} + +function booleanTypeAnnotation() { + return _builder.default.apply("BooleanTypeAnnotation", arguments); +} + +function booleanLiteralTypeAnnotation(value) { + return _builder.default.apply("BooleanLiteralTypeAnnotation", arguments); +} + +function nullLiteralTypeAnnotation() { + return _builder.default.apply("NullLiteralTypeAnnotation", arguments); +} + +function classImplements(id, typeParameters) { + return _builder.default.apply("ClassImplements", arguments); +} + +function declareClass(id, typeParameters, _extends, body) { + return _builder.default.apply("DeclareClass", arguments); +} + +function declareFunction(id) { + return _builder.default.apply("DeclareFunction", arguments); +} + +function declareInterface(id, typeParameters, _extends, body) { + return _builder.default.apply("DeclareInterface", arguments); +} + +function declareModule(id, body, kind) { + return _builder.default.apply("DeclareModule", arguments); +} + +function declareModuleExports(typeAnnotation) { + return _builder.default.apply("DeclareModuleExports", arguments); +} + +function declareTypeAlias(id, typeParameters, right) { + return _builder.default.apply("DeclareTypeAlias", arguments); +} + +function declareOpaqueType(id, typeParameters, supertype) { + return _builder.default.apply("DeclareOpaqueType", arguments); +} + +function declareVariable(id) { + return _builder.default.apply("DeclareVariable", arguments); +} + +function declareExportDeclaration(declaration, specifiers, source) { + return _builder.default.apply("DeclareExportDeclaration", arguments); +} + +function declareExportAllDeclaration(source) { + return _builder.default.apply("DeclareExportAllDeclaration", arguments); +} + +function declaredPredicate(value) { + return _builder.default.apply("DeclaredPredicate", arguments); +} + +function existsTypeAnnotation() { + return _builder.default.apply("ExistsTypeAnnotation", arguments); +} + +function functionTypeAnnotation(typeParameters, params, rest, returnType) { + return _builder.default.apply("FunctionTypeAnnotation", arguments); +} + +function functionTypeParam(name, typeAnnotation) { + return _builder.default.apply("FunctionTypeParam", arguments); +} + +function genericTypeAnnotation(id, typeParameters) { + return _builder.default.apply("GenericTypeAnnotation", arguments); +} + +function inferredPredicate() { + return _builder.default.apply("InferredPredicate", arguments); +} + +function interfaceExtends(id, typeParameters) { + return _builder.default.apply("InterfaceExtends", arguments); +} + +function interfaceDeclaration(id, typeParameters, _extends, body) { + return _builder.default.apply("InterfaceDeclaration", arguments); +} + +function interfaceTypeAnnotation(_extends, body) { + return _builder.default.apply("InterfaceTypeAnnotation", arguments); +} + +function intersectionTypeAnnotation(types) { + return _builder.default.apply("IntersectionTypeAnnotation", arguments); +} + +function mixedTypeAnnotation() { + return _builder.default.apply("MixedTypeAnnotation", arguments); +} + +function emptyTypeAnnotation() { + return _builder.default.apply("EmptyTypeAnnotation", arguments); +} + +function nullableTypeAnnotation(typeAnnotation) { + return _builder.default.apply("NullableTypeAnnotation", arguments); +} + +function numberLiteralTypeAnnotation(value) { + return _builder.default.apply("NumberLiteralTypeAnnotation", arguments); +} + +function numberTypeAnnotation() { + return _builder.default.apply("NumberTypeAnnotation", arguments); +} + +function objectTypeAnnotation(properties, indexers, callProperties, internalSlots, exact) { + return _builder.default.apply("ObjectTypeAnnotation", arguments); +} + +function objectTypeInternalSlot(id, value, optional, _static, method) { + return _builder.default.apply("ObjectTypeInternalSlot", arguments); +} + +function objectTypeCallProperty(value) { + return _builder.default.apply("ObjectTypeCallProperty", arguments); +} + +function objectTypeIndexer(id, key, value, variance) { + return _builder.default.apply("ObjectTypeIndexer", arguments); +} + +function objectTypeProperty(key, value, variance) { + return _builder.default.apply("ObjectTypeProperty", arguments); +} + +function objectTypeSpreadProperty(argument) { + return _builder.default.apply("ObjectTypeSpreadProperty", arguments); +} + +function opaqueType(id, typeParameters, supertype, impltype) { + return _builder.default.apply("OpaqueType", arguments); +} + +function qualifiedTypeIdentifier(id, qualification) { + return _builder.default.apply("QualifiedTypeIdentifier", arguments); +} + +function stringLiteralTypeAnnotation(value) { + return _builder.default.apply("StringLiteralTypeAnnotation", arguments); +} + +function stringTypeAnnotation() { + return _builder.default.apply("StringTypeAnnotation", arguments); +} + +function symbolTypeAnnotation() { + return _builder.default.apply("SymbolTypeAnnotation", arguments); +} + +function thisTypeAnnotation() { + return _builder.default.apply("ThisTypeAnnotation", arguments); +} + +function tupleTypeAnnotation(types) { + return _builder.default.apply("TupleTypeAnnotation", arguments); +} + +function typeofTypeAnnotation(argument) { + return _builder.default.apply("TypeofTypeAnnotation", arguments); +} + +function typeAlias(id, typeParameters, right) { + return _builder.default.apply("TypeAlias", arguments); +} + +function typeAnnotation(typeAnnotation) { + return _builder.default.apply("TypeAnnotation", arguments); +} + +function typeCastExpression(expression, typeAnnotation) { + return _builder.default.apply("TypeCastExpression", arguments); +} + +function typeParameter(bound, _default, variance) { + return _builder.default.apply("TypeParameter", arguments); +} + +function typeParameterDeclaration(params) { + return _builder.default.apply("TypeParameterDeclaration", arguments); +} + +function typeParameterInstantiation(params) { + return _builder.default.apply("TypeParameterInstantiation", arguments); +} + +function unionTypeAnnotation(types) { + return _builder.default.apply("UnionTypeAnnotation", arguments); +} + +function variance(kind) { + return _builder.default.apply("Variance", arguments); +} + +function voidTypeAnnotation() { + return _builder.default.apply("VoidTypeAnnotation", arguments); +} + +function enumDeclaration(id, body) { + return _builder.default.apply("EnumDeclaration", arguments); +} + +function enumBooleanBody(members) { + return _builder.default.apply("EnumBooleanBody", arguments); +} + +function enumNumberBody(members) { + return _builder.default.apply("EnumNumberBody", arguments); +} + +function enumStringBody(members) { + return _builder.default.apply("EnumStringBody", arguments); +} + +function enumSymbolBody(members) { + return _builder.default.apply("EnumSymbolBody", arguments); +} + +function enumBooleanMember(id) { + return _builder.default.apply("EnumBooleanMember", arguments); +} + +function enumNumberMember(id, init) { + return _builder.default.apply("EnumNumberMember", arguments); +} + +function enumStringMember(id, init) { + return _builder.default.apply("EnumStringMember", arguments); +} + +function enumDefaultedMember(id) { + return _builder.default.apply("EnumDefaultedMember", arguments); +} + +function indexedAccessType(objectType, indexType) { + return _builder.default.apply("IndexedAccessType", arguments); +} + +function optionalIndexedAccessType(objectType, indexType) { + return _builder.default.apply("OptionalIndexedAccessType", arguments); +} + +function jsxAttribute(name, value) { + return _builder.default.apply("JSXAttribute", arguments); +} + +function jsxClosingElement(name) { + return _builder.default.apply("JSXClosingElement", arguments); +} + +function jsxElement(openingElement, closingElement, children, selfClosing) { + return _builder.default.apply("JSXElement", arguments); +} + +function jsxEmptyExpression() { + return _builder.default.apply("JSXEmptyExpression", arguments); +} + +function jsxExpressionContainer(expression) { + return _builder.default.apply("JSXExpressionContainer", arguments); +} + +function jsxSpreadChild(expression) { + return _builder.default.apply("JSXSpreadChild", arguments); +} + +function jsxIdentifier(name) { + return _builder.default.apply("JSXIdentifier", arguments); +} + +function jsxMemberExpression(object, property) { + return _builder.default.apply("JSXMemberExpression", arguments); +} + +function jsxNamespacedName(namespace, name) { + return _builder.default.apply("JSXNamespacedName", arguments); +} + +function jsxOpeningElement(name, attributes, selfClosing) { + return _builder.default.apply("JSXOpeningElement", arguments); +} + +function jsxSpreadAttribute(argument) { + return _builder.default.apply("JSXSpreadAttribute", arguments); +} + +function jsxText(value) { + return _builder.default.apply("JSXText", arguments); +} + +function jsxFragment(openingFragment, closingFragment, children) { + return _builder.default.apply("JSXFragment", arguments); +} + +function jsxOpeningFragment() { + return _builder.default.apply("JSXOpeningFragment", arguments); +} + +function jsxClosingFragment() { + return _builder.default.apply("JSXClosingFragment", arguments); +} + +function noop() { + return _builder.default.apply("Noop", arguments); +} + +function placeholder(expectedNode, name) { + return _builder.default.apply("Placeholder", arguments); +} + +function v8IntrinsicIdentifier(name) { + return _builder.default.apply("V8IntrinsicIdentifier", arguments); +} + +function argumentPlaceholder() { + return _builder.default.apply("ArgumentPlaceholder", arguments); +} + +function bindExpression(object, callee) { + return _builder.default.apply("BindExpression", arguments); +} + +function importAttribute(key, value) { + return _builder.default.apply("ImportAttribute", arguments); +} + +function decorator(expression) { + return _builder.default.apply("Decorator", arguments); +} + +function doExpression(body, async) { + return _builder.default.apply("DoExpression", arguments); +} + +function exportDefaultSpecifier(exported) { + return _builder.default.apply("ExportDefaultSpecifier", arguments); +} + +function recordExpression(properties) { + return _builder.default.apply("RecordExpression", arguments); +} + +function tupleExpression(elements) { + return _builder.default.apply("TupleExpression", arguments); +} + +function decimalLiteral(value) { + return _builder.default.apply("DecimalLiteral", arguments); +} + +function moduleExpression(body) { + return _builder.default.apply("ModuleExpression", arguments); +} + +function topicReference() { + return _builder.default.apply("TopicReference", arguments); +} + +function pipelineTopicExpression(expression) { + return _builder.default.apply("PipelineTopicExpression", arguments); +} + +function pipelineBareFunction(callee) { + return _builder.default.apply("PipelineBareFunction", arguments); +} + +function pipelinePrimaryTopicReference() { + return _builder.default.apply("PipelinePrimaryTopicReference", arguments); +} + +function tsParameterProperty(parameter) { + return _builder.default.apply("TSParameterProperty", arguments); +} + +function tsDeclareFunction(id, typeParameters, params, returnType) { + return _builder.default.apply("TSDeclareFunction", arguments); +} + +function tsDeclareMethod(decorators, key, typeParameters, params, returnType) { + return _builder.default.apply("TSDeclareMethod", arguments); +} + +function tsQualifiedName(left, right) { + return _builder.default.apply("TSQualifiedName", arguments); +} + +function tsCallSignatureDeclaration(typeParameters, parameters, typeAnnotation) { + return _builder.default.apply("TSCallSignatureDeclaration", arguments); +} + +function tsConstructSignatureDeclaration(typeParameters, parameters, typeAnnotation) { + return _builder.default.apply("TSConstructSignatureDeclaration", arguments); +} + +function tsPropertySignature(key, typeAnnotation, initializer) { + return _builder.default.apply("TSPropertySignature", arguments); +} + +function tsMethodSignature(key, typeParameters, parameters, typeAnnotation) { + return _builder.default.apply("TSMethodSignature", arguments); +} + +function tsIndexSignature(parameters, typeAnnotation) { + return _builder.default.apply("TSIndexSignature", arguments); +} + +function tsAnyKeyword() { + return _builder.default.apply("TSAnyKeyword", arguments); +} + +function tsBooleanKeyword() { + return _builder.default.apply("TSBooleanKeyword", arguments); +} + +function tsBigIntKeyword() { + return _builder.default.apply("TSBigIntKeyword", arguments); +} + +function tsIntrinsicKeyword() { + return _builder.default.apply("TSIntrinsicKeyword", arguments); +} + +function tsNeverKeyword() { + return _builder.default.apply("TSNeverKeyword", arguments); +} + +function tsNullKeyword() { + return _builder.default.apply("TSNullKeyword", arguments); +} + +function tsNumberKeyword() { + return _builder.default.apply("TSNumberKeyword", arguments); +} + +function tsObjectKeyword() { + return _builder.default.apply("TSObjectKeyword", arguments); +} + +function tsStringKeyword() { + return _builder.default.apply("TSStringKeyword", arguments); +} + +function tsSymbolKeyword() { + return _builder.default.apply("TSSymbolKeyword", arguments); +} + +function tsUndefinedKeyword() { + return _builder.default.apply("TSUndefinedKeyword", arguments); +} + +function tsUnknownKeyword() { + return _builder.default.apply("TSUnknownKeyword", arguments); +} + +function tsVoidKeyword() { + return _builder.default.apply("TSVoidKeyword", arguments); +} + +function tsThisType() { + return _builder.default.apply("TSThisType", arguments); +} + +function tsFunctionType(typeParameters, parameters, typeAnnotation) { + return _builder.default.apply("TSFunctionType", arguments); +} + +function tsConstructorType(typeParameters, parameters, typeAnnotation) { + return _builder.default.apply("TSConstructorType", arguments); +} + +function tsTypeReference(typeName, typeParameters) { + return _builder.default.apply("TSTypeReference", arguments); +} + +function tsTypePredicate(parameterName, typeAnnotation, asserts) { + return _builder.default.apply("TSTypePredicate", arguments); +} + +function tsTypeQuery(exprName) { + return _builder.default.apply("TSTypeQuery", arguments); +} + +function tsTypeLiteral(members) { + return _builder.default.apply("TSTypeLiteral", arguments); +} + +function tsArrayType(elementType) { + return _builder.default.apply("TSArrayType", arguments); +} + +function tsTupleType(elementTypes) { + return _builder.default.apply("TSTupleType", arguments); +} + +function tsOptionalType(typeAnnotation) { + return _builder.default.apply("TSOptionalType", arguments); +} + +function tsRestType(typeAnnotation) { + return _builder.default.apply("TSRestType", arguments); +} + +function tsNamedTupleMember(label, elementType, optional) { + return _builder.default.apply("TSNamedTupleMember", arguments); +} + +function tsUnionType(types) { + return _builder.default.apply("TSUnionType", arguments); +} + +function tsIntersectionType(types) { + return _builder.default.apply("TSIntersectionType", arguments); +} + +function tsConditionalType(checkType, extendsType, trueType, falseType) { + return _builder.default.apply("TSConditionalType", arguments); +} + +function tsInferType(typeParameter) { + return _builder.default.apply("TSInferType", arguments); +} + +function tsParenthesizedType(typeAnnotation) { + return _builder.default.apply("TSParenthesizedType", arguments); +} + +function tsTypeOperator(typeAnnotation) { + return _builder.default.apply("TSTypeOperator", arguments); +} + +function tsIndexedAccessType(objectType, indexType) { + return _builder.default.apply("TSIndexedAccessType", arguments); +} + +function tsMappedType(typeParameter, typeAnnotation, nameType) { + return _builder.default.apply("TSMappedType", arguments); +} + +function tsLiteralType(literal) { + return _builder.default.apply("TSLiteralType", arguments); +} + +function tsExpressionWithTypeArguments(expression, typeParameters) { + return _builder.default.apply("TSExpressionWithTypeArguments", arguments); +} + +function tsInterfaceDeclaration(id, typeParameters, _extends, body) { + return _builder.default.apply("TSInterfaceDeclaration", arguments); +} + +function tsInterfaceBody(body) { + return _builder.default.apply("TSInterfaceBody", arguments); +} + +function tsTypeAliasDeclaration(id, typeParameters, typeAnnotation) { + return _builder.default.apply("TSTypeAliasDeclaration", arguments); +} + +function tsAsExpression(expression, typeAnnotation) { + return _builder.default.apply("TSAsExpression", arguments); +} + +function tsTypeAssertion(typeAnnotation, expression) { + return _builder.default.apply("TSTypeAssertion", arguments); +} + +function tsEnumDeclaration(id, members) { + return _builder.default.apply("TSEnumDeclaration", arguments); +} + +function tsEnumMember(id, initializer) { + return _builder.default.apply("TSEnumMember", arguments); +} + +function tsModuleDeclaration(id, body) { + return _builder.default.apply("TSModuleDeclaration", arguments); +} + +function tsModuleBlock(body) { + return _builder.default.apply("TSModuleBlock", arguments); +} + +function tsImportType(argument, qualifier, typeParameters) { + return _builder.default.apply("TSImportType", arguments); +} + +function tsImportEqualsDeclaration(id, moduleReference) { + return _builder.default.apply("TSImportEqualsDeclaration", arguments); +} + +function tsExternalModuleReference(expression) { + return _builder.default.apply("TSExternalModuleReference", arguments); +} + +function tsNonNullExpression(expression) { + return _builder.default.apply("TSNonNullExpression", arguments); +} + +function tsExportAssignment(expression) { + return _builder.default.apply("TSExportAssignment", arguments); +} + +function tsNamespaceExportDeclaration(id) { + return _builder.default.apply("TSNamespaceExportDeclaration", arguments); +} + +function tsTypeAnnotation(typeAnnotation) { + return _builder.default.apply("TSTypeAnnotation", arguments); +} + +function tsTypeParameterInstantiation(params) { + return _builder.default.apply("TSTypeParameterInstantiation", arguments); +} + +function tsTypeParameterDeclaration(params) { + return _builder.default.apply("TSTypeParameterDeclaration", arguments); +} + +function tsTypeParameter(constraint, _default, name) { + return _builder.default.apply("TSTypeParameter", arguments); +} + +function NumberLiteral(value) { + console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); + return _builder.default.apply("NumberLiteral", arguments); +} + +function RegexLiteral(pattern, flags) { + console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); + return _builder.default.apply("RegexLiteral", arguments); +} + +function RestProperty(argument) { + console.trace("The node type RestProperty has been renamed to RestElement"); + return _builder.default.apply("RestProperty", arguments); +} + +function SpreadProperty(argument) { + console.trace("The node type SpreadProperty has been renamed to SpreadElement"); + return _builder.default.apply("SpreadProperty", arguments); +} \ No newline at end of file diff --git a/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/types/lib/builders/generated/uppercase.js b/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/types/lib/builders/generated/uppercase.js new file mode 100644 index 000000000..95c9a5258 --- /dev/null +++ b/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/types/lib/builders/generated/uppercase.js @@ -0,0 +1,1513 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +Object.defineProperty(exports, "AnyTypeAnnotation", { + enumerable: true, + get: function () { + return _index.anyTypeAnnotation; + } +}); +Object.defineProperty(exports, "ArgumentPlaceholder", { + enumerable: true, + get: function () { + return _index.argumentPlaceholder; + } +}); +Object.defineProperty(exports, "ArrayExpression", { + enumerable: true, + get: function () { + return _index.arrayExpression; + } +}); +Object.defineProperty(exports, "ArrayPattern", { + enumerable: true, + get: function () { + return _index.arrayPattern; + } +}); +Object.defineProperty(exports, "ArrayTypeAnnotation", { + enumerable: true, + get: function () { + return _index.arrayTypeAnnotation; + } +}); +Object.defineProperty(exports, "ArrowFunctionExpression", { + enumerable: true, + get: function () { + return _index.arrowFunctionExpression; + } +}); +Object.defineProperty(exports, "AssignmentExpression", { + enumerable: true, + get: function () { + return _index.assignmentExpression; + } +}); +Object.defineProperty(exports, "AssignmentPattern", { + enumerable: true, + get: function () { + return _index.assignmentPattern; + } +}); +Object.defineProperty(exports, "AwaitExpression", { + enumerable: true, + get: function () { + return _index.awaitExpression; + } +}); +Object.defineProperty(exports, "BigIntLiteral", { + enumerable: true, + get: function () { + return _index.bigIntLiteral; + } +}); +Object.defineProperty(exports, "BinaryExpression", { + enumerable: true, + get: function () { + return _index.binaryExpression; + } +}); +Object.defineProperty(exports, "BindExpression", { + enumerable: true, + get: function () { + return _index.bindExpression; + } +}); +Object.defineProperty(exports, "BlockStatement", { + enumerable: true, + get: function () { + return _index.blockStatement; + } +}); +Object.defineProperty(exports, "BooleanLiteral", { + enumerable: true, + get: function () { + return _index.booleanLiteral; + } +}); +Object.defineProperty(exports, "BooleanLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.booleanLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "BooleanTypeAnnotation", { + enumerable: true, + get: function () { + return _index.booleanTypeAnnotation; + } +}); +Object.defineProperty(exports, "BreakStatement", { + enumerable: true, + get: function () { + return _index.breakStatement; + } +}); +Object.defineProperty(exports, "CallExpression", { + enumerable: true, + get: function () { + return _index.callExpression; + } +}); +Object.defineProperty(exports, "CatchClause", { + enumerable: true, + get: function () { + return _index.catchClause; + } +}); +Object.defineProperty(exports, "ClassAccessorProperty", { + enumerable: true, + get: function () { + return _index.classAccessorProperty; + } +}); +Object.defineProperty(exports, "ClassBody", { + enumerable: true, + get: function () { + return _index.classBody; + } +}); +Object.defineProperty(exports, "ClassDeclaration", { + enumerable: true, + get: function () { + return _index.classDeclaration; + } +}); +Object.defineProperty(exports, "ClassExpression", { + enumerable: true, + get: function () { + return _index.classExpression; + } +}); +Object.defineProperty(exports, "ClassImplements", { + enumerable: true, + get: function () { + return _index.classImplements; + } +}); +Object.defineProperty(exports, "ClassMethod", { + enumerable: true, + get: function () { + return _index.classMethod; + } +}); +Object.defineProperty(exports, "ClassPrivateMethod", { + enumerable: true, + get: function () { + return _index.classPrivateMethod; + } +}); +Object.defineProperty(exports, "ClassPrivateProperty", { + enumerable: true, + get: function () { + return _index.classPrivateProperty; + } +}); +Object.defineProperty(exports, "ClassProperty", { + enumerable: true, + get: function () { + return _index.classProperty; + } +}); +Object.defineProperty(exports, "ConditionalExpression", { + enumerable: true, + get: function () { + return _index.conditionalExpression; + } +}); +Object.defineProperty(exports, "ContinueStatement", { + enumerable: true, + get: function () { + return _index.continueStatement; + } +}); +Object.defineProperty(exports, "DebuggerStatement", { + enumerable: true, + get: function () { + return _index.debuggerStatement; + } +}); +Object.defineProperty(exports, "DecimalLiteral", { + enumerable: true, + get: function () { + return _index.decimalLiteral; + } +}); +Object.defineProperty(exports, "DeclareClass", { + enumerable: true, + get: function () { + return _index.declareClass; + } +}); +Object.defineProperty(exports, "DeclareExportAllDeclaration", { + enumerable: true, + get: function () { + return _index.declareExportAllDeclaration; + } +}); +Object.defineProperty(exports, "DeclareExportDeclaration", { + enumerable: true, + get: function () { + return _index.declareExportDeclaration; + } +}); +Object.defineProperty(exports, "DeclareFunction", { + enumerable: true, + get: function () { + return _index.declareFunction; + } +}); +Object.defineProperty(exports, "DeclareInterface", { + enumerable: true, + get: function () { + return _index.declareInterface; + } +}); +Object.defineProperty(exports, "DeclareModule", { + enumerable: true, + get: function () { + return _index.declareModule; + } +}); +Object.defineProperty(exports, "DeclareModuleExports", { + enumerable: true, + get: function () { + return _index.declareModuleExports; + } +}); +Object.defineProperty(exports, "DeclareOpaqueType", { + enumerable: true, + get: function () { + return _index.declareOpaqueType; + } +}); +Object.defineProperty(exports, "DeclareTypeAlias", { + enumerable: true, + get: function () { + return _index.declareTypeAlias; + } +}); +Object.defineProperty(exports, "DeclareVariable", { + enumerable: true, + get: function () { + return _index.declareVariable; + } +}); +Object.defineProperty(exports, "DeclaredPredicate", { + enumerable: true, + get: function () { + return _index.declaredPredicate; + } +}); +Object.defineProperty(exports, "Decorator", { + enumerable: true, + get: function () { + return _index.decorator; + } +}); +Object.defineProperty(exports, "Directive", { + enumerable: true, + get: function () { + return _index.directive; + } +}); +Object.defineProperty(exports, "DirectiveLiteral", { + enumerable: true, + get: function () { + return _index.directiveLiteral; + } +}); +Object.defineProperty(exports, "DoExpression", { + enumerable: true, + get: function () { + return _index.doExpression; + } +}); +Object.defineProperty(exports, "DoWhileStatement", { + enumerable: true, + get: function () { + return _index.doWhileStatement; + } +}); +Object.defineProperty(exports, "EmptyStatement", { + enumerable: true, + get: function () { + return _index.emptyStatement; + } +}); +Object.defineProperty(exports, "EmptyTypeAnnotation", { + enumerable: true, + get: function () { + return _index.emptyTypeAnnotation; + } +}); +Object.defineProperty(exports, "EnumBooleanBody", { + enumerable: true, + get: function () { + return _index.enumBooleanBody; + } +}); +Object.defineProperty(exports, "EnumBooleanMember", { + enumerable: true, + get: function () { + return _index.enumBooleanMember; + } +}); +Object.defineProperty(exports, "EnumDeclaration", { + enumerable: true, + get: function () { + return _index.enumDeclaration; + } +}); +Object.defineProperty(exports, "EnumDefaultedMember", { + enumerable: true, + get: function () { + return _index.enumDefaultedMember; + } +}); +Object.defineProperty(exports, "EnumNumberBody", { + enumerable: true, + get: function () { + return _index.enumNumberBody; + } +}); +Object.defineProperty(exports, "EnumNumberMember", { + enumerable: true, + get: function () { + return _index.enumNumberMember; + } +}); +Object.defineProperty(exports, "EnumStringBody", { + enumerable: true, + get: function () { + return _index.enumStringBody; + } +}); +Object.defineProperty(exports, "EnumStringMember", { + enumerable: true, + get: function () { + return _index.enumStringMember; + } +}); +Object.defineProperty(exports, "EnumSymbolBody", { + enumerable: true, + get: function () { + return _index.enumSymbolBody; + } +}); +Object.defineProperty(exports, "ExistsTypeAnnotation", { + enumerable: true, + get: function () { + return _index.existsTypeAnnotation; + } +}); +Object.defineProperty(exports, "ExportAllDeclaration", { + enumerable: true, + get: function () { + return _index.exportAllDeclaration; + } +}); +Object.defineProperty(exports, "ExportDefaultDeclaration", { + enumerable: true, + get: function () { + return _index.exportDefaultDeclaration; + } +}); +Object.defineProperty(exports, "ExportDefaultSpecifier", { + enumerable: true, + get: function () { + return _index.exportDefaultSpecifier; + } +}); +Object.defineProperty(exports, "ExportNamedDeclaration", { + enumerable: true, + get: function () { + return _index.exportNamedDeclaration; + } +}); +Object.defineProperty(exports, "ExportNamespaceSpecifier", { + enumerable: true, + get: function () { + return _index.exportNamespaceSpecifier; + } +}); +Object.defineProperty(exports, "ExportSpecifier", { + enumerable: true, + get: function () { + return _index.exportSpecifier; + } +}); +Object.defineProperty(exports, "ExpressionStatement", { + enumerable: true, + get: function () { + return _index.expressionStatement; + } +}); +Object.defineProperty(exports, "File", { + enumerable: true, + get: function () { + return _index.file; + } +}); +Object.defineProperty(exports, "ForInStatement", { + enumerable: true, + get: function () { + return _index.forInStatement; + } +}); +Object.defineProperty(exports, "ForOfStatement", { + enumerable: true, + get: function () { + return _index.forOfStatement; + } +}); +Object.defineProperty(exports, "ForStatement", { + enumerable: true, + get: function () { + return _index.forStatement; + } +}); +Object.defineProperty(exports, "FunctionDeclaration", { + enumerable: true, + get: function () { + return _index.functionDeclaration; + } +}); +Object.defineProperty(exports, "FunctionExpression", { + enumerable: true, + get: function () { + return _index.functionExpression; + } +}); +Object.defineProperty(exports, "FunctionTypeAnnotation", { + enumerable: true, + get: function () { + return _index.functionTypeAnnotation; + } +}); +Object.defineProperty(exports, "FunctionTypeParam", { + enumerable: true, + get: function () { + return _index.functionTypeParam; + } +}); +Object.defineProperty(exports, "GenericTypeAnnotation", { + enumerable: true, + get: function () { + return _index.genericTypeAnnotation; + } +}); +Object.defineProperty(exports, "Identifier", { + enumerable: true, + get: function () { + return _index.identifier; + } +}); +Object.defineProperty(exports, "IfStatement", { + enumerable: true, + get: function () { + return _index.ifStatement; + } +}); +Object.defineProperty(exports, "Import", { + enumerable: true, + get: function () { + return _index.import; + } +}); +Object.defineProperty(exports, "ImportAttribute", { + enumerable: true, + get: function () { + return _index.importAttribute; + } +}); +Object.defineProperty(exports, "ImportDeclaration", { + enumerable: true, + get: function () { + return _index.importDeclaration; + } +}); +Object.defineProperty(exports, "ImportDefaultSpecifier", { + enumerable: true, + get: function () { + return _index.importDefaultSpecifier; + } +}); +Object.defineProperty(exports, "ImportNamespaceSpecifier", { + enumerable: true, + get: function () { + return _index.importNamespaceSpecifier; + } +}); +Object.defineProperty(exports, "ImportSpecifier", { + enumerable: true, + get: function () { + return _index.importSpecifier; + } +}); +Object.defineProperty(exports, "IndexedAccessType", { + enumerable: true, + get: function () { + return _index.indexedAccessType; + } +}); +Object.defineProperty(exports, "InferredPredicate", { + enumerable: true, + get: function () { + return _index.inferredPredicate; + } +}); +Object.defineProperty(exports, "InterfaceDeclaration", { + enumerable: true, + get: function () { + return _index.interfaceDeclaration; + } +}); +Object.defineProperty(exports, "InterfaceExtends", { + enumerable: true, + get: function () { + return _index.interfaceExtends; + } +}); +Object.defineProperty(exports, "InterfaceTypeAnnotation", { + enumerable: true, + get: function () { + return _index.interfaceTypeAnnotation; + } +}); +Object.defineProperty(exports, "InterpreterDirective", { + enumerable: true, + get: function () { + return _index.interpreterDirective; + } +}); +Object.defineProperty(exports, "IntersectionTypeAnnotation", { + enumerable: true, + get: function () { + return _index.intersectionTypeAnnotation; + } +}); +Object.defineProperty(exports, "JSXAttribute", { + enumerable: true, + get: function () { + return _index.jsxAttribute; + } +}); +Object.defineProperty(exports, "JSXClosingElement", { + enumerable: true, + get: function () { + return _index.jsxClosingElement; + } +}); +Object.defineProperty(exports, "JSXClosingFragment", { + enumerable: true, + get: function () { + return _index.jsxClosingFragment; + } +}); +Object.defineProperty(exports, "JSXElement", { + enumerable: true, + get: function () { + return _index.jsxElement; + } +}); +Object.defineProperty(exports, "JSXEmptyExpression", { + enumerable: true, + get: function () { + return _index.jsxEmptyExpression; + } +}); +Object.defineProperty(exports, "JSXExpressionContainer", { + enumerable: true, + get: function () { + return _index.jsxExpressionContainer; + } +}); +Object.defineProperty(exports, "JSXFragment", { + enumerable: true, + get: function () { + return _index.jsxFragment; + } +}); +Object.defineProperty(exports, "JSXIdentifier", { + enumerable: true, + get: function () { + return _index.jsxIdentifier; + } +}); +Object.defineProperty(exports, "JSXMemberExpression", { + enumerable: true, + get: function () { + return _index.jsxMemberExpression; + } +}); +Object.defineProperty(exports, "JSXNamespacedName", { + enumerable: true, + get: function () { + return _index.jsxNamespacedName; + } +}); +Object.defineProperty(exports, "JSXOpeningElement", { + enumerable: true, + get: function () { + return _index.jsxOpeningElement; + } +}); +Object.defineProperty(exports, "JSXOpeningFragment", { + enumerable: true, + get: function () { + return _index.jsxOpeningFragment; + } +}); +Object.defineProperty(exports, "JSXSpreadAttribute", { + enumerable: true, + get: function () { + return _index.jsxSpreadAttribute; + } +}); +Object.defineProperty(exports, "JSXSpreadChild", { + enumerable: true, + get: function () { + return _index.jsxSpreadChild; + } +}); +Object.defineProperty(exports, "JSXText", { + enumerable: true, + get: function () { + return _index.jsxText; + } +}); +Object.defineProperty(exports, "LabeledStatement", { + enumerable: true, + get: function () { + return _index.labeledStatement; + } +}); +Object.defineProperty(exports, "LogicalExpression", { + enumerable: true, + get: function () { + return _index.logicalExpression; + } +}); +Object.defineProperty(exports, "MemberExpression", { + enumerable: true, + get: function () { + return _index.memberExpression; + } +}); +Object.defineProperty(exports, "MetaProperty", { + enumerable: true, + get: function () { + return _index.metaProperty; + } +}); +Object.defineProperty(exports, "MixedTypeAnnotation", { + enumerable: true, + get: function () { + return _index.mixedTypeAnnotation; + } +}); +Object.defineProperty(exports, "ModuleExpression", { + enumerable: true, + get: function () { + return _index.moduleExpression; + } +}); +Object.defineProperty(exports, "NewExpression", { + enumerable: true, + get: function () { + return _index.newExpression; + } +}); +Object.defineProperty(exports, "Noop", { + enumerable: true, + get: function () { + return _index.noop; + } +}); +Object.defineProperty(exports, "NullLiteral", { + enumerable: true, + get: function () { + return _index.nullLiteral; + } +}); +Object.defineProperty(exports, "NullLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.nullLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "NullableTypeAnnotation", { + enumerable: true, + get: function () { + return _index.nullableTypeAnnotation; + } +}); +Object.defineProperty(exports, "NumberLiteral", { + enumerable: true, + get: function () { + return _index.numberLiteral; + } +}); +Object.defineProperty(exports, "NumberLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.numberLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "NumberTypeAnnotation", { + enumerable: true, + get: function () { + return _index.numberTypeAnnotation; + } +}); +Object.defineProperty(exports, "NumericLiteral", { + enumerable: true, + get: function () { + return _index.numericLiteral; + } +}); +Object.defineProperty(exports, "ObjectExpression", { + enumerable: true, + get: function () { + return _index.objectExpression; + } +}); +Object.defineProperty(exports, "ObjectMethod", { + enumerable: true, + get: function () { + return _index.objectMethod; + } +}); +Object.defineProperty(exports, "ObjectPattern", { + enumerable: true, + get: function () { + return _index.objectPattern; + } +}); +Object.defineProperty(exports, "ObjectProperty", { + enumerable: true, + get: function () { + return _index.objectProperty; + } +}); +Object.defineProperty(exports, "ObjectTypeAnnotation", { + enumerable: true, + get: function () { + return _index.objectTypeAnnotation; + } +}); +Object.defineProperty(exports, "ObjectTypeCallProperty", { + enumerable: true, + get: function () { + return _index.objectTypeCallProperty; + } +}); +Object.defineProperty(exports, "ObjectTypeIndexer", { + enumerable: true, + get: function () { + return _index.objectTypeIndexer; + } +}); +Object.defineProperty(exports, "ObjectTypeInternalSlot", { + enumerable: true, + get: function () { + return _index.objectTypeInternalSlot; + } +}); +Object.defineProperty(exports, "ObjectTypeProperty", { + enumerable: true, + get: function () { + return _index.objectTypeProperty; + } +}); +Object.defineProperty(exports, "ObjectTypeSpreadProperty", { + enumerable: true, + get: function () { + return _index.objectTypeSpreadProperty; + } +}); +Object.defineProperty(exports, "OpaqueType", { + enumerable: true, + get: function () { + return _index.opaqueType; + } +}); +Object.defineProperty(exports, "OptionalCallExpression", { + enumerable: true, + get: function () { + return _index.optionalCallExpression; + } +}); +Object.defineProperty(exports, "OptionalIndexedAccessType", { + enumerable: true, + get: function () { + return _index.optionalIndexedAccessType; + } +}); +Object.defineProperty(exports, "OptionalMemberExpression", { + enumerable: true, + get: function () { + return _index.optionalMemberExpression; + } +}); +Object.defineProperty(exports, "ParenthesizedExpression", { + enumerable: true, + get: function () { + return _index.parenthesizedExpression; + } +}); +Object.defineProperty(exports, "PipelineBareFunction", { + enumerable: true, + get: function () { + return _index.pipelineBareFunction; + } +}); +Object.defineProperty(exports, "PipelinePrimaryTopicReference", { + enumerable: true, + get: function () { + return _index.pipelinePrimaryTopicReference; + } +}); +Object.defineProperty(exports, "PipelineTopicExpression", { + enumerable: true, + get: function () { + return _index.pipelineTopicExpression; + } +}); +Object.defineProperty(exports, "Placeholder", { + enumerable: true, + get: function () { + return _index.placeholder; + } +}); +Object.defineProperty(exports, "PrivateName", { + enumerable: true, + get: function () { + return _index.privateName; + } +}); +Object.defineProperty(exports, "Program", { + enumerable: true, + get: function () { + return _index.program; + } +}); +Object.defineProperty(exports, "QualifiedTypeIdentifier", { + enumerable: true, + get: function () { + return _index.qualifiedTypeIdentifier; + } +}); +Object.defineProperty(exports, "RecordExpression", { + enumerable: true, + get: function () { + return _index.recordExpression; + } +}); +Object.defineProperty(exports, "RegExpLiteral", { + enumerable: true, + get: function () { + return _index.regExpLiteral; + } +}); +Object.defineProperty(exports, "RegexLiteral", { + enumerable: true, + get: function () { + return _index.regexLiteral; + } +}); +Object.defineProperty(exports, "RestElement", { + enumerable: true, + get: function () { + return _index.restElement; + } +}); +Object.defineProperty(exports, "RestProperty", { + enumerable: true, + get: function () { + return _index.restProperty; + } +}); +Object.defineProperty(exports, "ReturnStatement", { + enumerable: true, + get: function () { + return _index.returnStatement; + } +}); +Object.defineProperty(exports, "SequenceExpression", { + enumerable: true, + get: function () { + return _index.sequenceExpression; + } +}); +Object.defineProperty(exports, "SpreadElement", { + enumerable: true, + get: function () { + return _index.spreadElement; + } +}); +Object.defineProperty(exports, "SpreadProperty", { + enumerable: true, + get: function () { + return _index.spreadProperty; + } +}); +Object.defineProperty(exports, "StaticBlock", { + enumerable: true, + get: function () { + return _index.staticBlock; + } +}); +Object.defineProperty(exports, "StringLiteral", { + enumerable: true, + get: function () { + return _index.stringLiteral; + } +}); +Object.defineProperty(exports, "StringLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.stringLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "StringTypeAnnotation", { + enumerable: true, + get: function () { + return _index.stringTypeAnnotation; + } +}); +Object.defineProperty(exports, "Super", { + enumerable: true, + get: function () { + return _index.super; + } +}); +Object.defineProperty(exports, "SwitchCase", { + enumerable: true, + get: function () { + return _index.switchCase; + } +}); +Object.defineProperty(exports, "SwitchStatement", { + enumerable: true, + get: function () { + return _index.switchStatement; + } +}); +Object.defineProperty(exports, "SymbolTypeAnnotation", { + enumerable: true, + get: function () { + return _index.symbolTypeAnnotation; + } +}); +Object.defineProperty(exports, "TSAnyKeyword", { + enumerable: true, + get: function () { + return _index.tsAnyKeyword; + } +}); +Object.defineProperty(exports, "TSArrayType", { + enumerable: true, + get: function () { + return _index.tsArrayType; + } +}); +Object.defineProperty(exports, "TSAsExpression", { + enumerable: true, + get: function () { + return _index.tsAsExpression; + } +}); +Object.defineProperty(exports, "TSBigIntKeyword", { + enumerable: true, + get: function () { + return _index.tsBigIntKeyword; + } +}); +Object.defineProperty(exports, "TSBooleanKeyword", { + enumerable: true, + get: function () { + return _index.tsBooleanKeyword; + } +}); +Object.defineProperty(exports, "TSCallSignatureDeclaration", { + enumerable: true, + get: function () { + return _index.tsCallSignatureDeclaration; + } +}); +Object.defineProperty(exports, "TSConditionalType", { + enumerable: true, + get: function () { + return _index.tsConditionalType; + } +}); +Object.defineProperty(exports, "TSConstructSignatureDeclaration", { + enumerable: true, + get: function () { + return _index.tsConstructSignatureDeclaration; + } +}); +Object.defineProperty(exports, "TSConstructorType", { + enumerable: true, + get: function () { + return _index.tsConstructorType; + } +}); +Object.defineProperty(exports, "TSDeclareFunction", { + enumerable: true, + get: function () { + return _index.tsDeclareFunction; + } +}); +Object.defineProperty(exports, "TSDeclareMethod", { + enumerable: true, + get: function () { + return _index.tsDeclareMethod; + } +}); +Object.defineProperty(exports, "TSEnumDeclaration", { + enumerable: true, + get: function () { + return _index.tsEnumDeclaration; + } +}); +Object.defineProperty(exports, "TSEnumMember", { + enumerable: true, + get: function () { + return _index.tsEnumMember; + } +}); +Object.defineProperty(exports, "TSExportAssignment", { + enumerable: true, + get: function () { + return _index.tsExportAssignment; + } +}); +Object.defineProperty(exports, "TSExpressionWithTypeArguments", { + enumerable: true, + get: function () { + return _index.tsExpressionWithTypeArguments; + } +}); +Object.defineProperty(exports, "TSExternalModuleReference", { + enumerable: true, + get: function () { + return _index.tsExternalModuleReference; + } +}); +Object.defineProperty(exports, "TSFunctionType", { + enumerable: true, + get: function () { + return _index.tsFunctionType; + } +}); +Object.defineProperty(exports, "TSImportEqualsDeclaration", { + enumerable: true, + get: function () { + return _index.tsImportEqualsDeclaration; + } +}); +Object.defineProperty(exports, "TSImportType", { + enumerable: true, + get: function () { + return _index.tsImportType; + } +}); +Object.defineProperty(exports, "TSIndexSignature", { + enumerable: true, + get: function () { + return _index.tsIndexSignature; + } +}); +Object.defineProperty(exports, "TSIndexedAccessType", { + enumerable: true, + get: function () { + return _index.tsIndexedAccessType; + } +}); +Object.defineProperty(exports, "TSInferType", { + enumerable: true, + get: function () { + return _index.tsInferType; + } +}); +Object.defineProperty(exports, "TSInterfaceBody", { + enumerable: true, + get: function () { + return _index.tsInterfaceBody; + } +}); +Object.defineProperty(exports, "TSInterfaceDeclaration", { + enumerable: true, + get: function () { + return _index.tsInterfaceDeclaration; + } +}); +Object.defineProperty(exports, "TSIntersectionType", { + enumerable: true, + get: function () { + return _index.tsIntersectionType; + } +}); +Object.defineProperty(exports, "TSIntrinsicKeyword", { + enumerable: true, + get: function () { + return _index.tsIntrinsicKeyword; + } +}); +Object.defineProperty(exports, "TSLiteralType", { + enumerable: true, + get: function () { + return _index.tsLiteralType; + } +}); +Object.defineProperty(exports, "TSMappedType", { + enumerable: true, + get: function () { + return _index.tsMappedType; + } +}); +Object.defineProperty(exports, "TSMethodSignature", { + enumerable: true, + get: function () { + return _index.tsMethodSignature; + } +}); +Object.defineProperty(exports, "TSModuleBlock", { + enumerable: true, + get: function () { + return _index.tsModuleBlock; + } +}); +Object.defineProperty(exports, "TSModuleDeclaration", { + enumerable: true, + get: function () { + return _index.tsModuleDeclaration; + } +}); +Object.defineProperty(exports, "TSNamedTupleMember", { + enumerable: true, + get: function () { + return _index.tsNamedTupleMember; + } +}); +Object.defineProperty(exports, "TSNamespaceExportDeclaration", { + enumerable: true, + get: function () { + return _index.tsNamespaceExportDeclaration; + } +}); +Object.defineProperty(exports, "TSNeverKeyword", { + enumerable: true, + get: function () { + return _index.tsNeverKeyword; + } +}); +Object.defineProperty(exports, "TSNonNullExpression", { + enumerable: true, + get: function () { + return _index.tsNonNullExpression; + } +}); +Object.defineProperty(exports, "TSNullKeyword", { + enumerable: true, + get: function () { + return _index.tsNullKeyword; + } +}); +Object.defineProperty(exports, "TSNumberKeyword", { + enumerable: true, + get: function () { + return _index.tsNumberKeyword; + } +}); +Object.defineProperty(exports, "TSObjectKeyword", { + enumerable: true, + get: function () { + return _index.tsObjectKeyword; + } +}); +Object.defineProperty(exports, "TSOptionalType", { + enumerable: true, + get: function () { + return _index.tsOptionalType; + } +}); +Object.defineProperty(exports, "TSParameterProperty", { + enumerable: true, + get: function () { + return _index.tsParameterProperty; + } +}); +Object.defineProperty(exports, "TSParenthesizedType", { + enumerable: true, + get: function () { + return _index.tsParenthesizedType; + } +}); +Object.defineProperty(exports, "TSPropertySignature", { + enumerable: true, + get: function () { + return _index.tsPropertySignature; + } +}); +Object.defineProperty(exports, "TSQualifiedName", { + enumerable: true, + get: function () { + return _index.tsQualifiedName; + } +}); +Object.defineProperty(exports, "TSRestType", { + enumerable: true, + get: function () { + return _index.tsRestType; + } +}); +Object.defineProperty(exports, "TSStringKeyword", { + enumerable: true, + get: function () { + return _index.tsStringKeyword; + } +}); +Object.defineProperty(exports, "TSSymbolKeyword", { + enumerable: true, + get: function () { + return _index.tsSymbolKeyword; + } +}); +Object.defineProperty(exports, "TSThisType", { + enumerable: true, + get: function () { + return _index.tsThisType; + } +}); +Object.defineProperty(exports, "TSTupleType", { + enumerable: true, + get: function () { + return _index.tsTupleType; + } +}); +Object.defineProperty(exports, "TSTypeAliasDeclaration", { + enumerable: true, + get: function () { + return _index.tsTypeAliasDeclaration; + } +}); +Object.defineProperty(exports, "TSTypeAnnotation", { + enumerable: true, + get: function () { + return _index.tsTypeAnnotation; + } +}); +Object.defineProperty(exports, "TSTypeAssertion", { + enumerable: true, + get: function () { + return _index.tsTypeAssertion; + } +}); +Object.defineProperty(exports, "TSTypeLiteral", { + enumerable: true, + get: function () { + return _index.tsTypeLiteral; + } +}); +Object.defineProperty(exports, "TSTypeOperator", { + enumerable: true, + get: function () { + return _index.tsTypeOperator; + } +}); +Object.defineProperty(exports, "TSTypeParameter", { + enumerable: true, + get: function () { + return _index.tsTypeParameter; + } +}); +Object.defineProperty(exports, "TSTypeParameterDeclaration", { + enumerable: true, + get: function () { + return _index.tsTypeParameterDeclaration; + } +}); +Object.defineProperty(exports, "TSTypeParameterInstantiation", { + enumerable: true, + get: function () { + return _index.tsTypeParameterInstantiation; + } +}); +Object.defineProperty(exports, "TSTypePredicate", { + enumerable: true, + get: function () { + return _index.tsTypePredicate; + } +}); +Object.defineProperty(exports, "TSTypeQuery", { + enumerable: true, + get: function () { + return _index.tsTypeQuery; + } +}); +Object.defineProperty(exports, "TSTypeReference", { + enumerable: true, + get: function () { + return _index.tsTypeReference; + } +}); +Object.defineProperty(exports, "TSUndefinedKeyword", { + enumerable: true, + get: function () { + return _index.tsUndefinedKeyword; + } +}); +Object.defineProperty(exports, "TSUnionType", { + enumerable: true, + get: function () { + return _index.tsUnionType; + } +}); +Object.defineProperty(exports, "TSUnknownKeyword", { + enumerable: true, + get: function () { + return _index.tsUnknownKeyword; + } +}); +Object.defineProperty(exports, "TSVoidKeyword", { + enumerable: true, + get: function () { + return _index.tsVoidKeyword; + } +}); +Object.defineProperty(exports, "TaggedTemplateExpression", { + enumerable: true, + get: function () { + return _index.taggedTemplateExpression; + } +}); +Object.defineProperty(exports, "TemplateElement", { + enumerable: true, + get: function () { + return _index.templateElement; + } +}); +Object.defineProperty(exports, "TemplateLiteral", { + enumerable: true, + get: function () { + return _index.templateLiteral; + } +}); +Object.defineProperty(exports, "ThisExpression", { + enumerable: true, + get: function () { + return _index.thisExpression; + } +}); +Object.defineProperty(exports, "ThisTypeAnnotation", { + enumerable: true, + get: function () { + return _index.thisTypeAnnotation; + } +}); +Object.defineProperty(exports, "ThrowStatement", { + enumerable: true, + get: function () { + return _index.throwStatement; + } +}); +Object.defineProperty(exports, "TopicReference", { + enumerable: true, + get: function () { + return _index.topicReference; + } +}); +Object.defineProperty(exports, "TryStatement", { + enumerable: true, + get: function () { + return _index.tryStatement; + } +}); +Object.defineProperty(exports, "TupleExpression", { + enumerable: true, + get: function () { + return _index.tupleExpression; + } +}); +Object.defineProperty(exports, "TupleTypeAnnotation", { + enumerable: true, + get: function () { + return _index.tupleTypeAnnotation; + } +}); +Object.defineProperty(exports, "TypeAlias", { + enumerable: true, + get: function () { + return _index.typeAlias; + } +}); +Object.defineProperty(exports, "TypeAnnotation", { + enumerable: true, + get: function () { + return _index.typeAnnotation; + } +}); +Object.defineProperty(exports, "TypeCastExpression", { + enumerable: true, + get: function () { + return _index.typeCastExpression; + } +}); +Object.defineProperty(exports, "TypeParameter", { + enumerable: true, + get: function () { + return _index.typeParameter; + } +}); +Object.defineProperty(exports, "TypeParameterDeclaration", { + enumerable: true, + get: function () { + return _index.typeParameterDeclaration; + } +}); +Object.defineProperty(exports, "TypeParameterInstantiation", { + enumerable: true, + get: function () { + return _index.typeParameterInstantiation; + } +}); +Object.defineProperty(exports, "TypeofTypeAnnotation", { + enumerable: true, + get: function () { + return _index.typeofTypeAnnotation; + } +}); +Object.defineProperty(exports, "UnaryExpression", { + enumerable: true, + get: function () { + return _index.unaryExpression; + } +}); +Object.defineProperty(exports, "UnionTypeAnnotation", { + enumerable: true, + get: function () { + return _index.unionTypeAnnotation; + } +}); +Object.defineProperty(exports, "UpdateExpression", { + enumerable: true, + get: function () { + return _index.updateExpression; + } +}); +Object.defineProperty(exports, "V8IntrinsicIdentifier", { + enumerable: true, + get: function () { + return _index.v8IntrinsicIdentifier; + } +}); +Object.defineProperty(exports, "VariableDeclaration", { + enumerable: true, + get: function () { + return _index.variableDeclaration; + } +}); +Object.defineProperty(exports, "VariableDeclarator", { + enumerable: true, + get: function () { + return _index.variableDeclarator; + } +}); +Object.defineProperty(exports, "Variance", { + enumerable: true, + get: function () { + return _index.variance; + } +}); +Object.defineProperty(exports, "VoidTypeAnnotation", { + enumerable: true, + get: function () { + return _index.voidTypeAnnotation; + } +}); +Object.defineProperty(exports, "WhileStatement", { + enumerable: true, + get: function () { + return _index.whileStatement; + } +}); +Object.defineProperty(exports, "WithStatement", { + enumerable: true, + get: function () { + return _index.withStatement; + } +}); +Object.defineProperty(exports, "YieldExpression", { + enumerable: true, + get: function () { + return _index.yieldExpression; + } +}); + +var _index = require("./index"); \ No newline at end of file diff --git a/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/types/lib/constants/generated/index.js b/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/types/lib/constants/generated/index.js new file mode 100644 index 000000000..1e109e6a4 --- /dev/null +++ b/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/types/lib/constants/generated/index.js @@ -0,0 +1,107 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.WHILE_TYPES = exports.USERWHITESPACABLE_TYPES = exports.UNARYLIKE_TYPES = exports.TYPESCRIPT_TYPES = exports.TSTYPE_TYPES = exports.TSTYPEELEMENT_TYPES = exports.TSENTITYNAME_TYPES = exports.TSBASETYPE_TYPES = exports.TERMINATORLESS_TYPES = exports.STATEMENT_TYPES = exports.STANDARDIZED_TYPES = exports.SCOPABLE_TYPES = exports.PUREISH_TYPES = exports.PROPERTY_TYPES = exports.PRIVATE_TYPES = exports.PATTERN_TYPES = exports.PATTERNLIKE_TYPES = exports.OBJECTMEMBER_TYPES = exports.MODULESPECIFIER_TYPES = exports.MODULEDECLARATION_TYPES = exports.MISCELLANEOUS_TYPES = exports.METHOD_TYPES = exports.LVAL_TYPES = exports.LOOP_TYPES = exports.LITERAL_TYPES = exports.JSX_TYPES = exports.IMMUTABLE_TYPES = exports.FUNCTION_TYPES = exports.FUNCTIONPARENT_TYPES = exports.FOR_TYPES = exports.FORXSTATEMENT_TYPES = exports.FLOW_TYPES = exports.FLOWTYPE_TYPES = exports.FLOWPREDICATE_TYPES = exports.FLOWDECLARATION_TYPES = exports.FLOWBASEANNOTATION_TYPES = exports.EXPRESSION_TYPES = exports.EXPRESSIONWRAPPER_TYPES = exports.EXPORTDECLARATION_TYPES = exports.ENUMMEMBER_TYPES = exports.ENUMBODY_TYPES = exports.DECLARATION_TYPES = exports.CONDITIONAL_TYPES = exports.COMPLETIONSTATEMENT_TYPES = exports.CLASS_TYPES = exports.BLOCK_TYPES = exports.BLOCKPARENT_TYPES = exports.BINARY_TYPES = exports.ACCESSOR_TYPES = void 0; + +var _definitions = require("../../definitions"); + +const STANDARDIZED_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Standardized"]; +exports.STANDARDIZED_TYPES = STANDARDIZED_TYPES; +const EXPRESSION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Expression"]; +exports.EXPRESSION_TYPES = EXPRESSION_TYPES; +const BINARY_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Binary"]; +exports.BINARY_TYPES = BINARY_TYPES; +const SCOPABLE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Scopable"]; +exports.SCOPABLE_TYPES = SCOPABLE_TYPES; +const BLOCKPARENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["BlockParent"]; +exports.BLOCKPARENT_TYPES = BLOCKPARENT_TYPES; +const BLOCK_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Block"]; +exports.BLOCK_TYPES = BLOCK_TYPES; +const STATEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Statement"]; +exports.STATEMENT_TYPES = STATEMENT_TYPES; +const TERMINATORLESS_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Terminatorless"]; +exports.TERMINATORLESS_TYPES = TERMINATORLESS_TYPES; +const COMPLETIONSTATEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["CompletionStatement"]; +exports.COMPLETIONSTATEMENT_TYPES = COMPLETIONSTATEMENT_TYPES; +const CONDITIONAL_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Conditional"]; +exports.CONDITIONAL_TYPES = CONDITIONAL_TYPES; +const LOOP_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Loop"]; +exports.LOOP_TYPES = LOOP_TYPES; +const WHILE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["While"]; +exports.WHILE_TYPES = WHILE_TYPES; +const EXPRESSIONWRAPPER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ExpressionWrapper"]; +exports.EXPRESSIONWRAPPER_TYPES = EXPRESSIONWRAPPER_TYPES; +const FOR_TYPES = _definitions.FLIPPED_ALIAS_KEYS["For"]; +exports.FOR_TYPES = FOR_TYPES; +const FORXSTATEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ForXStatement"]; +exports.FORXSTATEMENT_TYPES = FORXSTATEMENT_TYPES; +const FUNCTION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Function"]; +exports.FUNCTION_TYPES = FUNCTION_TYPES; +const FUNCTIONPARENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FunctionParent"]; +exports.FUNCTIONPARENT_TYPES = FUNCTIONPARENT_TYPES; +const PUREISH_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Pureish"]; +exports.PUREISH_TYPES = PUREISH_TYPES; +const DECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Declaration"]; +exports.DECLARATION_TYPES = DECLARATION_TYPES; +const PATTERNLIKE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["PatternLike"]; +exports.PATTERNLIKE_TYPES = PATTERNLIKE_TYPES; +const LVAL_TYPES = _definitions.FLIPPED_ALIAS_KEYS["LVal"]; +exports.LVAL_TYPES = LVAL_TYPES; +const TSENTITYNAME_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSEntityName"]; +exports.TSENTITYNAME_TYPES = TSENTITYNAME_TYPES; +const LITERAL_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Literal"]; +exports.LITERAL_TYPES = LITERAL_TYPES; +const IMMUTABLE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Immutable"]; +exports.IMMUTABLE_TYPES = IMMUTABLE_TYPES; +const USERWHITESPACABLE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["UserWhitespacable"]; +exports.USERWHITESPACABLE_TYPES = USERWHITESPACABLE_TYPES; +const METHOD_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Method"]; +exports.METHOD_TYPES = METHOD_TYPES; +const OBJECTMEMBER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ObjectMember"]; +exports.OBJECTMEMBER_TYPES = OBJECTMEMBER_TYPES; +const PROPERTY_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Property"]; +exports.PROPERTY_TYPES = PROPERTY_TYPES; +const UNARYLIKE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["UnaryLike"]; +exports.UNARYLIKE_TYPES = UNARYLIKE_TYPES; +const PATTERN_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Pattern"]; +exports.PATTERN_TYPES = PATTERN_TYPES; +const CLASS_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Class"]; +exports.CLASS_TYPES = CLASS_TYPES; +const MODULEDECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ModuleDeclaration"]; +exports.MODULEDECLARATION_TYPES = MODULEDECLARATION_TYPES; +const EXPORTDECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ExportDeclaration"]; +exports.EXPORTDECLARATION_TYPES = EXPORTDECLARATION_TYPES; +const MODULESPECIFIER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ModuleSpecifier"]; +exports.MODULESPECIFIER_TYPES = MODULESPECIFIER_TYPES; +const ACCESSOR_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Accessor"]; +exports.ACCESSOR_TYPES = ACCESSOR_TYPES; +const PRIVATE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Private"]; +exports.PRIVATE_TYPES = PRIVATE_TYPES; +const FLOW_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Flow"]; +exports.FLOW_TYPES = FLOW_TYPES; +const FLOWTYPE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowType"]; +exports.FLOWTYPE_TYPES = FLOWTYPE_TYPES; +const FLOWBASEANNOTATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowBaseAnnotation"]; +exports.FLOWBASEANNOTATION_TYPES = FLOWBASEANNOTATION_TYPES; +const FLOWDECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowDeclaration"]; +exports.FLOWDECLARATION_TYPES = FLOWDECLARATION_TYPES; +const FLOWPREDICATE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowPredicate"]; +exports.FLOWPREDICATE_TYPES = FLOWPREDICATE_TYPES; +const ENUMBODY_TYPES = _definitions.FLIPPED_ALIAS_KEYS["EnumBody"]; +exports.ENUMBODY_TYPES = ENUMBODY_TYPES; +const ENUMMEMBER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["EnumMember"]; +exports.ENUMMEMBER_TYPES = ENUMMEMBER_TYPES; +const JSX_TYPES = _definitions.FLIPPED_ALIAS_KEYS["JSX"]; +exports.JSX_TYPES = JSX_TYPES; +const MISCELLANEOUS_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Miscellaneous"]; +exports.MISCELLANEOUS_TYPES = MISCELLANEOUS_TYPES; +const TYPESCRIPT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TypeScript"]; +exports.TYPESCRIPT_TYPES = TYPESCRIPT_TYPES; +const TSTYPEELEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSTypeElement"]; +exports.TSTYPEELEMENT_TYPES = TSTYPEELEMENT_TYPES; +const TSTYPE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSType"]; +exports.TSTYPE_TYPES = TSTYPE_TYPES; +const TSBASETYPE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSBaseType"]; +exports.TSBASETYPE_TYPES = TSBASETYPE_TYPES; \ No newline at end of file diff --git a/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/types/lib/validators/generated/index.js b/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/types/lib/validators/generated/index.js new file mode 100644 index 000000000..f2956ec01 --- /dev/null +++ b/node_modules/@isaacs/import-jsx/node_modules/@babel/plugin-syntax-object-rest-spread/node_modules/@babel/types/lib/validators/generated/index.js @@ -0,0 +1,4811 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.isAccessor = isAccessor; +exports.isAnyTypeAnnotation = isAnyTypeAnnotation; +exports.isArgumentPlaceholder = isArgumentPlaceholder; +exports.isArrayExpression = isArrayExpression; +exports.isArrayPattern = isArrayPattern; +exports.isArrayTypeAnnotation = isArrayTypeAnnotation; +exports.isArrowFunctionExpression = isArrowFunctionExpression; +exports.isAssignmentExpression = isAssignmentExpression; +exports.isAssignmentPattern = isAssignmentPattern; +exports.isAwaitExpression = isAwaitExpression; +exports.isBigIntLiteral = isBigIntLiteral; +exports.isBinary = isBinary; +exports.isBinaryExpression = isBinaryExpression; +exports.isBindExpression = isBindExpression; +exports.isBlock = isBlock; +exports.isBlockParent = isBlockParent; +exports.isBlockStatement = isBlockStatement; +exports.isBooleanLiteral = isBooleanLiteral; +exports.isBooleanLiteralTypeAnnotation = isBooleanLiteralTypeAnnotation; +exports.isBooleanTypeAnnotation = isBooleanTypeAnnotation; +exports.isBreakStatement = isBreakStatement; +exports.isCallExpression = isCallExpression; +exports.isCatchClause = isCatchClause; +exports.isClass = isClass; +exports.isClassAccessorProperty = isClassAccessorProperty; +exports.isClassBody = isClassBody; +exports.isClassDeclaration = isClassDeclaration; +exports.isClassExpression = isClassExpression; +exports.isClassImplements = isClassImplements; +exports.isClassMethod = isClassMethod; +exports.isClassPrivateMethod = isClassPrivateMethod; +exports.isClassPrivateProperty = isClassPrivateProperty; +exports.isClassProperty = isClassProperty; +exports.isCompletionStatement = isCompletionStatement; +exports.isConditional = isConditional; +exports.isConditionalExpression = isConditionalExpression; +exports.isContinueStatement = isContinueStatement; +exports.isDebuggerStatement = isDebuggerStatement; +exports.isDecimalLiteral = isDecimalLiteral; +exports.isDeclaration = isDeclaration; +exports.isDeclareClass = isDeclareClass; +exports.isDeclareExportAllDeclaration = isDeclareExportAllDeclaration; +exports.isDeclareExportDeclaration = isDeclareExportDeclaration; +exports.isDeclareFunction = isDeclareFunction; +exports.isDeclareInterface = isDeclareInterface; +exports.isDeclareModule = isDeclareModule; +exports.isDeclareModuleExports = isDeclareModuleExports; +exports.isDeclareOpaqueType = isDeclareOpaqueType; +exports.isDeclareTypeAlias = isDeclareTypeAlias; +exports.isDeclareVariable = isDeclareVariable; +exports.isDeclaredPredicate = isDeclaredPredicate; +exports.isDecorator = isDecorator; +exports.isDirective = isDirective; +exports.isDirectiveLiteral = isDirectiveLiteral; +exports.isDoExpression = isDoExpression; +exports.isDoWhileStatement = isDoWhileStatement; +exports.isEmptyStatement = isEmptyStatement; +exports.isEmptyTypeAnnotation = isEmptyTypeAnnotation; +exports.isEnumBody = isEnumBody; +exports.isEnumBooleanBody = isEnumBooleanBody; +exports.isEnumBooleanMember = isEnumBooleanMember; +exports.isEnumDeclaration = isEnumDeclaration; +exports.isEnumDefaultedMember = isEnumDefaultedMember; +exports.isEnumMember = isEnumMember; +exports.isEnumNumberBody = isEnumNumberBody; +exports.isEnumNumberMember = isEnumNumberMember; +exports.isEnumStringBody = isEnumStringBody; +exports.isEnumStringMember = isEnumStringMember; +exports.isEnumSymbolBody = isEnumSymbolBody; +exports.isExistsTypeAnnotation = isExistsTypeAnnotation; +exports.isExportAllDeclaration = isExportAllDeclaration; +exports.isExportDeclaration = isExportDeclaration; +exports.isExportDefaultDeclaration = isExportDefaultDeclaration; +exports.isExportDefaultSpecifier = isExportDefaultSpecifier; +exports.isExportNamedDeclaration = isExportNamedDeclaration; +exports.isExportNamespaceSpecifier = isExportNamespaceSpecifier; +exports.isExportSpecifier = isExportSpecifier; +exports.isExpression = isExpression; +exports.isExpressionStatement = isExpressionStatement; +exports.isExpressionWrapper = isExpressionWrapper; +exports.isFile = isFile; +exports.isFlow = isFlow; +exports.isFlowBaseAnnotation = isFlowBaseAnnotation; +exports.isFlowDeclaration = isFlowDeclaration; +exports.isFlowPredicate = isFlowPredicate; +exports.isFlowType = isFlowType; +exports.isFor = isFor; +exports.isForInStatement = isForInStatement; +exports.isForOfStatement = isForOfStatement; +exports.isForStatement = isForStatement; +exports.isForXStatement = isForXStatement; +exports.isFunction = isFunction; +exports.isFunctionDeclaration = isFunctionDeclaration; +exports.isFunctionExpression = isFunctionExpression; +exports.isFunctionParent = isFunctionParent; +exports.isFunctionTypeAnnotation = isFunctionTypeAnnotation; +exports.isFunctionTypeParam = isFunctionTypeParam; +exports.isGenericTypeAnnotation = isGenericTypeAnnotation; +exports.isIdentifier = isIdentifier; +exports.isIfStatement = isIfStatement; +exports.isImmutable = isImmutable; +exports.isImport = isImport; +exports.isImportAttribute = isImportAttribute; +exports.isImportDeclaration = isImportDeclaration; +exports.isImportDefaultSpecifier = isImportDefaultSpecifier; +exports.isImportNamespaceSpecifier = isImportNamespaceSpecifier; +exports.isImportSpecifier = isImportSpecifier; +exports.isIndexedAccessType = isIndexedAccessType; +exports.isInferredPredicate = isInferredPredicate; +exports.isInterfaceDeclaration = isInterfaceDeclaration; +exports.isInterfaceExtends = isInterfaceExtends; +exports.isInterfaceTypeAnnotation = isInterfaceTypeAnnotation; +exports.isInterpreterDirective = isInterpreterDirective; +exports.isIntersectionTypeAnnotation = isIntersectionTypeAnnotation; +exports.isJSX = isJSX; +exports.isJSXAttribute = isJSXAttribute; +exports.isJSXClosingElement = isJSXClosingElement; +exports.isJSXClosingFragment = isJSXClosingFragment; +exports.isJSXElement = isJSXElement; +exports.isJSXEmptyExpression = isJSXEmptyExpression; +exports.isJSXExpressionContainer = isJSXExpressionContainer; +exports.isJSXFragment = isJSXFragment; +exports.isJSXIdentifier = isJSXIdentifier; +exports.isJSXMemberExpression = isJSXMemberExpression; +exports.isJSXNamespacedName = isJSXNamespacedName; +exports.isJSXOpeningElement = isJSXOpeningElement; +exports.isJSXOpeningFragment = isJSXOpeningFragment; +exports.isJSXSpreadAttribute = isJSXSpreadAttribute; +exports.isJSXSpreadChild = isJSXSpreadChild; +exports.isJSXText = isJSXText; +exports.isLVal = isLVal; +exports.isLabeledStatement = isLabeledStatement; +exports.isLiteral = isLiteral; +exports.isLogicalExpression = isLogicalExpression; +exports.isLoop = isLoop; +exports.isMemberExpression = isMemberExpression; +exports.isMetaProperty = isMetaProperty; +exports.isMethod = isMethod; +exports.isMiscellaneous = isMiscellaneous; +exports.isMixedTypeAnnotation = isMixedTypeAnnotation; +exports.isModuleDeclaration = isModuleDeclaration; +exports.isModuleExpression = isModuleExpression; +exports.isModuleSpecifier = isModuleSpecifier; +exports.isNewExpression = isNewExpression; +exports.isNoop = isNoop; +exports.isNullLiteral = isNullLiteral; +exports.isNullLiteralTypeAnnotation = isNullLiteralTypeAnnotation; +exports.isNullableTypeAnnotation = isNullableTypeAnnotation; +exports.isNumberLiteral = isNumberLiteral; +exports.isNumberLiteralTypeAnnotation = isNumberLiteralTypeAnnotation; +exports.isNumberTypeAnnotation = isNumberTypeAnnotation; +exports.isNumericLiteral = isNumericLiteral; +exports.isObjectExpression = isObjectExpression; +exports.isObjectMember = isObjectMember; +exports.isObjectMethod = isObjectMethod; +exports.isObjectPattern = isObjectPattern; +exports.isObjectProperty = isObjectProperty; +exports.isObjectTypeAnnotation = isObjectTypeAnnotation; +exports.isObjectTypeCallProperty = isObjectTypeCallProperty; +exports.isObjectTypeIndexer = isObjectTypeIndexer; +exports.isObjectTypeInternalSlot = isObjectTypeInternalSlot; +exports.isObjectTypeProperty = isObjectTypeProperty; +exports.isObjectTypeSpreadProperty = isObjectTypeSpreadProperty; +exports.isOpaqueType = isOpaqueType; +exports.isOptionalCallExpression = isOptionalCallExpression; +exports.isOptionalIndexedAccessType = isOptionalIndexedAccessType; +exports.isOptionalMemberExpression = isOptionalMemberExpression; +exports.isParenthesizedExpression = isParenthesizedExpression; +exports.isPattern = isPattern; +exports.isPatternLike = isPatternLike; +exports.isPipelineBareFunction = isPipelineBareFunction; +exports.isPipelinePrimaryTopicReference = isPipelinePrimaryTopicReference; +exports.isPipelineTopicExpression = isPipelineTopicExpression; +exports.isPlaceholder = isPlaceholder; +exports.isPrivate = isPrivate; +exports.isPrivateName = isPrivateName; +exports.isProgram = isProgram; +exports.isProperty = isProperty; +exports.isPureish = isPureish; +exports.isQualifiedTypeIdentifier = isQualifiedTypeIdentifier; +exports.isRecordExpression = isRecordExpression; +exports.isRegExpLiteral = isRegExpLiteral; +exports.isRegexLiteral = isRegexLiteral; +exports.isRestElement = isRestElement; +exports.isRestProperty = isRestProperty; +exports.isReturnStatement = isReturnStatement; +exports.isScopable = isScopable; +exports.isSequenceExpression = isSequenceExpression; +exports.isSpreadElement = isSpreadElement; +exports.isSpreadProperty = isSpreadProperty; +exports.isStandardized = isStandardized; +exports.isStatement = isStatement; +exports.isStaticBlock = isStaticBlock; +exports.isStringLiteral = isStringLiteral; +exports.isStringLiteralTypeAnnotation = isStringLiteralTypeAnnotation; +exports.isStringTypeAnnotation = isStringTypeAnnotation; +exports.isSuper = isSuper; +exports.isSwitchCase = isSwitchCase; +exports.isSwitchStatement = isSwitchStatement; +exports.isSymbolTypeAnnotation = isSymbolTypeAnnotation; +exports.isTSAnyKeyword = isTSAnyKeyword; +exports.isTSArrayType = isTSArrayType; +exports.isTSAsExpression = isTSAsExpression; +exports.isTSBaseType = isTSBaseType; +exports.isTSBigIntKeyword = isTSBigIntKeyword; +exports.isTSBooleanKeyword = isTSBooleanKeyword; +exports.isTSCallSignatureDeclaration = isTSCallSignatureDeclaration; +exports.isTSConditionalType = isTSConditionalType; +exports.isTSConstructSignatureDeclaration = isTSConstructSignatureDeclaration; +exports.isTSConstructorType = isTSConstructorType; +exports.isTSDeclareFunction = isTSDeclareFunction; +exports.isTSDeclareMethod = isTSDeclareMethod; +exports.isTSEntityName = isTSEntityName; +exports.isTSEnumDeclaration = isTSEnumDeclaration; +exports.isTSEnumMember = isTSEnumMember; +exports.isTSExportAssignment = isTSExportAssignment; +exports.isTSExpressionWithTypeArguments = isTSExpressionWithTypeArguments; +exports.isTSExternalModuleReference = isTSExternalModuleReference; +exports.isTSFunctionType = isTSFunctionType; +exports.isTSImportEqualsDeclaration = isTSImportEqualsDeclaration; +exports.isTSImportType = isTSImportType; +exports.isTSIndexSignature = isTSIndexSignature; +exports.isTSIndexedAccessType = isTSIndexedAccessType; +exports.isTSInferType = isTSInferType; +exports.isTSInterfaceBody = isTSInterfaceBody; +exports.isTSInterfaceDeclaration = isTSInterfaceDeclaration; +exports.isTSIntersectionType = isTSIntersectionType; +exports.isTSIntrinsicKeyword = isTSIntrinsicKeyword; +exports.isTSLiteralType = isTSLiteralType; +exports.isTSMappedType = isTSMappedType; +exports.isTSMethodSignature = isTSMethodSignature; +exports.isTSModuleBlock = isTSModuleBlock; +exports.isTSModuleDeclaration = isTSModuleDeclaration; +exports.isTSNamedTupleMember = isTSNamedTupleMember; +exports.isTSNamespaceExportDeclaration = isTSNamespaceExportDeclaration; +exports.isTSNeverKeyword = isTSNeverKeyword; +exports.isTSNonNullExpression = isTSNonNullExpression; +exports.isTSNullKeyword = isTSNullKeyword; +exports.isTSNumberKeyword = isTSNumberKeyword; +exports.isTSObjectKeyword = isTSObjectKeyword; +exports.isTSOptionalType = isTSOptionalType; +exports.isTSParameterProperty = isTSParameterProperty; +exports.isTSParenthesizedType = isTSParenthesizedType; +exports.isTSPropertySignature = isTSPropertySignature; +exports.isTSQualifiedName = isTSQualifiedName; +exports.isTSRestType = isTSRestType; +exports.isTSStringKeyword = isTSStringKeyword; +exports.isTSSymbolKeyword = isTSSymbolKeyword; +exports.isTSThisType = isTSThisType; +exports.isTSTupleType = isTSTupleType; +exports.isTSType = isTSType; +exports.isTSTypeAliasDeclaration = isTSTypeAliasDeclaration; +exports.isTSTypeAnnotation = isTSTypeAnnotation; +exports.isTSTypeAssertion = isTSTypeAssertion; +exports.isTSTypeElement = isTSTypeElement; +exports.isTSTypeLiteral = isTSTypeLiteral; +exports.isTSTypeOperator = isTSTypeOperator; +exports.isTSTypeParameter = isTSTypeParameter; +exports.isTSTypeParameterDeclaration = isTSTypeParameterDeclaration; +exports.isTSTypeParameterInstantiation = isTSTypeParameterInstantiation; +exports.isTSTypePredicate = isTSTypePredicate; +exports.isTSTypeQuery = isTSTypeQuery; +exports.isTSTypeReference = isTSTypeReference; +exports.isTSUndefinedKeyword = isTSUndefinedKeyword; +exports.isTSUnionType = isTSUnionType; +exports.isTSUnknownKeyword = isTSUnknownKeyword; +exports.isTSVoidKeyword = isTSVoidKeyword; +exports.isTaggedTemplateExpression = isTaggedTemplateExpression; +exports.isTemplateElement = isTemplateElement; +exports.isTemplateLiteral = isTemplateLiteral; +exports.isTerminatorless = isTerminatorless; +exports.isThisExpression = isThisExpression; +exports.isThisTypeAnnotation = isThisTypeAnnotation; +exports.isThrowStatement = isThrowStatement; +exports.isTopicReference = isTopicReference; +exports.isTryStatement = isTryStatement; +exports.isTupleExpression = isTupleExpression; +exports.isTupleTypeAnnotation = isTupleTypeAnnotation; +exports.isTypeAlias = isTypeAlias; +exports.isTypeAnnotation = isTypeAnnotation; +exports.isTypeCastExpression = isTypeCastExpression; +exports.isTypeParameter = isTypeParameter; +exports.isTypeParameterDeclaration = isTypeParameterDeclaration; +exports.isTypeParameterInstantiation = isTypeParameterInstantiation; +exports.isTypeScript = isTypeScript; +exports.isTypeofTypeAnnotation = isTypeofTypeAnnotation; +exports.isUnaryExpression = isUnaryExpression; +exports.isUnaryLike = isUnaryLike; +exports.isUnionTypeAnnotation = isUnionTypeAnnotation; +exports.isUpdateExpression = isUpdateExpression; +exports.isUserWhitespacable = isUserWhitespacable; +exports.isV8IntrinsicIdentifier = isV8IntrinsicIdentifier; +exports.isVariableDeclaration = isVariableDeclaration; +exports.isVariableDeclarator = isVariableDeclarator; +exports.isVariance = isVariance; +exports.isVoidTypeAnnotation = isVoidTypeAnnotation; +exports.isWhile = isWhile; +exports.isWhileStatement = isWhileStatement; +exports.isWithStatement = isWithStatement; +exports.isYieldExpression = isYieldExpression; + +var _shallowEqual = require("../../utils/shallowEqual"); + +function isArrayExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrayExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAssignmentExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AssignmentExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBinaryExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BinaryExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterpreterDirective(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterpreterDirective") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDirective(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Directive") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDirectiveLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DirectiveLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBlockStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BlockStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBreakStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BreakStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isCallExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "CallExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isCatchClause(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "CatchClause") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isConditionalExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ConditionalExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isContinueStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ContinueStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDebuggerStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DebuggerStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDoWhileStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DoWhileStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEmptyStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EmptyStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExpressionStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExpressionStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFile(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "File") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForInStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ForInStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ForStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Identifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIfStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "IfStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLabeledStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "LabeledStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStringLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StringLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumericLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumericLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNullLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NullLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBooleanLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BooleanLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRegExpLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RegExpLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLogicalExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "LogicalExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMemberExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "MemberExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNewExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NewExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isProgram(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Program") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRestElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RestElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isReturnStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ReturnStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSequenceExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SequenceExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isParenthesizedExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ParenthesizedExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSwitchCase(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SwitchCase") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSwitchStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SwitchStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isThisExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ThisExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isThrowStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ThrowStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTryStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TryStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUnaryExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "UnaryExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUpdateExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "UpdateExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVariableDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "VariableDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVariableDeclarator(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "VariableDeclarator") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isWhileStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "WhileStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isWithStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "WithStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAssignmentPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AssignmentPattern") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArrayPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrayPattern") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArrowFunctionExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrowFunctionExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportAllDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportAllDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportDefaultDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportDefaultDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportNamedDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportNamedDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForOfStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ForOfStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportDefaultSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportDefaultSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportNamespaceSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportNamespaceSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMetaProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "MetaProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectPattern") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSpreadElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SpreadElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSuper(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Super") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTaggedTemplateExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TaggedTemplateExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTemplateElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TemplateElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTemplateLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TemplateLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isYieldExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "YieldExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAwaitExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AwaitExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImport(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Import") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBigIntLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BigIntLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportNamespaceSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportNamespaceSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOptionalMemberExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OptionalMemberExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOptionalCallExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OptionalCallExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassAccessorProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassAccessorProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassPrivateProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassPrivateProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassPrivateMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassPrivateMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPrivateName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PrivateName") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStaticBlock(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StaticBlock") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAnyTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AnyTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArrayTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrayTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBooleanTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BooleanTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBooleanLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BooleanLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNullLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NullLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassImplements(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassImplements") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareClass(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareClass") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareFunction") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareInterface(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareInterface") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareModule(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareModule") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareModuleExports(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareModuleExports") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareTypeAlias(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareTypeAlias") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareOpaqueType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareOpaqueType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareVariable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareVariable") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareExportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareExportDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareExportAllDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareExportAllDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclaredPredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclaredPredicate") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExistsTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExistsTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionTypeParam(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionTypeParam") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isGenericTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "GenericTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInferredPredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InferredPredicate") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterfaceExtends(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterfaceExtends") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterfaceDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterfaceDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterfaceTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterfaceTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIntersectionTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "IntersectionTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMixedTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "MixedTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEmptyTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EmptyTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNullableTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NullableTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumberLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumberLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumberTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumberTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeInternalSlot(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeInternalSlot") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeCallProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeCallProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeIndexer(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeIndexer") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeSpreadProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeSpreadProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOpaqueType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OpaqueType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isQualifiedTypeIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "QualifiedTypeIdentifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStringLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StringLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStringTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StringTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSymbolTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SymbolTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isThisTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ThisTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTupleTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TupleTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeofTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeofTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeAlias(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeAlias") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeCastExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeCastExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeParameter(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeParameter") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeParameterDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeParameterDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeParameterInstantiation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeParameterInstantiation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUnionTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "UnionTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVariance(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Variance") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVoidTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "VoidTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumBooleanBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumBooleanBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumNumberBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumNumberBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumStringBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumStringBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumSymbolBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumSymbolBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumBooleanMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumBooleanMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumNumberMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumNumberMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumStringMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumStringMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumDefaultedMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumDefaultedMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIndexedAccessType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "IndexedAccessType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOptionalIndexedAccessType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OptionalIndexedAccessType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXAttribute(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXAttribute") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXClosingElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXClosingElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXEmptyExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXEmptyExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXExpressionContainer(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXExpressionContainer") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXSpreadChild(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXSpreadChild") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXIdentifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXMemberExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXMemberExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXNamespacedName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXNamespacedName") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXOpeningElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXOpeningElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXSpreadAttribute(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXSpreadAttribute") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXText(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXText") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXFragment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXFragment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXOpeningFragment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXOpeningFragment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXClosingFragment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXClosingFragment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNoop(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Noop") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPlaceholder(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Placeholder") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isV8IntrinsicIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "V8IntrinsicIdentifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArgumentPlaceholder(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArgumentPlaceholder") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBindExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BindExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportAttribute(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportAttribute") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDecorator(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Decorator") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDoExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DoExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportDefaultSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportDefaultSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRecordExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RecordExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTupleExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TupleExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDecimalLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DecimalLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isModuleExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ModuleExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTopicReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TopicReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPipelineTopicExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PipelineTopicExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPipelineBareFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PipelineBareFunction") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPipelinePrimaryTopicReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PipelinePrimaryTopicReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSParameterProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSParameterProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSDeclareFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSDeclareFunction") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSDeclareMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSDeclareMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSQualifiedName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSQualifiedName") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSCallSignatureDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSCallSignatureDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSConstructSignatureDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSConstructSignatureDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSPropertySignature(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSPropertySignature") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSMethodSignature(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSMethodSignature") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIndexSignature(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIndexSignature") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSAnyKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSAnyKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSBooleanKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSBooleanKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSBigIntKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSBigIntKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIntrinsicKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIntrinsicKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNeverKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNeverKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNullKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNullKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNumberKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNumberKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSObjectKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSObjectKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSStringKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSStringKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSSymbolKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSSymbolKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSUndefinedKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSUndefinedKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSUnknownKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSUnknownKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSVoidKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSVoidKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSThisType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSThisType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSFunctionType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSFunctionType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSConstructorType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSConstructorType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypePredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypePredicate") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeQuery(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeQuery") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSArrayType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSArrayType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTupleType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTupleType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSOptionalType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSOptionalType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSRestType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSRestType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNamedTupleMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNamedTupleMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSUnionType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSUnionType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIntersectionType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIntersectionType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSConditionalType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSConditionalType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSInferType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSInferType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSParenthesizedType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSParenthesizedType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeOperator(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeOperator") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIndexedAccessType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIndexedAccessType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSMappedType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSMappedType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSLiteralType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSLiteralType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSExpressionWithTypeArguments(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSExpressionWithTypeArguments") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSInterfaceDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSInterfaceDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSInterfaceBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSInterfaceBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeAliasDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeAliasDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSAsExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSAsExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeAssertion(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeAssertion") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSEnumDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSEnumDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSEnumMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSEnumMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSModuleDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSModuleDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSModuleBlock(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSModuleBlock") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSImportType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSImportType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSImportEqualsDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSImportEqualsDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSExternalModuleReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSExternalModuleReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNonNullExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNonNullExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSExportAssignment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSExportAssignment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNamespaceExportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNamespaceExportDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeParameterInstantiation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeParameterInstantiation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeParameterDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeParameterDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeParameter(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeParameter") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStandardized(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ArrayExpression" === nodeType || "AssignmentExpression" === nodeType || "BinaryExpression" === nodeType || "InterpreterDirective" === nodeType || "Directive" === nodeType || "DirectiveLiteral" === nodeType || "BlockStatement" === nodeType || "BreakStatement" === nodeType || "CallExpression" === nodeType || "CatchClause" === nodeType || "ConditionalExpression" === nodeType || "ContinueStatement" === nodeType || "DebuggerStatement" === nodeType || "DoWhileStatement" === nodeType || "EmptyStatement" === nodeType || "ExpressionStatement" === nodeType || "File" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "Identifier" === nodeType || "IfStatement" === nodeType || "LabeledStatement" === nodeType || "StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "LogicalExpression" === nodeType || "MemberExpression" === nodeType || "NewExpression" === nodeType || "Program" === nodeType || "ObjectExpression" === nodeType || "ObjectMethod" === nodeType || "ObjectProperty" === nodeType || "RestElement" === nodeType || "ReturnStatement" === nodeType || "SequenceExpression" === nodeType || "ParenthesizedExpression" === nodeType || "SwitchCase" === nodeType || "SwitchStatement" === nodeType || "ThisExpression" === nodeType || "ThrowStatement" === nodeType || "TryStatement" === nodeType || "UnaryExpression" === nodeType || "UpdateExpression" === nodeType || "VariableDeclaration" === nodeType || "VariableDeclarator" === nodeType || "WhileStatement" === nodeType || "WithStatement" === nodeType || "AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassBody" === nodeType || "ClassExpression" === nodeType || "ClassDeclaration" === nodeType || "ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ExportSpecifier" === nodeType || "ForOfStatement" === nodeType || "ImportDeclaration" === nodeType || "ImportDefaultSpecifier" === nodeType || "ImportNamespaceSpecifier" === nodeType || "ImportSpecifier" === nodeType || "MetaProperty" === nodeType || "ClassMethod" === nodeType || "ObjectPattern" === nodeType || "SpreadElement" === nodeType || "Super" === nodeType || "TaggedTemplateExpression" === nodeType || "TemplateElement" === nodeType || "TemplateLiteral" === nodeType || "YieldExpression" === nodeType || "AwaitExpression" === nodeType || "Import" === nodeType || "BigIntLiteral" === nodeType || "ExportNamespaceSpecifier" === nodeType || "OptionalMemberExpression" === nodeType || "OptionalCallExpression" === nodeType || "ClassProperty" === nodeType || "ClassAccessorProperty" === nodeType || "ClassPrivateProperty" === nodeType || "ClassPrivateMethod" === nodeType || "PrivateName" === nodeType || "StaticBlock" === nodeType || nodeType === "Placeholder" && ("Identifier" === node.expectedNode || "StringLiteral" === node.expectedNode || "BlockStatement" === node.expectedNode || "ClassBody" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ArrayExpression" === nodeType || "AssignmentExpression" === nodeType || "BinaryExpression" === nodeType || "CallExpression" === nodeType || "ConditionalExpression" === nodeType || "FunctionExpression" === nodeType || "Identifier" === nodeType || "StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "LogicalExpression" === nodeType || "MemberExpression" === nodeType || "NewExpression" === nodeType || "ObjectExpression" === nodeType || "SequenceExpression" === nodeType || "ParenthesizedExpression" === nodeType || "ThisExpression" === nodeType || "UnaryExpression" === nodeType || "UpdateExpression" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassExpression" === nodeType || "MetaProperty" === nodeType || "Super" === nodeType || "TaggedTemplateExpression" === nodeType || "TemplateLiteral" === nodeType || "YieldExpression" === nodeType || "AwaitExpression" === nodeType || "Import" === nodeType || "BigIntLiteral" === nodeType || "OptionalMemberExpression" === nodeType || "OptionalCallExpression" === nodeType || "TypeCastExpression" === nodeType || "JSXElement" === nodeType || "JSXFragment" === nodeType || "BindExpression" === nodeType || "DoExpression" === nodeType || "RecordExpression" === nodeType || "TupleExpression" === nodeType || "DecimalLiteral" === nodeType || "ModuleExpression" === nodeType || "TopicReference" === nodeType || "PipelineTopicExpression" === nodeType || "PipelineBareFunction" === nodeType || "PipelinePrimaryTopicReference" === nodeType || "TSAsExpression" === nodeType || "TSTypeAssertion" === nodeType || "TSNonNullExpression" === nodeType || nodeType === "Placeholder" && ("Expression" === node.expectedNode || "Identifier" === node.expectedNode || "StringLiteral" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBinary(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BinaryExpression" === nodeType || "LogicalExpression" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isScopable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "CatchClause" === nodeType || "DoWhileStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "Program" === nodeType || "ObjectMethod" === nodeType || "SwitchStatement" === nodeType || "WhileStatement" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassExpression" === nodeType || "ClassDeclaration" === nodeType || "ForOfStatement" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType || "StaticBlock" === nodeType || "TSModuleBlock" === nodeType || nodeType === "Placeholder" && "BlockStatement" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBlockParent(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "CatchClause" === nodeType || "DoWhileStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "Program" === nodeType || "ObjectMethod" === nodeType || "SwitchStatement" === nodeType || "WhileStatement" === nodeType || "ArrowFunctionExpression" === nodeType || "ForOfStatement" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType || "StaticBlock" === nodeType || "TSModuleBlock" === nodeType || nodeType === "Placeholder" && "BlockStatement" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBlock(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "Program" === nodeType || "TSModuleBlock" === nodeType || nodeType === "Placeholder" && "BlockStatement" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "BreakStatement" === nodeType || "ContinueStatement" === nodeType || "DebuggerStatement" === nodeType || "DoWhileStatement" === nodeType || "EmptyStatement" === nodeType || "ExpressionStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "IfStatement" === nodeType || "LabeledStatement" === nodeType || "ReturnStatement" === nodeType || "SwitchStatement" === nodeType || "ThrowStatement" === nodeType || "TryStatement" === nodeType || "VariableDeclaration" === nodeType || "WhileStatement" === nodeType || "WithStatement" === nodeType || "ClassDeclaration" === nodeType || "ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ForOfStatement" === nodeType || "ImportDeclaration" === nodeType || "DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "InterfaceDeclaration" === nodeType || "OpaqueType" === nodeType || "TypeAlias" === nodeType || "EnumDeclaration" === nodeType || "TSDeclareFunction" === nodeType || "TSInterfaceDeclaration" === nodeType || "TSTypeAliasDeclaration" === nodeType || "TSEnumDeclaration" === nodeType || "TSModuleDeclaration" === nodeType || "TSImportEqualsDeclaration" === nodeType || "TSExportAssignment" === nodeType || "TSNamespaceExportDeclaration" === nodeType || nodeType === "Placeholder" && ("Statement" === node.expectedNode || "Declaration" === node.expectedNode || "BlockStatement" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTerminatorless(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BreakStatement" === nodeType || "ContinueStatement" === nodeType || "ReturnStatement" === nodeType || "ThrowStatement" === nodeType || "YieldExpression" === nodeType || "AwaitExpression" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isCompletionStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BreakStatement" === nodeType || "ContinueStatement" === nodeType || "ReturnStatement" === nodeType || "ThrowStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isConditional(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ConditionalExpression" === nodeType || "IfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLoop(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DoWhileStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "WhileStatement" === nodeType || "ForOfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isWhile(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DoWhileStatement" === nodeType || "WhileStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExpressionWrapper(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExpressionStatement" === nodeType || "ParenthesizedExpression" === nodeType || "TypeCastExpression" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFor(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ForInStatement" === nodeType || "ForStatement" === nodeType || "ForOfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForXStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ForInStatement" === nodeType || "ForOfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "ObjectMethod" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionParent(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "ObjectMethod" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType || "StaticBlock" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPureish(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "ArrowFunctionExpression" === nodeType || "BigIntLiteral" === nodeType || "DecimalLiteral" === nodeType || nodeType === "Placeholder" && "StringLiteral" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "VariableDeclaration" === nodeType || "ClassDeclaration" === nodeType || "ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ImportDeclaration" === nodeType || "DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "InterfaceDeclaration" === nodeType || "OpaqueType" === nodeType || "TypeAlias" === nodeType || "EnumDeclaration" === nodeType || "TSDeclareFunction" === nodeType || "TSInterfaceDeclaration" === nodeType || "TSTypeAliasDeclaration" === nodeType || "TSEnumDeclaration" === nodeType || "TSModuleDeclaration" === nodeType || nodeType === "Placeholder" && "Declaration" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPatternLike(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Identifier" === nodeType || "RestElement" === nodeType || "AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ObjectPattern" === nodeType || nodeType === "Placeholder" && ("Pattern" === node.expectedNode || "Identifier" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLVal(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Identifier" === nodeType || "MemberExpression" === nodeType || "RestElement" === nodeType || "AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ObjectPattern" === nodeType || "TSParameterProperty" === nodeType || nodeType === "Placeholder" && ("Pattern" === node.expectedNode || "Identifier" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSEntityName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Identifier" === nodeType || "TSQualifiedName" === nodeType || nodeType === "Placeholder" && "Identifier" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "TemplateLiteral" === nodeType || "BigIntLiteral" === nodeType || "DecimalLiteral" === nodeType || nodeType === "Placeholder" && "StringLiteral" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImmutable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "BigIntLiteral" === nodeType || "JSXAttribute" === nodeType || "JSXClosingElement" === nodeType || "JSXElement" === nodeType || "JSXExpressionContainer" === nodeType || "JSXSpreadChild" === nodeType || "JSXOpeningElement" === nodeType || "JSXText" === nodeType || "JSXFragment" === nodeType || "JSXOpeningFragment" === nodeType || "JSXClosingFragment" === nodeType || "DecimalLiteral" === nodeType || nodeType === "Placeholder" && "StringLiteral" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUserWhitespacable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectMethod" === nodeType || "ObjectProperty" === nodeType || "ObjectTypeInternalSlot" === nodeType || "ObjectTypeCallProperty" === nodeType || "ObjectTypeIndexer" === nodeType || "ObjectTypeProperty" === nodeType || "ObjectTypeSpreadProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectMethod" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectMethod" === nodeType || "ObjectProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectProperty" === nodeType || "ClassProperty" === nodeType || "ClassAccessorProperty" === nodeType || "ClassPrivateProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUnaryLike(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("UnaryExpression" === nodeType || "SpreadElement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ObjectPattern" === nodeType || nodeType === "Placeholder" && "Pattern" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClass(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ClassExpression" === nodeType || "ClassDeclaration" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isModuleDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ImportDeclaration" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isModuleSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExportSpecifier" === nodeType || "ImportDefaultSpecifier" === nodeType || "ImportNamespaceSpecifier" === nodeType || "ImportSpecifier" === nodeType || "ExportNamespaceSpecifier" === nodeType || "ExportDefaultSpecifier" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAccessor(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ClassAccessorProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPrivate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ClassPrivateProperty" === nodeType || "ClassPrivateMethod" === nodeType || "PrivateName" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlow(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AnyTypeAnnotation" === nodeType || "ArrayTypeAnnotation" === nodeType || "BooleanTypeAnnotation" === nodeType || "BooleanLiteralTypeAnnotation" === nodeType || "NullLiteralTypeAnnotation" === nodeType || "ClassImplements" === nodeType || "DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "DeclaredPredicate" === nodeType || "ExistsTypeAnnotation" === nodeType || "FunctionTypeAnnotation" === nodeType || "FunctionTypeParam" === nodeType || "GenericTypeAnnotation" === nodeType || "InferredPredicate" === nodeType || "InterfaceExtends" === nodeType || "InterfaceDeclaration" === nodeType || "InterfaceTypeAnnotation" === nodeType || "IntersectionTypeAnnotation" === nodeType || "MixedTypeAnnotation" === nodeType || "EmptyTypeAnnotation" === nodeType || "NullableTypeAnnotation" === nodeType || "NumberLiteralTypeAnnotation" === nodeType || "NumberTypeAnnotation" === nodeType || "ObjectTypeAnnotation" === nodeType || "ObjectTypeInternalSlot" === nodeType || "ObjectTypeCallProperty" === nodeType || "ObjectTypeIndexer" === nodeType || "ObjectTypeProperty" === nodeType || "ObjectTypeSpreadProperty" === nodeType || "OpaqueType" === nodeType || "QualifiedTypeIdentifier" === nodeType || "StringLiteralTypeAnnotation" === nodeType || "StringTypeAnnotation" === nodeType || "SymbolTypeAnnotation" === nodeType || "ThisTypeAnnotation" === nodeType || "TupleTypeAnnotation" === nodeType || "TypeofTypeAnnotation" === nodeType || "TypeAlias" === nodeType || "TypeAnnotation" === nodeType || "TypeCastExpression" === nodeType || "TypeParameter" === nodeType || "TypeParameterDeclaration" === nodeType || "TypeParameterInstantiation" === nodeType || "UnionTypeAnnotation" === nodeType || "Variance" === nodeType || "VoidTypeAnnotation" === nodeType || "EnumDeclaration" === nodeType || "EnumBooleanBody" === nodeType || "EnumNumberBody" === nodeType || "EnumStringBody" === nodeType || "EnumSymbolBody" === nodeType || "EnumBooleanMember" === nodeType || "EnumNumberMember" === nodeType || "EnumStringMember" === nodeType || "EnumDefaultedMember" === nodeType || "IndexedAccessType" === nodeType || "OptionalIndexedAccessType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AnyTypeAnnotation" === nodeType || "ArrayTypeAnnotation" === nodeType || "BooleanTypeAnnotation" === nodeType || "BooleanLiteralTypeAnnotation" === nodeType || "NullLiteralTypeAnnotation" === nodeType || "ExistsTypeAnnotation" === nodeType || "FunctionTypeAnnotation" === nodeType || "GenericTypeAnnotation" === nodeType || "InterfaceTypeAnnotation" === nodeType || "IntersectionTypeAnnotation" === nodeType || "MixedTypeAnnotation" === nodeType || "EmptyTypeAnnotation" === nodeType || "NullableTypeAnnotation" === nodeType || "NumberLiteralTypeAnnotation" === nodeType || "NumberTypeAnnotation" === nodeType || "ObjectTypeAnnotation" === nodeType || "StringLiteralTypeAnnotation" === nodeType || "StringTypeAnnotation" === nodeType || "SymbolTypeAnnotation" === nodeType || "ThisTypeAnnotation" === nodeType || "TupleTypeAnnotation" === nodeType || "TypeofTypeAnnotation" === nodeType || "UnionTypeAnnotation" === nodeType || "VoidTypeAnnotation" === nodeType || "IndexedAccessType" === nodeType || "OptionalIndexedAccessType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowBaseAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AnyTypeAnnotation" === nodeType || "BooleanTypeAnnotation" === nodeType || "NullLiteralTypeAnnotation" === nodeType || "MixedTypeAnnotation" === nodeType || "EmptyTypeAnnotation" === nodeType || "NumberTypeAnnotation" === nodeType || "StringTypeAnnotation" === nodeType || "SymbolTypeAnnotation" === nodeType || "ThisTypeAnnotation" === nodeType || "VoidTypeAnnotation" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "InterfaceDeclaration" === nodeType || "OpaqueType" === nodeType || "TypeAlias" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowPredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DeclaredPredicate" === nodeType || "InferredPredicate" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("EnumBooleanBody" === nodeType || "EnumNumberBody" === nodeType || "EnumStringBody" === nodeType || "EnumSymbolBody" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("EnumBooleanMember" === nodeType || "EnumNumberMember" === nodeType || "EnumStringMember" === nodeType || "EnumDefaultedMember" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSX(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("JSXAttribute" === nodeType || "JSXClosingElement" === nodeType || "JSXElement" === nodeType || "JSXEmptyExpression" === nodeType || "JSXExpressionContainer" === nodeType || "JSXSpreadChild" === nodeType || "JSXIdentifier" === nodeType || "JSXMemberExpression" === nodeType || "JSXNamespacedName" === nodeType || "JSXOpeningElement" === nodeType || "JSXSpreadAttribute" === nodeType || "JSXText" === nodeType || "JSXFragment" === nodeType || "JSXOpeningFragment" === nodeType || "JSXClosingFragment" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMiscellaneous(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Noop" === nodeType || "Placeholder" === nodeType || "V8IntrinsicIdentifier" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeScript(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSParameterProperty" === nodeType || "TSDeclareFunction" === nodeType || "TSDeclareMethod" === nodeType || "TSQualifiedName" === nodeType || "TSCallSignatureDeclaration" === nodeType || "TSConstructSignatureDeclaration" === nodeType || "TSPropertySignature" === nodeType || "TSMethodSignature" === nodeType || "TSIndexSignature" === nodeType || "TSAnyKeyword" === nodeType || "TSBooleanKeyword" === nodeType || "TSBigIntKeyword" === nodeType || "TSIntrinsicKeyword" === nodeType || "TSNeverKeyword" === nodeType || "TSNullKeyword" === nodeType || "TSNumberKeyword" === nodeType || "TSObjectKeyword" === nodeType || "TSStringKeyword" === nodeType || "TSSymbolKeyword" === nodeType || "TSUndefinedKeyword" === nodeType || "TSUnknownKeyword" === nodeType || "TSVoidKeyword" === nodeType || "TSThisType" === nodeType || "TSFunctionType" === nodeType || "TSConstructorType" === nodeType || "TSTypeReference" === nodeType || "TSTypePredicate" === nodeType || "TSTypeQuery" === nodeType || "TSTypeLiteral" === nodeType || "TSArrayType" === nodeType || "TSTupleType" === nodeType || "TSOptionalType" === nodeType || "TSRestType" === nodeType || "TSNamedTupleMember" === nodeType || "TSUnionType" === nodeType || "TSIntersectionType" === nodeType || "TSConditionalType" === nodeType || "TSInferType" === nodeType || "TSParenthesizedType" === nodeType || "TSTypeOperator" === nodeType || "TSIndexedAccessType" === nodeType || "TSMappedType" === nodeType || "TSLiteralType" === nodeType || "TSExpressionWithTypeArguments" === nodeType || "TSInterfaceDeclaration" === nodeType || "TSInterfaceBody" === nodeType || "TSTypeAliasDeclaration" === nodeType || "TSAsExpression" === nodeType || "TSTypeAssertion" === nodeType || "TSEnumDeclaration" === nodeType || "TSEnumMember" === nodeType || "TSModuleDeclaration" === nodeType || "TSModuleBlock" === nodeType || "TSImportType" === nodeType || "TSImportEqualsDeclaration" === nodeType || "TSExternalModuleReference" === nodeType || "TSNonNullExpression" === nodeType || "TSExportAssignment" === nodeType || "TSNamespaceExportDeclaration" === nodeType || "TSTypeAnnotation" === nodeType || "TSTypeParameterInstantiation" === nodeType || "TSTypeParameterDeclaration" === nodeType || "TSTypeParameter" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSCallSignatureDeclaration" === nodeType || "TSConstructSignatureDeclaration" === nodeType || "TSPropertySignature" === nodeType || "TSMethodSignature" === nodeType || "TSIndexSignature" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSAnyKeyword" === nodeType || "TSBooleanKeyword" === nodeType || "TSBigIntKeyword" === nodeType || "TSIntrinsicKeyword" === nodeType || "TSNeverKeyword" === nodeType || "TSNullKeyword" === nodeType || "TSNumberKeyword" === nodeType || "TSObjectKeyword" === nodeType || "TSStringKeyword" === nodeType || "TSSymbolKeyword" === nodeType || "TSUndefinedKeyword" === nodeType || "TSUnknownKeyword" === nodeType || "TSVoidKeyword" === nodeType || "TSThisType" === nodeType || "TSFunctionType" === nodeType || "TSConstructorType" === nodeType || "TSTypeReference" === nodeType || "TSTypePredicate" === nodeType || "TSTypeQuery" === nodeType || "TSTypeLiteral" === nodeType || "TSArrayType" === nodeType || "TSTupleType" === nodeType || "TSOptionalType" === nodeType || "TSRestType" === nodeType || "TSUnionType" === nodeType || "TSIntersectionType" === nodeType || "TSConditionalType" === nodeType || "TSInferType" === nodeType || "TSParenthesizedType" === nodeType || "TSTypeOperator" === nodeType || "TSIndexedAccessType" === nodeType || "TSMappedType" === nodeType || "TSLiteralType" === nodeType || "TSExpressionWithTypeArguments" === nodeType || "TSImportType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSBaseType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSAnyKeyword" === nodeType || "TSBooleanKeyword" === nodeType || "TSBigIntKeyword" === nodeType || "TSIntrinsicKeyword" === nodeType || "TSNeverKeyword" === nodeType || "TSNullKeyword" === nodeType || "TSNumberKeyword" === nodeType || "TSObjectKeyword" === nodeType || "TSStringKeyword" === nodeType || "TSSymbolKeyword" === nodeType || "TSUndefinedKeyword" === nodeType || "TSUnknownKeyword" === nodeType || "TSVoidKeyword" === nodeType || "TSThisType" === nodeType || "TSLiteralType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumberLiteral(node, opts) { + console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumberLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRegexLiteral(node, opts) { + console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RegexLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRestProperty(node, opts) { + console.trace("The node type RestProperty has been renamed to RestElement"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RestProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSpreadProperty(node, opts) { + console.trace("The node type SpreadProperty has been renamed to SpreadElement"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SpreadProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} \ No newline at end of file diff --git a/node_modules/@isaacs/import-jsx/node_modules/@babel/traverse/lib/path/generated/asserts.js b/node_modules/@isaacs/import-jsx/node_modules/@babel/traverse/lib/path/generated/asserts.js new file mode 100644 index 000000000..bee8a438e --- /dev/null +++ b/node_modules/@isaacs/import-jsx/node_modules/@babel/traverse/lib/path/generated/asserts.js @@ -0,0 +1,5 @@ +"use strict"; + +var t = require("@babel/types"); + +var _index = require("../index"); \ No newline at end of file diff --git a/node_modules/@isaacs/import-jsx/node_modules/@babel/traverse/lib/path/generated/validators.js b/node_modules/@isaacs/import-jsx/node_modules/@babel/traverse/lib/path/generated/validators.js new file mode 100644 index 000000000..bee8a438e --- /dev/null +++ b/node_modules/@isaacs/import-jsx/node_modules/@babel/traverse/lib/path/generated/validators.js @@ -0,0 +1,5 @@ +"use strict"; + +var t = require("@babel/types"); + +var _index = require("../index"); \ No newline at end of file diff --git a/node_modules/@isaacs/import-jsx/node_modules/@babel/traverse/lib/path/generated/virtual-types.js b/node_modules/@isaacs/import-jsx/node_modules/@babel/traverse/lib/path/generated/virtual-types.js new file mode 100644 index 000000000..bf37ed937 --- /dev/null +++ b/node_modules/@isaacs/import-jsx/node_modules/@babel/traverse/lib/path/generated/virtual-types.js @@ -0,0 +1,3 @@ +"use strict"; + +var t = require("@babel/types"); \ No newline at end of file diff --git a/node_modules/@isaacs/import-jsx/node_modules/@babel/types/lib/asserts/generated/index.js b/node_modules/@isaacs/import-jsx/node_modules/@babel/types/lib/asserts/generated/index.js new file mode 100644 index 000000000..b75a4e936 --- /dev/null +++ b/node_modules/@isaacs/import-jsx/node_modules/@babel/types/lib/asserts/generated/index.js @@ -0,0 +1,1522 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.assertAccessor = assertAccessor; +exports.assertAnyTypeAnnotation = assertAnyTypeAnnotation; +exports.assertArgumentPlaceholder = assertArgumentPlaceholder; +exports.assertArrayExpression = assertArrayExpression; +exports.assertArrayPattern = assertArrayPattern; +exports.assertArrayTypeAnnotation = assertArrayTypeAnnotation; +exports.assertArrowFunctionExpression = assertArrowFunctionExpression; +exports.assertAssignmentExpression = assertAssignmentExpression; +exports.assertAssignmentPattern = assertAssignmentPattern; +exports.assertAwaitExpression = assertAwaitExpression; +exports.assertBigIntLiteral = assertBigIntLiteral; +exports.assertBinary = assertBinary; +exports.assertBinaryExpression = assertBinaryExpression; +exports.assertBindExpression = assertBindExpression; +exports.assertBlock = assertBlock; +exports.assertBlockParent = assertBlockParent; +exports.assertBlockStatement = assertBlockStatement; +exports.assertBooleanLiteral = assertBooleanLiteral; +exports.assertBooleanLiteralTypeAnnotation = assertBooleanLiteralTypeAnnotation; +exports.assertBooleanTypeAnnotation = assertBooleanTypeAnnotation; +exports.assertBreakStatement = assertBreakStatement; +exports.assertCallExpression = assertCallExpression; +exports.assertCatchClause = assertCatchClause; +exports.assertClass = assertClass; +exports.assertClassAccessorProperty = assertClassAccessorProperty; +exports.assertClassBody = assertClassBody; +exports.assertClassDeclaration = assertClassDeclaration; +exports.assertClassExpression = assertClassExpression; +exports.assertClassImplements = assertClassImplements; +exports.assertClassMethod = assertClassMethod; +exports.assertClassPrivateMethod = assertClassPrivateMethod; +exports.assertClassPrivateProperty = assertClassPrivateProperty; +exports.assertClassProperty = assertClassProperty; +exports.assertCompletionStatement = assertCompletionStatement; +exports.assertConditional = assertConditional; +exports.assertConditionalExpression = assertConditionalExpression; +exports.assertContinueStatement = assertContinueStatement; +exports.assertDebuggerStatement = assertDebuggerStatement; +exports.assertDecimalLiteral = assertDecimalLiteral; +exports.assertDeclaration = assertDeclaration; +exports.assertDeclareClass = assertDeclareClass; +exports.assertDeclareExportAllDeclaration = assertDeclareExportAllDeclaration; +exports.assertDeclareExportDeclaration = assertDeclareExportDeclaration; +exports.assertDeclareFunction = assertDeclareFunction; +exports.assertDeclareInterface = assertDeclareInterface; +exports.assertDeclareModule = assertDeclareModule; +exports.assertDeclareModuleExports = assertDeclareModuleExports; +exports.assertDeclareOpaqueType = assertDeclareOpaqueType; +exports.assertDeclareTypeAlias = assertDeclareTypeAlias; +exports.assertDeclareVariable = assertDeclareVariable; +exports.assertDeclaredPredicate = assertDeclaredPredicate; +exports.assertDecorator = assertDecorator; +exports.assertDirective = assertDirective; +exports.assertDirectiveLiteral = assertDirectiveLiteral; +exports.assertDoExpression = assertDoExpression; +exports.assertDoWhileStatement = assertDoWhileStatement; +exports.assertEmptyStatement = assertEmptyStatement; +exports.assertEmptyTypeAnnotation = assertEmptyTypeAnnotation; +exports.assertEnumBody = assertEnumBody; +exports.assertEnumBooleanBody = assertEnumBooleanBody; +exports.assertEnumBooleanMember = assertEnumBooleanMember; +exports.assertEnumDeclaration = assertEnumDeclaration; +exports.assertEnumDefaultedMember = assertEnumDefaultedMember; +exports.assertEnumMember = assertEnumMember; +exports.assertEnumNumberBody = assertEnumNumberBody; +exports.assertEnumNumberMember = assertEnumNumberMember; +exports.assertEnumStringBody = assertEnumStringBody; +exports.assertEnumStringMember = assertEnumStringMember; +exports.assertEnumSymbolBody = assertEnumSymbolBody; +exports.assertExistsTypeAnnotation = assertExistsTypeAnnotation; +exports.assertExportAllDeclaration = assertExportAllDeclaration; +exports.assertExportDeclaration = assertExportDeclaration; +exports.assertExportDefaultDeclaration = assertExportDefaultDeclaration; +exports.assertExportDefaultSpecifier = assertExportDefaultSpecifier; +exports.assertExportNamedDeclaration = assertExportNamedDeclaration; +exports.assertExportNamespaceSpecifier = assertExportNamespaceSpecifier; +exports.assertExportSpecifier = assertExportSpecifier; +exports.assertExpression = assertExpression; +exports.assertExpressionStatement = assertExpressionStatement; +exports.assertExpressionWrapper = assertExpressionWrapper; +exports.assertFile = assertFile; +exports.assertFlow = assertFlow; +exports.assertFlowBaseAnnotation = assertFlowBaseAnnotation; +exports.assertFlowDeclaration = assertFlowDeclaration; +exports.assertFlowPredicate = assertFlowPredicate; +exports.assertFlowType = assertFlowType; +exports.assertFor = assertFor; +exports.assertForInStatement = assertForInStatement; +exports.assertForOfStatement = assertForOfStatement; +exports.assertForStatement = assertForStatement; +exports.assertForXStatement = assertForXStatement; +exports.assertFunction = assertFunction; +exports.assertFunctionDeclaration = assertFunctionDeclaration; +exports.assertFunctionExpression = assertFunctionExpression; +exports.assertFunctionParent = assertFunctionParent; +exports.assertFunctionTypeAnnotation = assertFunctionTypeAnnotation; +exports.assertFunctionTypeParam = assertFunctionTypeParam; +exports.assertGenericTypeAnnotation = assertGenericTypeAnnotation; +exports.assertIdentifier = assertIdentifier; +exports.assertIfStatement = assertIfStatement; +exports.assertImmutable = assertImmutable; +exports.assertImport = assertImport; +exports.assertImportAttribute = assertImportAttribute; +exports.assertImportDeclaration = assertImportDeclaration; +exports.assertImportDefaultSpecifier = assertImportDefaultSpecifier; +exports.assertImportNamespaceSpecifier = assertImportNamespaceSpecifier; +exports.assertImportSpecifier = assertImportSpecifier; +exports.assertIndexedAccessType = assertIndexedAccessType; +exports.assertInferredPredicate = assertInferredPredicate; +exports.assertInterfaceDeclaration = assertInterfaceDeclaration; +exports.assertInterfaceExtends = assertInterfaceExtends; +exports.assertInterfaceTypeAnnotation = assertInterfaceTypeAnnotation; +exports.assertInterpreterDirective = assertInterpreterDirective; +exports.assertIntersectionTypeAnnotation = assertIntersectionTypeAnnotation; +exports.assertJSX = assertJSX; +exports.assertJSXAttribute = assertJSXAttribute; +exports.assertJSXClosingElement = assertJSXClosingElement; +exports.assertJSXClosingFragment = assertJSXClosingFragment; +exports.assertJSXElement = assertJSXElement; +exports.assertJSXEmptyExpression = assertJSXEmptyExpression; +exports.assertJSXExpressionContainer = assertJSXExpressionContainer; +exports.assertJSXFragment = assertJSXFragment; +exports.assertJSXIdentifier = assertJSXIdentifier; +exports.assertJSXMemberExpression = assertJSXMemberExpression; +exports.assertJSXNamespacedName = assertJSXNamespacedName; +exports.assertJSXOpeningElement = assertJSXOpeningElement; +exports.assertJSXOpeningFragment = assertJSXOpeningFragment; +exports.assertJSXSpreadAttribute = assertJSXSpreadAttribute; +exports.assertJSXSpreadChild = assertJSXSpreadChild; +exports.assertJSXText = assertJSXText; +exports.assertLVal = assertLVal; +exports.assertLabeledStatement = assertLabeledStatement; +exports.assertLiteral = assertLiteral; +exports.assertLogicalExpression = assertLogicalExpression; +exports.assertLoop = assertLoop; +exports.assertMemberExpression = assertMemberExpression; +exports.assertMetaProperty = assertMetaProperty; +exports.assertMethod = assertMethod; +exports.assertMiscellaneous = assertMiscellaneous; +exports.assertMixedTypeAnnotation = assertMixedTypeAnnotation; +exports.assertModuleDeclaration = assertModuleDeclaration; +exports.assertModuleExpression = assertModuleExpression; +exports.assertModuleSpecifier = assertModuleSpecifier; +exports.assertNewExpression = assertNewExpression; +exports.assertNoop = assertNoop; +exports.assertNullLiteral = assertNullLiteral; +exports.assertNullLiteralTypeAnnotation = assertNullLiteralTypeAnnotation; +exports.assertNullableTypeAnnotation = assertNullableTypeAnnotation; +exports.assertNumberLiteral = assertNumberLiteral; +exports.assertNumberLiteralTypeAnnotation = assertNumberLiteralTypeAnnotation; +exports.assertNumberTypeAnnotation = assertNumberTypeAnnotation; +exports.assertNumericLiteral = assertNumericLiteral; +exports.assertObjectExpression = assertObjectExpression; +exports.assertObjectMember = assertObjectMember; +exports.assertObjectMethod = assertObjectMethod; +exports.assertObjectPattern = assertObjectPattern; +exports.assertObjectProperty = assertObjectProperty; +exports.assertObjectTypeAnnotation = assertObjectTypeAnnotation; +exports.assertObjectTypeCallProperty = assertObjectTypeCallProperty; +exports.assertObjectTypeIndexer = assertObjectTypeIndexer; +exports.assertObjectTypeInternalSlot = assertObjectTypeInternalSlot; +exports.assertObjectTypeProperty = assertObjectTypeProperty; +exports.assertObjectTypeSpreadProperty = assertObjectTypeSpreadProperty; +exports.assertOpaqueType = assertOpaqueType; +exports.assertOptionalCallExpression = assertOptionalCallExpression; +exports.assertOptionalIndexedAccessType = assertOptionalIndexedAccessType; +exports.assertOptionalMemberExpression = assertOptionalMemberExpression; +exports.assertParenthesizedExpression = assertParenthesizedExpression; +exports.assertPattern = assertPattern; +exports.assertPatternLike = assertPatternLike; +exports.assertPipelineBareFunction = assertPipelineBareFunction; +exports.assertPipelinePrimaryTopicReference = assertPipelinePrimaryTopicReference; +exports.assertPipelineTopicExpression = assertPipelineTopicExpression; +exports.assertPlaceholder = assertPlaceholder; +exports.assertPrivate = assertPrivate; +exports.assertPrivateName = assertPrivateName; +exports.assertProgram = assertProgram; +exports.assertProperty = assertProperty; +exports.assertPureish = assertPureish; +exports.assertQualifiedTypeIdentifier = assertQualifiedTypeIdentifier; +exports.assertRecordExpression = assertRecordExpression; +exports.assertRegExpLiteral = assertRegExpLiteral; +exports.assertRegexLiteral = assertRegexLiteral; +exports.assertRestElement = assertRestElement; +exports.assertRestProperty = assertRestProperty; +exports.assertReturnStatement = assertReturnStatement; +exports.assertScopable = assertScopable; +exports.assertSequenceExpression = assertSequenceExpression; +exports.assertSpreadElement = assertSpreadElement; +exports.assertSpreadProperty = assertSpreadProperty; +exports.assertStandardized = assertStandardized; +exports.assertStatement = assertStatement; +exports.assertStaticBlock = assertStaticBlock; +exports.assertStringLiteral = assertStringLiteral; +exports.assertStringLiteralTypeAnnotation = assertStringLiteralTypeAnnotation; +exports.assertStringTypeAnnotation = assertStringTypeAnnotation; +exports.assertSuper = assertSuper; +exports.assertSwitchCase = assertSwitchCase; +exports.assertSwitchStatement = assertSwitchStatement; +exports.assertSymbolTypeAnnotation = assertSymbolTypeAnnotation; +exports.assertTSAnyKeyword = assertTSAnyKeyword; +exports.assertTSArrayType = assertTSArrayType; +exports.assertTSAsExpression = assertTSAsExpression; +exports.assertTSBaseType = assertTSBaseType; +exports.assertTSBigIntKeyword = assertTSBigIntKeyword; +exports.assertTSBooleanKeyword = assertTSBooleanKeyword; +exports.assertTSCallSignatureDeclaration = assertTSCallSignatureDeclaration; +exports.assertTSConditionalType = assertTSConditionalType; +exports.assertTSConstructSignatureDeclaration = assertTSConstructSignatureDeclaration; +exports.assertTSConstructorType = assertTSConstructorType; +exports.assertTSDeclareFunction = assertTSDeclareFunction; +exports.assertTSDeclareMethod = assertTSDeclareMethod; +exports.assertTSEntityName = assertTSEntityName; +exports.assertTSEnumDeclaration = assertTSEnumDeclaration; +exports.assertTSEnumMember = assertTSEnumMember; +exports.assertTSExportAssignment = assertTSExportAssignment; +exports.assertTSExpressionWithTypeArguments = assertTSExpressionWithTypeArguments; +exports.assertTSExternalModuleReference = assertTSExternalModuleReference; +exports.assertTSFunctionType = assertTSFunctionType; +exports.assertTSImportEqualsDeclaration = assertTSImportEqualsDeclaration; +exports.assertTSImportType = assertTSImportType; +exports.assertTSIndexSignature = assertTSIndexSignature; +exports.assertTSIndexedAccessType = assertTSIndexedAccessType; +exports.assertTSInferType = assertTSInferType; +exports.assertTSInstantiationExpression = assertTSInstantiationExpression; +exports.assertTSInterfaceBody = assertTSInterfaceBody; +exports.assertTSInterfaceDeclaration = assertTSInterfaceDeclaration; +exports.assertTSIntersectionType = assertTSIntersectionType; +exports.assertTSIntrinsicKeyword = assertTSIntrinsicKeyword; +exports.assertTSLiteralType = assertTSLiteralType; +exports.assertTSMappedType = assertTSMappedType; +exports.assertTSMethodSignature = assertTSMethodSignature; +exports.assertTSModuleBlock = assertTSModuleBlock; +exports.assertTSModuleDeclaration = assertTSModuleDeclaration; +exports.assertTSNamedTupleMember = assertTSNamedTupleMember; +exports.assertTSNamespaceExportDeclaration = assertTSNamespaceExportDeclaration; +exports.assertTSNeverKeyword = assertTSNeverKeyword; +exports.assertTSNonNullExpression = assertTSNonNullExpression; +exports.assertTSNullKeyword = assertTSNullKeyword; +exports.assertTSNumberKeyword = assertTSNumberKeyword; +exports.assertTSObjectKeyword = assertTSObjectKeyword; +exports.assertTSOptionalType = assertTSOptionalType; +exports.assertTSParameterProperty = assertTSParameterProperty; +exports.assertTSParenthesizedType = assertTSParenthesizedType; +exports.assertTSPropertySignature = assertTSPropertySignature; +exports.assertTSQualifiedName = assertTSQualifiedName; +exports.assertTSRestType = assertTSRestType; +exports.assertTSStringKeyword = assertTSStringKeyword; +exports.assertTSSymbolKeyword = assertTSSymbolKeyword; +exports.assertTSThisType = assertTSThisType; +exports.assertTSTupleType = assertTSTupleType; +exports.assertTSType = assertTSType; +exports.assertTSTypeAliasDeclaration = assertTSTypeAliasDeclaration; +exports.assertTSTypeAnnotation = assertTSTypeAnnotation; +exports.assertTSTypeAssertion = assertTSTypeAssertion; +exports.assertTSTypeElement = assertTSTypeElement; +exports.assertTSTypeLiteral = assertTSTypeLiteral; +exports.assertTSTypeOperator = assertTSTypeOperator; +exports.assertTSTypeParameter = assertTSTypeParameter; +exports.assertTSTypeParameterDeclaration = assertTSTypeParameterDeclaration; +exports.assertTSTypeParameterInstantiation = assertTSTypeParameterInstantiation; +exports.assertTSTypePredicate = assertTSTypePredicate; +exports.assertTSTypeQuery = assertTSTypeQuery; +exports.assertTSTypeReference = assertTSTypeReference; +exports.assertTSUndefinedKeyword = assertTSUndefinedKeyword; +exports.assertTSUnionType = assertTSUnionType; +exports.assertTSUnknownKeyword = assertTSUnknownKeyword; +exports.assertTSVoidKeyword = assertTSVoidKeyword; +exports.assertTaggedTemplateExpression = assertTaggedTemplateExpression; +exports.assertTemplateElement = assertTemplateElement; +exports.assertTemplateLiteral = assertTemplateLiteral; +exports.assertTerminatorless = assertTerminatorless; +exports.assertThisExpression = assertThisExpression; +exports.assertThisTypeAnnotation = assertThisTypeAnnotation; +exports.assertThrowStatement = assertThrowStatement; +exports.assertTopicReference = assertTopicReference; +exports.assertTryStatement = assertTryStatement; +exports.assertTupleExpression = assertTupleExpression; +exports.assertTupleTypeAnnotation = assertTupleTypeAnnotation; +exports.assertTypeAlias = assertTypeAlias; +exports.assertTypeAnnotation = assertTypeAnnotation; +exports.assertTypeCastExpression = assertTypeCastExpression; +exports.assertTypeParameter = assertTypeParameter; +exports.assertTypeParameterDeclaration = assertTypeParameterDeclaration; +exports.assertTypeParameterInstantiation = assertTypeParameterInstantiation; +exports.assertTypeScript = assertTypeScript; +exports.assertTypeofTypeAnnotation = assertTypeofTypeAnnotation; +exports.assertUnaryExpression = assertUnaryExpression; +exports.assertUnaryLike = assertUnaryLike; +exports.assertUnionTypeAnnotation = assertUnionTypeAnnotation; +exports.assertUpdateExpression = assertUpdateExpression; +exports.assertUserWhitespacable = assertUserWhitespacable; +exports.assertV8IntrinsicIdentifier = assertV8IntrinsicIdentifier; +exports.assertVariableDeclaration = assertVariableDeclaration; +exports.assertVariableDeclarator = assertVariableDeclarator; +exports.assertVariance = assertVariance; +exports.assertVoidTypeAnnotation = assertVoidTypeAnnotation; +exports.assertWhile = assertWhile; +exports.assertWhileStatement = assertWhileStatement; +exports.assertWithStatement = assertWithStatement; +exports.assertYieldExpression = assertYieldExpression; + +var _is = require("../../validators/is"); + +function assert(type, node, opts) { + if (!(0, _is.default)(type, node, opts)) { + throw new Error(`Expected type "${type}" with option ${JSON.stringify(opts)}, ` + `but instead got "${node.type}".`); + } +} + +function assertArrayExpression(node, opts) { + assert("ArrayExpression", node, opts); +} + +function assertAssignmentExpression(node, opts) { + assert("AssignmentExpression", node, opts); +} + +function assertBinaryExpression(node, opts) { + assert("BinaryExpression", node, opts); +} + +function assertInterpreterDirective(node, opts) { + assert("InterpreterDirective", node, opts); +} + +function assertDirective(node, opts) { + assert("Directive", node, opts); +} + +function assertDirectiveLiteral(node, opts) { + assert("DirectiveLiteral", node, opts); +} + +function assertBlockStatement(node, opts) { + assert("BlockStatement", node, opts); +} + +function assertBreakStatement(node, opts) { + assert("BreakStatement", node, opts); +} + +function assertCallExpression(node, opts) { + assert("CallExpression", node, opts); +} + +function assertCatchClause(node, opts) { + assert("CatchClause", node, opts); +} + +function assertConditionalExpression(node, opts) { + assert("ConditionalExpression", node, opts); +} + +function assertContinueStatement(node, opts) { + assert("ContinueStatement", node, opts); +} + +function assertDebuggerStatement(node, opts) { + assert("DebuggerStatement", node, opts); +} + +function assertDoWhileStatement(node, opts) { + assert("DoWhileStatement", node, opts); +} + +function assertEmptyStatement(node, opts) { + assert("EmptyStatement", node, opts); +} + +function assertExpressionStatement(node, opts) { + assert("ExpressionStatement", node, opts); +} + +function assertFile(node, opts) { + assert("File", node, opts); +} + +function assertForInStatement(node, opts) { + assert("ForInStatement", node, opts); +} + +function assertForStatement(node, opts) { + assert("ForStatement", node, opts); +} + +function assertFunctionDeclaration(node, opts) { + assert("FunctionDeclaration", node, opts); +} + +function assertFunctionExpression(node, opts) { + assert("FunctionExpression", node, opts); +} + +function assertIdentifier(node, opts) { + assert("Identifier", node, opts); +} + +function assertIfStatement(node, opts) { + assert("IfStatement", node, opts); +} + +function assertLabeledStatement(node, opts) { + assert("LabeledStatement", node, opts); +} + +function assertStringLiteral(node, opts) { + assert("StringLiteral", node, opts); +} + +function assertNumericLiteral(node, opts) { + assert("NumericLiteral", node, opts); +} + +function assertNullLiteral(node, opts) { + assert("NullLiteral", node, opts); +} + +function assertBooleanLiteral(node, opts) { + assert("BooleanLiteral", node, opts); +} + +function assertRegExpLiteral(node, opts) { + assert("RegExpLiteral", node, opts); +} + +function assertLogicalExpression(node, opts) { + assert("LogicalExpression", node, opts); +} + +function assertMemberExpression(node, opts) { + assert("MemberExpression", node, opts); +} + +function assertNewExpression(node, opts) { + assert("NewExpression", node, opts); +} + +function assertProgram(node, opts) { + assert("Program", node, opts); +} + +function assertObjectExpression(node, opts) { + assert("ObjectExpression", node, opts); +} + +function assertObjectMethod(node, opts) { + assert("ObjectMethod", node, opts); +} + +function assertObjectProperty(node, opts) { + assert("ObjectProperty", node, opts); +} + +function assertRestElement(node, opts) { + assert("RestElement", node, opts); +} + +function assertReturnStatement(node, opts) { + assert("ReturnStatement", node, opts); +} + +function assertSequenceExpression(node, opts) { + assert("SequenceExpression", node, opts); +} + +function assertParenthesizedExpression(node, opts) { + assert("ParenthesizedExpression", node, opts); +} + +function assertSwitchCase(node, opts) { + assert("SwitchCase", node, opts); +} + +function assertSwitchStatement(node, opts) { + assert("SwitchStatement", node, opts); +} + +function assertThisExpression(node, opts) { + assert("ThisExpression", node, opts); +} + +function assertThrowStatement(node, opts) { + assert("ThrowStatement", node, opts); +} + +function assertTryStatement(node, opts) { + assert("TryStatement", node, opts); +} + +function assertUnaryExpression(node, opts) { + assert("UnaryExpression", node, opts); +} + +function assertUpdateExpression(node, opts) { + assert("UpdateExpression", node, opts); +} + +function assertVariableDeclaration(node, opts) { + assert("VariableDeclaration", node, opts); +} + +function assertVariableDeclarator(node, opts) { + assert("VariableDeclarator", node, opts); +} + +function assertWhileStatement(node, opts) { + assert("WhileStatement", node, opts); +} + +function assertWithStatement(node, opts) { + assert("WithStatement", node, opts); +} + +function assertAssignmentPattern(node, opts) { + assert("AssignmentPattern", node, opts); +} + +function assertArrayPattern(node, opts) { + assert("ArrayPattern", node, opts); +} + +function assertArrowFunctionExpression(node, opts) { + assert("ArrowFunctionExpression", node, opts); +} + +function assertClassBody(node, opts) { + assert("ClassBody", node, opts); +} + +function assertClassExpression(node, opts) { + assert("ClassExpression", node, opts); +} + +function assertClassDeclaration(node, opts) { + assert("ClassDeclaration", node, opts); +} + +function assertExportAllDeclaration(node, opts) { + assert("ExportAllDeclaration", node, opts); +} + +function assertExportDefaultDeclaration(node, opts) { + assert("ExportDefaultDeclaration", node, opts); +} + +function assertExportNamedDeclaration(node, opts) { + assert("ExportNamedDeclaration", node, opts); +} + +function assertExportSpecifier(node, opts) { + assert("ExportSpecifier", node, opts); +} + +function assertForOfStatement(node, opts) { + assert("ForOfStatement", node, opts); +} + +function assertImportDeclaration(node, opts) { + assert("ImportDeclaration", node, opts); +} + +function assertImportDefaultSpecifier(node, opts) { + assert("ImportDefaultSpecifier", node, opts); +} + +function assertImportNamespaceSpecifier(node, opts) { + assert("ImportNamespaceSpecifier", node, opts); +} + +function assertImportSpecifier(node, opts) { + assert("ImportSpecifier", node, opts); +} + +function assertMetaProperty(node, opts) { + assert("MetaProperty", node, opts); +} + +function assertClassMethod(node, opts) { + assert("ClassMethod", node, opts); +} + +function assertObjectPattern(node, opts) { + assert("ObjectPattern", node, opts); +} + +function assertSpreadElement(node, opts) { + assert("SpreadElement", node, opts); +} + +function assertSuper(node, opts) { + assert("Super", node, opts); +} + +function assertTaggedTemplateExpression(node, opts) { + assert("TaggedTemplateExpression", node, opts); +} + +function assertTemplateElement(node, opts) { + assert("TemplateElement", node, opts); +} + +function assertTemplateLiteral(node, opts) { + assert("TemplateLiteral", node, opts); +} + +function assertYieldExpression(node, opts) { + assert("YieldExpression", node, opts); +} + +function assertAwaitExpression(node, opts) { + assert("AwaitExpression", node, opts); +} + +function assertImport(node, opts) { + assert("Import", node, opts); +} + +function assertBigIntLiteral(node, opts) { + assert("BigIntLiteral", node, opts); +} + +function assertExportNamespaceSpecifier(node, opts) { + assert("ExportNamespaceSpecifier", node, opts); +} + +function assertOptionalMemberExpression(node, opts) { + assert("OptionalMemberExpression", node, opts); +} + +function assertOptionalCallExpression(node, opts) { + assert("OptionalCallExpression", node, opts); +} + +function assertClassProperty(node, opts) { + assert("ClassProperty", node, opts); +} + +function assertClassAccessorProperty(node, opts) { + assert("ClassAccessorProperty", node, opts); +} + +function assertClassPrivateProperty(node, opts) { + assert("ClassPrivateProperty", node, opts); +} + +function assertClassPrivateMethod(node, opts) { + assert("ClassPrivateMethod", node, opts); +} + +function assertPrivateName(node, opts) { + assert("PrivateName", node, opts); +} + +function assertStaticBlock(node, opts) { + assert("StaticBlock", node, opts); +} + +function assertAnyTypeAnnotation(node, opts) { + assert("AnyTypeAnnotation", node, opts); +} + +function assertArrayTypeAnnotation(node, opts) { + assert("ArrayTypeAnnotation", node, opts); +} + +function assertBooleanTypeAnnotation(node, opts) { + assert("BooleanTypeAnnotation", node, opts); +} + +function assertBooleanLiteralTypeAnnotation(node, opts) { + assert("BooleanLiteralTypeAnnotation", node, opts); +} + +function assertNullLiteralTypeAnnotation(node, opts) { + assert("NullLiteralTypeAnnotation", node, opts); +} + +function assertClassImplements(node, opts) { + assert("ClassImplements", node, opts); +} + +function assertDeclareClass(node, opts) { + assert("DeclareClass", node, opts); +} + +function assertDeclareFunction(node, opts) { + assert("DeclareFunction", node, opts); +} + +function assertDeclareInterface(node, opts) { + assert("DeclareInterface", node, opts); +} + +function assertDeclareModule(node, opts) { + assert("DeclareModule", node, opts); +} + +function assertDeclareModuleExports(node, opts) { + assert("DeclareModuleExports", node, opts); +} + +function assertDeclareTypeAlias(node, opts) { + assert("DeclareTypeAlias", node, opts); +} + +function assertDeclareOpaqueType(node, opts) { + assert("DeclareOpaqueType", node, opts); +} + +function assertDeclareVariable(node, opts) { + assert("DeclareVariable", node, opts); +} + +function assertDeclareExportDeclaration(node, opts) { + assert("DeclareExportDeclaration", node, opts); +} + +function assertDeclareExportAllDeclaration(node, opts) { + assert("DeclareExportAllDeclaration", node, opts); +} + +function assertDeclaredPredicate(node, opts) { + assert("DeclaredPredicate", node, opts); +} + +function assertExistsTypeAnnotation(node, opts) { + assert("ExistsTypeAnnotation", node, opts); +} + +function assertFunctionTypeAnnotation(node, opts) { + assert("FunctionTypeAnnotation", node, opts); +} + +function assertFunctionTypeParam(node, opts) { + assert("FunctionTypeParam", node, opts); +} + +function assertGenericTypeAnnotation(node, opts) { + assert("GenericTypeAnnotation", node, opts); +} + +function assertInferredPredicate(node, opts) { + assert("InferredPredicate", node, opts); +} + +function assertInterfaceExtends(node, opts) { + assert("InterfaceExtends", node, opts); +} + +function assertInterfaceDeclaration(node, opts) { + assert("InterfaceDeclaration", node, opts); +} + +function assertInterfaceTypeAnnotation(node, opts) { + assert("InterfaceTypeAnnotation", node, opts); +} + +function assertIntersectionTypeAnnotation(node, opts) { + assert("IntersectionTypeAnnotation", node, opts); +} + +function assertMixedTypeAnnotation(node, opts) { + assert("MixedTypeAnnotation", node, opts); +} + +function assertEmptyTypeAnnotation(node, opts) { + assert("EmptyTypeAnnotation", node, opts); +} + +function assertNullableTypeAnnotation(node, opts) { + assert("NullableTypeAnnotation", node, opts); +} + +function assertNumberLiteralTypeAnnotation(node, opts) { + assert("NumberLiteralTypeAnnotation", node, opts); +} + +function assertNumberTypeAnnotation(node, opts) { + assert("NumberTypeAnnotation", node, opts); +} + +function assertObjectTypeAnnotation(node, opts) { + assert("ObjectTypeAnnotation", node, opts); +} + +function assertObjectTypeInternalSlot(node, opts) { + assert("ObjectTypeInternalSlot", node, opts); +} + +function assertObjectTypeCallProperty(node, opts) { + assert("ObjectTypeCallProperty", node, opts); +} + +function assertObjectTypeIndexer(node, opts) { + assert("ObjectTypeIndexer", node, opts); +} + +function assertObjectTypeProperty(node, opts) { + assert("ObjectTypeProperty", node, opts); +} + +function assertObjectTypeSpreadProperty(node, opts) { + assert("ObjectTypeSpreadProperty", node, opts); +} + +function assertOpaqueType(node, opts) { + assert("OpaqueType", node, opts); +} + +function assertQualifiedTypeIdentifier(node, opts) { + assert("QualifiedTypeIdentifier", node, opts); +} + +function assertStringLiteralTypeAnnotation(node, opts) { + assert("StringLiteralTypeAnnotation", node, opts); +} + +function assertStringTypeAnnotation(node, opts) { + assert("StringTypeAnnotation", node, opts); +} + +function assertSymbolTypeAnnotation(node, opts) { + assert("SymbolTypeAnnotation", node, opts); +} + +function assertThisTypeAnnotation(node, opts) { + assert("ThisTypeAnnotation", node, opts); +} + +function assertTupleTypeAnnotation(node, opts) { + assert("TupleTypeAnnotation", node, opts); +} + +function assertTypeofTypeAnnotation(node, opts) { + assert("TypeofTypeAnnotation", node, opts); +} + +function assertTypeAlias(node, opts) { + assert("TypeAlias", node, opts); +} + +function assertTypeAnnotation(node, opts) { + assert("TypeAnnotation", node, opts); +} + +function assertTypeCastExpression(node, opts) { + assert("TypeCastExpression", node, opts); +} + +function assertTypeParameter(node, opts) { + assert("TypeParameter", node, opts); +} + +function assertTypeParameterDeclaration(node, opts) { + assert("TypeParameterDeclaration", node, opts); +} + +function assertTypeParameterInstantiation(node, opts) { + assert("TypeParameterInstantiation", node, opts); +} + +function assertUnionTypeAnnotation(node, opts) { + assert("UnionTypeAnnotation", node, opts); +} + +function assertVariance(node, opts) { + assert("Variance", node, opts); +} + +function assertVoidTypeAnnotation(node, opts) { + assert("VoidTypeAnnotation", node, opts); +} + +function assertEnumDeclaration(node, opts) { + assert("EnumDeclaration", node, opts); +} + +function assertEnumBooleanBody(node, opts) { + assert("EnumBooleanBody", node, opts); +} + +function assertEnumNumberBody(node, opts) { + assert("EnumNumberBody", node, opts); +} + +function assertEnumStringBody(node, opts) { + assert("EnumStringBody", node, opts); +} + +function assertEnumSymbolBody(node, opts) { + assert("EnumSymbolBody", node, opts); +} + +function assertEnumBooleanMember(node, opts) { + assert("EnumBooleanMember", node, opts); +} + +function assertEnumNumberMember(node, opts) { + assert("EnumNumberMember", node, opts); +} + +function assertEnumStringMember(node, opts) { + assert("EnumStringMember", node, opts); +} + +function assertEnumDefaultedMember(node, opts) { + assert("EnumDefaultedMember", node, opts); +} + +function assertIndexedAccessType(node, opts) { + assert("IndexedAccessType", node, opts); +} + +function assertOptionalIndexedAccessType(node, opts) { + assert("OptionalIndexedAccessType", node, opts); +} + +function assertJSXAttribute(node, opts) { + assert("JSXAttribute", node, opts); +} + +function assertJSXClosingElement(node, opts) { + assert("JSXClosingElement", node, opts); +} + +function assertJSXElement(node, opts) { + assert("JSXElement", node, opts); +} + +function assertJSXEmptyExpression(node, opts) { + assert("JSXEmptyExpression", node, opts); +} + +function assertJSXExpressionContainer(node, opts) { + assert("JSXExpressionContainer", node, opts); +} + +function assertJSXSpreadChild(node, opts) { + assert("JSXSpreadChild", node, opts); +} + +function assertJSXIdentifier(node, opts) { + assert("JSXIdentifier", node, opts); +} + +function assertJSXMemberExpression(node, opts) { + assert("JSXMemberExpression", node, opts); +} + +function assertJSXNamespacedName(node, opts) { + assert("JSXNamespacedName", node, opts); +} + +function assertJSXOpeningElement(node, opts) { + assert("JSXOpeningElement", node, opts); +} + +function assertJSXSpreadAttribute(node, opts) { + assert("JSXSpreadAttribute", node, opts); +} + +function assertJSXText(node, opts) { + assert("JSXText", node, opts); +} + +function assertJSXFragment(node, opts) { + assert("JSXFragment", node, opts); +} + +function assertJSXOpeningFragment(node, opts) { + assert("JSXOpeningFragment", node, opts); +} + +function assertJSXClosingFragment(node, opts) { + assert("JSXClosingFragment", node, opts); +} + +function assertNoop(node, opts) { + assert("Noop", node, opts); +} + +function assertPlaceholder(node, opts) { + assert("Placeholder", node, opts); +} + +function assertV8IntrinsicIdentifier(node, opts) { + assert("V8IntrinsicIdentifier", node, opts); +} + +function assertArgumentPlaceholder(node, opts) { + assert("ArgumentPlaceholder", node, opts); +} + +function assertBindExpression(node, opts) { + assert("BindExpression", node, opts); +} + +function assertImportAttribute(node, opts) { + assert("ImportAttribute", node, opts); +} + +function assertDecorator(node, opts) { + assert("Decorator", node, opts); +} + +function assertDoExpression(node, opts) { + assert("DoExpression", node, opts); +} + +function assertExportDefaultSpecifier(node, opts) { + assert("ExportDefaultSpecifier", node, opts); +} + +function assertRecordExpression(node, opts) { + assert("RecordExpression", node, opts); +} + +function assertTupleExpression(node, opts) { + assert("TupleExpression", node, opts); +} + +function assertDecimalLiteral(node, opts) { + assert("DecimalLiteral", node, opts); +} + +function assertModuleExpression(node, opts) { + assert("ModuleExpression", node, opts); +} + +function assertTopicReference(node, opts) { + assert("TopicReference", node, opts); +} + +function assertPipelineTopicExpression(node, opts) { + assert("PipelineTopicExpression", node, opts); +} + +function assertPipelineBareFunction(node, opts) { + assert("PipelineBareFunction", node, opts); +} + +function assertPipelinePrimaryTopicReference(node, opts) { + assert("PipelinePrimaryTopicReference", node, opts); +} + +function assertTSParameterProperty(node, opts) { + assert("TSParameterProperty", node, opts); +} + +function assertTSDeclareFunction(node, opts) { + assert("TSDeclareFunction", node, opts); +} + +function assertTSDeclareMethod(node, opts) { + assert("TSDeclareMethod", node, opts); +} + +function assertTSQualifiedName(node, opts) { + assert("TSQualifiedName", node, opts); +} + +function assertTSCallSignatureDeclaration(node, opts) { + assert("TSCallSignatureDeclaration", node, opts); +} + +function assertTSConstructSignatureDeclaration(node, opts) { + assert("TSConstructSignatureDeclaration", node, opts); +} + +function assertTSPropertySignature(node, opts) { + assert("TSPropertySignature", node, opts); +} + +function assertTSMethodSignature(node, opts) { + assert("TSMethodSignature", node, opts); +} + +function assertTSIndexSignature(node, opts) { + assert("TSIndexSignature", node, opts); +} + +function assertTSAnyKeyword(node, opts) { + assert("TSAnyKeyword", node, opts); +} + +function assertTSBooleanKeyword(node, opts) { + assert("TSBooleanKeyword", node, opts); +} + +function assertTSBigIntKeyword(node, opts) { + assert("TSBigIntKeyword", node, opts); +} + +function assertTSIntrinsicKeyword(node, opts) { + assert("TSIntrinsicKeyword", node, opts); +} + +function assertTSNeverKeyword(node, opts) { + assert("TSNeverKeyword", node, opts); +} + +function assertTSNullKeyword(node, opts) { + assert("TSNullKeyword", node, opts); +} + +function assertTSNumberKeyword(node, opts) { + assert("TSNumberKeyword", node, opts); +} + +function assertTSObjectKeyword(node, opts) { + assert("TSObjectKeyword", node, opts); +} + +function assertTSStringKeyword(node, opts) { + assert("TSStringKeyword", node, opts); +} + +function assertTSSymbolKeyword(node, opts) { + assert("TSSymbolKeyword", node, opts); +} + +function assertTSUndefinedKeyword(node, opts) { + assert("TSUndefinedKeyword", node, opts); +} + +function assertTSUnknownKeyword(node, opts) { + assert("TSUnknownKeyword", node, opts); +} + +function assertTSVoidKeyword(node, opts) { + assert("TSVoidKeyword", node, opts); +} + +function assertTSThisType(node, opts) { + assert("TSThisType", node, opts); +} + +function assertTSFunctionType(node, opts) { + assert("TSFunctionType", node, opts); +} + +function assertTSConstructorType(node, opts) { + assert("TSConstructorType", node, opts); +} + +function assertTSTypeReference(node, opts) { + assert("TSTypeReference", node, opts); +} + +function assertTSTypePredicate(node, opts) { + assert("TSTypePredicate", node, opts); +} + +function assertTSTypeQuery(node, opts) { + assert("TSTypeQuery", node, opts); +} + +function assertTSTypeLiteral(node, opts) { + assert("TSTypeLiteral", node, opts); +} + +function assertTSArrayType(node, opts) { + assert("TSArrayType", node, opts); +} + +function assertTSTupleType(node, opts) { + assert("TSTupleType", node, opts); +} + +function assertTSOptionalType(node, opts) { + assert("TSOptionalType", node, opts); +} + +function assertTSRestType(node, opts) { + assert("TSRestType", node, opts); +} + +function assertTSNamedTupleMember(node, opts) { + assert("TSNamedTupleMember", node, opts); +} + +function assertTSUnionType(node, opts) { + assert("TSUnionType", node, opts); +} + +function assertTSIntersectionType(node, opts) { + assert("TSIntersectionType", node, opts); +} + +function assertTSConditionalType(node, opts) { + assert("TSConditionalType", node, opts); +} + +function assertTSInferType(node, opts) { + assert("TSInferType", node, opts); +} + +function assertTSParenthesizedType(node, opts) { + assert("TSParenthesizedType", node, opts); +} + +function assertTSTypeOperator(node, opts) { + assert("TSTypeOperator", node, opts); +} + +function assertTSIndexedAccessType(node, opts) { + assert("TSIndexedAccessType", node, opts); +} + +function assertTSMappedType(node, opts) { + assert("TSMappedType", node, opts); +} + +function assertTSLiteralType(node, opts) { + assert("TSLiteralType", node, opts); +} + +function assertTSExpressionWithTypeArguments(node, opts) { + assert("TSExpressionWithTypeArguments", node, opts); +} + +function assertTSInterfaceDeclaration(node, opts) { + assert("TSInterfaceDeclaration", node, opts); +} + +function assertTSInterfaceBody(node, opts) { + assert("TSInterfaceBody", node, opts); +} + +function assertTSTypeAliasDeclaration(node, opts) { + assert("TSTypeAliasDeclaration", node, opts); +} + +function assertTSInstantiationExpression(node, opts) { + assert("TSInstantiationExpression", node, opts); +} + +function assertTSAsExpression(node, opts) { + assert("TSAsExpression", node, opts); +} + +function assertTSTypeAssertion(node, opts) { + assert("TSTypeAssertion", node, opts); +} + +function assertTSEnumDeclaration(node, opts) { + assert("TSEnumDeclaration", node, opts); +} + +function assertTSEnumMember(node, opts) { + assert("TSEnumMember", node, opts); +} + +function assertTSModuleDeclaration(node, opts) { + assert("TSModuleDeclaration", node, opts); +} + +function assertTSModuleBlock(node, opts) { + assert("TSModuleBlock", node, opts); +} + +function assertTSImportType(node, opts) { + assert("TSImportType", node, opts); +} + +function assertTSImportEqualsDeclaration(node, opts) { + assert("TSImportEqualsDeclaration", node, opts); +} + +function assertTSExternalModuleReference(node, opts) { + assert("TSExternalModuleReference", node, opts); +} + +function assertTSNonNullExpression(node, opts) { + assert("TSNonNullExpression", node, opts); +} + +function assertTSExportAssignment(node, opts) { + assert("TSExportAssignment", node, opts); +} + +function assertTSNamespaceExportDeclaration(node, opts) { + assert("TSNamespaceExportDeclaration", node, opts); +} + +function assertTSTypeAnnotation(node, opts) { + assert("TSTypeAnnotation", node, opts); +} + +function assertTSTypeParameterInstantiation(node, opts) { + assert("TSTypeParameterInstantiation", node, opts); +} + +function assertTSTypeParameterDeclaration(node, opts) { + assert("TSTypeParameterDeclaration", node, opts); +} + +function assertTSTypeParameter(node, opts) { + assert("TSTypeParameter", node, opts); +} + +function assertStandardized(node, opts) { + assert("Standardized", node, opts); +} + +function assertExpression(node, opts) { + assert("Expression", node, opts); +} + +function assertBinary(node, opts) { + assert("Binary", node, opts); +} + +function assertScopable(node, opts) { + assert("Scopable", node, opts); +} + +function assertBlockParent(node, opts) { + assert("BlockParent", node, opts); +} + +function assertBlock(node, opts) { + assert("Block", node, opts); +} + +function assertStatement(node, opts) { + assert("Statement", node, opts); +} + +function assertTerminatorless(node, opts) { + assert("Terminatorless", node, opts); +} + +function assertCompletionStatement(node, opts) { + assert("CompletionStatement", node, opts); +} + +function assertConditional(node, opts) { + assert("Conditional", node, opts); +} + +function assertLoop(node, opts) { + assert("Loop", node, opts); +} + +function assertWhile(node, opts) { + assert("While", node, opts); +} + +function assertExpressionWrapper(node, opts) { + assert("ExpressionWrapper", node, opts); +} + +function assertFor(node, opts) { + assert("For", node, opts); +} + +function assertForXStatement(node, opts) { + assert("ForXStatement", node, opts); +} + +function assertFunction(node, opts) { + assert("Function", node, opts); +} + +function assertFunctionParent(node, opts) { + assert("FunctionParent", node, opts); +} + +function assertPureish(node, opts) { + assert("Pureish", node, opts); +} + +function assertDeclaration(node, opts) { + assert("Declaration", node, opts); +} + +function assertPatternLike(node, opts) { + assert("PatternLike", node, opts); +} + +function assertLVal(node, opts) { + assert("LVal", node, opts); +} + +function assertTSEntityName(node, opts) { + assert("TSEntityName", node, opts); +} + +function assertLiteral(node, opts) { + assert("Literal", node, opts); +} + +function assertImmutable(node, opts) { + assert("Immutable", node, opts); +} + +function assertUserWhitespacable(node, opts) { + assert("UserWhitespacable", node, opts); +} + +function assertMethod(node, opts) { + assert("Method", node, opts); +} + +function assertObjectMember(node, opts) { + assert("ObjectMember", node, opts); +} + +function assertProperty(node, opts) { + assert("Property", node, opts); +} + +function assertUnaryLike(node, opts) { + assert("UnaryLike", node, opts); +} + +function assertPattern(node, opts) { + assert("Pattern", node, opts); +} + +function assertClass(node, opts) { + assert("Class", node, opts); +} + +function assertModuleDeclaration(node, opts) { + assert("ModuleDeclaration", node, opts); +} + +function assertExportDeclaration(node, opts) { + assert("ExportDeclaration", node, opts); +} + +function assertModuleSpecifier(node, opts) { + assert("ModuleSpecifier", node, opts); +} + +function assertAccessor(node, opts) { + assert("Accessor", node, opts); +} + +function assertPrivate(node, opts) { + assert("Private", node, opts); +} + +function assertFlow(node, opts) { + assert("Flow", node, opts); +} + +function assertFlowType(node, opts) { + assert("FlowType", node, opts); +} + +function assertFlowBaseAnnotation(node, opts) { + assert("FlowBaseAnnotation", node, opts); +} + +function assertFlowDeclaration(node, opts) { + assert("FlowDeclaration", node, opts); +} + +function assertFlowPredicate(node, opts) { + assert("FlowPredicate", node, opts); +} + +function assertEnumBody(node, opts) { + assert("EnumBody", node, opts); +} + +function assertEnumMember(node, opts) { + assert("EnumMember", node, opts); +} + +function assertJSX(node, opts) { + assert("JSX", node, opts); +} + +function assertMiscellaneous(node, opts) { + assert("Miscellaneous", node, opts); +} + +function assertTypeScript(node, opts) { + assert("TypeScript", node, opts); +} + +function assertTSTypeElement(node, opts) { + assert("TSTypeElement", node, opts); +} + +function assertTSType(node, opts) { + assert("TSType", node, opts); +} + +function assertTSBaseType(node, opts) { + assert("TSBaseType", node, opts); +} + +function assertNumberLiteral(node, opts) { + console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); + assert("NumberLiteral", node, opts); +} + +function assertRegexLiteral(node, opts) { + console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); + assert("RegexLiteral", node, opts); +} + +function assertRestProperty(node, opts) { + console.trace("The node type RestProperty has been renamed to RestElement"); + assert("RestProperty", node, opts); +} + +function assertSpreadProperty(node, opts) { + console.trace("The node type SpreadProperty has been renamed to SpreadElement"); + assert("SpreadProperty", node, opts); +} \ No newline at end of file diff --git a/node_modules/@isaacs/import-jsx/node_modules/@babel/types/lib/ast-types/generated/index.js b/node_modules/@isaacs/import-jsx/node_modules/@babel/types/lib/ast-types/generated/index.js new file mode 100644 index 000000000..e69de29bb diff --git a/node_modules/@isaacs/import-jsx/node_modules/@babel/types/lib/builders/generated/index.js b/node_modules/@isaacs/import-jsx/node_modules/@babel/types/lib/builders/generated/index.js new file mode 100644 index 000000000..35a8e143b --- /dev/null +++ b/node_modules/@isaacs/import-jsx/node_modules/@babel/types/lib/builders/generated/index.js @@ -0,0 +1,2227 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.anyTypeAnnotation = anyTypeAnnotation; +exports.argumentPlaceholder = argumentPlaceholder; +exports.arrayExpression = arrayExpression; +exports.arrayPattern = arrayPattern; +exports.arrayTypeAnnotation = arrayTypeAnnotation; +exports.arrowFunctionExpression = arrowFunctionExpression; +exports.assignmentExpression = assignmentExpression; +exports.assignmentPattern = assignmentPattern; +exports.awaitExpression = awaitExpression; +exports.bigIntLiteral = bigIntLiteral; +exports.binaryExpression = binaryExpression; +exports.bindExpression = bindExpression; +exports.blockStatement = blockStatement; +exports.booleanLiteral = booleanLiteral; +exports.booleanLiteralTypeAnnotation = booleanLiteralTypeAnnotation; +exports.booleanTypeAnnotation = booleanTypeAnnotation; +exports.breakStatement = breakStatement; +exports.callExpression = callExpression; +exports.catchClause = catchClause; +exports.classAccessorProperty = classAccessorProperty; +exports.classBody = classBody; +exports.classDeclaration = classDeclaration; +exports.classExpression = classExpression; +exports.classImplements = classImplements; +exports.classMethod = classMethod; +exports.classPrivateMethod = classPrivateMethod; +exports.classPrivateProperty = classPrivateProperty; +exports.classProperty = classProperty; +exports.conditionalExpression = conditionalExpression; +exports.continueStatement = continueStatement; +exports.debuggerStatement = debuggerStatement; +exports.decimalLiteral = decimalLiteral; +exports.declareClass = declareClass; +exports.declareExportAllDeclaration = declareExportAllDeclaration; +exports.declareExportDeclaration = declareExportDeclaration; +exports.declareFunction = declareFunction; +exports.declareInterface = declareInterface; +exports.declareModule = declareModule; +exports.declareModuleExports = declareModuleExports; +exports.declareOpaqueType = declareOpaqueType; +exports.declareTypeAlias = declareTypeAlias; +exports.declareVariable = declareVariable; +exports.declaredPredicate = declaredPredicate; +exports.decorator = decorator; +exports.directive = directive; +exports.directiveLiteral = directiveLiteral; +exports.doExpression = doExpression; +exports.doWhileStatement = doWhileStatement; +exports.emptyStatement = emptyStatement; +exports.emptyTypeAnnotation = emptyTypeAnnotation; +exports.enumBooleanBody = enumBooleanBody; +exports.enumBooleanMember = enumBooleanMember; +exports.enumDeclaration = enumDeclaration; +exports.enumDefaultedMember = enumDefaultedMember; +exports.enumNumberBody = enumNumberBody; +exports.enumNumberMember = enumNumberMember; +exports.enumStringBody = enumStringBody; +exports.enumStringMember = enumStringMember; +exports.enumSymbolBody = enumSymbolBody; +exports.existsTypeAnnotation = existsTypeAnnotation; +exports.exportAllDeclaration = exportAllDeclaration; +exports.exportDefaultDeclaration = exportDefaultDeclaration; +exports.exportDefaultSpecifier = exportDefaultSpecifier; +exports.exportNamedDeclaration = exportNamedDeclaration; +exports.exportNamespaceSpecifier = exportNamespaceSpecifier; +exports.exportSpecifier = exportSpecifier; +exports.expressionStatement = expressionStatement; +exports.file = file; +exports.forInStatement = forInStatement; +exports.forOfStatement = forOfStatement; +exports.forStatement = forStatement; +exports.functionDeclaration = functionDeclaration; +exports.functionExpression = functionExpression; +exports.functionTypeAnnotation = functionTypeAnnotation; +exports.functionTypeParam = functionTypeParam; +exports.genericTypeAnnotation = genericTypeAnnotation; +exports.identifier = identifier; +exports.ifStatement = ifStatement; +exports.import = _import; +exports.importAttribute = importAttribute; +exports.importDeclaration = importDeclaration; +exports.importDefaultSpecifier = importDefaultSpecifier; +exports.importNamespaceSpecifier = importNamespaceSpecifier; +exports.importSpecifier = importSpecifier; +exports.indexedAccessType = indexedAccessType; +exports.inferredPredicate = inferredPredicate; +exports.interfaceDeclaration = interfaceDeclaration; +exports.interfaceExtends = interfaceExtends; +exports.interfaceTypeAnnotation = interfaceTypeAnnotation; +exports.interpreterDirective = interpreterDirective; +exports.intersectionTypeAnnotation = intersectionTypeAnnotation; +exports.jSXAttribute = exports.jsxAttribute = jsxAttribute; +exports.jSXClosingElement = exports.jsxClosingElement = jsxClosingElement; +exports.jSXClosingFragment = exports.jsxClosingFragment = jsxClosingFragment; +exports.jSXElement = exports.jsxElement = jsxElement; +exports.jSXEmptyExpression = exports.jsxEmptyExpression = jsxEmptyExpression; +exports.jSXExpressionContainer = exports.jsxExpressionContainer = jsxExpressionContainer; +exports.jSXFragment = exports.jsxFragment = jsxFragment; +exports.jSXIdentifier = exports.jsxIdentifier = jsxIdentifier; +exports.jSXMemberExpression = exports.jsxMemberExpression = jsxMemberExpression; +exports.jSXNamespacedName = exports.jsxNamespacedName = jsxNamespacedName; +exports.jSXOpeningElement = exports.jsxOpeningElement = jsxOpeningElement; +exports.jSXOpeningFragment = exports.jsxOpeningFragment = jsxOpeningFragment; +exports.jSXSpreadAttribute = exports.jsxSpreadAttribute = jsxSpreadAttribute; +exports.jSXSpreadChild = exports.jsxSpreadChild = jsxSpreadChild; +exports.jSXText = exports.jsxText = jsxText; +exports.labeledStatement = labeledStatement; +exports.logicalExpression = logicalExpression; +exports.memberExpression = memberExpression; +exports.metaProperty = metaProperty; +exports.mixedTypeAnnotation = mixedTypeAnnotation; +exports.moduleExpression = moduleExpression; +exports.newExpression = newExpression; +exports.noop = noop; +exports.nullLiteral = nullLiteral; +exports.nullLiteralTypeAnnotation = nullLiteralTypeAnnotation; +exports.nullableTypeAnnotation = nullableTypeAnnotation; +exports.numberLiteral = NumberLiteral; +exports.numberLiteralTypeAnnotation = numberLiteralTypeAnnotation; +exports.numberTypeAnnotation = numberTypeAnnotation; +exports.numericLiteral = numericLiteral; +exports.objectExpression = objectExpression; +exports.objectMethod = objectMethod; +exports.objectPattern = objectPattern; +exports.objectProperty = objectProperty; +exports.objectTypeAnnotation = objectTypeAnnotation; +exports.objectTypeCallProperty = objectTypeCallProperty; +exports.objectTypeIndexer = objectTypeIndexer; +exports.objectTypeInternalSlot = objectTypeInternalSlot; +exports.objectTypeProperty = objectTypeProperty; +exports.objectTypeSpreadProperty = objectTypeSpreadProperty; +exports.opaqueType = opaqueType; +exports.optionalCallExpression = optionalCallExpression; +exports.optionalIndexedAccessType = optionalIndexedAccessType; +exports.optionalMemberExpression = optionalMemberExpression; +exports.parenthesizedExpression = parenthesizedExpression; +exports.pipelineBareFunction = pipelineBareFunction; +exports.pipelinePrimaryTopicReference = pipelinePrimaryTopicReference; +exports.pipelineTopicExpression = pipelineTopicExpression; +exports.placeholder = placeholder; +exports.privateName = privateName; +exports.program = program; +exports.qualifiedTypeIdentifier = qualifiedTypeIdentifier; +exports.recordExpression = recordExpression; +exports.regExpLiteral = regExpLiteral; +exports.regexLiteral = RegexLiteral; +exports.restElement = restElement; +exports.restProperty = RestProperty; +exports.returnStatement = returnStatement; +exports.sequenceExpression = sequenceExpression; +exports.spreadElement = spreadElement; +exports.spreadProperty = SpreadProperty; +exports.staticBlock = staticBlock; +exports.stringLiteral = stringLiteral; +exports.stringLiteralTypeAnnotation = stringLiteralTypeAnnotation; +exports.stringTypeAnnotation = stringTypeAnnotation; +exports.super = _super; +exports.switchCase = switchCase; +exports.switchStatement = switchStatement; +exports.symbolTypeAnnotation = symbolTypeAnnotation; +exports.taggedTemplateExpression = taggedTemplateExpression; +exports.templateElement = templateElement; +exports.templateLiteral = templateLiteral; +exports.thisExpression = thisExpression; +exports.thisTypeAnnotation = thisTypeAnnotation; +exports.throwStatement = throwStatement; +exports.topicReference = topicReference; +exports.tryStatement = tryStatement; +exports.tSAnyKeyword = exports.tsAnyKeyword = tsAnyKeyword; +exports.tSArrayType = exports.tsArrayType = tsArrayType; +exports.tSAsExpression = exports.tsAsExpression = tsAsExpression; +exports.tSBigIntKeyword = exports.tsBigIntKeyword = tsBigIntKeyword; +exports.tSBooleanKeyword = exports.tsBooleanKeyword = tsBooleanKeyword; +exports.tSCallSignatureDeclaration = exports.tsCallSignatureDeclaration = tsCallSignatureDeclaration; +exports.tSConditionalType = exports.tsConditionalType = tsConditionalType; +exports.tSConstructSignatureDeclaration = exports.tsConstructSignatureDeclaration = tsConstructSignatureDeclaration; +exports.tSConstructorType = exports.tsConstructorType = tsConstructorType; +exports.tSDeclareFunction = exports.tsDeclareFunction = tsDeclareFunction; +exports.tSDeclareMethod = exports.tsDeclareMethod = tsDeclareMethod; +exports.tSEnumDeclaration = exports.tsEnumDeclaration = tsEnumDeclaration; +exports.tSEnumMember = exports.tsEnumMember = tsEnumMember; +exports.tSExportAssignment = exports.tsExportAssignment = tsExportAssignment; +exports.tSExpressionWithTypeArguments = exports.tsExpressionWithTypeArguments = tsExpressionWithTypeArguments; +exports.tSExternalModuleReference = exports.tsExternalModuleReference = tsExternalModuleReference; +exports.tSFunctionType = exports.tsFunctionType = tsFunctionType; +exports.tSImportEqualsDeclaration = exports.tsImportEqualsDeclaration = tsImportEqualsDeclaration; +exports.tSImportType = exports.tsImportType = tsImportType; +exports.tSIndexSignature = exports.tsIndexSignature = tsIndexSignature; +exports.tSIndexedAccessType = exports.tsIndexedAccessType = tsIndexedAccessType; +exports.tSInferType = exports.tsInferType = tsInferType; +exports.tSInstantiationExpression = exports.tsInstantiationExpression = tsInstantiationExpression; +exports.tSInterfaceBody = exports.tsInterfaceBody = tsInterfaceBody; +exports.tSInterfaceDeclaration = exports.tsInterfaceDeclaration = tsInterfaceDeclaration; +exports.tSIntersectionType = exports.tsIntersectionType = tsIntersectionType; +exports.tSIntrinsicKeyword = exports.tsIntrinsicKeyword = tsIntrinsicKeyword; +exports.tSLiteralType = exports.tsLiteralType = tsLiteralType; +exports.tSMappedType = exports.tsMappedType = tsMappedType; +exports.tSMethodSignature = exports.tsMethodSignature = tsMethodSignature; +exports.tSModuleBlock = exports.tsModuleBlock = tsModuleBlock; +exports.tSModuleDeclaration = exports.tsModuleDeclaration = tsModuleDeclaration; +exports.tSNamedTupleMember = exports.tsNamedTupleMember = tsNamedTupleMember; +exports.tSNamespaceExportDeclaration = exports.tsNamespaceExportDeclaration = tsNamespaceExportDeclaration; +exports.tSNeverKeyword = exports.tsNeverKeyword = tsNeverKeyword; +exports.tSNonNullExpression = exports.tsNonNullExpression = tsNonNullExpression; +exports.tSNullKeyword = exports.tsNullKeyword = tsNullKeyword; +exports.tSNumberKeyword = exports.tsNumberKeyword = tsNumberKeyword; +exports.tSObjectKeyword = exports.tsObjectKeyword = tsObjectKeyword; +exports.tSOptionalType = exports.tsOptionalType = tsOptionalType; +exports.tSParameterProperty = exports.tsParameterProperty = tsParameterProperty; +exports.tSParenthesizedType = exports.tsParenthesizedType = tsParenthesizedType; +exports.tSPropertySignature = exports.tsPropertySignature = tsPropertySignature; +exports.tSQualifiedName = exports.tsQualifiedName = tsQualifiedName; +exports.tSRestType = exports.tsRestType = tsRestType; +exports.tSStringKeyword = exports.tsStringKeyword = tsStringKeyword; +exports.tSSymbolKeyword = exports.tsSymbolKeyword = tsSymbolKeyword; +exports.tSThisType = exports.tsThisType = tsThisType; +exports.tSTupleType = exports.tsTupleType = tsTupleType; +exports.tSTypeAliasDeclaration = exports.tsTypeAliasDeclaration = tsTypeAliasDeclaration; +exports.tSTypeAnnotation = exports.tsTypeAnnotation = tsTypeAnnotation; +exports.tSTypeAssertion = exports.tsTypeAssertion = tsTypeAssertion; +exports.tSTypeLiteral = exports.tsTypeLiteral = tsTypeLiteral; +exports.tSTypeOperator = exports.tsTypeOperator = tsTypeOperator; +exports.tSTypeParameter = exports.tsTypeParameter = tsTypeParameter; +exports.tSTypeParameterDeclaration = exports.tsTypeParameterDeclaration = tsTypeParameterDeclaration; +exports.tSTypeParameterInstantiation = exports.tsTypeParameterInstantiation = tsTypeParameterInstantiation; +exports.tSTypePredicate = exports.tsTypePredicate = tsTypePredicate; +exports.tSTypeQuery = exports.tsTypeQuery = tsTypeQuery; +exports.tSTypeReference = exports.tsTypeReference = tsTypeReference; +exports.tSUndefinedKeyword = exports.tsUndefinedKeyword = tsUndefinedKeyword; +exports.tSUnionType = exports.tsUnionType = tsUnionType; +exports.tSUnknownKeyword = exports.tsUnknownKeyword = tsUnknownKeyword; +exports.tSVoidKeyword = exports.tsVoidKeyword = tsVoidKeyword; +exports.tupleExpression = tupleExpression; +exports.tupleTypeAnnotation = tupleTypeAnnotation; +exports.typeAlias = typeAlias; +exports.typeAnnotation = typeAnnotation; +exports.typeCastExpression = typeCastExpression; +exports.typeParameter = typeParameter; +exports.typeParameterDeclaration = typeParameterDeclaration; +exports.typeParameterInstantiation = typeParameterInstantiation; +exports.typeofTypeAnnotation = typeofTypeAnnotation; +exports.unaryExpression = unaryExpression; +exports.unionTypeAnnotation = unionTypeAnnotation; +exports.updateExpression = updateExpression; +exports.v8IntrinsicIdentifier = v8IntrinsicIdentifier; +exports.variableDeclaration = variableDeclaration; +exports.variableDeclarator = variableDeclarator; +exports.variance = variance; +exports.voidTypeAnnotation = voidTypeAnnotation; +exports.whileStatement = whileStatement; +exports.withStatement = withStatement; +exports.yieldExpression = yieldExpression; + +var _validateNode = require("../validateNode"); + +function arrayExpression(elements = []) { + return (0, _validateNode.default)({ + type: "ArrayExpression", + elements + }); +} + +function assignmentExpression(operator, left, right) { + return (0, _validateNode.default)({ + type: "AssignmentExpression", + operator, + left, + right + }); +} + +function binaryExpression(operator, left, right) { + return (0, _validateNode.default)({ + type: "BinaryExpression", + operator, + left, + right + }); +} + +function interpreterDirective(value) { + return (0, _validateNode.default)({ + type: "InterpreterDirective", + value + }); +} + +function directive(value) { + return (0, _validateNode.default)({ + type: "Directive", + value + }); +} + +function directiveLiteral(value) { + return (0, _validateNode.default)({ + type: "DirectiveLiteral", + value + }); +} + +function blockStatement(body, directives = []) { + return (0, _validateNode.default)({ + type: "BlockStatement", + body, + directives + }); +} + +function breakStatement(label = null) { + return (0, _validateNode.default)({ + type: "BreakStatement", + label + }); +} + +function callExpression(callee, _arguments) { + return (0, _validateNode.default)({ + type: "CallExpression", + callee, + arguments: _arguments + }); +} + +function catchClause(param = null, body) { + return (0, _validateNode.default)({ + type: "CatchClause", + param, + body + }); +} + +function conditionalExpression(test, consequent, alternate) { + return (0, _validateNode.default)({ + type: "ConditionalExpression", + test, + consequent, + alternate + }); +} + +function continueStatement(label = null) { + return (0, _validateNode.default)({ + type: "ContinueStatement", + label + }); +} + +function debuggerStatement() { + return { + type: "DebuggerStatement" + }; +} + +function doWhileStatement(test, body) { + return (0, _validateNode.default)({ + type: "DoWhileStatement", + test, + body + }); +} + +function emptyStatement() { + return { + type: "EmptyStatement" + }; +} + +function expressionStatement(expression) { + return (0, _validateNode.default)({ + type: "ExpressionStatement", + expression + }); +} + +function file(program, comments = null, tokens = null) { + return (0, _validateNode.default)({ + type: "File", + program, + comments, + tokens + }); +} + +function forInStatement(left, right, body) { + return (0, _validateNode.default)({ + type: "ForInStatement", + left, + right, + body + }); +} + +function forStatement(init = null, test = null, update = null, body) { + return (0, _validateNode.default)({ + type: "ForStatement", + init, + test, + update, + body + }); +} + +function functionDeclaration(id = null, params, body, generator = false, async = false) { + return (0, _validateNode.default)({ + type: "FunctionDeclaration", + id, + params, + body, + generator, + async + }); +} + +function functionExpression(id = null, params, body, generator = false, async = false) { + return (0, _validateNode.default)({ + type: "FunctionExpression", + id, + params, + body, + generator, + async + }); +} + +function identifier(name) { + return (0, _validateNode.default)({ + type: "Identifier", + name + }); +} + +function ifStatement(test, consequent, alternate = null) { + return (0, _validateNode.default)({ + type: "IfStatement", + test, + consequent, + alternate + }); +} + +function labeledStatement(label, body) { + return (0, _validateNode.default)({ + type: "LabeledStatement", + label, + body + }); +} + +function stringLiteral(value) { + return (0, _validateNode.default)({ + type: "StringLiteral", + value + }); +} + +function numericLiteral(value) { + return (0, _validateNode.default)({ + type: "NumericLiteral", + value + }); +} + +function nullLiteral() { + return { + type: "NullLiteral" + }; +} + +function booleanLiteral(value) { + return (0, _validateNode.default)({ + type: "BooleanLiteral", + value + }); +} + +function regExpLiteral(pattern, flags = "") { + return (0, _validateNode.default)({ + type: "RegExpLiteral", + pattern, + flags + }); +} + +function logicalExpression(operator, left, right) { + return (0, _validateNode.default)({ + type: "LogicalExpression", + operator, + left, + right + }); +} + +function memberExpression(object, property, computed = false, optional = null) { + return (0, _validateNode.default)({ + type: "MemberExpression", + object, + property, + computed, + optional + }); +} + +function newExpression(callee, _arguments) { + return (0, _validateNode.default)({ + type: "NewExpression", + callee, + arguments: _arguments + }); +} + +function program(body, directives = [], sourceType = "script", interpreter = null) { + return (0, _validateNode.default)({ + type: "Program", + body, + directives, + sourceType, + interpreter, + sourceFile: null + }); +} + +function objectExpression(properties) { + return (0, _validateNode.default)({ + type: "ObjectExpression", + properties + }); +} + +function objectMethod(kind = "method", key, params, body, computed = false, generator = false, async = false) { + return (0, _validateNode.default)({ + type: "ObjectMethod", + kind, + key, + params, + body, + computed, + generator, + async + }); +} + +function objectProperty(key, value, computed = false, shorthand = false, decorators = null) { + return (0, _validateNode.default)({ + type: "ObjectProperty", + key, + value, + computed, + shorthand, + decorators + }); +} + +function restElement(argument) { + return (0, _validateNode.default)({ + type: "RestElement", + argument + }); +} + +function returnStatement(argument = null) { + return (0, _validateNode.default)({ + type: "ReturnStatement", + argument + }); +} + +function sequenceExpression(expressions) { + return (0, _validateNode.default)({ + type: "SequenceExpression", + expressions + }); +} + +function parenthesizedExpression(expression) { + return (0, _validateNode.default)({ + type: "ParenthesizedExpression", + expression + }); +} + +function switchCase(test = null, consequent) { + return (0, _validateNode.default)({ + type: "SwitchCase", + test, + consequent + }); +} + +function switchStatement(discriminant, cases) { + return (0, _validateNode.default)({ + type: "SwitchStatement", + discriminant, + cases + }); +} + +function thisExpression() { + return { + type: "ThisExpression" + }; +} + +function throwStatement(argument) { + return (0, _validateNode.default)({ + type: "ThrowStatement", + argument + }); +} + +function tryStatement(block, handler = null, finalizer = null) { + return (0, _validateNode.default)({ + type: "TryStatement", + block, + handler, + finalizer + }); +} + +function unaryExpression(operator, argument, prefix = true) { + return (0, _validateNode.default)({ + type: "UnaryExpression", + operator, + argument, + prefix + }); +} + +function updateExpression(operator, argument, prefix = false) { + return (0, _validateNode.default)({ + type: "UpdateExpression", + operator, + argument, + prefix + }); +} + +function variableDeclaration(kind, declarations) { + return (0, _validateNode.default)({ + type: "VariableDeclaration", + kind, + declarations + }); +} + +function variableDeclarator(id, init = null) { + return (0, _validateNode.default)({ + type: "VariableDeclarator", + id, + init + }); +} + +function whileStatement(test, body) { + return (0, _validateNode.default)({ + type: "WhileStatement", + test, + body + }); +} + +function withStatement(object, body) { + return (0, _validateNode.default)({ + type: "WithStatement", + object, + body + }); +} + +function assignmentPattern(left, right) { + return (0, _validateNode.default)({ + type: "AssignmentPattern", + left, + right + }); +} + +function arrayPattern(elements) { + return (0, _validateNode.default)({ + type: "ArrayPattern", + elements + }); +} + +function arrowFunctionExpression(params, body, async = false) { + return (0, _validateNode.default)({ + type: "ArrowFunctionExpression", + params, + body, + async, + expression: null + }); +} + +function classBody(body) { + return (0, _validateNode.default)({ + type: "ClassBody", + body + }); +} + +function classExpression(id = null, superClass = null, body, decorators = null) { + return (0, _validateNode.default)({ + type: "ClassExpression", + id, + superClass, + body, + decorators + }); +} + +function classDeclaration(id, superClass = null, body, decorators = null) { + return (0, _validateNode.default)({ + type: "ClassDeclaration", + id, + superClass, + body, + decorators + }); +} + +function exportAllDeclaration(source) { + return (0, _validateNode.default)({ + type: "ExportAllDeclaration", + source + }); +} + +function exportDefaultDeclaration(declaration) { + return (0, _validateNode.default)({ + type: "ExportDefaultDeclaration", + declaration + }); +} + +function exportNamedDeclaration(declaration = null, specifiers = [], source = null) { + return (0, _validateNode.default)({ + type: "ExportNamedDeclaration", + declaration, + specifiers, + source + }); +} + +function exportSpecifier(local, exported) { + return (0, _validateNode.default)({ + type: "ExportSpecifier", + local, + exported + }); +} + +function forOfStatement(left, right, body, _await = false) { + return (0, _validateNode.default)({ + type: "ForOfStatement", + left, + right, + body, + await: _await + }); +} + +function importDeclaration(specifiers, source) { + return (0, _validateNode.default)({ + type: "ImportDeclaration", + specifiers, + source + }); +} + +function importDefaultSpecifier(local) { + return (0, _validateNode.default)({ + type: "ImportDefaultSpecifier", + local + }); +} + +function importNamespaceSpecifier(local) { + return (0, _validateNode.default)({ + type: "ImportNamespaceSpecifier", + local + }); +} + +function importSpecifier(local, imported) { + return (0, _validateNode.default)({ + type: "ImportSpecifier", + local, + imported + }); +} + +function metaProperty(meta, property) { + return (0, _validateNode.default)({ + type: "MetaProperty", + meta, + property + }); +} + +function classMethod(kind = "method", key, params, body, computed = false, _static = false, generator = false, async = false) { + return (0, _validateNode.default)({ + type: "ClassMethod", + kind, + key, + params, + body, + computed, + static: _static, + generator, + async + }); +} + +function objectPattern(properties) { + return (0, _validateNode.default)({ + type: "ObjectPattern", + properties + }); +} + +function spreadElement(argument) { + return (0, _validateNode.default)({ + type: "SpreadElement", + argument + }); +} + +function _super() { + return { + type: "Super" + }; +} + +function taggedTemplateExpression(tag, quasi) { + return (0, _validateNode.default)({ + type: "TaggedTemplateExpression", + tag, + quasi + }); +} + +function templateElement(value, tail = false) { + return (0, _validateNode.default)({ + type: "TemplateElement", + value, + tail + }); +} + +function templateLiteral(quasis, expressions) { + return (0, _validateNode.default)({ + type: "TemplateLiteral", + quasis, + expressions + }); +} + +function yieldExpression(argument = null, delegate = false) { + return (0, _validateNode.default)({ + type: "YieldExpression", + argument, + delegate + }); +} + +function awaitExpression(argument) { + return (0, _validateNode.default)({ + type: "AwaitExpression", + argument + }); +} + +function _import() { + return { + type: "Import" + }; +} + +function bigIntLiteral(value) { + return (0, _validateNode.default)({ + type: "BigIntLiteral", + value + }); +} + +function exportNamespaceSpecifier(exported) { + return (0, _validateNode.default)({ + type: "ExportNamespaceSpecifier", + exported + }); +} + +function optionalMemberExpression(object, property, computed = false, optional) { + return (0, _validateNode.default)({ + type: "OptionalMemberExpression", + object, + property, + computed, + optional + }); +} + +function optionalCallExpression(callee, _arguments, optional) { + return (0, _validateNode.default)({ + type: "OptionalCallExpression", + callee, + arguments: _arguments, + optional + }); +} + +function classProperty(key, value = null, typeAnnotation = null, decorators = null, computed = false, _static = false) { + return (0, _validateNode.default)({ + type: "ClassProperty", + key, + value, + typeAnnotation, + decorators, + computed, + static: _static + }); +} + +function classAccessorProperty(key, value = null, typeAnnotation = null, decorators = null, computed = false, _static = false) { + return (0, _validateNode.default)({ + type: "ClassAccessorProperty", + key, + value, + typeAnnotation, + decorators, + computed, + static: _static + }); +} + +function classPrivateProperty(key, value = null, decorators = null, _static) { + return (0, _validateNode.default)({ + type: "ClassPrivateProperty", + key, + value, + decorators, + static: _static + }); +} + +function classPrivateMethod(kind = "method", key, params, body, _static = false) { + return (0, _validateNode.default)({ + type: "ClassPrivateMethod", + kind, + key, + params, + body, + static: _static + }); +} + +function privateName(id) { + return (0, _validateNode.default)({ + type: "PrivateName", + id + }); +} + +function staticBlock(body) { + return (0, _validateNode.default)({ + type: "StaticBlock", + body + }); +} + +function anyTypeAnnotation() { + return { + type: "AnyTypeAnnotation" + }; +} + +function arrayTypeAnnotation(elementType) { + return (0, _validateNode.default)({ + type: "ArrayTypeAnnotation", + elementType + }); +} + +function booleanTypeAnnotation() { + return { + type: "BooleanTypeAnnotation" + }; +} + +function booleanLiteralTypeAnnotation(value) { + return (0, _validateNode.default)({ + type: "BooleanLiteralTypeAnnotation", + value + }); +} + +function nullLiteralTypeAnnotation() { + return { + type: "NullLiteralTypeAnnotation" + }; +} + +function classImplements(id, typeParameters = null) { + return (0, _validateNode.default)({ + type: "ClassImplements", + id, + typeParameters + }); +} + +function declareClass(id, typeParameters = null, _extends = null, body) { + return (0, _validateNode.default)({ + type: "DeclareClass", + id, + typeParameters, + extends: _extends, + body + }); +} + +function declareFunction(id) { + return (0, _validateNode.default)({ + type: "DeclareFunction", + id + }); +} + +function declareInterface(id, typeParameters = null, _extends = null, body) { + return (0, _validateNode.default)({ + type: "DeclareInterface", + id, + typeParameters, + extends: _extends, + body + }); +} + +function declareModule(id, body, kind = null) { + return (0, _validateNode.default)({ + type: "DeclareModule", + id, + body, + kind + }); +} + +function declareModuleExports(typeAnnotation) { + return (0, _validateNode.default)({ + type: "DeclareModuleExports", + typeAnnotation + }); +} + +function declareTypeAlias(id, typeParameters = null, right) { + return (0, _validateNode.default)({ + type: "DeclareTypeAlias", + id, + typeParameters, + right + }); +} + +function declareOpaqueType(id, typeParameters = null, supertype = null) { + return (0, _validateNode.default)({ + type: "DeclareOpaqueType", + id, + typeParameters, + supertype + }); +} + +function declareVariable(id) { + return (0, _validateNode.default)({ + type: "DeclareVariable", + id + }); +} + +function declareExportDeclaration(declaration = null, specifiers = null, source = null) { + return (0, _validateNode.default)({ + type: "DeclareExportDeclaration", + declaration, + specifiers, + source + }); +} + +function declareExportAllDeclaration(source) { + return (0, _validateNode.default)({ + type: "DeclareExportAllDeclaration", + source + }); +} + +function declaredPredicate(value) { + return (0, _validateNode.default)({ + type: "DeclaredPredicate", + value + }); +} + +function existsTypeAnnotation() { + return { + type: "ExistsTypeAnnotation" + }; +} + +function functionTypeAnnotation(typeParameters = null, params, rest = null, returnType) { + return (0, _validateNode.default)({ + type: "FunctionTypeAnnotation", + typeParameters, + params, + rest, + returnType + }); +} + +function functionTypeParam(name = null, typeAnnotation) { + return (0, _validateNode.default)({ + type: "FunctionTypeParam", + name, + typeAnnotation + }); +} + +function genericTypeAnnotation(id, typeParameters = null) { + return (0, _validateNode.default)({ + type: "GenericTypeAnnotation", + id, + typeParameters + }); +} + +function inferredPredicate() { + return { + type: "InferredPredicate" + }; +} + +function interfaceExtends(id, typeParameters = null) { + return (0, _validateNode.default)({ + type: "InterfaceExtends", + id, + typeParameters + }); +} + +function interfaceDeclaration(id, typeParameters = null, _extends = null, body) { + return (0, _validateNode.default)({ + type: "InterfaceDeclaration", + id, + typeParameters, + extends: _extends, + body + }); +} + +function interfaceTypeAnnotation(_extends = null, body) { + return (0, _validateNode.default)({ + type: "InterfaceTypeAnnotation", + extends: _extends, + body + }); +} + +function intersectionTypeAnnotation(types) { + return (0, _validateNode.default)({ + type: "IntersectionTypeAnnotation", + types + }); +} + +function mixedTypeAnnotation() { + return { + type: "MixedTypeAnnotation" + }; +} + +function emptyTypeAnnotation() { + return { + type: "EmptyTypeAnnotation" + }; +} + +function nullableTypeAnnotation(typeAnnotation) { + return (0, _validateNode.default)({ + type: "NullableTypeAnnotation", + typeAnnotation + }); +} + +function numberLiteralTypeAnnotation(value) { + return (0, _validateNode.default)({ + type: "NumberLiteralTypeAnnotation", + value + }); +} + +function numberTypeAnnotation() { + return { + type: "NumberTypeAnnotation" + }; +} + +function objectTypeAnnotation(properties, indexers = [], callProperties = [], internalSlots = [], exact = false) { + return (0, _validateNode.default)({ + type: "ObjectTypeAnnotation", + properties, + indexers, + callProperties, + internalSlots, + exact + }); +} + +function objectTypeInternalSlot(id, value, optional, _static, method) { + return (0, _validateNode.default)({ + type: "ObjectTypeInternalSlot", + id, + value, + optional, + static: _static, + method + }); +} + +function objectTypeCallProperty(value) { + return (0, _validateNode.default)({ + type: "ObjectTypeCallProperty", + value, + static: null + }); +} + +function objectTypeIndexer(id = null, key, value, variance = null) { + return (0, _validateNode.default)({ + type: "ObjectTypeIndexer", + id, + key, + value, + variance, + static: null + }); +} + +function objectTypeProperty(key, value, variance = null) { + return (0, _validateNode.default)({ + type: "ObjectTypeProperty", + key, + value, + variance, + kind: null, + method: null, + optional: null, + proto: null, + static: null + }); +} + +function objectTypeSpreadProperty(argument) { + return (0, _validateNode.default)({ + type: "ObjectTypeSpreadProperty", + argument + }); +} + +function opaqueType(id, typeParameters = null, supertype = null, impltype) { + return (0, _validateNode.default)({ + type: "OpaqueType", + id, + typeParameters, + supertype, + impltype + }); +} + +function qualifiedTypeIdentifier(id, qualification) { + return (0, _validateNode.default)({ + type: "QualifiedTypeIdentifier", + id, + qualification + }); +} + +function stringLiteralTypeAnnotation(value) { + return (0, _validateNode.default)({ + type: "StringLiteralTypeAnnotation", + value + }); +} + +function stringTypeAnnotation() { + return { + type: "StringTypeAnnotation" + }; +} + +function symbolTypeAnnotation() { + return { + type: "SymbolTypeAnnotation" + }; +} + +function thisTypeAnnotation() { + return { + type: "ThisTypeAnnotation" + }; +} + +function tupleTypeAnnotation(types) { + return (0, _validateNode.default)({ + type: "TupleTypeAnnotation", + types + }); +} + +function typeofTypeAnnotation(argument) { + return (0, _validateNode.default)({ + type: "TypeofTypeAnnotation", + argument + }); +} + +function typeAlias(id, typeParameters = null, right) { + return (0, _validateNode.default)({ + type: "TypeAlias", + id, + typeParameters, + right + }); +} + +function typeAnnotation(typeAnnotation) { + return (0, _validateNode.default)({ + type: "TypeAnnotation", + typeAnnotation + }); +} + +function typeCastExpression(expression, typeAnnotation) { + return (0, _validateNode.default)({ + type: "TypeCastExpression", + expression, + typeAnnotation + }); +} + +function typeParameter(bound = null, _default = null, variance = null) { + return (0, _validateNode.default)({ + type: "TypeParameter", + bound, + default: _default, + variance, + name: null + }); +} + +function typeParameterDeclaration(params) { + return (0, _validateNode.default)({ + type: "TypeParameterDeclaration", + params + }); +} + +function typeParameterInstantiation(params) { + return (0, _validateNode.default)({ + type: "TypeParameterInstantiation", + params + }); +} + +function unionTypeAnnotation(types) { + return (0, _validateNode.default)({ + type: "UnionTypeAnnotation", + types + }); +} + +function variance(kind) { + return (0, _validateNode.default)({ + type: "Variance", + kind + }); +} + +function voidTypeAnnotation() { + return { + type: "VoidTypeAnnotation" + }; +} + +function enumDeclaration(id, body) { + return (0, _validateNode.default)({ + type: "EnumDeclaration", + id, + body + }); +} + +function enumBooleanBody(members) { + return (0, _validateNode.default)({ + type: "EnumBooleanBody", + members, + explicitType: null, + hasUnknownMembers: null + }); +} + +function enumNumberBody(members) { + return (0, _validateNode.default)({ + type: "EnumNumberBody", + members, + explicitType: null, + hasUnknownMembers: null + }); +} + +function enumStringBody(members) { + return (0, _validateNode.default)({ + type: "EnumStringBody", + members, + explicitType: null, + hasUnknownMembers: null + }); +} + +function enumSymbolBody(members) { + return (0, _validateNode.default)({ + type: "EnumSymbolBody", + members, + hasUnknownMembers: null + }); +} + +function enumBooleanMember(id) { + return (0, _validateNode.default)({ + type: "EnumBooleanMember", + id, + init: null + }); +} + +function enumNumberMember(id, init) { + return (0, _validateNode.default)({ + type: "EnumNumberMember", + id, + init + }); +} + +function enumStringMember(id, init) { + return (0, _validateNode.default)({ + type: "EnumStringMember", + id, + init + }); +} + +function enumDefaultedMember(id) { + return (0, _validateNode.default)({ + type: "EnumDefaultedMember", + id + }); +} + +function indexedAccessType(objectType, indexType) { + return (0, _validateNode.default)({ + type: "IndexedAccessType", + objectType, + indexType + }); +} + +function optionalIndexedAccessType(objectType, indexType) { + return (0, _validateNode.default)({ + type: "OptionalIndexedAccessType", + objectType, + indexType, + optional: null + }); +} + +function jsxAttribute(name, value = null) { + return (0, _validateNode.default)({ + type: "JSXAttribute", + name, + value + }); +} + +function jsxClosingElement(name) { + return (0, _validateNode.default)({ + type: "JSXClosingElement", + name + }); +} + +function jsxElement(openingElement, closingElement = null, children, selfClosing = null) { + return (0, _validateNode.default)({ + type: "JSXElement", + openingElement, + closingElement, + children, + selfClosing + }); +} + +function jsxEmptyExpression() { + return { + type: "JSXEmptyExpression" + }; +} + +function jsxExpressionContainer(expression) { + return (0, _validateNode.default)({ + type: "JSXExpressionContainer", + expression + }); +} + +function jsxSpreadChild(expression) { + return (0, _validateNode.default)({ + type: "JSXSpreadChild", + expression + }); +} + +function jsxIdentifier(name) { + return (0, _validateNode.default)({ + type: "JSXIdentifier", + name + }); +} + +function jsxMemberExpression(object, property) { + return (0, _validateNode.default)({ + type: "JSXMemberExpression", + object, + property + }); +} + +function jsxNamespacedName(namespace, name) { + return (0, _validateNode.default)({ + type: "JSXNamespacedName", + namespace, + name + }); +} + +function jsxOpeningElement(name, attributes, selfClosing = false) { + return (0, _validateNode.default)({ + type: "JSXOpeningElement", + name, + attributes, + selfClosing + }); +} + +function jsxSpreadAttribute(argument) { + return (0, _validateNode.default)({ + type: "JSXSpreadAttribute", + argument + }); +} + +function jsxText(value) { + return (0, _validateNode.default)({ + type: "JSXText", + value + }); +} + +function jsxFragment(openingFragment, closingFragment, children) { + return (0, _validateNode.default)({ + type: "JSXFragment", + openingFragment, + closingFragment, + children + }); +} + +function jsxOpeningFragment() { + return { + type: "JSXOpeningFragment" + }; +} + +function jsxClosingFragment() { + return { + type: "JSXClosingFragment" + }; +} + +function noop() { + return { + type: "Noop" + }; +} + +function placeholder(expectedNode, name) { + return (0, _validateNode.default)({ + type: "Placeholder", + expectedNode, + name + }); +} + +function v8IntrinsicIdentifier(name) { + return (0, _validateNode.default)({ + type: "V8IntrinsicIdentifier", + name + }); +} + +function argumentPlaceholder() { + return { + type: "ArgumentPlaceholder" + }; +} + +function bindExpression(object, callee) { + return (0, _validateNode.default)({ + type: "BindExpression", + object, + callee + }); +} + +function importAttribute(key, value) { + return (0, _validateNode.default)({ + type: "ImportAttribute", + key, + value + }); +} + +function decorator(expression) { + return (0, _validateNode.default)({ + type: "Decorator", + expression + }); +} + +function doExpression(body, async = false) { + return (0, _validateNode.default)({ + type: "DoExpression", + body, + async + }); +} + +function exportDefaultSpecifier(exported) { + return (0, _validateNode.default)({ + type: "ExportDefaultSpecifier", + exported + }); +} + +function recordExpression(properties) { + return (0, _validateNode.default)({ + type: "RecordExpression", + properties + }); +} + +function tupleExpression(elements = []) { + return (0, _validateNode.default)({ + type: "TupleExpression", + elements + }); +} + +function decimalLiteral(value) { + return (0, _validateNode.default)({ + type: "DecimalLiteral", + value + }); +} + +function moduleExpression(body) { + return (0, _validateNode.default)({ + type: "ModuleExpression", + body + }); +} + +function topicReference() { + return { + type: "TopicReference" + }; +} + +function pipelineTopicExpression(expression) { + return (0, _validateNode.default)({ + type: "PipelineTopicExpression", + expression + }); +} + +function pipelineBareFunction(callee) { + return (0, _validateNode.default)({ + type: "PipelineBareFunction", + callee + }); +} + +function pipelinePrimaryTopicReference() { + return { + type: "PipelinePrimaryTopicReference" + }; +} + +function tsParameterProperty(parameter) { + return (0, _validateNode.default)({ + type: "TSParameterProperty", + parameter + }); +} + +function tsDeclareFunction(id = null, typeParameters = null, params, returnType = null) { + return (0, _validateNode.default)({ + type: "TSDeclareFunction", + id, + typeParameters, + params, + returnType + }); +} + +function tsDeclareMethod(decorators = null, key, typeParameters = null, params, returnType = null) { + return (0, _validateNode.default)({ + type: "TSDeclareMethod", + decorators, + key, + typeParameters, + params, + returnType + }); +} + +function tsQualifiedName(left, right) { + return (0, _validateNode.default)({ + type: "TSQualifiedName", + left, + right + }); +} + +function tsCallSignatureDeclaration(typeParameters = null, parameters, typeAnnotation = null) { + return (0, _validateNode.default)({ + type: "TSCallSignatureDeclaration", + typeParameters, + parameters, + typeAnnotation + }); +} + +function tsConstructSignatureDeclaration(typeParameters = null, parameters, typeAnnotation = null) { + return (0, _validateNode.default)({ + type: "TSConstructSignatureDeclaration", + typeParameters, + parameters, + typeAnnotation + }); +} + +function tsPropertySignature(key, typeAnnotation = null, initializer = null) { + return (0, _validateNode.default)({ + type: "TSPropertySignature", + key, + typeAnnotation, + initializer, + kind: null + }); +} + +function tsMethodSignature(key, typeParameters = null, parameters, typeAnnotation = null) { + return (0, _validateNode.default)({ + type: "TSMethodSignature", + key, + typeParameters, + parameters, + typeAnnotation, + kind: null + }); +} + +function tsIndexSignature(parameters, typeAnnotation = null) { + return (0, _validateNode.default)({ + type: "TSIndexSignature", + parameters, + typeAnnotation + }); +} + +function tsAnyKeyword() { + return { + type: "TSAnyKeyword" + }; +} + +function tsBooleanKeyword() { + return { + type: "TSBooleanKeyword" + }; +} + +function tsBigIntKeyword() { + return { + type: "TSBigIntKeyword" + }; +} + +function tsIntrinsicKeyword() { + return { + type: "TSIntrinsicKeyword" + }; +} + +function tsNeverKeyword() { + return { + type: "TSNeverKeyword" + }; +} + +function tsNullKeyword() { + return { + type: "TSNullKeyword" + }; +} + +function tsNumberKeyword() { + return { + type: "TSNumberKeyword" + }; +} + +function tsObjectKeyword() { + return { + type: "TSObjectKeyword" + }; +} + +function tsStringKeyword() { + return { + type: "TSStringKeyword" + }; +} + +function tsSymbolKeyword() { + return { + type: "TSSymbolKeyword" + }; +} + +function tsUndefinedKeyword() { + return { + type: "TSUndefinedKeyword" + }; +} + +function tsUnknownKeyword() { + return { + type: "TSUnknownKeyword" + }; +} + +function tsVoidKeyword() { + return { + type: "TSVoidKeyword" + }; +} + +function tsThisType() { + return { + type: "TSThisType" + }; +} + +function tsFunctionType(typeParameters = null, parameters, typeAnnotation = null) { + return (0, _validateNode.default)({ + type: "TSFunctionType", + typeParameters, + parameters, + typeAnnotation + }); +} + +function tsConstructorType(typeParameters = null, parameters, typeAnnotation = null) { + return (0, _validateNode.default)({ + type: "TSConstructorType", + typeParameters, + parameters, + typeAnnotation + }); +} + +function tsTypeReference(typeName, typeParameters = null) { + return (0, _validateNode.default)({ + type: "TSTypeReference", + typeName, + typeParameters + }); +} + +function tsTypePredicate(parameterName, typeAnnotation = null, asserts = null) { + return (0, _validateNode.default)({ + type: "TSTypePredicate", + parameterName, + typeAnnotation, + asserts + }); +} + +function tsTypeQuery(exprName, typeParameters = null) { + return (0, _validateNode.default)({ + type: "TSTypeQuery", + exprName, + typeParameters + }); +} + +function tsTypeLiteral(members) { + return (0, _validateNode.default)({ + type: "TSTypeLiteral", + members + }); +} + +function tsArrayType(elementType) { + return (0, _validateNode.default)({ + type: "TSArrayType", + elementType + }); +} + +function tsTupleType(elementTypes) { + return (0, _validateNode.default)({ + type: "TSTupleType", + elementTypes + }); +} + +function tsOptionalType(typeAnnotation) { + return (0, _validateNode.default)({ + type: "TSOptionalType", + typeAnnotation + }); +} + +function tsRestType(typeAnnotation) { + return (0, _validateNode.default)({ + type: "TSRestType", + typeAnnotation + }); +} + +function tsNamedTupleMember(label, elementType, optional = false) { + return (0, _validateNode.default)({ + type: "TSNamedTupleMember", + label, + elementType, + optional + }); +} + +function tsUnionType(types) { + return (0, _validateNode.default)({ + type: "TSUnionType", + types + }); +} + +function tsIntersectionType(types) { + return (0, _validateNode.default)({ + type: "TSIntersectionType", + types + }); +} + +function tsConditionalType(checkType, extendsType, trueType, falseType) { + return (0, _validateNode.default)({ + type: "TSConditionalType", + checkType, + extendsType, + trueType, + falseType + }); +} + +function tsInferType(typeParameter) { + return (0, _validateNode.default)({ + type: "TSInferType", + typeParameter + }); +} + +function tsParenthesizedType(typeAnnotation) { + return (0, _validateNode.default)({ + type: "TSParenthesizedType", + typeAnnotation + }); +} + +function tsTypeOperator(typeAnnotation) { + return (0, _validateNode.default)({ + type: "TSTypeOperator", + typeAnnotation, + operator: null + }); +} + +function tsIndexedAccessType(objectType, indexType) { + return (0, _validateNode.default)({ + type: "TSIndexedAccessType", + objectType, + indexType + }); +} + +function tsMappedType(typeParameter, typeAnnotation = null, nameType = null) { + return (0, _validateNode.default)({ + type: "TSMappedType", + typeParameter, + typeAnnotation, + nameType + }); +} + +function tsLiteralType(literal) { + return (0, _validateNode.default)({ + type: "TSLiteralType", + literal + }); +} + +function tsExpressionWithTypeArguments(expression, typeParameters = null) { + return (0, _validateNode.default)({ + type: "TSExpressionWithTypeArguments", + expression, + typeParameters + }); +} + +function tsInterfaceDeclaration(id, typeParameters = null, _extends = null, body) { + return (0, _validateNode.default)({ + type: "TSInterfaceDeclaration", + id, + typeParameters, + extends: _extends, + body + }); +} + +function tsInterfaceBody(body) { + return (0, _validateNode.default)({ + type: "TSInterfaceBody", + body + }); +} + +function tsTypeAliasDeclaration(id, typeParameters = null, typeAnnotation) { + return (0, _validateNode.default)({ + type: "TSTypeAliasDeclaration", + id, + typeParameters, + typeAnnotation + }); +} + +function tsInstantiationExpression(expression, typeParameters = null) { + return (0, _validateNode.default)({ + type: "TSInstantiationExpression", + expression, + typeParameters + }); +} + +function tsAsExpression(expression, typeAnnotation) { + return (0, _validateNode.default)({ + type: "TSAsExpression", + expression, + typeAnnotation + }); +} + +function tsTypeAssertion(typeAnnotation, expression) { + return (0, _validateNode.default)({ + type: "TSTypeAssertion", + typeAnnotation, + expression + }); +} + +function tsEnumDeclaration(id, members) { + return (0, _validateNode.default)({ + type: "TSEnumDeclaration", + id, + members + }); +} + +function tsEnumMember(id, initializer = null) { + return (0, _validateNode.default)({ + type: "TSEnumMember", + id, + initializer + }); +} + +function tsModuleDeclaration(id, body) { + return (0, _validateNode.default)({ + type: "TSModuleDeclaration", + id, + body + }); +} + +function tsModuleBlock(body) { + return (0, _validateNode.default)({ + type: "TSModuleBlock", + body + }); +} + +function tsImportType(argument, qualifier = null, typeParameters = null) { + return (0, _validateNode.default)({ + type: "TSImportType", + argument, + qualifier, + typeParameters + }); +} + +function tsImportEqualsDeclaration(id, moduleReference) { + return (0, _validateNode.default)({ + type: "TSImportEqualsDeclaration", + id, + moduleReference, + isExport: null + }); +} + +function tsExternalModuleReference(expression) { + return (0, _validateNode.default)({ + type: "TSExternalModuleReference", + expression + }); +} + +function tsNonNullExpression(expression) { + return (0, _validateNode.default)({ + type: "TSNonNullExpression", + expression + }); +} + +function tsExportAssignment(expression) { + return (0, _validateNode.default)({ + type: "TSExportAssignment", + expression + }); +} + +function tsNamespaceExportDeclaration(id) { + return (0, _validateNode.default)({ + type: "TSNamespaceExportDeclaration", + id + }); +} + +function tsTypeAnnotation(typeAnnotation) { + return (0, _validateNode.default)({ + type: "TSTypeAnnotation", + typeAnnotation + }); +} + +function tsTypeParameterInstantiation(params) { + return (0, _validateNode.default)({ + type: "TSTypeParameterInstantiation", + params + }); +} + +function tsTypeParameterDeclaration(params) { + return (0, _validateNode.default)({ + type: "TSTypeParameterDeclaration", + params + }); +} + +function tsTypeParameter(constraint = null, _default = null, name) { + return (0, _validateNode.default)({ + type: "TSTypeParameter", + constraint, + default: _default, + name + }); +} + +function NumberLiteral(value) { + console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); + return numericLiteral(value); +} + +function RegexLiteral(pattern, flags = "") { + console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); + return regExpLiteral(pattern, flags); +} + +function RestProperty(argument) { + console.trace("The node type RestProperty has been renamed to RestElement"); + return restElement(argument); +} + +function SpreadProperty(argument) { + console.trace("The node type SpreadProperty has been renamed to SpreadElement"); + return spreadElement(argument); +} \ No newline at end of file diff --git a/node_modules/@isaacs/import-jsx/node_modules/@babel/types/lib/builders/generated/uppercase.js b/node_modules/@isaacs/import-jsx/node_modules/@babel/types/lib/builders/generated/uppercase.js new file mode 100644 index 000000000..0c49f05c4 --- /dev/null +++ b/node_modules/@isaacs/import-jsx/node_modules/@babel/types/lib/builders/generated/uppercase.js @@ -0,0 +1,1519 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +Object.defineProperty(exports, "AnyTypeAnnotation", { + enumerable: true, + get: function () { + return _index.anyTypeAnnotation; + } +}); +Object.defineProperty(exports, "ArgumentPlaceholder", { + enumerable: true, + get: function () { + return _index.argumentPlaceholder; + } +}); +Object.defineProperty(exports, "ArrayExpression", { + enumerable: true, + get: function () { + return _index.arrayExpression; + } +}); +Object.defineProperty(exports, "ArrayPattern", { + enumerable: true, + get: function () { + return _index.arrayPattern; + } +}); +Object.defineProperty(exports, "ArrayTypeAnnotation", { + enumerable: true, + get: function () { + return _index.arrayTypeAnnotation; + } +}); +Object.defineProperty(exports, "ArrowFunctionExpression", { + enumerable: true, + get: function () { + return _index.arrowFunctionExpression; + } +}); +Object.defineProperty(exports, "AssignmentExpression", { + enumerable: true, + get: function () { + return _index.assignmentExpression; + } +}); +Object.defineProperty(exports, "AssignmentPattern", { + enumerable: true, + get: function () { + return _index.assignmentPattern; + } +}); +Object.defineProperty(exports, "AwaitExpression", { + enumerable: true, + get: function () { + return _index.awaitExpression; + } +}); +Object.defineProperty(exports, "BigIntLiteral", { + enumerable: true, + get: function () { + return _index.bigIntLiteral; + } +}); +Object.defineProperty(exports, "BinaryExpression", { + enumerable: true, + get: function () { + return _index.binaryExpression; + } +}); +Object.defineProperty(exports, "BindExpression", { + enumerable: true, + get: function () { + return _index.bindExpression; + } +}); +Object.defineProperty(exports, "BlockStatement", { + enumerable: true, + get: function () { + return _index.blockStatement; + } +}); +Object.defineProperty(exports, "BooleanLiteral", { + enumerable: true, + get: function () { + return _index.booleanLiteral; + } +}); +Object.defineProperty(exports, "BooleanLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.booleanLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "BooleanTypeAnnotation", { + enumerable: true, + get: function () { + return _index.booleanTypeAnnotation; + } +}); +Object.defineProperty(exports, "BreakStatement", { + enumerable: true, + get: function () { + return _index.breakStatement; + } +}); +Object.defineProperty(exports, "CallExpression", { + enumerable: true, + get: function () { + return _index.callExpression; + } +}); +Object.defineProperty(exports, "CatchClause", { + enumerable: true, + get: function () { + return _index.catchClause; + } +}); +Object.defineProperty(exports, "ClassAccessorProperty", { + enumerable: true, + get: function () { + return _index.classAccessorProperty; + } +}); +Object.defineProperty(exports, "ClassBody", { + enumerable: true, + get: function () { + return _index.classBody; + } +}); +Object.defineProperty(exports, "ClassDeclaration", { + enumerable: true, + get: function () { + return _index.classDeclaration; + } +}); +Object.defineProperty(exports, "ClassExpression", { + enumerable: true, + get: function () { + return _index.classExpression; + } +}); +Object.defineProperty(exports, "ClassImplements", { + enumerable: true, + get: function () { + return _index.classImplements; + } +}); +Object.defineProperty(exports, "ClassMethod", { + enumerable: true, + get: function () { + return _index.classMethod; + } +}); +Object.defineProperty(exports, "ClassPrivateMethod", { + enumerable: true, + get: function () { + return _index.classPrivateMethod; + } +}); +Object.defineProperty(exports, "ClassPrivateProperty", { + enumerable: true, + get: function () { + return _index.classPrivateProperty; + } +}); +Object.defineProperty(exports, "ClassProperty", { + enumerable: true, + get: function () { + return _index.classProperty; + } +}); +Object.defineProperty(exports, "ConditionalExpression", { + enumerable: true, + get: function () { + return _index.conditionalExpression; + } +}); +Object.defineProperty(exports, "ContinueStatement", { + enumerable: true, + get: function () { + return _index.continueStatement; + } +}); +Object.defineProperty(exports, "DebuggerStatement", { + enumerable: true, + get: function () { + return _index.debuggerStatement; + } +}); +Object.defineProperty(exports, "DecimalLiteral", { + enumerable: true, + get: function () { + return _index.decimalLiteral; + } +}); +Object.defineProperty(exports, "DeclareClass", { + enumerable: true, + get: function () { + return _index.declareClass; + } +}); +Object.defineProperty(exports, "DeclareExportAllDeclaration", { + enumerable: true, + get: function () { + return _index.declareExportAllDeclaration; + } +}); +Object.defineProperty(exports, "DeclareExportDeclaration", { + enumerable: true, + get: function () { + return _index.declareExportDeclaration; + } +}); +Object.defineProperty(exports, "DeclareFunction", { + enumerable: true, + get: function () { + return _index.declareFunction; + } +}); +Object.defineProperty(exports, "DeclareInterface", { + enumerable: true, + get: function () { + return _index.declareInterface; + } +}); +Object.defineProperty(exports, "DeclareModule", { + enumerable: true, + get: function () { + return _index.declareModule; + } +}); +Object.defineProperty(exports, "DeclareModuleExports", { + enumerable: true, + get: function () { + return _index.declareModuleExports; + } +}); +Object.defineProperty(exports, "DeclareOpaqueType", { + enumerable: true, + get: function () { + return _index.declareOpaqueType; + } +}); +Object.defineProperty(exports, "DeclareTypeAlias", { + enumerable: true, + get: function () { + return _index.declareTypeAlias; + } +}); +Object.defineProperty(exports, "DeclareVariable", { + enumerable: true, + get: function () { + return _index.declareVariable; + } +}); +Object.defineProperty(exports, "DeclaredPredicate", { + enumerable: true, + get: function () { + return _index.declaredPredicate; + } +}); +Object.defineProperty(exports, "Decorator", { + enumerable: true, + get: function () { + return _index.decorator; + } +}); +Object.defineProperty(exports, "Directive", { + enumerable: true, + get: function () { + return _index.directive; + } +}); +Object.defineProperty(exports, "DirectiveLiteral", { + enumerable: true, + get: function () { + return _index.directiveLiteral; + } +}); +Object.defineProperty(exports, "DoExpression", { + enumerable: true, + get: function () { + return _index.doExpression; + } +}); +Object.defineProperty(exports, "DoWhileStatement", { + enumerable: true, + get: function () { + return _index.doWhileStatement; + } +}); +Object.defineProperty(exports, "EmptyStatement", { + enumerable: true, + get: function () { + return _index.emptyStatement; + } +}); +Object.defineProperty(exports, "EmptyTypeAnnotation", { + enumerable: true, + get: function () { + return _index.emptyTypeAnnotation; + } +}); +Object.defineProperty(exports, "EnumBooleanBody", { + enumerable: true, + get: function () { + return _index.enumBooleanBody; + } +}); +Object.defineProperty(exports, "EnumBooleanMember", { + enumerable: true, + get: function () { + return _index.enumBooleanMember; + } +}); +Object.defineProperty(exports, "EnumDeclaration", { + enumerable: true, + get: function () { + return _index.enumDeclaration; + } +}); +Object.defineProperty(exports, "EnumDefaultedMember", { + enumerable: true, + get: function () { + return _index.enumDefaultedMember; + } +}); +Object.defineProperty(exports, "EnumNumberBody", { + enumerable: true, + get: function () { + return _index.enumNumberBody; + } +}); +Object.defineProperty(exports, "EnumNumberMember", { + enumerable: true, + get: function () { + return _index.enumNumberMember; + } +}); +Object.defineProperty(exports, "EnumStringBody", { + enumerable: true, + get: function () { + return _index.enumStringBody; + } +}); +Object.defineProperty(exports, "EnumStringMember", { + enumerable: true, + get: function () { + return _index.enumStringMember; + } +}); +Object.defineProperty(exports, "EnumSymbolBody", { + enumerable: true, + get: function () { + return _index.enumSymbolBody; + } +}); +Object.defineProperty(exports, "ExistsTypeAnnotation", { + enumerable: true, + get: function () { + return _index.existsTypeAnnotation; + } +}); +Object.defineProperty(exports, "ExportAllDeclaration", { + enumerable: true, + get: function () { + return _index.exportAllDeclaration; + } +}); +Object.defineProperty(exports, "ExportDefaultDeclaration", { + enumerable: true, + get: function () { + return _index.exportDefaultDeclaration; + } +}); +Object.defineProperty(exports, "ExportDefaultSpecifier", { + enumerable: true, + get: function () { + return _index.exportDefaultSpecifier; + } +}); +Object.defineProperty(exports, "ExportNamedDeclaration", { + enumerable: true, + get: function () { + return _index.exportNamedDeclaration; + } +}); +Object.defineProperty(exports, "ExportNamespaceSpecifier", { + enumerable: true, + get: function () { + return _index.exportNamespaceSpecifier; + } +}); +Object.defineProperty(exports, "ExportSpecifier", { + enumerable: true, + get: function () { + return _index.exportSpecifier; + } +}); +Object.defineProperty(exports, "ExpressionStatement", { + enumerable: true, + get: function () { + return _index.expressionStatement; + } +}); +Object.defineProperty(exports, "File", { + enumerable: true, + get: function () { + return _index.file; + } +}); +Object.defineProperty(exports, "ForInStatement", { + enumerable: true, + get: function () { + return _index.forInStatement; + } +}); +Object.defineProperty(exports, "ForOfStatement", { + enumerable: true, + get: function () { + return _index.forOfStatement; + } +}); +Object.defineProperty(exports, "ForStatement", { + enumerable: true, + get: function () { + return _index.forStatement; + } +}); +Object.defineProperty(exports, "FunctionDeclaration", { + enumerable: true, + get: function () { + return _index.functionDeclaration; + } +}); +Object.defineProperty(exports, "FunctionExpression", { + enumerable: true, + get: function () { + return _index.functionExpression; + } +}); +Object.defineProperty(exports, "FunctionTypeAnnotation", { + enumerable: true, + get: function () { + return _index.functionTypeAnnotation; + } +}); +Object.defineProperty(exports, "FunctionTypeParam", { + enumerable: true, + get: function () { + return _index.functionTypeParam; + } +}); +Object.defineProperty(exports, "GenericTypeAnnotation", { + enumerable: true, + get: function () { + return _index.genericTypeAnnotation; + } +}); +Object.defineProperty(exports, "Identifier", { + enumerable: true, + get: function () { + return _index.identifier; + } +}); +Object.defineProperty(exports, "IfStatement", { + enumerable: true, + get: function () { + return _index.ifStatement; + } +}); +Object.defineProperty(exports, "Import", { + enumerable: true, + get: function () { + return _index.import; + } +}); +Object.defineProperty(exports, "ImportAttribute", { + enumerable: true, + get: function () { + return _index.importAttribute; + } +}); +Object.defineProperty(exports, "ImportDeclaration", { + enumerable: true, + get: function () { + return _index.importDeclaration; + } +}); +Object.defineProperty(exports, "ImportDefaultSpecifier", { + enumerable: true, + get: function () { + return _index.importDefaultSpecifier; + } +}); +Object.defineProperty(exports, "ImportNamespaceSpecifier", { + enumerable: true, + get: function () { + return _index.importNamespaceSpecifier; + } +}); +Object.defineProperty(exports, "ImportSpecifier", { + enumerable: true, + get: function () { + return _index.importSpecifier; + } +}); +Object.defineProperty(exports, "IndexedAccessType", { + enumerable: true, + get: function () { + return _index.indexedAccessType; + } +}); +Object.defineProperty(exports, "InferredPredicate", { + enumerable: true, + get: function () { + return _index.inferredPredicate; + } +}); +Object.defineProperty(exports, "InterfaceDeclaration", { + enumerable: true, + get: function () { + return _index.interfaceDeclaration; + } +}); +Object.defineProperty(exports, "InterfaceExtends", { + enumerable: true, + get: function () { + return _index.interfaceExtends; + } +}); +Object.defineProperty(exports, "InterfaceTypeAnnotation", { + enumerable: true, + get: function () { + return _index.interfaceTypeAnnotation; + } +}); +Object.defineProperty(exports, "InterpreterDirective", { + enumerable: true, + get: function () { + return _index.interpreterDirective; + } +}); +Object.defineProperty(exports, "IntersectionTypeAnnotation", { + enumerable: true, + get: function () { + return _index.intersectionTypeAnnotation; + } +}); +Object.defineProperty(exports, "JSXAttribute", { + enumerable: true, + get: function () { + return _index.jsxAttribute; + } +}); +Object.defineProperty(exports, "JSXClosingElement", { + enumerable: true, + get: function () { + return _index.jsxClosingElement; + } +}); +Object.defineProperty(exports, "JSXClosingFragment", { + enumerable: true, + get: function () { + return _index.jsxClosingFragment; + } +}); +Object.defineProperty(exports, "JSXElement", { + enumerable: true, + get: function () { + return _index.jsxElement; + } +}); +Object.defineProperty(exports, "JSXEmptyExpression", { + enumerable: true, + get: function () { + return _index.jsxEmptyExpression; + } +}); +Object.defineProperty(exports, "JSXExpressionContainer", { + enumerable: true, + get: function () { + return _index.jsxExpressionContainer; + } +}); +Object.defineProperty(exports, "JSXFragment", { + enumerable: true, + get: function () { + return _index.jsxFragment; + } +}); +Object.defineProperty(exports, "JSXIdentifier", { + enumerable: true, + get: function () { + return _index.jsxIdentifier; + } +}); +Object.defineProperty(exports, "JSXMemberExpression", { + enumerable: true, + get: function () { + return _index.jsxMemberExpression; + } +}); +Object.defineProperty(exports, "JSXNamespacedName", { + enumerable: true, + get: function () { + return _index.jsxNamespacedName; + } +}); +Object.defineProperty(exports, "JSXOpeningElement", { + enumerable: true, + get: function () { + return _index.jsxOpeningElement; + } +}); +Object.defineProperty(exports, "JSXOpeningFragment", { + enumerable: true, + get: function () { + return _index.jsxOpeningFragment; + } +}); +Object.defineProperty(exports, "JSXSpreadAttribute", { + enumerable: true, + get: function () { + return _index.jsxSpreadAttribute; + } +}); +Object.defineProperty(exports, "JSXSpreadChild", { + enumerable: true, + get: function () { + return _index.jsxSpreadChild; + } +}); +Object.defineProperty(exports, "JSXText", { + enumerable: true, + get: function () { + return _index.jsxText; + } +}); +Object.defineProperty(exports, "LabeledStatement", { + enumerable: true, + get: function () { + return _index.labeledStatement; + } +}); +Object.defineProperty(exports, "LogicalExpression", { + enumerable: true, + get: function () { + return _index.logicalExpression; + } +}); +Object.defineProperty(exports, "MemberExpression", { + enumerable: true, + get: function () { + return _index.memberExpression; + } +}); +Object.defineProperty(exports, "MetaProperty", { + enumerable: true, + get: function () { + return _index.metaProperty; + } +}); +Object.defineProperty(exports, "MixedTypeAnnotation", { + enumerable: true, + get: function () { + return _index.mixedTypeAnnotation; + } +}); +Object.defineProperty(exports, "ModuleExpression", { + enumerable: true, + get: function () { + return _index.moduleExpression; + } +}); +Object.defineProperty(exports, "NewExpression", { + enumerable: true, + get: function () { + return _index.newExpression; + } +}); +Object.defineProperty(exports, "Noop", { + enumerable: true, + get: function () { + return _index.noop; + } +}); +Object.defineProperty(exports, "NullLiteral", { + enumerable: true, + get: function () { + return _index.nullLiteral; + } +}); +Object.defineProperty(exports, "NullLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.nullLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "NullableTypeAnnotation", { + enumerable: true, + get: function () { + return _index.nullableTypeAnnotation; + } +}); +Object.defineProperty(exports, "NumberLiteral", { + enumerable: true, + get: function () { + return _index.numberLiteral; + } +}); +Object.defineProperty(exports, "NumberLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.numberLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "NumberTypeAnnotation", { + enumerable: true, + get: function () { + return _index.numberTypeAnnotation; + } +}); +Object.defineProperty(exports, "NumericLiteral", { + enumerable: true, + get: function () { + return _index.numericLiteral; + } +}); +Object.defineProperty(exports, "ObjectExpression", { + enumerable: true, + get: function () { + return _index.objectExpression; + } +}); +Object.defineProperty(exports, "ObjectMethod", { + enumerable: true, + get: function () { + return _index.objectMethod; + } +}); +Object.defineProperty(exports, "ObjectPattern", { + enumerable: true, + get: function () { + return _index.objectPattern; + } +}); +Object.defineProperty(exports, "ObjectProperty", { + enumerable: true, + get: function () { + return _index.objectProperty; + } +}); +Object.defineProperty(exports, "ObjectTypeAnnotation", { + enumerable: true, + get: function () { + return _index.objectTypeAnnotation; + } +}); +Object.defineProperty(exports, "ObjectTypeCallProperty", { + enumerable: true, + get: function () { + return _index.objectTypeCallProperty; + } +}); +Object.defineProperty(exports, "ObjectTypeIndexer", { + enumerable: true, + get: function () { + return _index.objectTypeIndexer; + } +}); +Object.defineProperty(exports, "ObjectTypeInternalSlot", { + enumerable: true, + get: function () { + return _index.objectTypeInternalSlot; + } +}); +Object.defineProperty(exports, "ObjectTypeProperty", { + enumerable: true, + get: function () { + return _index.objectTypeProperty; + } +}); +Object.defineProperty(exports, "ObjectTypeSpreadProperty", { + enumerable: true, + get: function () { + return _index.objectTypeSpreadProperty; + } +}); +Object.defineProperty(exports, "OpaqueType", { + enumerable: true, + get: function () { + return _index.opaqueType; + } +}); +Object.defineProperty(exports, "OptionalCallExpression", { + enumerable: true, + get: function () { + return _index.optionalCallExpression; + } +}); +Object.defineProperty(exports, "OptionalIndexedAccessType", { + enumerable: true, + get: function () { + return _index.optionalIndexedAccessType; + } +}); +Object.defineProperty(exports, "OptionalMemberExpression", { + enumerable: true, + get: function () { + return _index.optionalMemberExpression; + } +}); +Object.defineProperty(exports, "ParenthesizedExpression", { + enumerable: true, + get: function () { + return _index.parenthesizedExpression; + } +}); +Object.defineProperty(exports, "PipelineBareFunction", { + enumerable: true, + get: function () { + return _index.pipelineBareFunction; + } +}); +Object.defineProperty(exports, "PipelinePrimaryTopicReference", { + enumerable: true, + get: function () { + return _index.pipelinePrimaryTopicReference; + } +}); +Object.defineProperty(exports, "PipelineTopicExpression", { + enumerable: true, + get: function () { + return _index.pipelineTopicExpression; + } +}); +Object.defineProperty(exports, "Placeholder", { + enumerable: true, + get: function () { + return _index.placeholder; + } +}); +Object.defineProperty(exports, "PrivateName", { + enumerable: true, + get: function () { + return _index.privateName; + } +}); +Object.defineProperty(exports, "Program", { + enumerable: true, + get: function () { + return _index.program; + } +}); +Object.defineProperty(exports, "QualifiedTypeIdentifier", { + enumerable: true, + get: function () { + return _index.qualifiedTypeIdentifier; + } +}); +Object.defineProperty(exports, "RecordExpression", { + enumerable: true, + get: function () { + return _index.recordExpression; + } +}); +Object.defineProperty(exports, "RegExpLiteral", { + enumerable: true, + get: function () { + return _index.regExpLiteral; + } +}); +Object.defineProperty(exports, "RegexLiteral", { + enumerable: true, + get: function () { + return _index.regexLiteral; + } +}); +Object.defineProperty(exports, "RestElement", { + enumerable: true, + get: function () { + return _index.restElement; + } +}); +Object.defineProperty(exports, "RestProperty", { + enumerable: true, + get: function () { + return _index.restProperty; + } +}); +Object.defineProperty(exports, "ReturnStatement", { + enumerable: true, + get: function () { + return _index.returnStatement; + } +}); +Object.defineProperty(exports, "SequenceExpression", { + enumerable: true, + get: function () { + return _index.sequenceExpression; + } +}); +Object.defineProperty(exports, "SpreadElement", { + enumerable: true, + get: function () { + return _index.spreadElement; + } +}); +Object.defineProperty(exports, "SpreadProperty", { + enumerable: true, + get: function () { + return _index.spreadProperty; + } +}); +Object.defineProperty(exports, "StaticBlock", { + enumerable: true, + get: function () { + return _index.staticBlock; + } +}); +Object.defineProperty(exports, "StringLiteral", { + enumerable: true, + get: function () { + return _index.stringLiteral; + } +}); +Object.defineProperty(exports, "StringLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.stringLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "StringTypeAnnotation", { + enumerable: true, + get: function () { + return _index.stringTypeAnnotation; + } +}); +Object.defineProperty(exports, "Super", { + enumerable: true, + get: function () { + return _index.super; + } +}); +Object.defineProperty(exports, "SwitchCase", { + enumerable: true, + get: function () { + return _index.switchCase; + } +}); +Object.defineProperty(exports, "SwitchStatement", { + enumerable: true, + get: function () { + return _index.switchStatement; + } +}); +Object.defineProperty(exports, "SymbolTypeAnnotation", { + enumerable: true, + get: function () { + return _index.symbolTypeAnnotation; + } +}); +Object.defineProperty(exports, "TSAnyKeyword", { + enumerable: true, + get: function () { + return _index.tsAnyKeyword; + } +}); +Object.defineProperty(exports, "TSArrayType", { + enumerable: true, + get: function () { + return _index.tsArrayType; + } +}); +Object.defineProperty(exports, "TSAsExpression", { + enumerable: true, + get: function () { + return _index.tsAsExpression; + } +}); +Object.defineProperty(exports, "TSBigIntKeyword", { + enumerable: true, + get: function () { + return _index.tsBigIntKeyword; + } +}); +Object.defineProperty(exports, "TSBooleanKeyword", { + enumerable: true, + get: function () { + return _index.tsBooleanKeyword; + } +}); +Object.defineProperty(exports, "TSCallSignatureDeclaration", { + enumerable: true, + get: function () { + return _index.tsCallSignatureDeclaration; + } +}); +Object.defineProperty(exports, "TSConditionalType", { + enumerable: true, + get: function () { + return _index.tsConditionalType; + } +}); +Object.defineProperty(exports, "TSConstructSignatureDeclaration", { + enumerable: true, + get: function () { + return _index.tsConstructSignatureDeclaration; + } +}); +Object.defineProperty(exports, "TSConstructorType", { + enumerable: true, + get: function () { + return _index.tsConstructorType; + } +}); +Object.defineProperty(exports, "TSDeclareFunction", { + enumerable: true, + get: function () { + return _index.tsDeclareFunction; + } +}); +Object.defineProperty(exports, "TSDeclareMethod", { + enumerable: true, + get: function () { + return _index.tsDeclareMethod; + } +}); +Object.defineProperty(exports, "TSEnumDeclaration", { + enumerable: true, + get: function () { + return _index.tsEnumDeclaration; + } +}); +Object.defineProperty(exports, "TSEnumMember", { + enumerable: true, + get: function () { + return _index.tsEnumMember; + } +}); +Object.defineProperty(exports, "TSExportAssignment", { + enumerable: true, + get: function () { + return _index.tsExportAssignment; + } +}); +Object.defineProperty(exports, "TSExpressionWithTypeArguments", { + enumerable: true, + get: function () { + return _index.tsExpressionWithTypeArguments; + } +}); +Object.defineProperty(exports, "TSExternalModuleReference", { + enumerable: true, + get: function () { + return _index.tsExternalModuleReference; + } +}); +Object.defineProperty(exports, "TSFunctionType", { + enumerable: true, + get: function () { + return _index.tsFunctionType; + } +}); +Object.defineProperty(exports, "TSImportEqualsDeclaration", { + enumerable: true, + get: function () { + return _index.tsImportEqualsDeclaration; + } +}); +Object.defineProperty(exports, "TSImportType", { + enumerable: true, + get: function () { + return _index.tsImportType; + } +}); +Object.defineProperty(exports, "TSIndexSignature", { + enumerable: true, + get: function () { + return _index.tsIndexSignature; + } +}); +Object.defineProperty(exports, "TSIndexedAccessType", { + enumerable: true, + get: function () { + return _index.tsIndexedAccessType; + } +}); +Object.defineProperty(exports, "TSInferType", { + enumerable: true, + get: function () { + return _index.tsInferType; + } +}); +Object.defineProperty(exports, "TSInstantiationExpression", { + enumerable: true, + get: function () { + return _index.tsInstantiationExpression; + } +}); +Object.defineProperty(exports, "TSInterfaceBody", { + enumerable: true, + get: function () { + return _index.tsInterfaceBody; + } +}); +Object.defineProperty(exports, "TSInterfaceDeclaration", { + enumerable: true, + get: function () { + return _index.tsInterfaceDeclaration; + } +}); +Object.defineProperty(exports, "TSIntersectionType", { + enumerable: true, + get: function () { + return _index.tsIntersectionType; + } +}); +Object.defineProperty(exports, "TSIntrinsicKeyword", { + enumerable: true, + get: function () { + return _index.tsIntrinsicKeyword; + } +}); +Object.defineProperty(exports, "TSLiteralType", { + enumerable: true, + get: function () { + return _index.tsLiteralType; + } +}); +Object.defineProperty(exports, "TSMappedType", { + enumerable: true, + get: function () { + return _index.tsMappedType; + } +}); +Object.defineProperty(exports, "TSMethodSignature", { + enumerable: true, + get: function () { + return _index.tsMethodSignature; + } +}); +Object.defineProperty(exports, "TSModuleBlock", { + enumerable: true, + get: function () { + return _index.tsModuleBlock; + } +}); +Object.defineProperty(exports, "TSModuleDeclaration", { + enumerable: true, + get: function () { + return _index.tsModuleDeclaration; + } +}); +Object.defineProperty(exports, "TSNamedTupleMember", { + enumerable: true, + get: function () { + return _index.tsNamedTupleMember; + } +}); +Object.defineProperty(exports, "TSNamespaceExportDeclaration", { + enumerable: true, + get: function () { + return _index.tsNamespaceExportDeclaration; + } +}); +Object.defineProperty(exports, "TSNeverKeyword", { + enumerable: true, + get: function () { + return _index.tsNeverKeyword; + } +}); +Object.defineProperty(exports, "TSNonNullExpression", { + enumerable: true, + get: function () { + return _index.tsNonNullExpression; + } +}); +Object.defineProperty(exports, "TSNullKeyword", { + enumerable: true, + get: function () { + return _index.tsNullKeyword; + } +}); +Object.defineProperty(exports, "TSNumberKeyword", { + enumerable: true, + get: function () { + return _index.tsNumberKeyword; + } +}); +Object.defineProperty(exports, "TSObjectKeyword", { + enumerable: true, + get: function () { + return _index.tsObjectKeyword; + } +}); +Object.defineProperty(exports, "TSOptionalType", { + enumerable: true, + get: function () { + return _index.tsOptionalType; + } +}); +Object.defineProperty(exports, "TSParameterProperty", { + enumerable: true, + get: function () { + return _index.tsParameterProperty; + } +}); +Object.defineProperty(exports, "TSParenthesizedType", { + enumerable: true, + get: function () { + return _index.tsParenthesizedType; + } +}); +Object.defineProperty(exports, "TSPropertySignature", { + enumerable: true, + get: function () { + return _index.tsPropertySignature; + } +}); +Object.defineProperty(exports, "TSQualifiedName", { + enumerable: true, + get: function () { + return _index.tsQualifiedName; + } +}); +Object.defineProperty(exports, "TSRestType", { + enumerable: true, + get: function () { + return _index.tsRestType; + } +}); +Object.defineProperty(exports, "TSStringKeyword", { + enumerable: true, + get: function () { + return _index.tsStringKeyword; + } +}); +Object.defineProperty(exports, "TSSymbolKeyword", { + enumerable: true, + get: function () { + return _index.tsSymbolKeyword; + } +}); +Object.defineProperty(exports, "TSThisType", { + enumerable: true, + get: function () { + return _index.tsThisType; + } +}); +Object.defineProperty(exports, "TSTupleType", { + enumerable: true, + get: function () { + return _index.tsTupleType; + } +}); +Object.defineProperty(exports, "TSTypeAliasDeclaration", { + enumerable: true, + get: function () { + return _index.tsTypeAliasDeclaration; + } +}); +Object.defineProperty(exports, "TSTypeAnnotation", { + enumerable: true, + get: function () { + return _index.tsTypeAnnotation; + } +}); +Object.defineProperty(exports, "TSTypeAssertion", { + enumerable: true, + get: function () { + return _index.tsTypeAssertion; + } +}); +Object.defineProperty(exports, "TSTypeLiteral", { + enumerable: true, + get: function () { + return _index.tsTypeLiteral; + } +}); +Object.defineProperty(exports, "TSTypeOperator", { + enumerable: true, + get: function () { + return _index.tsTypeOperator; + } +}); +Object.defineProperty(exports, "TSTypeParameter", { + enumerable: true, + get: function () { + return _index.tsTypeParameter; + } +}); +Object.defineProperty(exports, "TSTypeParameterDeclaration", { + enumerable: true, + get: function () { + return _index.tsTypeParameterDeclaration; + } +}); +Object.defineProperty(exports, "TSTypeParameterInstantiation", { + enumerable: true, + get: function () { + return _index.tsTypeParameterInstantiation; + } +}); +Object.defineProperty(exports, "TSTypePredicate", { + enumerable: true, + get: function () { + return _index.tsTypePredicate; + } +}); +Object.defineProperty(exports, "TSTypeQuery", { + enumerable: true, + get: function () { + return _index.tsTypeQuery; + } +}); +Object.defineProperty(exports, "TSTypeReference", { + enumerable: true, + get: function () { + return _index.tsTypeReference; + } +}); +Object.defineProperty(exports, "TSUndefinedKeyword", { + enumerable: true, + get: function () { + return _index.tsUndefinedKeyword; + } +}); +Object.defineProperty(exports, "TSUnionType", { + enumerable: true, + get: function () { + return _index.tsUnionType; + } +}); +Object.defineProperty(exports, "TSUnknownKeyword", { + enumerable: true, + get: function () { + return _index.tsUnknownKeyword; + } +}); +Object.defineProperty(exports, "TSVoidKeyword", { + enumerable: true, + get: function () { + return _index.tsVoidKeyword; + } +}); +Object.defineProperty(exports, "TaggedTemplateExpression", { + enumerable: true, + get: function () { + return _index.taggedTemplateExpression; + } +}); +Object.defineProperty(exports, "TemplateElement", { + enumerable: true, + get: function () { + return _index.templateElement; + } +}); +Object.defineProperty(exports, "TemplateLiteral", { + enumerable: true, + get: function () { + return _index.templateLiteral; + } +}); +Object.defineProperty(exports, "ThisExpression", { + enumerable: true, + get: function () { + return _index.thisExpression; + } +}); +Object.defineProperty(exports, "ThisTypeAnnotation", { + enumerable: true, + get: function () { + return _index.thisTypeAnnotation; + } +}); +Object.defineProperty(exports, "ThrowStatement", { + enumerable: true, + get: function () { + return _index.throwStatement; + } +}); +Object.defineProperty(exports, "TopicReference", { + enumerable: true, + get: function () { + return _index.topicReference; + } +}); +Object.defineProperty(exports, "TryStatement", { + enumerable: true, + get: function () { + return _index.tryStatement; + } +}); +Object.defineProperty(exports, "TupleExpression", { + enumerable: true, + get: function () { + return _index.tupleExpression; + } +}); +Object.defineProperty(exports, "TupleTypeAnnotation", { + enumerable: true, + get: function () { + return _index.tupleTypeAnnotation; + } +}); +Object.defineProperty(exports, "TypeAlias", { + enumerable: true, + get: function () { + return _index.typeAlias; + } +}); +Object.defineProperty(exports, "TypeAnnotation", { + enumerable: true, + get: function () { + return _index.typeAnnotation; + } +}); +Object.defineProperty(exports, "TypeCastExpression", { + enumerable: true, + get: function () { + return _index.typeCastExpression; + } +}); +Object.defineProperty(exports, "TypeParameter", { + enumerable: true, + get: function () { + return _index.typeParameter; + } +}); +Object.defineProperty(exports, "TypeParameterDeclaration", { + enumerable: true, + get: function () { + return _index.typeParameterDeclaration; + } +}); +Object.defineProperty(exports, "TypeParameterInstantiation", { + enumerable: true, + get: function () { + return _index.typeParameterInstantiation; + } +}); +Object.defineProperty(exports, "TypeofTypeAnnotation", { + enumerable: true, + get: function () { + return _index.typeofTypeAnnotation; + } +}); +Object.defineProperty(exports, "UnaryExpression", { + enumerable: true, + get: function () { + return _index.unaryExpression; + } +}); +Object.defineProperty(exports, "UnionTypeAnnotation", { + enumerable: true, + get: function () { + return _index.unionTypeAnnotation; + } +}); +Object.defineProperty(exports, "UpdateExpression", { + enumerable: true, + get: function () { + return _index.updateExpression; + } +}); +Object.defineProperty(exports, "V8IntrinsicIdentifier", { + enumerable: true, + get: function () { + return _index.v8IntrinsicIdentifier; + } +}); +Object.defineProperty(exports, "VariableDeclaration", { + enumerable: true, + get: function () { + return _index.variableDeclaration; + } +}); +Object.defineProperty(exports, "VariableDeclarator", { + enumerable: true, + get: function () { + return _index.variableDeclarator; + } +}); +Object.defineProperty(exports, "Variance", { + enumerable: true, + get: function () { + return _index.variance; + } +}); +Object.defineProperty(exports, "VoidTypeAnnotation", { + enumerable: true, + get: function () { + return _index.voidTypeAnnotation; + } +}); +Object.defineProperty(exports, "WhileStatement", { + enumerable: true, + get: function () { + return _index.whileStatement; + } +}); +Object.defineProperty(exports, "WithStatement", { + enumerable: true, + get: function () { + return _index.withStatement; + } +}); +Object.defineProperty(exports, "YieldExpression", { + enumerable: true, + get: function () { + return _index.yieldExpression; + } +}); + +var _index = require("./index"); \ No newline at end of file diff --git a/node_modules/@isaacs/import-jsx/node_modules/@babel/types/lib/constants/generated/index.js b/node_modules/@isaacs/import-jsx/node_modules/@babel/types/lib/constants/generated/index.js new file mode 100644 index 000000000..1e109e6a4 --- /dev/null +++ b/node_modules/@isaacs/import-jsx/node_modules/@babel/types/lib/constants/generated/index.js @@ -0,0 +1,107 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.WHILE_TYPES = exports.USERWHITESPACABLE_TYPES = exports.UNARYLIKE_TYPES = exports.TYPESCRIPT_TYPES = exports.TSTYPE_TYPES = exports.TSTYPEELEMENT_TYPES = exports.TSENTITYNAME_TYPES = exports.TSBASETYPE_TYPES = exports.TERMINATORLESS_TYPES = exports.STATEMENT_TYPES = exports.STANDARDIZED_TYPES = exports.SCOPABLE_TYPES = exports.PUREISH_TYPES = exports.PROPERTY_TYPES = exports.PRIVATE_TYPES = exports.PATTERN_TYPES = exports.PATTERNLIKE_TYPES = exports.OBJECTMEMBER_TYPES = exports.MODULESPECIFIER_TYPES = exports.MODULEDECLARATION_TYPES = exports.MISCELLANEOUS_TYPES = exports.METHOD_TYPES = exports.LVAL_TYPES = exports.LOOP_TYPES = exports.LITERAL_TYPES = exports.JSX_TYPES = exports.IMMUTABLE_TYPES = exports.FUNCTION_TYPES = exports.FUNCTIONPARENT_TYPES = exports.FOR_TYPES = exports.FORXSTATEMENT_TYPES = exports.FLOW_TYPES = exports.FLOWTYPE_TYPES = exports.FLOWPREDICATE_TYPES = exports.FLOWDECLARATION_TYPES = exports.FLOWBASEANNOTATION_TYPES = exports.EXPRESSION_TYPES = exports.EXPRESSIONWRAPPER_TYPES = exports.EXPORTDECLARATION_TYPES = exports.ENUMMEMBER_TYPES = exports.ENUMBODY_TYPES = exports.DECLARATION_TYPES = exports.CONDITIONAL_TYPES = exports.COMPLETIONSTATEMENT_TYPES = exports.CLASS_TYPES = exports.BLOCK_TYPES = exports.BLOCKPARENT_TYPES = exports.BINARY_TYPES = exports.ACCESSOR_TYPES = void 0; + +var _definitions = require("../../definitions"); + +const STANDARDIZED_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Standardized"]; +exports.STANDARDIZED_TYPES = STANDARDIZED_TYPES; +const EXPRESSION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Expression"]; +exports.EXPRESSION_TYPES = EXPRESSION_TYPES; +const BINARY_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Binary"]; +exports.BINARY_TYPES = BINARY_TYPES; +const SCOPABLE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Scopable"]; +exports.SCOPABLE_TYPES = SCOPABLE_TYPES; +const BLOCKPARENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["BlockParent"]; +exports.BLOCKPARENT_TYPES = BLOCKPARENT_TYPES; +const BLOCK_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Block"]; +exports.BLOCK_TYPES = BLOCK_TYPES; +const STATEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Statement"]; +exports.STATEMENT_TYPES = STATEMENT_TYPES; +const TERMINATORLESS_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Terminatorless"]; +exports.TERMINATORLESS_TYPES = TERMINATORLESS_TYPES; +const COMPLETIONSTATEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["CompletionStatement"]; +exports.COMPLETIONSTATEMENT_TYPES = COMPLETIONSTATEMENT_TYPES; +const CONDITIONAL_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Conditional"]; +exports.CONDITIONAL_TYPES = CONDITIONAL_TYPES; +const LOOP_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Loop"]; +exports.LOOP_TYPES = LOOP_TYPES; +const WHILE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["While"]; +exports.WHILE_TYPES = WHILE_TYPES; +const EXPRESSIONWRAPPER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ExpressionWrapper"]; +exports.EXPRESSIONWRAPPER_TYPES = EXPRESSIONWRAPPER_TYPES; +const FOR_TYPES = _definitions.FLIPPED_ALIAS_KEYS["For"]; +exports.FOR_TYPES = FOR_TYPES; +const FORXSTATEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ForXStatement"]; +exports.FORXSTATEMENT_TYPES = FORXSTATEMENT_TYPES; +const FUNCTION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Function"]; +exports.FUNCTION_TYPES = FUNCTION_TYPES; +const FUNCTIONPARENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FunctionParent"]; +exports.FUNCTIONPARENT_TYPES = FUNCTIONPARENT_TYPES; +const PUREISH_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Pureish"]; +exports.PUREISH_TYPES = PUREISH_TYPES; +const DECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Declaration"]; +exports.DECLARATION_TYPES = DECLARATION_TYPES; +const PATTERNLIKE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["PatternLike"]; +exports.PATTERNLIKE_TYPES = PATTERNLIKE_TYPES; +const LVAL_TYPES = _definitions.FLIPPED_ALIAS_KEYS["LVal"]; +exports.LVAL_TYPES = LVAL_TYPES; +const TSENTITYNAME_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSEntityName"]; +exports.TSENTITYNAME_TYPES = TSENTITYNAME_TYPES; +const LITERAL_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Literal"]; +exports.LITERAL_TYPES = LITERAL_TYPES; +const IMMUTABLE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Immutable"]; +exports.IMMUTABLE_TYPES = IMMUTABLE_TYPES; +const USERWHITESPACABLE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["UserWhitespacable"]; +exports.USERWHITESPACABLE_TYPES = USERWHITESPACABLE_TYPES; +const METHOD_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Method"]; +exports.METHOD_TYPES = METHOD_TYPES; +const OBJECTMEMBER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ObjectMember"]; +exports.OBJECTMEMBER_TYPES = OBJECTMEMBER_TYPES; +const PROPERTY_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Property"]; +exports.PROPERTY_TYPES = PROPERTY_TYPES; +const UNARYLIKE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["UnaryLike"]; +exports.UNARYLIKE_TYPES = UNARYLIKE_TYPES; +const PATTERN_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Pattern"]; +exports.PATTERN_TYPES = PATTERN_TYPES; +const CLASS_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Class"]; +exports.CLASS_TYPES = CLASS_TYPES; +const MODULEDECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ModuleDeclaration"]; +exports.MODULEDECLARATION_TYPES = MODULEDECLARATION_TYPES; +const EXPORTDECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ExportDeclaration"]; +exports.EXPORTDECLARATION_TYPES = EXPORTDECLARATION_TYPES; +const MODULESPECIFIER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ModuleSpecifier"]; +exports.MODULESPECIFIER_TYPES = MODULESPECIFIER_TYPES; +const ACCESSOR_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Accessor"]; +exports.ACCESSOR_TYPES = ACCESSOR_TYPES; +const PRIVATE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Private"]; +exports.PRIVATE_TYPES = PRIVATE_TYPES; +const FLOW_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Flow"]; +exports.FLOW_TYPES = FLOW_TYPES; +const FLOWTYPE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowType"]; +exports.FLOWTYPE_TYPES = FLOWTYPE_TYPES; +const FLOWBASEANNOTATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowBaseAnnotation"]; +exports.FLOWBASEANNOTATION_TYPES = FLOWBASEANNOTATION_TYPES; +const FLOWDECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowDeclaration"]; +exports.FLOWDECLARATION_TYPES = FLOWDECLARATION_TYPES; +const FLOWPREDICATE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowPredicate"]; +exports.FLOWPREDICATE_TYPES = FLOWPREDICATE_TYPES; +const ENUMBODY_TYPES = _definitions.FLIPPED_ALIAS_KEYS["EnumBody"]; +exports.ENUMBODY_TYPES = ENUMBODY_TYPES; +const ENUMMEMBER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["EnumMember"]; +exports.ENUMMEMBER_TYPES = ENUMMEMBER_TYPES; +const JSX_TYPES = _definitions.FLIPPED_ALIAS_KEYS["JSX"]; +exports.JSX_TYPES = JSX_TYPES; +const MISCELLANEOUS_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Miscellaneous"]; +exports.MISCELLANEOUS_TYPES = MISCELLANEOUS_TYPES; +const TYPESCRIPT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TypeScript"]; +exports.TYPESCRIPT_TYPES = TYPESCRIPT_TYPES; +const TSTYPEELEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSTypeElement"]; +exports.TSTYPEELEMENT_TYPES = TSTYPEELEMENT_TYPES; +const TSTYPE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSType"]; +exports.TSTYPE_TYPES = TSTYPE_TYPES; +const TSBASETYPE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSBaseType"]; +exports.TSBASETYPE_TYPES = TSBASETYPE_TYPES; \ No newline at end of file diff --git a/node_modules/@isaacs/import-jsx/node_modules/@babel/types/lib/validators/generated/index.js b/node_modules/@isaacs/import-jsx/node_modules/@babel/types/lib/validators/generated/index.js new file mode 100644 index 000000000..f175aa495 --- /dev/null +++ b/node_modules/@isaacs/import-jsx/node_modules/@babel/types/lib/validators/generated/index.js @@ -0,0 +1,4827 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.isAccessor = isAccessor; +exports.isAnyTypeAnnotation = isAnyTypeAnnotation; +exports.isArgumentPlaceholder = isArgumentPlaceholder; +exports.isArrayExpression = isArrayExpression; +exports.isArrayPattern = isArrayPattern; +exports.isArrayTypeAnnotation = isArrayTypeAnnotation; +exports.isArrowFunctionExpression = isArrowFunctionExpression; +exports.isAssignmentExpression = isAssignmentExpression; +exports.isAssignmentPattern = isAssignmentPattern; +exports.isAwaitExpression = isAwaitExpression; +exports.isBigIntLiteral = isBigIntLiteral; +exports.isBinary = isBinary; +exports.isBinaryExpression = isBinaryExpression; +exports.isBindExpression = isBindExpression; +exports.isBlock = isBlock; +exports.isBlockParent = isBlockParent; +exports.isBlockStatement = isBlockStatement; +exports.isBooleanLiteral = isBooleanLiteral; +exports.isBooleanLiteralTypeAnnotation = isBooleanLiteralTypeAnnotation; +exports.isBooleanTypeAnnotation = isBooleanTypeAnnotation; +exports.isBreakStatement = isBreakStatement; +exports.isCallExpression = isCallExpression; +exports.isCatchClause = isCatchClause; +exports.isClass = isClass; +exports.isClassAccessorProperty = isClassAccessorProperty; +exports.isClassBody = isClassBody; +exports.isClassDeclaration = isClassDeclaration; +exports.isClassExpression = isClassExpression; +exports.isClassImplements = isClassImplements; +exports.isClassMethod = isClassMethod; +exports.isClassPrivateMethod = isClassPrivateMethod; +exports.isClassPrivateProperty = isClassPrivateProperty; +exports.isClassProperty = isClassProperty; +exports.isCompletionStatement = isCompletionStatement; +exports.isConditional = isConditional; +exports.isConditionalExpression = isConditionalExpression; +exports.isContinueStatement = isContinueStatement; +exports.isDebuggerStatement = isDebuggerStatement; +exports.isDecimalLiteral = isDecimalLiteral; +exports.isDeclaration = isDeclaration; +exports.isDeclareClass = isDeclareClass; +exports.isDeclareExportAllDeclaration = isDeclareExportAllDeclaration; +exports.isDeclareExportDeclaration = isDeclareExportDeclaration; +exports.isDeclareFunction = isDeclareFunction; +exports.isDeclareInterface = isDeclareInterface; +exports.isDeclareModule = isDeclareModule; +exports.isDeclareModuleExports = isDeclareModuleExports; +exports.isDeclareOpaqueType = isDeclareOpaqueType; +exports.isDeclareTypeAlias = isDeclareTypeAlias; +exports.isDeclareVariable = isDeclareVariable; +exports.isDeclaredPredicate = isDeclaredPredicate; +exports.isDecorator = isDecorator; +exports.isDirective = isDirective; +exports.isDirectiveLiteral = isDirectiveLiteral; +exports.isDoExpression = isDoExpression; +exports.isDoWhileStatement = isDoWhileStatement; +exports.isEmptyStatement = isEmptyStatement; +exports.isEmptyTypeAnnotation = isEmptyTypeAnnotation; +exports.isEnumBody = isEnumBody; +exports.isEnumBooleanBody = isEnumBooleanBody; +exports.isEnumBooleanMember = isEnumBooleanMember; +exports.isEnumDeclaration = isEnumDeclaration; +exports.isEnumDefaultedMember = isEnumDefaultedMember; +exports.isEnumMember = isEnumMember; +exports.isEnumNumberBody = isEnumNumberBody; +exports.isEnumNumberMember = isEnumNumberMember; +exports.isEnumStringBody = isEnumStringBody; +exports.isEnumStringMember = isEnumStringMember; +exports.isEnumSymbolBody = isEnumSymbolBody; +exports.isExistsTypeAnnotation = isExistsTypeAnnotation; +exports.isExportAllDeclaration = isExportAllDeclaration; +exports.isExportDeclaration = isExportDeclaration; +exports.isExportDefaultDeclaration = isExportDefaultDeclaration; +exports.isExportDefaultSpecifier = isExportDefaultSpecifier; +exports.isExportNamedDeclaration = isExportNamedDeclaration; +exports.isExportNamespaceSpecifier = isExportNamespaceSpecifier; +exports.isExportSpecifier = isExportSpecifier; +exports.isExpression = isExpression; +exports.isExpressionStatement = isExpressionStatement; +exports.isExpressionWrapper = isExpressionWrapper; +exports.isFile = isFile; +exports.isFlow = isFlow; +exports.isFlowBaseAnnotation = isFlowBaseAnnotation; +exports.isFlowDeclaration = isFlowDeclaration; +exports.isFlowPredicate = isFlowPredicate; +exports.isFlowType = isFlowType; +exports.isFor = isFor; +exports.isForInStatement = isForInStatement; +exports.isForOfStatement = isForOfStatement; +exports.isForStatement = isForStatement; +exports.isForXStatement = isForXStatement; +exports.isFunction = isFunction; +exports.isFunctionDeclaration = isFunctionDeclaration; +exports.isFunctionExpression = isFunctionExpression; +exports.isFunctionParent = isFunctionParent; +exports.isFunctionTypeAnnotation = isFunctionTypeAnnotation; +exports.isFunctionTypeParam = isFunctionTypeParam; +exports.isGenericTypeAnnotation = isGenericTypeAnnotation; +exports.isIdentifier = isIdentifier; +exports.isIfStatement = isIfStatement; +exports.isImmutable = isImmutable; +exports.isImport = isImport; +exports.isImportAttribute = isImportAttribute; +exports.isImportDeclaration = isImportDeclaration; +exports.isImportDefaultSpecifier = isImportDefaultSpecifier; +exports.isImportNamespaceSpecifier = isImportNamespaceSpecifier; +exports.isImportSpecifier = isImportSpecifier; +exports.isIndexedAccessType = isIndexedAccessType; +exports.isInferredPredicate = isInferredPredicate; +exports.isInterfaceDeclaration = isInterfaceDeclaration; +exports.isInterfaceExtends = isInterfaceExtends; +exports.isInterfaceTypeAnnotation = isInterfaceTypeAnnotation; +exports.isInterpreterDirective = isInterpreterDirective; +exports.isIntersectionTypeAnnotation = isIntersectionTypeAnnotation; +exports.isJSX = isJSX; +exports.isJSXAttribute = isJSXAttribute; +exports.isJSXClosingElement = isJSXClosingElement; +exports.isJSXClosingFragment = isJSXClosingFragment; +exports.isJSXElement = isJSXElement; +exports.isJSXEmptyExpression = isJSXEmptyExpression; +exports.isJSXExpressionContainer = isJSXExpressionContainer; +exports.isJSXFragment = isJSXFragment; +exports.isJSXIdentifier = isJSXIdentifier; +exports.isJSXMemberExpression = isJSXMemberExpression; +exports.isJSXNamespacedName = isJSXNamespacedName; +exports.isJSXOpeningElement = isJSXOpeningElement; +exports.isJSXOpeningFragment = isJSXOpeningFragment; +exports.isJSXSpreadAttribute = isJSXSpreadAttribute; +exports.isJSXSpreadChild = isJSXSpreadChild; +exports.isJSXText = isJSXText; +exports.isLVal = isLVal; +exports.isLabeledStatement = isLabeledStatement; +exports.isLiteral = isLiteral; +exports.isLogicalExpression = isLogicalExpression; +exports.isLoop = isLoop; +exports.isMemberExpression = isMemberExpression; +exports.isMetaProperty = isMetaProperty; +exports.isMethod = isMethod; +exports.isMiscellaneous = isMiscellaneous; +exports.isMixedTypeAnnotation = isMixedTypeAnnotation; +exports.isModuleDeclaration = isModuleDeclaration; +exports.isModuleExpression = isModuleExpression; +exports.isModuleSpecifier = isModuleSpecifier; +exports.isNewExpression = isNewExpression; +exports.isNoop = isNoop; +exports.isNullLiteral = isNullLiteral; +exports.isNullLiteralTypeAnnotation = isNullLiteralTypeAnnotation; +exports.isNullableTypeAnnotation = isNullableTypeAnnotation; +exports.isNumberLiteral = isNumberLiteral; +exports.isNumberLiteralTypeAnnotation = isNumberLiteralTypeAnnotation; +exports.isNumberTypeAnnotation = isNumberTypeAnnotation; +exports.isNumericLiteral = isNumericLiteral; +exports.isObjectExpression = isObjectExpression; +exports.isObjectMember = isObjectMember; +exports.isObjectMethod = isObjectMethod; +exports.isObjectPattern = isObjectPattern; +exports.isObjectProperty = isObjectProperty; +exports.isObjectTypeAnnotation = isObjectTypeAnnotation; +exports.isObjectTypeCallProperty = isObjectTypeCallProperty; +exports.isObjectTypeIndexer = isObjectTypeIndexer; +exports.isObjectTypeInternalSlot = isObjectTypeInternalSlot; +exports.isObjectTypeProperty = isObjectTypeProperty; +exports.isObjectTypeSpreadProperty = isObjectTypeSpreadProperty; +exports.isOpaqueType = isOpaqueType; +exports.isOptionalCallExpression = isOptionalCallExpression; +exports.isOptionalIndexedAccessType = isOptionalIndexedAccessType; +exports.isOptionalMemberExpression = isOptionalMemberExpression; +exports.isParenthesizedExpression = isParenthesizedExpression; +exports.isPattern = isPattern; +exports.isPatternLike = isPatternLike; +exports.isPipelineBareFunction = isPipelineBareFunction; +exports.isPipelinePrimaryTopicReference = isPipelinePrimaryTopicReference; +exports.isPipelineTopicExpression = isPipelineTopicExpression; +exports.isPlaceholder = isPlaceholder; +exports.isPrivate = isPrivate; +exports.isPrivateName = isPrivateName; +exports.isProgram = isProgram; +exports.isProperty = isProperty; +exports.isPureish = isPureish; +exports.isQualifiedTypeIdentifier = isQualifiedTypeIdentifier; +exports.isRecordExpression = isRecordExpression; +exports.isRegExpLiteral = isRegExpLiteral; +exports.isRegexLiteral = isRegexLiteral; +exports.isRestElement = isRestElement; +exports.isRestProperty = isRestProperty; +exports.isReturnStatement = isReturnStatement; +exports.isScopable = isScopable; +exports.isSequenceExpression = isSequenceExpression; +exports.isSpreadElement = isSpreadElement; +exports.isSpreadProperty = isSpreadProperty; +exports.isStandardized = isStandardized; +exports.isStatement = isStatement; +exports.isStaticBlock = isStaticBlock; +exports.isStringLiteral = isStringLiteral; +exports.isStringLiteralTypeAnnotation = isStringLiteralTypeAnnotation; +exports.isStringTypeAnnotation = isStringTypeAnnotation; +exports.isSuper = isSuper; +exports.isSwitchCase = isSwitchCase; +exports.isSwitchStatement = isSwitchStatement; +exports.isSymbolTypeAnnotation = isSymbolTypeAnnotation; +exports.isTSAnyKeyword = isTSAnyKeyword; +exports.isTSArrayType = isTSArrayType; +exports.isTSAsExpression = isTSAsExpression; +exports.isTSBaseType = isTSBaseType; +exports.isTSBigIntKeyword = isTSBigIntKeyword; +exports.isTSBooleanKeyword = isTSBooleanKeyword; +exports.isTSCallSignatureDeclaration = isTSCallSignatureDeclaration; +exports.isTSConditionalType = isTSConditionalType; +exports.isTSConstructSignatureDeclaration = isTSConstructSignatureDeclaration; +exports.isTSConstructorType = isTSConstructorType; +exports.isTSDeclareFunction = isTSDeclareFunction; +exports.isTSDeclareMethod = isTSDeclareMethod; +exports.isTSEntityName = isTSEntityName; +exports.isTSEnumDeclaration = isTSEnumDeclaration; +exports.isTSEnumMember = isTSEnumMember; +exports.isTSExportAssignment = isTSExportAssignment; +exports.isTSExpressionWithTypeArguments = isTSExpressionWithTypeArguments; +exports.isTSExternalModuleReference = isTSExternalModuleReference; +exports.isTSFunctionType = isTSFunctionType; +exports.isTSImportEqualsDeclaration = isTSImportEqualsDeclaration; +exports.isTSImportType = isTSImportType; +exports.isTSIndexSignature = isTSIndexSignature; +exports.isTSIndexedAccessType = isTSIndexedAccessType; +exports.isTSInferType = isTSInferType; +exports.isTSInstantiationExpression = isTSInstantiationExpression; +exports.isTSInterfaceBody = isTSInterfaceBody; +exports.isTSInterfaceDeclaration = isTSInterfaceDeclaration; +exports.isTSIntersectionType = isTSIntersectionType; +exports.isTSIntrinsicKeyword = isTSIntrinsicKeyword; +exports.isTSLiteralType = isTSLiteralType; +exports.isTSMappedType = isTSMappedType; +exports.isTSMethodSignature = isTSMethodSignature; +exports.isTSModuleBlock = isTSModuleBlock; +exports.isTSModuleDeclaration = isTSModuleDeclaration; +exports.isTSNamedTupleMember = isTSNamedTupleMember; +exports.isTSNamespaceExportDeclaration = isTSNamespaceExportDeclaration; +exports.isTSNeverKeyword = isTSNeverKeyword; +exports.isTSNonNullExpression = isTSNonNullExpression; +exports.isTSNullKeyword = isTSNullKeyword; +exports.isTSNumberKeyword = isTSNumberKeyword; +exports.isTSObjectKeyword = isTSObjectKeyword; +exports.isTSOptionalType = isTSOptionalType; +exports.isTSParameterProperty = isTSParameterProperty; +exports.isTSParenthesizedType = isTSParenthesizedType; +exports.isTSPropertySignature = isTSPropertySignature; +exports.isTSQualifiedName = isTSQualifiedName; +exports.isTSRestType = isTSRestType; +exports.isTSStringKeyword = isTSStringKeyword; +exports.isTSSymbolKeyword = isTSSymbolKeyword; +exports.isTSThisType = isTSThisType; +exports.isTSTupleType = isTSTupleType; +exports.isTSType = isTSType; +exports.isTSTypeAliasDeclaration = isTSTypeAliasDeclaration; +exports.isTSTypeAnnotation = isTSTypeAnnotation; +exports.isTSTypeAssertion = isTSTypeAssertion; +exports.isTSTypeElement = isTSTypeElement; +exports.isTSTypeLiteral = isTSTypeLiteral; +exports.isTSTypeOperator = isTSTypeOperator; +exports.isTSTypeParameter = isTSTypeParameter; +exports.isTSTypeParameterDeclaration = isTSTypeParameterDeclaration; +exports.isTSTypeParameterInstantiation = isTSTypeParameterInstantiation; +exports.isTSTypePredicate = isTSTypePredicate; +exports.isTSTypeQuery = isTSTypeQuery; +exports.isTSTypeReference = isTSTypeReference; +exports.isTSUndefinedKeyword = isTSUndefinedKeyword; +exports.isTSUnionType = isTSUnionType; +exports.isTSUnknownKeyword = isTSUnknownKeyword; +exports.isTSVoidKeyword = isTSVoidKeyword; +exports.isTaggedTemplateExpression = isTaggedTemplateExpression; +exports.isTemplateElement = isTemplateElement; +exports.isTemplateLiteral = isTemplateLiteral; +exports.isTerminatorless = isTerminatorless; +exports.isThisExpression = isThisExpression; +exports.isThisTypeAnnotation = isThisTypeAnnotation; +exports.isThrowStatement = isThrowStatement; +exports.isTopicReference = isTopicReference; +exports.isTryStatement = isTryStatement; +exports.isTupleExpression = isTupleExpression; +exports.isTupleTypeAnnotation = isTupleTypeAnnotation; +exports.isTypeAlias = isTypeAlias; +exports.isTypeAnnotation = isTypeAnnotation; +exports.isTypeCastExpression = isTypeCastExpression; +exports.isTypeParameter = isTypeParameter; +exports.isTypeParameterDeclaration = isTypeParameterDeclaration; +exports.isTypeParameterInstantiation = isTypeParameterInstantiation; +exports.isTypeScript = isTypeScript; +exports.isTypeofTypeAnnotation = isTypeofTypeAnnotation; +exports.isUnaryExpression = isUnaryExpression; +exports.isUnaryLike = isUnaryLike; +exports.isUnionTypeAnnotation = isUnionTypeAnnotation; +exports.isUpdateExpression = isUpdateExpression; +exports.isUserWhitespacable = isUserWhitespacable; +exports.isV8IntrinsicIdentifier = isV8IntrinsicIdentifier; +exports.isVariableDeclaration = isVariableDeclaration; +exports.isVariableDeclarator = isVariableDeclarator; +exports.isVariance = isVariance; +exports.isVoidTypeAnnotation = isVoidTypeAnnotation; +exports.isWhile = isWhile; +exports.isWhileStatement = isWhileStatement; +exports.isWithStatement = isWithStatement; +exports.isYieldExpression = isYieldExpression; + +var _shallowEqual = require("../../utils/shallowEqual"); + +function isArrayExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrayExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAssignmentExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AssignmentExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBinaryExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BinaryExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterpreterDirective(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterpreterDirective") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDirective(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Directive") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDirectiveLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DirectiveLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBlockStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BlockStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBreakStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BreakStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isCallExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "CallExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isCatchClause(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "CatchClause") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isConditionalExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ConditionalExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isContinueStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ContinueStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDebuggerStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DebuggerStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDoWhileStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DoWhileStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEmptyStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EmptyStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExpressionStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExpressionStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFile(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "File") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForInStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ForInStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ForStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Identifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIfStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "IfStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLabeledStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "LabeledStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStringLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StringLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumericLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumericLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNullLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NullLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBooleanLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BooleanLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRegExpLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RegExpLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLogicalExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "LogicalExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMemberExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "MemberExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNewExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NewExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isProgram(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Program") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRestElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RestElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isReturnStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ReturnStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSequenceExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SequenceExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isParenthesizedExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ParenthesizedExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSwitchCase(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SwitchCase") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSwitchStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SwitchStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isThisExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ThisExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isThrowStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ThrowStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTryStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TryStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUnaryExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "UnaryExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUpdateExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "UpdateExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVariableDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "VariableDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVariableDeclarator(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "VariableDeclarator") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isWhileStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "WhileStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isWithStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "WithStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAssignmentPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AssignmentPattern") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArrayPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrayPattern") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArrowFunctionExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrowFunctionExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportAllDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportAllDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportDefaultDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportDefaultDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportNamedDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportNamedDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForOfStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ForOfStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportDefaultSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportDefaultSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportNamespaceSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportNamespaceSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMetaProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "MetaProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectPattern") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSpreadElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SpreadElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSuper(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Super") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTaggedTemplateExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TaggedTemplateExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTemplateElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TemplateElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTemplateLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TemplateLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isYieldExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "YieldExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAwaitExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AwaitExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImport(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Import") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBigIntLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BigIntLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportNamespaceSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportNamespaceSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOptionalMemberExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OptionalMemberExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOptionalCallExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OptionalCallExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassAccessorProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassAccessorProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassPrivateProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassPrivateProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassPrivateMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassPrivateMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPrivateName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PrivateName") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStaticBlock(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StaticBlock") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAnyTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AnyTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArrayTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrayTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBooleanTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BooleanTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBooleanLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BooleanLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNullLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NullLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassImplements(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassImplements") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareClass(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareClass") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareFunction") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareInterface(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareInterface") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareModule(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareModule") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareModuleExports(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareModuleExports") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareTypeAlias(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareTypeAlias") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareOpaqueType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareOpaqueType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareVariable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareVariable") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareExportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareExportDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareExportAllDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareExportAllDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclaredPredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclaredPredicate") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExistsTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExistsTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionTypeParam(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionTypeParam") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isGenericTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "GenericTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInferredPredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InferredPredicate") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterfaceExtends(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterfaceExtends") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterfaceDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterfaceDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterfaceTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterfaceTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIntersectionTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "IntersectionTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMixedTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "MixedTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEmptyTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EmptyTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNullableTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NullableTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumberLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumberLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumberTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumberTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeInternalSlot(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeInternalSlot") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeCallProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeCallProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeIndexer(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeIndexer") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeSpreadProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeSpreadProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOpaqueType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OpaqueType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isQualifiedTypeIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "QualifiedTypeIdentifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStringLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StringLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStringTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StringTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSymbolTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SymbolTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isThisTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ThisTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTupleTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TupleTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeofTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeofTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeAlias(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeAlias") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeCastExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeCastExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeParameter(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeParameter") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeParameterDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeParameterDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeParameterInstantiation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeParameterInstantiation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUnionTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "UnionTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVariance(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Variance") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVoidTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "VoidTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumBooleanBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumBooleanBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumNumberBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumNumberBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumStringBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumStringBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumSymbolBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumSymbolBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumBooleanMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumBooleanMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumNumberMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumNumberMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumStringMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumStringMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumDefaultedMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumDefaultedMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIndexedAccessType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "IndexedAccessType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOptionalIndexedAccessType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OptionalIndexedAccessType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXAttribute(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXAttribute") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXClosingElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXClosingElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXEmptyExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXEmptyExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXExpressionContainer(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXExpressionContainer") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXSpreadChild(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXSpreadChild") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXIdentifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXMemberExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXMemberExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXNamespacedName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXNamespacedName") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXOpeningElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXOpeningElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXSpreadAttribute(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXSpreadAttribute") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXText(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXText") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXFragment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXFragment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXOpeningFragment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXOpeningFragment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXClosingFragment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXClosingFragment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNoop(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Noop") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPlaceholder(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Placeholder") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isV8IntrinsicIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "V8IntrinsicIdentifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArgumentPlaceholder(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArgumentPlaceholder") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBindExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BindExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportAttribute(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportAttribute") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDecorator(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Decorator") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDoExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DoExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportDefaultSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportDefaultSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRecordExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RecordExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTupleExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TupleExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDecimalLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DecimalLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isModuleExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ModuleExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTopicReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TopicReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPipelineTopicExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PipelineTopicExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPipelineBareFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PipelineBareFunction") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPipelinePrimaryTopicReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PipelinePrimaryTopicReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSParameterProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSParameterProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSDeclareFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSDeclareFunction") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSDeclareMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSDeclareMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSQualifiedName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSQualifiedName") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSCallSignatureDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSCallSignatureDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSConstructSignatureDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSConstructSignatureDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSPropertySignature(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSPropertySignature") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSMethodSignature(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSMethodSignature") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIndexSignature(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIndexSignature") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSAnyKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSAnyKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSBooleanKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSBooleanKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSBigIntKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSBigIntKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIntrinsicKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIntrinsicKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNeverKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNeverKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNullKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNullKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNumberKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNumberKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSObjectKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSObjectKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSStringKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSStringKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSSymbolKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSSymbolKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSUndefinedKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSUndefinedKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSUnknownKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSUnknownKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSVoidKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSVoidKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSThisType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSThisType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSFunctionType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSFunctionType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSConstructorType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSConstructorType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypePredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypePredicate") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeQuery(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeQuery") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSArrayType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSArrayType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTupleType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTupleType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSOptionalType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSOptionalType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSRestType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSRestType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNamedTupleMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNamedTupleMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSUnionType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSUnionType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIntersectionType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIntersectionType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSConditionalType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSConditionalType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSInferType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSInferType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSParenthesizedType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSParenthesizedType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeOperator(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeOperator") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIndexedAccessType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIndexedAccessType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSMappedType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSMappedType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSLiteralType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSLiteralType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSExpressionWithTypeArguments(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSExpressionWithTypeArguments") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSInterfaceDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSInterfaceDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSInterfaceBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSInterfaceBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeAliasDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeAliasDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSInstantiationExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSInstantiationExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSAsExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSAsExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeAssertion(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeAssertion") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSEnumDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSEnumDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSEnumMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSEnumMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSModuleDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSModuleDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSModuleBlock(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSModuleBlock") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSImportType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSImportType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSImportEqualsDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSImportEqualsDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSExternalModuleReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSExternalModuleReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNonNullExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNonNullExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSExportAssignment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSExportAssignment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNamespaceExportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNamespaceExportDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeParameterInstantiation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeParameterInstantiation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeParameterDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeParameterDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeParameter(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeParameter") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStandardized(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ArrayExpression" === nodeType || "AssignmentExpression" === nodeType || "BinaryExpression" === nodeType || "InterpreterDirective" === nodeType || "Directive" === nodeType || "DirectiveLiteral" === nodeType || "BlockStatement" === nodeType || "BreakStatement" === nodeType || "CallExpression" === nodeType || "CatchClause" === nodeType || "ConditionalExpression" === nodeType || "ContinueStatement" === nodeType || "DebuggerStatement" === nodeType || "DoWhileStatement" === nodeType || "EmptyStatement" === nodeType || "ExpressionStatement" === nodeType || "File" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "Identifier" === nodeType || "IfStatement" === nodeType || "LabeledStatement" === nodeType || "StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "LogicalExpression" === nodeType || "MemberExpression" === nodeType || "NewExpression" === nodeType || "Program" === nodeType || "ObjectExpression" === nodeType || "ObjectMethod" === nodeType || "ObjectProperty" === nodeType || "RestElement" === nodeType || "ReturnStatement" === nodeType || "SequenceExpression" === nodeType || "ParenthesizedExpression" === nodeType || "SwitchCase" === nodeType || "SwitchStatement" === nodeType || "ThisExpression" === nodeType || "ThrowStatement" === nodeType || "TryStatement" === nodeType || "UnaryExpression" === nodeType || "UpdateExpression" === nodeType || "VariableDeclaration" === nodeType || "VariableDeclarator" === nodeType || "WhileStatement" === nodeType || "WithStatement" === nodeType || "AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassBody" === nodeType || "ClassExpression" === nodeType || "ClassDeclaration" === nodeType || "ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ExportSpecifier" === nodeType || "ForOfStatement" === nodeType || "ImportDeclaration" === nodeType || "ImportDefaultSpecifier" === nodeType || "ImportNamespaceSpecifier" === nodeType || "ImportSpecifier" === nodeType || "MetaProperty" === nodeType || "ClassMethod" === nodeType || "ObjectPattern" === nodeType || "SpreadElement" === nodeType || "Super" === nodeType || "TaggedTemplateExpression" === nodeType || "TemplateElement" === nodeType || "TemplateLiteral" === nodeType || "YieldExpression" === nodeType || "AwaitExpression" === nodeType || "Import" === nodeType || "BigIntLiteral" === nodeType || "ExportNamespaceSpecifier" === nodeType || "OptionalMemberExpression" === nodeType || "OptionalCallExpression" === nodeType || "ClassProperty" === nodeType || "ClassAccessorProperty" === nodeType || "ClassPrivateProperty" === nodeType || "ClassPrivateMethod" === nodeType || "PrivateName" === nodeType || "StaticBlock" === nodeType || nodeType === "Placeholder" && ("Identifier" === node.expectedNode || "StringLiteral" === node.expectedNode || "BlockStatement" === node.expectedNode || "ClassBody" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ArrayExpression" === nodeType || "AssignmentExpression" === nodeType || "BinaryExpression" === nodeType || "CallExpression" === nodeType || "ConditionalExpression" === nodeType || "FunctionExpression" === nodeType || "Identifier" === nodeType || "StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "LogicalExpression" === nodeType || "MemberExpression" === nodeType || "NewExpression" === nodeType || "ObjectExpression" === nodeType || "SequenceExpression" === nodeType || "ParenthesizedExpression" === nodeType || "ThisExpression" === nodeType || "UnaryExpression" === nodeType || "UpdateExpression" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassExpression" === nodeType || "MetaProperty" === nodeType || "Super" === nodeType || "TaggedTemplateExpression" === nodeType || "TemplateLiteral" === nodeType || "YieldExpression" === nodeType || "AwaitExpression" === nodeType || "Import" === nodeType || "BigIntLiteral" === nodeType || "OptionalMemberExpression" === nodeType || "OptionalCallExpression" === nodeType || "TypeCastExpression" === nodeType || "JSXElement" === nodeType || "JSXFragment" === nodeType || "BindExpression" === nodeType || "DoExpression" === nodeType || "RecordExpression" === nodeType || "TupleExpression" === nodeType || "DecimalLiteral" === nodeType || "ModuleExpression" === nodeType || "TopicReference" === nodeType || "PipelineTopicExpression" === nodeType || "PipelineBareFunction" === nodeType || "PipelinePrimaryTopicReference" === nodeType || "TSInstantiationExpression" === nodeType || "TSAsExpression" === nodeType || "TSTypeAssertion" === nodeType || "TSNonNullExpression" === nodeType || nodeType === "Placeholder" && ("Expression" === node.expectedNode || "Identifier" === node.expectedNode || "StringLiteral" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBinary(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BinaryExpression" === nodeType || "LogicalExpression" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isScopable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "CatchClause" === nodeType || "DoWhileStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "Program" === nodeType || "ObjectMethod" === nodeType || "SwitchStatement" === nodeType || "WhileStatement" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassExpression" === nodeType || "ClassDeclaration" === nodeType || "ForOfStatement" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType || "StaticBlock" === nodeType || "TSModuleBlock" === nodeType || nodeType === "Placeholder" && "BlockStatement" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBlockParent(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "CatchClause" === nodeType || "DoWhileStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "Program" === nodeType || "ObjectMethod" === nodeType || "SwitchStatement" === nodeType || "WhileStatement" === nodeType || "ArrowFunctionExpression" === nodeType || "ForOfStatement" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType || "StaticBlock" === nodeType || "TSModuleBlock" === nodeType || nodeType === "Placeholder" && "BlockStatement" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBlock(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "Program" === nodeType || "TSModuleBlock" === nodeType || nodeType === "Placeholder" && "BlockStatement" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "BreakStatement" === nodeType || "ContinueStatement" === nodeType || "DebuggerStatement" === nodeType || "DoWhileStatement" === nodeType || "EmptyStatement" === nodeType || "ExpressionStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "IfStatement" === nodeType || "LabeledStatement" === nodeType || "ReturnStatement" === nodeType || "SwitchStatement" === nodeType || "ThrowStatement" === nodeType || "TryStatement" === nodeType || "VariableDeclaration" === nodeType || "WhileStatement" === nodeType || "WithStatement" === nodeType || "ClassDeclaration" === nodeType || "ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ForOfStatement" === nodeType || "ImportDeclaration" === nodeType || "DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "InterfaceDeclaration" === nodeType || "OpaqueType" === nodeType || "TypeAlias" === nodeType || "EnumDeclaration" === nodeType || "TSDeclareFunction" === nodeType || "TSInterfaceDeclaration" === nodeType || "TSTypeAliasDeclaration" === nodeType || "TSEnumDeclaration" === nodeType || "TSModuleDeclaration" === nodeType || "TSImportEqualsDeclaration" === nodeType || "TSExportAssignment" === nodeType || "TSNamespaceExportDeclaration" === nodeType || nodeType === "Placeholder" && ("Statement" === node.expectedNode || "Declaration" === node.expectedNode || "BlockStatement" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTerminatorless(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BreakStatement" === nodeType || "ContinueStatement" === nodeType || "ReturnStatement" === nodeType || "ThrowStatement" === nodeType || "YieldExpression" === nodeType || "AwaitExpression" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isCompletionStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BreakStatement" === nodeType || "ContinueStatement" === nodeType || "ReturnStatement" === nodeType || "ThrowStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isConditional(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ConditionalExpression" === nodeType || "IfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLoop(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DoWhileStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "WhileStatement" === nodeType || "ForOfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isWhile(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DoWhileStatement" === nodeType || "WhileStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExpressionWrapper(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExpressionStatement" === nodeType || "ParenthesizedExpression" === nodeType || "TypeCastExpression" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFor(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ForInStatement" === nodeType || "ForStatement" === nodeType || "ForOfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForXStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ForInStatement" === nodeType || "ForOfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "ObjectMethod" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionParent(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "ObjectMethod" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType || "StaticBlock" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPureish(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "ArrowFunctionExpression" === nodeType || "BigIntLiteral" === nodeType || "DecimalLiteral" === nodeType || nodeType === "Placeholder" && "StringLiteral" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "VariableDeclaration" === nodeType || "ClassDeclaration" === nodeType || "ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ImportDeclaration" === nodeType || "DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "InterfaceDeclaration" === nodeType || "OpaqueType" === nodeType || "TypeAlias" === nodeType || "EnumDeclaration" === nodeType || "TSDeclareFunction" === nodeType || "TSInterfaceDeclaration" === nodeType || "TSTypeAliasDeclaration" === nodeType || "TSEnumDeclaration" === nodeType || "TSModuleDeclaration" === nodeType || nodeType === "Placeholder" && "Declaration" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPatternLike(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Identifier" === nodeType || "RestElement" === nodeType || "AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ObjectPattern" === nodeType || "TSAsExpression" === nodeType || "TSTypeAssertion" === nodeType || "TSNonNullExpression" === nodeType || nodeType === "Placeholder" && ("Pattern" === node.expectedNode || "Identifier" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLVal(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Identifier" === nodeType || "MemberExpression" === nodeType || "RestElement" === nodeType || "AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ObjectPattern" === nodeType || "TSParameterProperty" === nodeType || "TSAsExpression" === nodeType || "TSTypeAssertion" === nodeType || "TSNonNullExpression" === nodeType || nodeType === "Placeholder" && ("Pattern" === node.expectedNode || "Identifier" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSEntityName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Identifier" === nodeType || "TSQualifiedName" === nodeType || nodeType === "Placeholder" && "Identifier" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "TemplateLiteral" === nodeType || "BigIntLiteral" === nodeType || "DecimalLiteral" === nodeType || nodeType === "Placeholder" && "StringLiteral" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImmutable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "BigIntLiteral" === nodeType || "JSXAttribute" === nodeType || "JSXClosingElement" === nodeType || "JSXElement" === nodeType || "JSXExpressionContainer" === nodeType || "JSXSpreadChild" === nodeType || "JSXOpeningElement" === nodeType || "JSXText" === nodeType || "JSXFragment" === nodeType || "JSXOpeningFragment" === nodeType || "JSXClosingFragment" === nodeType || "DecimalLiteral" === nodeType || nodeType === "Placeholder" && "StringLiteral" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUserWhitespacable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectMethod" === nodeType || "ObjectProperty" === nodeType || "ObjectTypeInternalSlot" === nodeType || "ObjectTypeCallProperty" === nodeType || "ObjectTypeIndexer" === nodeType || "ObjectTypeProperty" === nodeType || "ObjectTypeSpreadProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectMethod" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectMethod" === nodeType || "ObjectProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectProperty" === nodeType || "ClassProperty" === nodeType || "ClassAccessorProperty" === nodeType || "ClassPrivateProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUnaryLike(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("UnaryExpression" === nodeType || "SpreadElement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ObjectPattern" === nodeType || nodeType === "Placeholder" && "Pattern" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClass(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ClassExpression" === nodeType || "ClassDeclaration" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isModuleDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ImportDeclaration" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isModuleSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExportSpecifier" === nodeType || "ImportDefaultSpecifier" === nodeType || "ImportNamespaceSpecifier" === nodeType || "ImportSpecifier" === nodeType || "ExportNamespaceSpecifier" === nodeType || "ExportDefaultSpecifier" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAccessor(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ClassAccessorProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPrivate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ClassPrivateProperty" === nodeType || "ClassPrivateMethod" === nodeType || "PrivateName" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlow(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AnyTypeAnnotation" === nodeType || "ArrayTypeAnnotation" === nodeType || "BooleanTypeAnnotation" === nodeType || "BooleanLiteralTypeAnnotation" === nodeType || "NullLiteralTypeAnnotation" === nodeType || "ClassImplements" === nodeType || "DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "DeclaredPredicate" === nodeType || "ExistsTypeAnnotation" === nodeType || "FunctionTypeAnnotation" === nodeType || "FunctionTypeParam" === nodeType || "GenericTypeAnnotation" === nodeType || "InferredPredicate" === nodeType || "InterfaceExtends" === nodeType || "InterfaceDeclaration" === nodeType || "InterfaceTypeAnnotation" === nodeType || "IntersectionTypeAnnotation" === nodeType || "MixedTypeAnnotation" === nodeType || "EmptyTypeAnnotation" === nodeType || "NullableTypeAnnotation" === nodeType || "NumberLiteralTypeAnnotation" === nodeType || "NumberTypeAnnotation" === nodeType || "ObjectTypeAnnotation" === nodeType || "ObjectTypeInternalSlot" === nodeType || "ObjectTypeCallProperty" === nodeType || "ObjectTypeIndexer" === nodeType || "ObjectTypeProperty" === nodeType || "ObjectTypeSpreadProperty" === nodeType || "OpaqueType" === nodeType || "QualifiedTypeIdentifier" === nodeType || "StringLiteralTypeAnnotation" === nodeType || "StringTypeAnnotation" === nodeType || "SymbolTypeAnnotation" === nodeType || "ThisTypeAnnotation" === nodeType || "TupleTypeAnnotation" === nodeType || "TypeofTypeAnnotation" === nodeType || "TypeAlias" === nodeType || "TypeAnnotation" === nodeType || "TypeCastExpression" === nodeType || "TypeParameter" === nodeType || "TypeParameterDeclaration" === nodeType || "TypeParameterInstantiation" === nodeType || "UnionTypeAnnotation" === nodeType || "Variance" === nodeType || "VoidTypeAnnotation" === nodeType || "EnumDeclaration" === nodeType || "EnumBooleanBody" === nodeType || "EnumNumberBody" === nodeType || "EnumStringBody" === nodeType || "EnumSymbolBody" === nodeType || "EnumBooleanMember" === nodeType || "EnumNumberMember" === nodeType || "EnumStringMember" === nodeType || "EnumDefaultedMember" === nodeType || "IndexedAccessType" === nodeType || "OptionalIndexedAccessType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AnyTypeAnnotation" === nodeType || "ArrayTypeAnnotation" === nodeType || "BooleanTypeAnnotation" === nodeType || "BooleanLiteralTypeAnnotation" === nodeType || "NullLiteralTypeAnnotation" === nodeType || "ExistsTypeAnnotation" === nodeType || "FunctionTypeAnnotation" === nodeType || "GenericTypeAnnotation" === nodeType || "InterfaceTypeAnnotation" === nodeType || "IntersectionTypeAnnotation" === nodeType || "MixedTypeAnnotation" === nodeType || "EmptyTypeAnnotation" === nodeType || "NullableTypeAnnotation" === nodeType || "NumberLiteralTypeAnnotation" === nodeType || "NumberTypeAnnotation" === nodeType || "ObjectTypeAnnotation" === nodeType || "StringLiteralTypeAnnotation" === nodeType || "StringTypeAnnotation" === nodeType || "SymbolTypeAnnotation" === nodeType || "ThisTypeAnnotation" === nodeType || "TupleTypeAnnotation" === nodeType || "TypeofTypeAnnotation" === nodeType || "UnionTypeAnnotation" === nodeType || "VoidTypeAnnotation" === nodeType || "IndexedAccessType" === nodeType || "OptionalIndexedAccessType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowBaseAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AnyTypeAnnotation" === nodeType || "BooleanTypeAnnotation" === nodeType || "NullLiteralTypeAnnotation" === nodeType || "MixedTypeAnnotation" === nodeType || "EmptyTypeAnnotation" === nodeType || "NumberTypeAnnotation" === nodeType || "StringTypeAnnotation" === nodeType || "SymbolTypeAnnotation" === nodeType || "ThisTypeAnnotation" === nodeType || "VoidTypeAnnotation" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "InterfaceDeclaration" === nodeType || "OpaqueType" === nodeType || "TypeAlias" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowPredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DeclaredPredicate" === nodeType || "InferredPredicate" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("EnumBooleanBody" === nodeType || "EnumNumberBody" === nodeType || "EnumStringBody" === nodeType || "EnumSymbolBody" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("EnumBooleanMember" === nodeType || "EnumNumberMember" === nodeType || "EnumStringMember" === nodeType || "EnumDefaultedMember" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSX(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("JSXAttribute" === nodeType || "JSXClosingElement" === nodeType || "JSXElement" === nodeType || "JSXEmptyExpression" === nodeType || "JSXExpressionContainer" === nodeType || "JSXSpreadChild" === nodeType || "JSXIdentifier" === nodeType || "JSXMemberExpression" === nodeType || "JSXNamespacedName" === nodeType || "JSXOpeningElement" === nodeType || "JSXSpreadAttribute" === nodeType || "JSXText" === nodeType || "JSXFragment" === nodeType || "JSXOpeningFragment" === nodeType || "JSXClosingFragment" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMiscellaneous(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Noop" === nodeType || "Placeholder" === nodeType || "V8IntrinsicIdentifier" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeScript(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSParameterProperty" === nodeType || "TSDeclareFunction" === nodeType || "TSDeclareMethod" === nodeType || "TSQualifiedName" === nodeType || "TSCallSignatureDeclaration" === nodeType || "TSConstructSignatureDeclaration" === nodeType || "TSPropertySignature" === nodeType || "TSMethodSignature" === nodeType || "TSIndexSignature" === nodeType || "TSAnyKeyword" === nodeType || "TSBooleanKeyword" === nodeType || "TSBigIntKeyword" === nodeType || "TSIntrinsicKeyword" === nodeType || "TSNeverKeyword" === nodeType || "TSNullKeyword" === nodeType || "TSNumberKeyword" === nodeType || "TSObjectKeyword" === nodeType || "TSStringKeyword" === nodeType || "TSSymbolKeyword" === nodeType || "TSUndefinedKeyword" === nodeType || "TSUnknownKeyword" === nodeType || "TSVoidKeyword" === nodeType || "TSThisType" === nodeType || "TSFunctionType" === nodeType || "TSConstructorType" === nodeType || "TSTypeReference" === nodeType || "TSTypePredicate" === nodeType || "TSTypeQuery" === nodeType || "TSTypeLiteral" === nodeType || "TSArrayType" === nodeType || "TSTupleType" === nodeType || "TSOptionalType" === nodeType || "TSRestType" === nodeType || "TSNamedTupleMember" === nodeType || "TSUnionType" === nodeType || "TSIntersectionType" === nodeType || "TSConditionalType" === nodeType || "TSInferType" === nodeType || "TSParenthesizedType" === nodeType || "TSTypeOperator" === nodeType || "TSIndexedAccessType" === nodeType || "TSMappedType" === nodeType || "TSLiteralType" === nodeType || "TSExpressionWithTypeArguments" === nodeType || "TSInterfaceDeclaration" === nodeType || "TSInterfaceBody" === nodeType || "TSTypeAliasDeclaration" === nodeType || "TSInstantiationExpression" === nodeType || "TSAsExpression" === nodeType || "TSTypeAssertion" === nodeType || "TSEnumDeclaration" === nodeType || "TSEnumMember" === nodeType || "TSModuleDeclaration" === nodeType || "TSModuleBlock" === nodeType || "TSImportType" === nodeType || "TSImportEqualsDeclaration" === nodeType || "TSExternalModuleReference" === nodeType || "TSNonNullExpression" === nodeType || "TSExportAssignment" === nodeType || "TSNamespaceExportDeclaration" === nodeType || "TSTypeAnnotation" === nodeType || "TSTypeParameterInstantiation" === nodeType || "TSTypeParameterDeclaration" === nodeType || "TSTypeParameter" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSCallSignatureDeclaration" === nodeType || "TSConstructSignatureDeclaration" === nodeType || "TSPropertySignature" === nodeType || "TSMethodSignature" === nodeType || "TSIndexSignature" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSAnyKeyword" === nodeType || "TSBooleanKeyword" === nodeType || "TSBigIntKeyword" === nodeType || "TSIntrinsicKeyword" === nodeType || "TSNeverKeyword" === nodeType || "TSNullKeyword" === nodeType || "TSNumberKeyword" === nodeType || "TSObjectKeyword" === nodeType || "TSStringKeyword" === nodeType || "TSSymbolKeyword" === nodeType || "TSUndefinedKeyword" === nodeType || "TSUnknownKeyword" === nodeType || "TSVoidKeyword" === nodeType || "TSThisType" === nodeType || "TSFunctionType" === nodeType || "TSConstructorType" === nodeType || "TSTypeReference" === nodeType || "TSTypePredicate" === nodeType || "TSTypeQuery" === nodeType || "TSTypeLiteral" === nodeType || "TSArrayType" === nodeType || "TSTupleType" === nodeType || "TSOptionalType" === nodeType || "TSRestType" === nodeType || "TSUnionType" === nodeType || "TSIntersectionType" === nodeType || "TSConditionalType" === nodeType || "TSInferType" === nodeType || "TSParenthesizedType" === nodeType || "TSTypeOperator" === nodeType || "TSIndexedAccessType" === nodeType || "TSMappedType" === nodeType || "TSLiteralType" === nodeType || "TSExpressionWithTypeArguments" === nodeType || "TSImportType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSBaseType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSAnyKeyword" === nodeType || "TSBooleanKeyword" === nodeType || "TSBigIntKeyword" === nodeType || "TSIntrinsicKeyword" === nodeType || "TSNeverKeyword" === nodeType || "TSNullKeyword" === nodeType || "TSNumberKeyword" === nodeType || "TSObjectKeyword" === nodeType || "TSStringKeyword" === nodeType || "TSSymbolKeyword" === nodeType || "TSUndefinedKeyword" === nodeType || "TSUnknownKeyword" === nodeType || "TSVoidKeyword" === nodeType || "TSThisType" === nodeType || "TSLiteralType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumberLiteral(node, opts) { + console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumberLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRegexLiteral(node, opts) { + console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RegexLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRestProperty(node, opts) { + console.trace("The node type RestProperty has been renamed to RestElement"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RestProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSpreadProperty(node, opts) { + console.trace("The node type SpreadProperty has been renamed to SpreadElement"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SpreadProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} \ No newline at end of file diff --git a/node_modules/@typescript-eslint/types/dist/generated/ast-spec.d.ts b/node_modules/@typescript-eslint/types/dist/generated/ast-spec.d.ts new file mode 100644 index 000000000..1630fb751 --- /dev/null +++ b/node_modules/@typescript-eslint/types/dist/generated/ast-spec.d.ts @@ -0,0 +1,1384 @@ +/********************************************** + * DO NOT MODIFY THIS FILE MANUALLY * + * * + * THIS FILE HAS BEEN COPIED FROM ast-spec. * + * ANY CHANGES WILL BE LOST ON THE NEXT BUILD * + * * + * MAKE CHANGES TO ast-spec AND THEN RUN * + * yarn build * + **********************************************/ +import type { SyntaxKind } from 'typescript'; +export declare type Accessibility = 'private' | 'protected' | 'public'; +export declare interface ArrayExpression extends BaseNode { + type: AST_NODE_TYPES.ArrayExpression; + elements: Expression[]; +} +export declare interface ArrayPattern extends BaseNode { + type: AST_NODE_TYPES.ArrayPattern; + elements: (DestructuringPattern | null)[]; + typeAnnotation?: TSTypeAnnotation; + optional?: boolean; + decorators?: Decorator[]; +} +export declare interface ArrowFunctionExpression extends BaseNode { + type: AST_NODE_TYPES.ArrowFunctionExpression; + generator: boolean; + id: null; + params: Parameter[]; + body: BlockStatement | Expression; + async: boolean; + expression: boolean; + returnType?: TSTypeAnnotation; + typeParameters?: TSTypeParameterDeclaration; +} +export declare interface AssignmentExpression extends BaseNode { + type: AST_NODE_TYPES.AssignmentExpression; + operator: '-=' | '??=' | '**=' | '*=' | '/=' | '&&=' | '&=' | '%=' | '^=' | '+=' | '<<=' | '=' | '>>=' | '>>>=' | '|=' | '||='; + left: Expression; + right: Expression; +} +export declare interface AssignmentPattern extends BaseNode { + type: AST_NODE_TYPES.AssignmentPattern; + left: BindingName; + right: Expression; + typeAnnotation?: TSTypeAnnotation; + optional?: boolean; + decorators?: Decorator[]; +} +export declare enum AST_NODE_TYPES { + ArrayExpression = "ArrayExpression", + ArrayPattern = "ArrayPattern", + ArrowFunctionExpression = "ArrowFunctionExpression", + AssignmentExpression = "AssignmentExpression", + AssignmentPattern = "AssignmentPattern", + AwaitExpression = "AwaitExpression", + BinaryExpression = "BinaryExpression", + BlockStatement = "BlockStatement", + BreakStatement = "BreakStatement", + CallExpression = "CallExpression", + CatchClause = "CatchClause", + ChainExpression = "ChainExpression", + ClassBody = "ClassBody", + ClassDeclaration = "ClassDeclaration", + ClassExpression = "ClassExpression", + ConditionalExpression = "ConditionalExpression", + ContinueStatement = "ContinueStatement", + DebuggerStatement = "DebuggerStatement", + Decorator = "Decorator", + DoWhileStatement = "DoWhileStatement", + EmptyStatement = "EmptyStatement", + ExportAllDeclaration = "ExportAllDeclaration", + ExportDefaultDeclaration = "ExportDefaultDeclaration", + ExportNamedDeclaration = "ExportNamedDeclaration", + ExportSpecifier = "ExportSpecifier", + ExpressionStatement = "ExpressionStatement", + ForInStatement = "ForInStatement", + ForOfStatement = "ForOfStatement", + ForStatement = "ForStatement", + FunctionDeclaration = "FunctionDeclaration", + FunctionExpression = "FunctionExpression", + Identifier = "Identifier", + IfStatement = "IfStatement", + ImportAttribute = "ImportAttribute", + ImportDeclaration = "ImportDeclaration", + ImportDefaultSpecifier = "ImportDefaultSpecifier", + ImportExpression = "ImportExpression", + ImportNamespaceSpecifier = "ImportNamespaceSpecifier", + ImportSpecifier = "ImportSpecifier", + JSXAttribute = "JSXAttribute", + JSXClosingElement = "JSXClosingElement", + JSXClosingFragment = "JSXClosingFragment", + JSXElement = "JSXElement", + JSXEmptyExpression = "JSXEmptyExpression", + JSXExpressionContainer = "JSXExpressionContainer", + JSXFragment = "JSXFragment", + JSXIdentifier = "JSXIdentifier", + JSXMemberExpression = "JSXMemberExpression", + JSXNamespacedName = "JSXNamespacedName", + JSXOpeningElement = "JSXOpeningElement", + JSXOpeningFragment = "JSXOpeningFragment", + JSXSpreadAttribute = "JSXSpreadAttribute", + JSXSpreadChild = "JSXSpreadChild", + JSXText = "JSXText", + LabeledStatement = "LabeledStatement", + Literal = "Literal", + LogicalExpression = "LogicalExpression", + MemberExpression = "MemberExpression", + MetaProperty = "MetaProperty", + MethodDefinition = "MethodDefinition", + NewExpression = "NewExpression", + ObjectExpression = "ObjectExpression", + ObjectPattern = "ObjectPattern", + PrivateIdentifier = "PrivateIdentifier", + Program = "Program", + Property = "Property", + PropertyDefinition = "PropertyDefinition", + RestElement = "RestElement", + ReturnStatement = "ReturnStatement", + SequenceExpression = "SequenceExpression", + SpreadElement = "SpreadElement", + StaticBlock = "StaticBlock", + Super = "Super", + SwitchCase = "SwitchCase", + SwitchStatement = "SwitchStatement", + TaggedTemplateExpression = "TaggedTemplateExpression", + TemplateElement = "TemplateElement", + TemplateLiteral = "TemplateLiteral", + ThisExpression = "ThisExpression", + ThrowStatement = "ThrowStatement", + TryStatement = "TryStatement", + UnaryExpression = "UnaryExpression", + UpdateExpression = "UpdateExpression", + VariableDeclaration = "VariableDeclaration", + VariableDeclarator = "VariableDeclarator", + WhileStatement = "WhileStatement", + WithStatement = "WithStatement", + YieldExpression = "YieldExpression", + /** + * TS-prefixed nodes + */ + TSAbstractKeyword = "TSAbstractKeyword", + TSAbstractMethodDefinition = "TSAbstractMethodDefinition", + TSAbstractPropertyDefinition = "TSAbstractPropertyDefinition", + TSAnyKeyword = "TSAnyKeyword", + TSArrayType = "TSArrayType", + TSAsExpression = "TSAsExpression", + TSAsyncKeyword = "TSAsyncKeyword", + TSBigIntKeyword = "TSBigIntKeyword", + TSBooleanKeyword = "TSBooleanKeyword", + TSCallSignatureDeclaration = "TSCallSignatureDeclaration", + TSClassImplements = "TSClassImplements", + TSConditionalType = "TSConditionalType", + TSConstructorType = "TSConstructorType", + TSConstructSignatureDeclaration = "TSConstructSignatureDeclaration", + TSDeclareFunction = "TSDeclareFunction", + TSDeclareKeyword = "TSDeclareKeyword", + TSEmptyBodyFunctionExpression = "TSEmptyBodyFunctionExpression", + TSEnumDeclaration = "TSEnumDeclaration", + TSEnumMember = "TSEnumMember", + TSExportAssignment = "TSExportAssignment", + TSExportKeyword = "TSExportKeyword", + TSExternalModuleReference = "TSExternalModuleReference", + TSFunctionType = "TSFunctionType", + TSImportEqualsDeclaration = "TSImportEqualsDeclaration", + TSImportType = "TSImportType", + TSIndexedAccessType = "TSIndexedAccessType", + TSIndexSignature = "TSIndexSignature", + TSInferType = "TSInferType", + TSInterfaceBody = "TSInterfaceBody", + TSInterfaceDeclaration = "TSInterfaceDeclaration", + TSInterfaceHeritage = "TSInterfaceHeritage", + TSIntersectionType = "TSIntersectionType", + TSIntrinsicKeyword = "TSIntrinsicKeyword", + TSLiteralType = "TSLiteralType", + TSMappedType = "TSMappedType", + TSMethodSignature = "TSMethodSignature", + TSModuleBlock = "TSModuleBlock", + TSModuleDeclaration = "TSModuleDeclaration", + TSNamedTupleMember = "TSNamedTupleMember", + TSNamespaceExportDeclaration = "TSNamespaceExportDeclaration", + TSNeverKeyword = "TSNeverKeyword", + TSNonNullExpression = "TSNonNullExpression", + TSNullKeyword = "TSNullKeyword", + TSNumberKeyword = "TSNumberKeyword", + TSObjectKeyword = "TSObjectKeyword", + TSOptionalType = "TSOptionalType", + TSParameterProperty = "TSParameterProperty", + TSPrivateKeyword = "TSPrivateKeyword", + TSPropertySignature = "TSPropertySignature", + TSProtectedKeyword = "TSProtectedKeyword", + TSPublicKeyword = "TSPublicKeyword", + TSQualifiedName = "TSQualifiedName", + TSReadonlyKeyword = "TSReadonlyKeyword", + TSRestType = "TSRestType", + TSStaticKeyword = "TSStaticKeyword", + TSStringKeyword = "TSStringKeyword", + TSSymbolKeyword = "TSSymbolKeyword", + TSTemplateLiteralType = "TSTemplateLiteralType", + TSThisType = "TSThisType", + TSTupleType = "TSTupleType", + TSTypeAliasDeclaration = "TSTypeAliasDeclaration", + TSTypeAnnotation = "TSTypeAnnotation", + TSTypeAssertion = "TSTypeAssertion", + TSTypeLiteral = "TSTypeLiteral", + TSTypeOperator = "TSTypeOperator", + TSTypeParameter = "TSTypeParameter", + TSTypeParameterDeclaration = "TSTypeParameterDeclaration", + TSTypeParameterInstantiation = "TSTypeParameterInstantiation", + TSTypePredicate = "TSTypePredicate", + TSTypeQuery = "TSTypeQuery", + TSTypeReference = "TSTypeReference", + TSUndefinedKeyword = "TSUndefinedKeyword", + TSUnionType = "TSUnionType", + TSUnknownKeyword = "TSUnknownKeyword", + TSVoidKeyword = "TSVoidKeyword" +} +export declare enum AST_TOKEN_TYPES { + Boolean = "Boolean", + Identifier = "Identifier", + JSXIdentifier = "JSXIdentifier", + JSXText = "JSXText", + Keyword = "Keyword", + Null = "Null", + Numeric = "Numeric", + Punctuator = "Punctuator", + RegularExpression = "RegularExpression", + String = "String", + Template = "Template", + Block = "Block", + Line = "Line" +} +export declare interface AwaitExpression extends BaseNode { + type: AST_NODE_TYPES.AwaitExpression; + argument: AwaitExpression | LeftHandSideExpression | UnaryExpression | UpdateExpression; +} +export declare interface BaseNode extends NodeOrTokenData { + /** + * The parent node of the current node + * + * This is added in the @typescript-eslint/types package as ESLint adds it + * while traversing. + */ + type: AST_NODE_TYPES; +} +declare interface BaseToken extends NodeOrTokenData { + type: AST_TOKEN_TYPES; + value: string; +} +export declare interface BigIntLiteral extends LiteralBase { + value: bigint | null; + bigint: string; +} +export declare interface BinaryExpression extends BaseNode { + type: AST_NODE_TYPES.BinaryExpression; + operator: string; + left: Expression | PrivateIdentifier; + right: Expression; +} +export declare type BindingName = BindingPattern | Identifier; +export declare type BindingPattern = ArrayPattern | ObjectPattern; +export declare interface BlockComment extends BaseToken { + type: AST_TOKEN_TYPES.Block; +} +export declare interface BlockStatement extends BaseNode { + type: AST_NODE_TYPES.BlockStatement; + body: Statement[]; +} +export declare interface BooleanLiteral extends LiteralBase { + value: boolean; + raw: 'false' | 'true'; +} +export declare interface BooleanToken extends BaseToken { + type: AST_TOKEN_TYPES.Boolean; +} +export declare interface BreakStatement extends BaseNode { + type: AST_NODE_TYPES.BreakStatement; + label: Identifier | null; +} +export declare interface CallExpression extends BaseNode { + type: AST_NODE_TYPES.CallExpression; + callee: LeftHandSideExpression; + arguments: CallExpressionArgument[]; + typeParameters?: TSTypeParameterInstantiation; + optional: boolean; +} +export declare type CallExpressionArgument = Expression | SpreadElement; +export declare interface CatchClause extends BaseNode { + type: AST_NODE_TYPES.CatchClause; + param: BindingName | null; + body: BlockStatement; +} +export declare type ChainElement = CallExpression | MemberExpression | TSNonNullExpression; +export declare interface ChainExpression extends BaseNode { + type: AST_NODE_TYPES.ChainExpression; + expression: ChainElement; +} +export declare interface ClassBody extends BaseNode { + type: AST_NODE_TYPES.ClassBody; + body: ClassElement[]; +} +export declare interface ClassDeclaration extends ClassDeclarationBase { + type: AST_NODE_TYPES.ClassDeclaration; +} +declare interface ClassDeclarationBase extends BaseNode { + typeParameters?: TSTypeParameterDeclaration; + superTypeParameters?: TSTypeParameterInstantiation; + id: Identifier | null; + body: ClassBody; + superClass: LeftHandSideExpression | null; + implements?: TSClassImplements[]; + abstract?: boolean; + declare?: boolean; + decorators?: Decorator[]; +} +export declare type ClassElement = MethodDefinition | PropertyDefinition | StaticBlock | TSAbstractMethodDefinition | TSAbstractPropertyDefinition | TSIndexSignature; +export declare interface ClassExpression extends ClassDeclarationBase { + type: AST_NODE_TYPES.ClassExpression; +} +declare interface ClassMethodDefinitionNonComputedNameBase extends MethodDefinitionBase { + key: ClassPropertyNameNonComputed; + computed: false; +} +declare interface ClassPropertyDefinitionNonComputedNameBase extends PropertyDefinitionBase { + key: ClassPropertyNameNonComputed; + computed: false; +} +export declare type ClassPropertyNameNonComputed = PrivateIdentifier | PropertyNameNonComputed; +export declare type Comment = BlockComment | LineComment; +export declare interface ConditionalExpression extends BaseNode { + type: AST_NODE_TYPES.ConditionalExpression; + test: Expression; + consequent: Expression; + alternate: Expression; +} +export declare interface ContinueStatement extends BaseNode { + type: AST_NODE_TYPES.ContinueStatement; + label: Identifier | null; +} +export declare interface DebuggerStatement extends BaseNode { + type: AST_NODE_TYPES.DebuggerStatement; +} +export declare type DeclarationStatement = ClassDeclaration | ClassExpression | ExportAllDeclaration | ExportDefaultDeclaration | ExportNamedDeclaration | FunctionDeclaration | TSDeclareFunction | TSEnumDeclaration | TSImportEqualsDeclaration | TSInterfaceDeclaration | TSModuleDeclaration | TSNamespaceExportDeclaration | TSTypeAliasDeclaration; +export declare interface Decorator extends BaseNode { + type: AST_NODE_TYPES.Decorator; + expression: LeftHandSideExpression; +} +export declare type DestructuringPattern = ArrayPattern | AssignmentPattern | Identifier | MemberExpression | ObjectPattern | RestElement; +export declare interface DoWhileStatement extends BaseNode { + type: AST_NODE_TYPES.DoWhileStatement; + test: Expression; + body: Statement; +} +export declare interface EmptyStatement extends BaseNode { + type: AST_NODE_TYPES.EmptyStatement; +} +export declare type EntityName = Identifier | TSQualifiedName; +export declare interface ExportAllDeclaration extends BaseNode { + type: AST_NODE_TYPES.ExportAllDeclaration; + source: StringLiteral | null; + exportKind: ExportKind; + exported: Identifier | null; + assertions: ImportAttribute[]; +} +declare type ExportAndImportKind = 'type' | 'value'; +export declare type ExportDeclaration = ClassDeclaration | ClassExpression | FunctionDeclaration | TSDeclareFunction | TSEnumDeclaration | TSInterfaceDeclaration | TSModuleDeclaration | TSTypeAliasDeclaration | VariableDeclaration; +export declare interface ExportDefaultDeclaration extends BaseNode { + type: AST_NODE_TYPES.ExportDefaultDeclaration; + declaration: ExportDeclaration | Expression; + exportKind: ExportKind; +} +declare type ExportKind = ExportAndImportKind; +export declare interface ExportNamedDeclaration extends BaseNode { + type: AST_NODE_TYPES.ExportNamedDeclaration; + declaration: ExportDeclaration | null; + specifiers: ExportSpecifier[]; + source: StringLiteral | null; + exportKind: ExportKind; + assertions: ImportAttribute[]; +} +export declare interface ExportSpecifier extends BaseNode { + type: AST_NODE_TYPES.ExportSpecifier; + local: Identifier; + exported: Identifier; + exportKind: ExportKind; +} +export declare type Expression = ArrayExpression | ArrayPattern | ArrowFunctionExpression | AssignmentExpression | AwaitExpression | BinaryExpression | CallExpression | ChainExpression | ClassExpression | ConditionalExpression | FunctionExpression | Identifier | ImportExpression | JSXElement | JSXFragment | LiteralExpression | LogicalExpression | MemberExpression | MetaProperty | NewExpression | ObjectExpression | ObjectPattern | SequenceExpression | Super | TaggedTemplateExpression | TemplateLiteral | ThisExpression | TSAsExpression | TSNonNullExpression | TSTypeAssertion | UnaryExpression | UpdateExpression | YieldExpression; +export declare interface ExpressionStatement extends BaseNode { + type: AST_NODE_TYPES.ExpressionStatement; + expression: Expression; + directive?: string; +} +export declare type ForInitialiser = Expression | VariableDeclaration; +export declare interface ForInStatement extends BaseNode { + type: AST_NODE_TYPES.ForInStatement; + left: ForInitialiser; + right: Expression; + body: Statement; +} +export declare interface ForOfStatement extends BaseNode { + type: AST_NODE_TYPES.ForOfStatement; + left: ForInitialiser; + right: Expression; + body: Statement; + await: boolean; +} +export declare interface ForStatement extends BaseNode { + type: AST_NODE_TYPES.ForStatement; + init: Expression | ForInitialiser | null; + test: Expression | null; + update: Expression | null; + body: Statement; +} +export declare interface FunctionDeclaration extends FunctionDeclarationBase { + type: AST_NODE_TYPES.FunctionDeclaration; + body: BlockStatement; +} +declare interface FunctionDeclarationBase extends BaseNode { + id: Identifier | null; + generator: boolean; + expression: boolean; + async: boolean; + params: Parameter[]; + body?: BlockStatement | null; + returnType?: TSTypeAnnotation; + typeParameters?: TSTypeParameterDeclaration; + declare?: boolean; +} +export declare interface FunctionExpression extends FunctionDeclarationBase { + type: AST_NODE_TYPES.FunctionExpression; + body: BlockStatement; +} +export declare type FunctionLike = ArrowFunctionExpression | FunctionDeclaration | FunctionExpression | TSDeclareFunction | TSEmptyBodyFunctionExpression; +export declare interface Identifier extends BaseNode { + type: AST_NODE_TYPES.Identifier; + name: string; + typeAnnotation?: TSTypeAnnotation; + optional?: boolean; + decorators?: Decorator[]; +} +export declare interface IdentifierToken extends BaseToken { + type: AST_TOKEN_TYPES.Identifier; +} +export declare interface IfStatement extends BaseNode { + type: AST_NODE_TYPES.IfStatement; + test: Expression; + consequent: Statement; + alternate: Statement | null; +} +export declare interface ImportAttribute extends BaseNode { + type: AST_NODE_TYPES.ImportAttribute; + key: Identifier | Literal; + value: Literal; +} +export declare type ImportClause = ImportDefaultSpecifier | ImportNamespaceSpecifier | ImportSpecifier; +export declare interface ImportDeclaration extends BaseNode { + type: AST_NODE_TYPES.ImportDeclaration; + source: StringLiteral; + specifiers: ImportClause[]; + importKind: ImportKind; + assertions: ImportAttribute[]; +} +export declare interface ImportDefaultSpecifier extends BaseNode { + type: AST_NODE_TYPES.ImportDefaultSpecifier; + local: Identifier; +} +export declare interface ImportExpression extends BaseNode { + type: AST_NODE_TYPES.ImportExpression; + source: Expression; + attributes: Expression | null; +} +declare type ImportKind = ExportAndImportKind; +export declare interface ImportNamespaceSpecifier extends BaseNode { + type: AST_NODE_TYPES.ImportNamespaceSpecifier; + local: Identifier; +} +export declare interface ImportSpecifier extends BaseNode { + type: AST_NODE_TYPES.ImportSpecifier; + local: Identifier; + imported: Identifier; + importKind: ImportKind; +} +export declare type IterationStatement = DoWhileStatement | ForInStatement | ForOfStatement | ForStatement | WhileStatement; +export declare interface JSXAttribute extends BaseNode { + type: AST_NODE_TYPES.JSXAttribute; + name: JSXIdentifier | JSXNamespacedName; + value: JSXExpression | Literal | null; +} +export declare type JSXChild = JSXElement | JSXExpression | JSXFragment | JSXText; +export declare interface JSXClosingElement extends BaseNode { + type: AST_NODE_TYPES.JSXClosingElement; + name: JSXTagNameExpression; +} +export declare interface JSXClosingFragment extends BaseNode { + type: AST_NODE_TYPES.JSXClosingFragment; +} +export declare interface JSXElement extends BaseNode { + type: AST_NODE_TYPES.JSXElement; + openingElement: JSXOpeningElement; + closingElement: JSXClosingElement | null; + children: JSXChild[]; +} +export declare interface JSXEmptyExpression extends BaseNode { + type: AST_NODE_TYPES.JSXEmptyExpression; +} +export declare type JSXExpression = JSXEmptyExpression | JSXExpressionContainer | JSXSpreadChild; +export declare interface JSXExpressionContainer extends BaseNode { + type: AST_NODE_TYPES.JSXExpressionContainer; + expression: Expression | JSXEmptyExpression; +} +export declare interface JSXFragment extends BaseNode { + type: AST_NODE_TYPES.JSXFragment; + openingFragment: JSXOpeningFragment; + closingFragment: JSXClosingFragment; + children: JSXChild[]; +} +export declare interface JSXIdentifier extends BaseNode { + type: AST_NODE_TYPES.JSXIdentifier; + name: string; +} +export declare interface JSXIdentifierToken extends BaseToken { + type: AST_TOKEN_TYPES.JSXIdentifier; +} +export declare interface JSXMemberExpression extends BaseNode { + type: AST_NODE_TYPES.JSXMemberExpression; + object: JSXTagNameExpression; + property: JSXIdentifier; +} +export declare interface JSXNamespacedName extends BaseNode { + type: AST_NODE_TYPES.JSXNamespacedName; + namespace: JSXIdentifier; + name: JSXIdentifier; +} +export declare interface JSXOpeningElement extends BaseNode { + type: AST_NODE_TYPES.JSXOpeningElement; + typeParameters?: TSTypeParameterInstantiation; + selfClosing: boolean; + name: JSXTagNameExpression; + attributes: (JSXAttribute | JSXSpreadAttribute)[]; +} +export declare interface JSXOpeningFragment extends BaseNode { + type: AST_NODE_TYPES.JSXOpeningFragment; +} +export declare interface JSXSpreadAttribute extends BaseNode { + type: AST_NODE_TYPES.JSXSpreadAttribute; + argument: Expression; +} +export declare interface JSXSpreadChild extends BaseNode { + type: AST_NODE_TYPES.JSXSpreadChild; + expression: Expression | JSXEmptyExpression; +} +export declare type JSXTagNameExpression = JSXIdentifier | JSXMemberExpression | JSXNamespacedName; +export declare interface JSXText extends BaseNode { + type: AST_NODE_TYPES.JSXText; + value: string; + raw: string; +} +export declare interface JSXTextToken extends BaseToken { + type: AST_TOKEN_TYPES.JSXText; +} +export declare interface KeywordToken extends BaseToken { + type: AST_TOKEN_TYPES.Keyword; +} +export declare interface LabeledStatement extends BaseNode { + type: AST_NODE_TYPES.LabeledStatement; + label: Identifier; + body: Statement; +} +export declare type LeftHandSideExpression = ArrayExpression | ArrayPattern | ArrowFunctionExpression | CallExpression | ClassExpression | FunctionExpression | Identifier | JSXElement | JSXFragment | LiteralExpression | MemberExpression | MetaProperty | ObjectExpression | ObjectPattern | SequenceExpression | Super | TaggedTemplateExpression | ThisExpression | TSAsExpression | TSNonNullExpression | TSTypeAssertion; +export declare interface LineComment extends BaseToken { + type: AST_TOKEN_TYPES.Line; +} +export declare type Literal = BigIntLiteral | BooleanLiteral | NullLiteral | NumberLiteral | RegExpLiteral | StringLiteral; +declare interface LiteralBase extends BaseNode { + type: AST_NODE_TYPES.Literal; + raw: string; + value: RegExp | bigint | boolean | number | string | null; +} +export declare type LiteralExpression = Literal | TemplateLiteral; +export declare interface LogicalExpression extends BaseNode { + type: AST_NODE_TYPES.LogicalExpression; + operator: '??' | '&&' | '||'; + left: Expression; + right: Expression; +} +export declare type MemberExpression = MemberExpressionComputedName | MemberExpressionNonComputedName; +declare interface MemberExpressionBase extends BaseNode { + object: LeftHandSideExpression; + property: Expression | Identifier | PrivateIdentifier; + computed: boolean; + optional: boolean; +} +export declare interface MemberExpressionComputedName extends MemberExpressionBase { + type: AST_NODE_TYPES.MemberExpression; + property: Expression; + computed: true; +} +export declare interface MemberExpressionNonComputedName extends MemberExpressionBase { + type: AST_NODE_TYPES.MemberExpression; + property: Identifier | PrivateIdentifier; + computed: false; +} +export declare interface MetaProperty extends BaseNode { + type: AST_NODE_TYPES.MetaProperty; + meta: Identifier; + property: Identifier; +} +export declare type MethodDefinition = MethodDefinitionComputedName | MethodDefinitionNonComputedName; +/** this should not be directly used - instead use MethodDefinitionComputedNameBase or MethodDefinitionNonComputedNameBase */ +declare interface MethodDefinitionBase extends BaseNode { + key: PropertyName; + value: FunctionExpression | TSEmptyBodyFunctionExpression; + computed: boolean; + static: boolean; + kind: 'constructor' | 'get' | 'method' | 'set'; + optional?: boolean; + decorators?: Decorator[]; + accessibility?: Accessibility; + typeParameters?: TSTypeParameterDeclaration; + override?: boolean; +} +export declare interface MethodDefinitionComputedName extends MethodDefinitionComputedNameBase { + type: AST_NODE_TYPES.MethodDefinition; +} +declare interface MethodDefinitionComputedNameBase extends MethodDefinitionBase { + key: PropertyNameComputed; + computed: true; +} +export declare interface MethodDefinitionNonComputedName extends ClassMethodDefinitionNonComputedNameBase { + type: AST_NODE_TYPES.MethodDefinition; +} +declare interface MethodDefinitionNonComputedNameBase extends MethodDefinitionBase { + key: PropertyNameNonComputed; + computed: false; +} +export declare type Modifier = TSAbstractKeyword | TSAsyncKeyword | TSPrivateKeyword | TSProtectedKeyword | TSPublicKeyword | TSReadonlyKeyword | TSStaticKeyword; +export declare interface NewExpression extends BaseNode { + type: AST_NODE_TYPES.NewExpression; + callee: LeftHandSideExpression; + arguments: Expression[]; + typeParameters?: TSTypeParameterInstantiation; +} +export declare type Node = ArrayExpression | ArrayPattern | ArrowFunctionExpression | AssignmentExpression | AssignmentPattern | AwaitExpression | BinaryExpression | BlockStatement | BreakStatement | CallExpression | CatchClause | ChainExpression | ClassBody | ClassDeclaration | ClassExpression | ConditionalExpression | ContinueStatement | DebuggerStatement | Decorator | DoWhileStatement | EmptyStatement | ExportAllDeclaration | ExportDefaultDeclaration | ExportNamedDeclaration | ExportSpecifier | ExpressionStatement | ForInStatement | ForOfStatement | ForStatement | FunctionDeclaration | FunctionExpression | Identifier | IfStatement | ImportAttribute | ImportDeclaration | ImportDefaultSpecifier | ImportExpression | ImportNamespaceSpecifier | ImportSpecifier | JSXAttribute | JSXClosingElement | JSXClosingFragment | JSXElement | JSXEmptyExpression | JSXExpressionContainer | JSXFragment | JSXIdentifier | JSXMemberExpression | JSXNamespacedName | JSXOpeningElement | JSXOpeningFragment | JSXSpreadAttribute | JSXSpreadChild | JSXText | LabeledStatement | Literal | LogicalExpression | MemberExpression | MetaProperty | MethodDefinition | NewExpression | ObjectExpression | ObjectPattern | PrivateIdentifier | Program | Property | PropertyDefinition | RestElement | ReturnStatement | SequenceExpression | SpreadElement | StaticBlock | Super | SwitchCase | SwitchStatement | TaggedTemplateExpression | TemplateElement | TemplateLiteral | ThisExpression | ThrowStatement | TryStatement | TSAbstractKeyword | TSAbstractMethodDefinition | TSAbstractPropertyDefinition | TSAnyKeyword | TSArrayType | TSAsExpression | TSAsyncKeyword | TSBigIntKeyword | TSBooleanKeyword | TSCallSignatureDeclaration | TSClassImplements | TSConditionalType | TSConstructorType | TSConstructSignatureDeclaration | TSDeclareFunction | TSDeclareKeyword | TSEmptyBodyFunctionExpression | TSEnumDeclaration | TSEnumMember | TSExportAssignment | TSExportKeyword | TSExternalModuleReference | TSFunctionType | TSImportEqualsDeclaration | TSImportType | TSIndexedAccessType | TSIndexSignature | TSInferType | TSInterfaceBody | TSInterfaceDeclaration | TSInterfaceHeritage | TSIntersectionType | TSIntrinsicKeyword | TSLiteralType | TSMappedType | TSMethodSignature | TSModuleBlock | TSModuleDeclaration | TSNamedTupleMember | TSNamespaceExportDeclaration | TSNeverKeyword | TSNonNullExpression | TSNullKeyword | TSNumberKeyword | TSObjectKeyword | TSOptionalType | TSParameterProperty | TSPrivateKeyword | TSPropertySignature | TSProtectedKeyword | TSPublicKeyword | TSQualifiedName | TSReadonlyKeyword | TSRestType | TSStaticKeyword | TSStringKeyword | TSSymbolKeyword | TSTemplateLiteralType | TSThisType | TSTupleType | TSTypeAliasDeclaration | TSTypeAnnotation | TSTypeAssertion | TSTypeLiteral | TSTypeOperator | TSTypeParameter | TSTypeParameterDeclaration | TSTypeParameterInstantiation | TSTypePredicate | TSTypeQuery | TSTypeReference | TSUndefinedKeyword | TSUnionType | TSUnknownKeyword | TSVoidKeyword | UnaryExpression | UpdateExpression | VariableDeclaration | VariableDeclarator | WhileStatement | WithStatement | YieldExpression; +declare interface NodeOrTokenData { + /** + * The source location information of the node. + * + * The loc property is defined as nullable by ESTree, but ESLint requires this property. + * + * @see {SourceLocation} + */ + loc: SourceLocation; + /** + * @see {Range} + */ + range: Range; + type: string; +} +export declare interface NullLiteral extends LiteralBase { + value: null; + raw: 'null'; +} +export declare interface NullToken extends BaseToken { + type: AST_TOKEN_TYPES.Null; +} +export declare interface NumberLiteral extends LiteralBase { + value: number; +} +export declare interface NumericToken extends BaseToken { + type: AST_TOKEN_TYPES.Numeric; +} +export declare interface ObjectExpression extends BaseNode { + type: AST_NODE_TYPES.ObjectExpression; + properties: ObjectLiteralElement[]; +} +export declare type ObjectLiteralElement = MethodDefinition | Property | SpreadElement; +export declare type ObjectLiteralElementLike = ObjectLiteralElement; +export declare interface ObjectPattern extends BaseNode { + type: AST_NODE_TYPES.ObjectPattern; + properties: (Property | RestElement)[]; + typeAnnotation?: TSTypeAnnotation; + optional?: boolean; + decorators?: Decorator[]; +} +export declare type OptionalRangeAndLoc = Pick> & { + range?: Range; + loc?: SourceLocation; +}; +export declare type Parameter = ArrayPattern | AssignmentPattern | Identifier | ObjectPattern | RestElement | TSParameterProperty; +export declare interface Position { + /** + * Line number (1-indexed) + */ + line: number; + /** + * Column number on the line (0-indexed) + */ + column: number; +} +export declare type PrimaryExpression = ArrayExpression | ArrayPattern | ClassExpression | FunctionExpression | Identifier | JSXElement | JSXFragment | JSXOpeningElement | LiteralExpression | MetaProperty | ObjectExpression | ObjectPattern | Super | TemplateLiteral | ThisExpression | TSNullKeyword; +export declare interface PrivateIdentifier extends BaseNode { + type: AST_NODE_TYPES.PrivateIdentifier; + name: string; +} +export declare interface Program extends BaseNode { + type: AST_NODE_TYPES.Program; + body: ProgramStatement[]; + sourceType: 'module' | 'script'; + comments?: Comment[]; + tokens?: Token[]; +} +export declare type ProgramStatement = ExportAllDeclaration | ExportDefaultDeclaration | ExportNamedDeclaration | ImportDeclaration | Statement | TSImportEqualsDeclaration | TSNamespaceExportDeclaration; +export declare type Property = PropertyComputedName | PropertyNonComputedName; +declare interface PropertyBase extends BaseNode { + type: AST_NODE_TYPES.Property; + key: PropertyName; + value: AssignmentPattern | BindingName | Expression | TSEmptyBodyFunctionExpression; + computed: boolean; + method: boolean; + shorthand: boolean; + optional?: boolean; + kind: 'get' | 'init' | 'set'; +} +export declare interface PropertyComputedName extends PropertyBase { + key: PropertyNameComputed; + computed: true; +} +export declare type PropertyDefinition = PropertyDefinitionComputedName | PropertyDefinitionNonComputedName; +declare interface PropertyDefinitionBase extends BaseNode { + key: PropertyName; + value: Expression | null; + computed: boolean; + static: boolean; + declare: boolean; + readonly?: boolean; + decorators?: Decorator[]; + accessibility?: Accessibility; + optional?: boolean; + definite?: boolean; + typeAnnotation?: TSTypeAnnotation; + override?: boolean; +} +export declare interface PropertyDefinitionComputedName extends PropertyDefinitionComputedNameBase { + type: AST_NODE_TYPES.PropertyDefinition; +} +declare interface PropertyDefinitionComputedNameBase extends PropertyDefinitionBase { + key: PropertyNameComputed; + computed: true; +} +export declare interface PropertyDefinitionNonComputedName extends ClassPropertyDefinitionNonComputedNameBase { + type: AST_NODE_TYPES.PropertyDefinition; +} +declare interface PropertyDefinitionNonComputedNameBase extends PropertyDefinitionBase { + key: PropertyNameNonComputed; + computed: false; +} +export declare type PropertyName = ClassPropertyNameNonComputed | PropertyNameComputed | PropertyNameNonComputed; +export declare type PropertyNameComputed = Expression; +export declare type PropertyNameNonComputed = Identifier | NumberLiteral | StringLiteral; +export declare interface PropertyNonComputedName extends PropertyBase { + key: PropertyNameNonComputed; + computed: false; +} +export declare interface PunctuatorToken extends BaseToken { + type: AST_TOKEN_TYPES.Punctuator; + value: ValueOf; +} +export declare interface PunctuatorTokenToText { + [SyntaxKind.OpenBraceToken]: '{'; + [SyntaxKind.CloseBraceToken]: '}'; + [SyntaxKind.OpenParenToken]: '('; + [SyntaxKind.CloseParenToken]: ')'; + [SyntaxKind.OpenBracketToken]: '['; + [SyntaxKind.CloseBracketToken]: ']'; + [SyntaxKind.DotToken]: '.'; + [SyntaxKind.DotDotDotToken]: '...'; + [SyntaxKind.SemicolonToken]: ';'; + [SyntaxKind.CommaToken]: ','; + [SyntaxKind.QuestionDotToken]: '?.'; + [SyntaxKind.LessThanToken]: '<'; + [SyntaxKind.LessThanSlashToken]: ''; + [SyntaxKind.LessThanEqualsToken]: '<='; + [SyntaxKind.GreaterThanEqualsToken]: '>='; + [SyntaxKind.EqualsEqualsToken]: '=='; + [SyntaxKind.ExclamationEqualsToken]: '!='; + [SyntaxKind.EqualsEqualsEqualsToken]: '==='; + [SyntaxKind.ExclamationEqualsEqualsToken]: '!=='; + [SyntaxKind.EqualsGreaterThanToken]: '=>'; + [SyntaxKind.PlusToken]: '+'; + [SyntaxKind.MinusToken]: '-'; + [SyntaxKind.AsteriskToken]: '*'; + [SyntaxKind.AsteriskAsteriskToken]: '**'; + [SyntaxKind.SlashToken]: '/'; + [SyntaxKind.PercentToken]: '%'; + [SyntaxKind.PlusPlusToken]: '++'; + [SyntaxKind.MinusMinusToken]: '--'; + [SyntaxKind.LessThanLessThanToken]: '<<'; + [SyntaxKind.GreaterThanGreaterThanToken]: '>>'; + [SyntaxKind.GreaterThanGreaterThanGreaterThanToken]: '>>>'; + [SyntaxKind.AmpersandToken]: '&'; + [SyntaxKind.BarToken]: '|'; + [SyntaxKind.CaretToken]: '^'; + [SyntaxKind.ExclamationToken]: '!'; + [SyntaxKind.TildeToken]: '~'; + [SyntaxKind.AmpersandAmpersandToken]: '&&'; + [SyntaxKind.BarBarToken]: '||'; + [SyntaxKind.QuestionToken]: '?'; + [SyntaxKind.ColonToken]: ':'; + [SyntaxKind.AtToken]: '@'; + [SyntaxKind.QuestionQuestionToken]: '??'; + [SyntaxKind.BacktickToken]: '`'; + [SyntaxKind.HashToken]: '#'; + [SyntaxKind.EqualsToken]: '='; + [SyntaxKind.PlusEqualsToken]: '+='; + [SyntaxKind.MinusEqualsToken]: '-='; + [SyntaxKind.AsteriskEqualsToken]: '*='; + [SyntaxKind.AsteriskAsteriskEqualsToken]: '**='; + [SyntaxKind.SlashEqualsToken]: '/='; + [SyntaxKind.PercentEqualsToken]: '%='; + [SyntaxKind.LessThanLessThanEqualsToken]: '<<='; + [SyntaxKind.GreaterThanGreaterThanEqualsToken]: '>>='; + [SyntaxKind.GreaterThanGreaterThanGreaterThanEqualsToken]: '>>>='; + [SyntaxKind.AmpersandEqualsToken]: '&='; + [SyntaxKind.BarEqualsToken]: '|='; + [SyntaxKind.BarBarEqualsToken]: '||='; + [SyntaxKind.AmpersandAmpersandEqualsToken]: '&&='; + [SyntaxKind.QuestionQuestionEqualsToken]: '??='; + [SyntaxKind.CaretEqualsToken]: '^='; +} +/** + * An array of two numbers. + * Both numbers are a 0-based index which is the position in the array of source code characters. + * The first is the start position of the node, the second is the end position of the node. + */ +export declare type Range = [number, number]; +export declare interface RegExpLiteral extends LiteralBase { + value: RegExp | null; + regex: { + pattern: string; + flags: string; + }; +} +export declare interface RegularExpressionToken extends BaseToken { + type: AST_TOKEN_TYPES.RegularExpression; + regex: { + pattern: string; + flags: string; + }; +} +export declare interface RestElement extends BaseNode { + type: AST_NODE_TYPES.RestElement; + argument: DestructuringPattern; + typeAnnotation?: TSTypeAnnotation; + optional?: boolean; + value?: AssignmentPattern; + decorators?: Decorator[]; +} +export declare interface ReturnStatement extends BaseNode { + type: AST_NODE_TYPES.ReturnStatement; + argument: Expression | null; +} +export declare interface SequenceExpression extends BaseNode { + type: AST_NODE_TYPES.SequenceExpression; + expressions: Expression[]; +} +export declare interface SourceLocation { + /** + * The position of the first character of the parsed source region + */ + start: Position; + /** + * The position of the first character after the parsed source region + */ + end: Position; +} +export declare interface SpreadElement extends BaseNode { + type: AST_NODE_TYPES.SpreadElement; + argument: Expression; +} +export declare type Statement = BlockStatement | BreakStatement | ClassDeclaration | ContinueStatement | DebuggerStatement | DoWhileStatement | ExportAllDeclaration | ExportDefaultDeclaration | ExportNamedDeclaration | ExpressionStatement | ForInStatement | ForOfStatement | ForStatement | FunctionDeclaration | IfStatement | ImportDeclaration | LabeledStatement | ReturnStatement | SwitchStatement | ThrowStatement | TryStatement | TSDeclareFunction | TSEnumDeclaration | TSExportAssignment | TSImportEqualsDeclaration | TSInterfaceDeclaration | TSModuleDeclaration | TSNamespaceExportDeclaration | TSTypeAliasDeclaration | VariableDeclaration | WhileStatement | WithStatement; +export declare interface StaticBlock extends BaseNode { + type: AST_NODE_TYPES.StaticBlock; + body: Statement[]; +} +export declare interface StringLiteral extends LiteralBase { + value: string; +} +export declare interface StringToken extends BaseToken { + type: AST_TOKEN_TYPES.String; +} +export declare interface Super extends BaseNode { + type: AST_NODE_TYPES.Super; +} +export declare interface SwitchCase extends BaseNode { + type: AST_NODE_TYPES.SwitchCase; + test: Expression | null; + consequent: Statement[]; +} +export declare interface SwitchStatement extends BaseNode { + type: AST_NODE_TYPES.SwitchStatement; + discriminant: Expression; + cases: SwitchCase[]; +} +export declare interface TaggedTemplateExpression extends BaseNode { + type: AST_NODE_TYPES.TaggedTemplateExpression; + typeParameters?: TSTypeParameterInstantiation; + tag: LeftHandSideExpression; + quasi: TemplateLiteral; +} +export declare interface TemplateElement extends BaseNode { + type: AST_NODE_TYPES.TemplateElement; + value: { + raw: string; + cooked: string; + }; + tail: boolean; +} +export declare interface TemplateLiteral extends BaseNode { + type: AST_NODE_TYPES.TemplateLiteral; + quasis: TemplateElement[]; + expressions: Expression[]; +} +export declare interface TemplateToken extends BaseToken { + type: AST_TOKEN_TYPES.Template; +} +export declare interface ThisExpression extends BaseNode { + type: AST_NODE_TYPES.ThisExpression; +} +export declare interface ThrowStatement extends BaseNode { + type: AST_NODE_TYPES.ThrowStatement; + argument: Statement | TSAsExpression | null; +} +export declare type Token = BooleanToken | Comment | IdentifierToken | JSXIdentifierToken | JSXTextToken | KeywordToken | NullToken | NumericToken | PunctuatorToken | RegularExpressionToken | StringToken | TemplateToken; +export declare interface TryStatement extends BaseNode { + type: AST_NODE_TYPES.TryStatement; + block: BlockStatement; + handler: CatchClause | null; + finalizer: BlockStatement | null; +} +export declare interface TSAbstractKeyword extends BaseNode { + type: AST_NODE_TYPES.TSAbstractKeyword; +} +export declare type TSAbstractMethodDefinition = TSAbstractMethodDefinitionComputedName | TSAbstractMethodDefinitionNonComputedName; +export declare interface TSAbstractMethodDefinitionComputedName extends MethodDefinitionComputedNameBase { + type: AST_NODE_TYPES.TSAbstractMethodDefinition; +} +export declare interface TSAbstractMethodDefinitionNonComputedName extends MethodDefinitionNonComputedNameBase { + type: AST_NODE_TYPES.TSAbstractMethodDefinition; +} +export declare type TSAbstractPropertyDefinition = TSAbstractPropertyDefinitionComputedName | TSAbstractPropertyDefinitionNonComputedName; +export declare interface TSAbstractPropertyDefinitionComputedName extends PropertyDefinitionComputedNameBase { + type: AST_NODE_TYPES.TSAbstractPropertyDefinition; + value: null; +} +export declare interface TSAbstractPropertyDefinitionNonComputedName extends PropertyDefinitionNonComputedNameBase { + type: AST_NODE_TYPES.TSAbstractPropertyDefinition; + value: null; +} +export declare interface TSAnyKeyword extends BaseNode { + type: AST_NODE_TYPES.TSAnyKeyword; +} +export declare interface TSArrayType extends BaseNode { + type: AST_NODE_TYPES.TSArrayType; + elementType: TypeNode; +} +export declare interface TSAsExpression extends BaseNode { + type: AST_NODE_TYPES.TSAsExpression; + expression: Expression; + typeAnnotation: TypeNode; +} +export declare interface TSAsyncKeyword extends BaseNode { + type: AST_NODE_TYPES.TSAsyncKeyword; +} +export declare interface TSBigIntKeyword extends BaseNode { + type: AST_NODE_TYPES.TSBigIntKeyword; +} +export declare interface TSBooleanKeyword extends BaseNode { + type: AST_NODE_TYPES.TSBooleanKeyword; +} +export declare interface TSCallSignatureDeclaration extends TSFunctionSignatureBase { + type: AST_NODE_TYPES.TSCallSignatureDeclaration; +} +export declare interface TSClassImplements extends TSHeritageBase { + type: AST_NODE_TYPES.TSClassImplements; +} +export declare interface TSConditionalType extends BaseNode { + type: AST_NODE_TYPES.TSConditionalType; + checkType: TypeNode; + extendsType: TypeNode; + trueType: TypeNode; + falseType: TypeNode; +} +export declare interface TSConstructorType extends TSFunctionSignatureBase { + type: AST_NODE_TYPES.TSConstructorType; + abstract: boolean; +} +export declare interface TSConstructSignatureDeclaration extends TSFunctionSignatureBase { + type: AST_NODE_TYPES.TSConstructSignatureDeclaration; +} +export declare interface TSDeclareFunction extends FunctionDeclarationBase { + type: AST_NODE_TYPES.TSDeclareFunction; +} +export declare interface TSDeclareKeyword extends BaseNode { + type: AST_NODE_TYPES.TSDeclareKeyword; +} +export declare interface TSEmptyBodyFunctionExpression extends FunctionDeclarationBase { + type: AST_NODE_TYPES.TSEmptyBodyFunctionExpression; + body: null; +} +export declare interface TSEnumDeclaration extends BaseNode { + type: AST_NODE_TYPES.TSEnumDeclaration; + id: Identifier; + members: TSEnumMember[]; + const?: boolean; + declare?: boolean; + modifiers?: Modifier[]; +} +export declare type TSEnumMember = TSEnumMemberComputedName | TSEnumMemberNonComputedName; +declare interface TSEnumMemberBase extends BaseNode { + type: AST_NODE_TYPES.TSEnumMember; + id: PropertyNameComputed | PropertyNameNonComputed; + initializer?: Expression; + computed?: boolean; +} +/** + * this should only really happen in semantically invalid code (errors 1164 and 2452) + * + * VALID: + * enum Foo { ['a'] } + * + * INVALID: + * const x = 'a'; + * enum Foo { [x] } + * enum Bar { ['a' + 'b'] } + */ +export declare interface TSEnumMemberComputedName extends TSEnumMemberBase { + id: PropertyNameComputed; + computed: true; +} +export declare interface TSEnumMemberNonComputedName extends TSEnumMemberBase { + id: PropertyNameNonComputed; + computed?: false; +} +export declare interface TSExportAssignment extends BaseNode { + type: AST_NODE_TYPES.TSExportAssignment; + expression: Expression; +} +export declare interface TSExportKeyword extends BaseNode { + type: AST_NODE_TYPES.TSExportKeyword; +} +export declare interface TSExternalModuleReference extends BaseNode { + type: AST_NODE_TYPES.TSExternalModuleReference; + expression: Expression; +} +declare interface TSFunctionSignatureBase extends BaseNode { + params: Parameter[]; + returnType?: TSTypeAnnotation; + typeParameters?: TSTypeParameterDeclaration; +} +export declare interface TSFunctionType extends TSFunctionSignatureBase { + type: AST_NODE_TYPES.TSFunctionType; +} +declare interface TSHeritageBase extends BaseNode { + expression: Expression; + typeParameters?: TSTypeParameterInstantiation; +} +export declare interface TSImportEqualsDeclaration extends BaseNode { + type: AST_NODE_TYPES.TSImportEqualsDeclaration; + id: Identifier; + moduleReference: EntityName | TSExternalModuleReference; + importKind: ImportKind; + isExport: boolean; +} +export declare interface TSImportType extends BaseNode { + type: AST_NODE_TYPES.TSImportType; + isTypeOf: boolean; + parameter: TypeNode; + qualifier: EntityName | null; + typeParameters: TSTypeParameterInstantiation | null; +} +export declare interface TSIndexedAccessType extends BaseNode { + type: AST_NODE_TYPES.TSIndexedAccessType; + objectType: TypeNode; + indexType: TypeNode; +} +export declare interface TSIndexSignature extends BaseNode { + type: AST_NODE_TYPES.TSIndexSignature; + parameters: Parameter[]; + typeAnnotation?: TSTypeAnnotation; + readonly?: boolean; + accessibility?: Accessibility; + export?: boolean; + static?: boolean; +} +export declare interface TSInferType extends BaseNode { + type: AST_NODE_TYPES.TSInferType; + typeParameter: TSTypeParameter; +} +export declare interface TSInterfaceBody extends BaseNode { + type: AST_NODE_TYPES.TSInterfaceBody; + body: TypeElement[]; +} +export declare interface TSInterfaceDeclaration extends BaseNode { + type: AST_NODE_TYPES.TSInterfaceDeclaration; + body: TSInterfaceBody; + id: Identifier; + typeParameters?: TSTypeParameterDeclaration; + extends?: TSInterfaceHeritage[]; + implements?: TSInterfaceHeritage[]; + abstract?: boolean; + declare?: boolean; +} +export declare interface TSInterfaceHeritage extends TSHeritageBase { + type: AST_NODE_TYPES.TSInterfaceHeritage; +} +export declare interface TSIntersectionType extends BaseNode { + type: AST_NODE_TYPES.TSIntersectionType; + types: TypeNode[]; +} +declare interface TSIntrinsicKeyword extends BaseNode { + type: AST_NODE_TYPES.TSIntrinsicKeyword; +} +export declare interface TSLiteralType extends BaseNode { + type: AST_NODE_TYPES.TSLiteralType; + literal: LiteralExpression | UnaryExpression | UpdateExpression; +} +export declare interface TSMappedType extends BaseNode { + type: AST_NODE_TYPES.TSMappedType; + typeParameter: TSTypeParameter; + readonly?: boolean | '-' | '+'; + optional?: boolean | '-' | '+'; + typeAnnotation?: TypeNode; + nameType: TypeNode | null; +} +export declare type TSMethodSignature = TSMethodSignatureComputedName | TSMethodSignatureNonComputedName; +declare interface TSMethodSignatureBase extends BaseNode { + type: AST_NODE_TYPES.TSMethodSignature; + key: PropertyName; + computed: boolean; + params: Parameter[]; + optional?: boolean; + returnType?: TSTypeAnnotation; + readonly?: boolean; + typeParameters?: TSTypeParameterDeclaration; + accessibility?: Accessibility; + export?: boolean; + static?: boolean; + kind: 'get' | 'method' | 'set'; +} +export declare interface TSMethodSignatureComputedName extends TSMethodSignatureBase { + key: PropertyNameComputed; + computed: true; +} +export declare interface TSMethodSignatureNonComputedName extends TSMethodSignatureBase { + key: PropertyNameNonComputed; + computed: false; +} +export declare interface TSModuleBlock extends BaseNode { + type: AST_NODE_TYPES.TSModuleBlock; + body: ProgramStatement[]; +} +export declare interface TSModuleDeclaration extends BaseNode { + type: AST_NODE_TYPES.TSModuleDeclaration; + id: Identifier | Literal; + body?: TSModuleBlock | TSModuleDeclaration; + global?: boolean; + declare?: boolean; + modifiers?: Modifier[]; +} +export declare interface TSNamedTupleMember extends BaseNode { + type: AST_NODE_TYPES.TSNamedTupleMember; + elementType: TypeNode; + label: Identifier; + optional: boolean; +} +export declare interface TSNamespaceExportDeclaration extends BaseNode { + type: AST_NODE_TYPES.TSNamespaceExportDeclaration; + id: Identifier; +} +export declare interface TSNeverKeyword extends BaseNode { + type: AST_NODE_TYPES.TSNeverKeyword; +} +export declare interface TSNonNullExpression extends BaseNode { + type: AST_NODE_TYPES.TSNonNullExpression; + expression: Expression; +} +export declare interface TSNullKeyword extends BaseNode { + type: AST_NODE_TYPES.TSNullKeyword; +} +export declare interface TSNumberKeyword extends BaseNode { + type: AST_NODE_TYPES.TSNumberKeyword; +} +export declare interface TSObjectKeyword extends BaseNode { + type: AST_NODE_TYPES.TSObjectKeyword; +} +export declare interface TSOptionalType extends BaseNode { + type: AST_NODE_TYPES.TSOptionalType; + typeAnnotation: TypeNode; +} +export declare interface TSParameterProperty extends BaseNode { + type: AST_NODE_TYPES.TSParameterProperty; + accessibility?: Accessibility; + readonly?: boolean; + static?: boolean; + export?: boolean; + override?: boolean; + parameter: AssignmentPattern | BindingName | RestElement; + decorators?: Decorator[]; +} +export declare interface TSPrivateKeyword extends BaseNode { + type: AST_NODE_TYPES.TSPrivateKeyword; +} +export declare type TSPropertySignature = TSPropertySignatureComputedName | TSPropertySignatureNonComputedName; +declare interface TSPropertySignatureBase extends BaseNode { + type: AST_NODE_TYPES.TSPropertySignature; + key: PropertyName; + optional?: boolean; + computed: boolean; + typeAnnotation?: TSTypeAnnotation; + initializer?: Expression; + readonly?: boolean; + static?: boolean; + export?: boolean; + accessibility?: Accessibility; +} +export declare interface TSPropertySignatureComputedName extends TSPropertySignatureBase { + key: PropertyNameComputed; + computed: true; +} +export declare interface TSPropertySignatureNonComputedName extends TSPropertySignatureBase { + key: PropertyNameNonComputed; + computed: false; +} +export declare interface TSProtectedKeyword extends BaseNode { + type: AST_NODE_TYPES.TSProtectedKeyword; +} +export declare interface TSPublicKeyword extends BaseNode { + type: AST_NODE_TYPES.TSPublicKeyword; +} +export declare interface TSQualifiedName extends BaseNode { + type: AST_NODE_TYPES.TSQualifiedName; + left: EntityName; + right: Identifier; +} +export declare interface TSReadonlyKeyword extends BaseNode { + type: AST_NODE_TYPES.TSReadonlyKeyword; +} +export declare interface TSRestType extends BaseNode { + type: AST_NODE_TYPES.TSRestType; + typeAnnotation: TypeNode; +} +export declare interface TSStaticKeyword extends BaseNode { + type: AST_NODE_TYPES.TSStaticKeyword; +} +export declare interface TSStringKeyword extends BaseNode { + type: AST_NODE_TYPES.TSStringKeyword; +} +export declare interface TSSymbolKeyword extends BaseNode { + type: AST_NODE_TYPES.TSSymbolKeyword; +} +export declare interface TSTemplateLiteralType extends BaseNode { + type: AST_NODE_TYPES.TSTemplateLiteralType; + quasis: TemplateElement[]; + types: TypeNode[]; +} +export declare interface TSThisType extends BaseNode { + type: AST_NODE_TYPES.TSThisType; +} +export declare interface TSTupleType extends BaseNode { + type: AST_NODE_TYPES.TSTupleType; + elementTypes: TypeNode[]; +} +export declare interface TSTypeAliasDeclaration extends BaseNode { + type: AST_NODE_TYPES.TSTypeAliasDeclaration; + id: Identifier; + typeAnnotation: TypeNode; + declare?: boolean; + typeParameters?: TSTypeParameterDeclaration; +} +export declare interface TSTypeAnnotation extends BaseNode { + type: AST_NODE_TYPES.TSTypeAnnotation; + typeAnnotation: TypeNode; +} +export declare interface TSTypeAssertion extends BaseNode { + type: AST_NODE_TYPES.TSTypeAssertion; + typeAnnotation: TypeNode; + expression: Expression; +} +export declare interface TSTypeLiteral extends BaseNode { + type: AST_NODE_TYPES.TSTypeLiteral; + members: TypeElement[]; +} +export declare interface TSTypeOperator extends BaseNode { + type: AST_NODE_TYPES.TSTypeOperator; + operator: 'keyof' | 'readonly' | 'unique'; + typeAnnotation?: TypeNode; +} +export declare interface TSTypeParameter extends BaseNode { + type: AST_NODE_TYPES.TSTypeParameter; + name: Identifier; + constraint?: TypeNode; + default?: TypeNode; +} +export declare interface TSTypeParameterDeclaration extends BaseNode { + type: AST_NODE_TYPES.TSTypeParameterDeclaration; + params: TSTypeParameter[]; +} +export declare interface TSTypeParameterInstantiation extends BaseNode { + type: AST_NODE_TYPES.TSTypeParameterInstantiation; + params: TypeNode[]; +} +export declare interface TSTypePredicate extends BaseNode { + type: AST_NODE_TYPES.TSTypePredicate; + asserts: boolean; + parameterName: Identifier | TSThisType; + typeAnnotation: TSTypeAnnotation | null; +} +export declare interface TSTypeQuery extends BaseNode { + type: AST_NODE_TYPES.TSTypeQuery; + exprName: EntityName; +} +export declare interface TSTypeReference extends BaseNode { + type: AST_NODE_TYPES.TSTypeReference; + typeName: EntityName; + typeParameters?: TSTypeParameterInstantiation; +} +export declare type TSUnaryExpression = AwaitExpression | LeftHandSideExpression | UnaryExpression | UpdateExpression; +export declare interface TSUndefinedKeyword extends BaseNode { + type: AST_NODE_TYPES.TSUndefinedKeyword; +} +export declare interface TSUnionType extends BaseNode { + type: AST_NODE_TYPES.TSUnionType; + types: TypeNode[]; +} +export declare interface TSUnknownKeyword extends BaseNode { + type: AST_NODE_TYPES.TSUnknownKeyword; +} +export declare interface TSVoidKeyword extends BaseNode { + type: AST_NODE_TYPES.TSVoidKeyword; +} +export declare type TypeElement = TSCallSignatureDeclaration | TSConstructSignatureDeclaration | TSIndexSignature | TSMethodSignature | TSPropertySignature; +export declare type TypeNode = TSAnyKeyword | TSArrayType | TSBigIntKeyword | TSBooleanKeyword | TSConditionalType | TSConstructorType | TSFunctionType | TSImportType | TSIndexedAccessType | TSInferType | TSIntersectionType | TSIntrinsicKeyword | TSLiteralType | TSMappedType | TSNamedTupleMember | TSNeverKeyword | TSNullKeyword | TSNumberKeyword | TSObjectKeyword | TSOptionalType | TSRestType | TSStringKeyword | TSSymbolKeyword | TSTemplateLiteralType | TSThisType | TSTupleType | TSTypeLiteral | TSTypeOperator | TSTypePredicate | TSTypeQuery | TSTypeReference | TSUndefinedKeyword | TSUnionType | TSUnknownKeyword | TSVoidKeyword; +export declare interface UnaryExpression extends UnaryExpressionBase { + type: AST_NODE_TYPES.UnaryExpression; + operator: '-' | '!' | '+' | '~' | 'delete' | 'typeof' | 'void'; +} +declare interface UnaryExpressionBase extends BaseNode { + operator: string; + prefix: boolean; + argument: LeftHandSideExpression | Literal | UnaryExpression; +} +export declare interface UpdateExpression extends UnaryExpressionBase { + type: AST_NODE_TYPES.UpdateExpression; + operator: '--' | '++'; +} +declare type ValueOf = T[keyof T]; +export declare interface VariableDeclaration extends BaseNode { + type: AST_NODE_TYPES.VariableDeclaration; + declarations: VariableDeclarator[]; + kind: 'const' | 'let' | 'var'; + declare?: boolean; +} +export declare interface VariableDeclarator extends BaseNode { + type: AST_NODE_TYPES.VariableDeclarator; + id: BindingName; + init: Expression | null; + definite?: boolean; +} +export declare interface WhileStatement extends BaseNode { + type: AST_NODE_TYPES.WhileStatement; + test: Expression; + body: Statement; +} +export declare interface WithStatement extends BaseNode { + type: AST_NODE_TYPES.WithStatement; + object: Expression; + body: Statement; +} +export declare interface YieldExpression extends BaseNode { + type: AST_NODE_TYPES.YieldExpression; + delegate: boolean; + argument?: Expression; +} +export {}; +//# sourceMappingURL=ast-spec.d.ts.map \ No newline at end of file diff --git a/node_modules/@typescript-eslint/types/dist/generated/ast-spec.d.ts.map b/node_modules/@typescript-eslint/types/dist/generated/ast-spec.d.ts.map new file mode 100644 index 000000000..eed912a27 --- /dev/null +++ b/node_modules/@typescript-eslint/types/dist/generated/ast-spec.d.ts.map @@ -0,0 +1 @@ +{"version":3,"file":"ast-spec.d.ts","sourceRoot":"","sources":["../../src/generated/ast-spec.ts"],"names":[],"mappings":"AAAA;;;;;;;;gDAQgD;AAEhD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAE7C,MAAM,CAAC,OAAO,MAAM,aAAa,GAAG,SAAS,GAAG,WAAW,GAAG,QAAQ,CAAC;AAEvE,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;IACrC,QAAQ,EAAE,UAAU,EAAE,CAAC;CACxB;AAED,MAAM,CAAC,OAAO,WAAW,YAAa,SAAQ,QAAQ;IACpD,IAAI,EAAE,cAAc,CAAC,YAAY,CAAC;IAClC,QAAQ,EAAE,CAAC,oBAAoB,GAAG,IAAI,CAAC,EAAE,CAAC;IAC1C,cAAc,CAAC,EAAE,gBAAgB,CAAC;IAClC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,UAAU,CAAC,EAAE,SAAS,EAAE,CAAC;CAC1B;AAED,MAAM,CAAC,OAAO,WAAW,uBAAwB,SAAQ,QAAQ;IAC/D,IAAI,EAAE,cAAc,CAAC,uBAAuB,CAAC;IAC7C,SAAS,EAAE,OAAO,CAAC;IACnB,EAAE,EAAE,IAAI,CAAC;IACT,MAAM,EAAE,SAAS,EAAE,CAAC;IACpB,IAAI,EAAE,cAAc,GAAG,UAAU,CAAC;IAClC,KAAK,EAAE,OAAO,CAAC;IACf,UAAU,EAAE,OAAO,CAAC;IACpB,UAAU,CAAC,EAAE,gBAAgB,CAAC;IAC9B,cAAc,CAAC,EAAE,0BAA0B,CAAC;CAC7C;AAED,MAAM,CAAC,OAAO,WAAW,oBAAqB,SAAQ,QAAQ;IAC5D,IAAI,EAAE,cAAc,CAAC,oBAAoB,CAAC;IAC1C,QAAQ,EACJ,IAAI,GACJ,KAAK,GACL,KAAK,GACL,IAAI,GACJ,IAAI,GACJ,KAAK,GACL,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,KAAK,GACL,GAAG,GACH,KAAK,GACL,MAAM,GACN,IAAI,GACJ,KAAK,CAAC;IACV,IAAI,EAAE,UAAU,CAAC;IACjB,KAAK,EAAE,UAAU,CAAC;CACnB;AAED,MAAM,CAAC,OAAO,WAAW,iBAAkB,SAAQ,QAAQ;IACzD,IAAI,EAAE,cAAc,CAAC,iBAAiB,CAAC;IACvC,IAAI,EAAE,WAAW,CAAC;IAClB,KAAK,EAAE,UAAU,CAAC;IAClB,cAAc,CAAC,EAAE,gBAAgB,CAAC;IAClC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,UAAU,CAAC,EAAE,SAAS,EAAE,CAAC;CAC1B;AAED,oBAAY,cAAc;IACxB,eAAe,oBAAoB;IACnC,YAAY,iBAAiB;IAC7B,uBAAuB,4BAA4B;IACnD,oBAAoB,yBAAyB;IAC7C,iBAAiB,sBAAsB;IACvC,eAAe,oBAAoB;IACnC,gBAAgB,qBAAqB;IACrC,cAAc,mBAAmB;IACjC,cAAc,mBAAmB;IACjC,cAAc,mBAAmB;IACjC,WAAW,gBAAgB;IAC3B,eAAe,oBAAoB;IACnC,SAAS,cAAc;IACvB,gBAAgB,qBAAqB;IACrC,eAAe,oBAAoB;IACnC,qBAAqB,0BAA0B;IAC/C,iBAAiB,sBAAsB;IACvC,iBAAiB,sBAAsB;IACvC,SAAS,cAAc;IACvB,gBAAgB,qBAAqB;IACrC,cAAc,mBAAmB;IACjC,oBAAoB,yBAAyB;IAC7C,wBAAwB,6BAA6B;IACrD,sBAAsB,2BAA2B;IACjD,eAAe,oBAAoB;IACnC,mBAAmB,wBAAwB;IAC3C,cAAc,mBAAmB;IACjC,cAAc,mBAAmB;IACjC,YAAY,iBAAiB;IAC7B,mBAAmB,wBAAwB;IAC3C,kBAAkB,uBAAuB;IACzC,UAAU,eAAe;IACzB,WAAW,gBAAgB;IAC3B,eAAe,oBAAoB;IACnC,iBAAiB,sBAAsB;IACvC,sBAAsB,2BAA2B;IACjD,gBAAgB,qBAAqB;IACrC,wBAAwB,6BAA6B;IACrD,eAAe,oBAAoB;IACnC,YAAY,iBAAiB;IAC7B,iBAAiB,sBAAsB;IACvC,kBAAkB,uBAAuB;IACzC,UAAU,eAAe;IACzB,kBAAkB,uBAAuB;IACzC,sBAAsB,2BAA2B;IACjD,WAAW,gBAAgB;IAC3B,aAAa,kBAAkB;IAC/B,mBAAmB,wBAAwB;IAC3C,iBAAiB,sBAAsB;IACvC,iBAAiB,sBAAsB;IACvC,kBAAkB,uBAAuB;IACzC,kBAAkB,uBAAuB;IACzC,cAAc,mBAAmB;IACjC,OAAO,YAAY;IACnB,gBAAgB,qBAAqB;IACrC,OAAO,YAAY;IACnB,iBAAiB,sBAAsB;IACvC,gBAAgB,qBAAqB;IACrC,YAAY,iBAAiB;IAC7B,gBAAgB,qBAAqB;IACrC,aAAa,kBAAkB;IAC/B,gBAAgB,qBAAqB;IACrC,aAAa,kBAAkB;IAC/B,iBAAiB,sBAAsB;IACvC,OAAO,YAAY;IACnB,QAAQ,aAAa;IACrB,kBAAkB,uBAAuB;IACzC,WAAW,gBAAgB;IAC3B,eAAe,oBAAoB;IACnC,kBAAkB,uBAAuB;IACzC,aAAa,kBAAkB;IAC/B,WAAW,gBAAgB;IAC3B,KAAK,UAAU;IACf,UAAU,eAAe;IACzB,eAAe,oBAAoB;IACnC,wBAAwB,6BAA6B;IACrD,eAAe,oBAAoB;IACnC,eAAe,oBAAoB;IACnC,cAAc,mBAAmB;IACjC,cAAc,mBAAmB;IACjC,YAAY,iBAAiB;IAC7B,eAAe,oBAAoB;IACnC,gBAAgB,qBAAqB;IACrC,mBAAmB,wBAAwB;IAC3C,kBAAkB,uBAAuB;IACzC,cAAc,mBAAmB;IACjC,aAAa,kBAAkB;IAC/B,eAAe,oBAAoB;IACnC;;OAEG;IACH,iBAAiB,sBAAsB;IACvC,0BAA0B,+BAA+B;IACzD,4BAA4B,iCAAiC;IAC7D,YAAY,iBAAiB;IAC7B,WAAW,gBAAgB;IAC3B,cAAc,mBAAmB;IACjC,cAAc,mBAAmB;IACjC,eAAe,oBAAoB;IACnC,gBAAgB,qBAAqB;IACrC,0BAA0B,+BAA+B;IACzD,iBAAiB,sBAAsB;IACvC,iBAAiB,sBAAsB;IACvC,iBAAiB,sBAAsB;IACvC,+BAA+B,oCAAoC;IACnE,iBAAiB,sBAAsB;IACvC,gBAAgB,qBAAqB;IACrC,6BAA6B,kCAAkC;IAC/D,iBAAiB,sBAAsB;IACvC,YAAY,iBAAiB;IAC7B,kBAAkB,uBAAuB;IACzC,eAAe,oBAAoB;IACnC,yBAAyB,8BAA8B;IACvD,cAAc,mBAAmB;IACjC,yBAAyB,8BAA8B;IACvD,YAAY,iBAAiB;IAC7B,mBAAmB,wBAAwB;IAC3C,gBAAgB,qBAAqB;IACrC,WAAW,gBAAgB;IAC3B,eAAe,oBAAoB;IACnC,sBAAsB,2BAA2B;IACjD,mBAAmB,wBAAwB;IAC3C,kBAAkB,uBAAuB;IACzC,kBAAkB,uBAAuB;IACzC,aAAa,kBAAkB;IAC/B,YAAY,iBAAiB;IAC7B,iBAAiB,sBAAsB;IACvC,aAAa,kBAAkB;IAC/B,mBAAmB,wBAAwB;IAC3C,kBAAkB,uBAAuB;IACzC,4BAA4B,iCAAiC;IAC7D,cAAc,mBAAmB;IACjC,mBAAmB,wBAAwB;IAC3C,aAAa,kBAAkB;IAC/B,eAAe,oBAAoB;IACnC,eAAe,oBAAoB;IACnC,cAAc,mBAAmB;IACjC,mBAAmB,wBAAwB;IAC3C,gBAAgB,qBAAqB;IACrC,mBAAmB,wBAAwB;IAC3C,kBAAkB,uBAAuB;IACzC,eAAe,oBAAoB;IACnC,eAAe,oBAAoB;IACnC,iBAAiB,sBAAsB;IACvC,UAAU,eAAe;IACzB,eAAe,oBAAoB;IACnC,eAAe,oBAAoB;IACnC,eAAe,oBAAoB;IACnC,qBAAqB,0BAA0B;IAC/C,UAAU,eAAe;IACzB,WAAW,gBAAgB;IAC3B,sBAAsB,2BAA2B;IACjD,gBAAgB,qBAAqB;IACrC,eAAe,oBAAoB;IACnC,aAAa,kBAAkB;IAC/B,cAAc,mBAAmB;IACjC,eAAe,oBAAoB;IACnC,0BAA0B,+BAA+B;IACzD,4BAA4B,iCAAiC;IAC7D,eAAe,oBAAoB;IACnC,WAAW,gBAAgB;IAC3B,eAAe,oBAAoB;IACnC,kBAAkB,uBAAuB;IACzC,WAAW,gBAAgB;IAC3B,gBAAgB,qBAAqB;IACrC,aAAa,kBAAkB;CAChC;AAED,oBAAY,eAAe;IACzB,OAAO,YAAY;IACnB,UAAU,eAAe;IACzB,aAAa,kBAAkB;IAC/B,OAAO,YAAY;IACnB,OAAO,YAAY;IACnB,IAAI,SAAS;IACb,OAAO,YAAY;IACnB,UAAU,eAAe;IACzB,iBAAiB,sBAAsB;IACvC,MAAM,WAAW;IACjB,QAAQ,aAAa;IACrB,KAAK,UAAU;IACf,IAAI,SAAS;CACd;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;IACrC,QAAQ,EACJ,eAAe,GACf,sBAAsB,GACtB,eAAe,GACf,gBAAgB,CAAC;CACtB;AAED,MAAM,CAAC,OAAO,WAAW,QAAS,SAAQ,eAAe;IACvD;;;;;OAKG;IACH,IAAI,EAAE,cAAc,CAAC;CACtB;AAED,OAAO,WAAW,SAAU,SAAQ,eAAe;IACjD,IAAI,EAAE,eAAe,CAAC;IACtB,KAAK,EAAE,MAAM,CAAC;CACf;AAED,MAAM,CAAC,OAAO,WAAW,aAAc,SAAQ,WAAW;IACxD,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,WAAW,gBAAiB,SAAQ,QAAQ;IACxD,IAAI,EAAE,cAAc,CAAC,gBAAgB,CAAC;IACtC,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,UAAU,GAAG,iBAAiB,CAAC;IACrC,KAAK,EAAE,UAAU,CAAC;CACnB;AAED,MAAM,CAAC,OAAO,MAAM,WAAW,GAAG,cAAc,GAAG,UAAU,CAAC;AAE9D,MAAM,CAAC,OAAO,MAAM,cAAc,GAAG,YAAY,GAAG,aAAa,CAAC;AAElE,MAAM,CAAC,OAAO,WAAW,YAAa,SAAQ,SAAS;IACrD,IAAI,EAAE,eAAe,CAAC,KAAK,CAAC;CAC7B;AAED,MAAM,CAAC,OAAO,WAAW,cAAe,SAAQ,QAAQ;IACtD,IAAI,EAAE,cAAc,CAAC,cAAc,CAAC;IACpC,IAAI,EAAE,SAAS,EAAE,CAAC;CACnB;AAED,MAAM,CAAC,OAAO,WAAW,cAAe,SAAQ,WAAW;IACzD,KAAK,EAAE,OAAO,CAAC;IACf,GAAG,EAAE,OAAO,GAAG,MAAM,CAAC;CACvB;AAED,MAAM,CAAC,OAAO,WAAW,YAAa,SAAQ,SAAS;IACrD,IAAI,EAAE,eAAe,CAAC,OAAO,CAAC;CAC/B;AAED,MAAM,CAAC,OAAO,WAAW,cAAe,SAAQ,QAAQ;IACtD,IAAI,EAAE,cAAc,CAAC,cAAc,CAAC;IACpC,KAAK,EAAE,UAAU,GAAG,IAAI,CAAC;CAC1B;AAED,MAAM,CAAC,OAAO,WAAW,cAAe,SAAQ,QAAQ;IACtD,IAAI,EAAE,cAAc,CAAC,cAAc,CAAC;IACpC,MAAM,EAAE,sBAAsB,CAAC;IAC/B,SAAS,EAAE,sBAAsB,EAAE,CAAC;IACpC,cAAc,CAAC,EAAE,4BAA4B,CAAC;IAC9C,QAAQ,EAAE,OAAO,CAAC;CACnB;AAED,MAAM,CAAC,OAAO,MAAM,sBAAsB,GAAG,UAAU,GAAG,aAAa,CAAC;AAExE,MAAM,CAAC,OAAO,WAAW,WAAY,SAAQ,QAAQ;IACnD,IAAI,EAAE,cAAc,CAAC,WAAW,CAAC;IACjC,KAAK,EAAE,WAAW,GAAG,IAAI,CAAC;IAC1B,IAAI,EAAE,cAAc,CAAC;CACtB;AAED,MAAM,CAAC,OAAO,MAAM,YAAY,GAC5B,cAAc,GACd,gBAAgB,GAChB,mBAAmB,CAAC;AAExB,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;IACrC,UAAU,EAAE,YAAY,CAAC;CAC1B;AAED,MAAM,CAAC,OAAO,WAAW,SAAU,SAAQ,QAAQ;IACjD,IAAI,EAAE,cAAc,CAAC,SAAS,CAAC;IAC/B,IAAI,EAAE,YAAY,EAAE,CAAC;CACtB;AAED,MAAM,CAAC,OAAO,WAAW,gBAAiB,SAAQ,oBAAoB;IACpE,IAAI,EAAE,cAAc,CAAC,gBAAgB,CAAC;CACvC;AAED,OAAO,WAAW,oBAAqB,SAAQ,QAAQ;IACrD,cAAc,CAAC,EAAE,0BAA0B,CAAC;IAC5C,mBAAmB,CAAC,EAAE,4BAA4B,CAAC;IACnD,EAAE,EAAE,UAAU,GAAG,IAAI,CAAC;IACtB,IAAI,EAAE,SAAS,CAAC;IAChB,UAAU,EAAE,sBAAsB,GAAG,IAAI,CAAC;IAC1C,UAAU,CAAC,EAAE,iBAAiB,EAAE,CAAC;IACjC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,UAAU,CAAC,EAAE,SAAS,EAAE,CAAC;CAC1B;AAED,MAAM,CAAC,OAAO,MAAM,YAAY,GAC5B,gBAAgB,GAChB,kBAAkB,GAClB,WAAW,GACX,0BAA0B,GAC1B,4BAA4B,GAC5B,gBAAgB,CAAC;AAErB,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,oBAAoB;IACnE,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;CACtC;AAED,OAAO,WAAW,wCAChB,SAAQ,oBAAoB;IAC5B,GAAG,EAAE,4BAA4B,CAAC;IAClC,QAAQ,EAAE,KAAK,CAAC;CACjB;AAED,OAAO,WAAW,0CAChB,SAAQ,sBAAsB;IAC9B,GAAG,EAAE,4BAA4B,CAAC;IAClC,QAAQ,EAAE,KAAK,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,MAAM,4BAA4B,GAC5C,iBAAiB,GACjB,uBAAuB,CAAC;AAE5B,MAAM,CAAC,OAAO,MAAM,OAAO,GAAG,YAAY,GAAG,WAAW,CAAC;AAEzD,MAAM,CAAC,OAAO,WAAW,qBAAsB,SAAQ,QAAQ;IAC7D,IAAI,EAAE,cAAc,CAAC,qBAAqB,CAAC;IAC3C,IAAI,EAAE,UAAU,CAAC;IACjB,UAAU,EAAE,UAAU,CAAC;IACvB,SAAS,EAAE,UAAU,CAAC;CACvB;AAED,MAAM,CAAC,OAAO,WAAW,iBAAkB,SAAQ,QAAQ;IACzD,IAAI,EAAE,cAAc,CAAC,iBAAiB,CAAC;IACvC,KAAK,EAAE,UAAU,GAAG,IAAI,CAAC;CAC1B;AAED,MAAM,CAAC,OAAO,WAAW,iBAAkB,SAAQ,QAAQ;IACzD,IAAI,EAAE,cAAc,CAAC,iBAAiB,CAAC;CACxC;AAED,MAAM,CAAC,OAAO,MAAM,oBAAoB,GACpC,gBAAgB,GAChB,eAAe,GACf,oBAAoB,GACpB,wBAAwB,GACxB,sBAAsB,GACtB,mBAAmB,GACnB,iBAAiB,GACjB,iBAAiB,GACjB,yBAAyB,GACzB,sBAAsB,GACtB,mBAAmB,GACnB,4BAA4B,GAC5B,sBAAsB,CAAC;AAE3B,MAAM,CAAC,OAAO,WAAW,SAAU,SAAQ,QAAQ;IACjD,IAAI,EAAE,cAAc,CAAC,SAAS,CAAC;IAC/B,UAAU,EAAE,sBAAsB,CAAC;CACpC;AAED,MAAM,CAAC,OAAO,MAAM,oBAAoB,GACpC,YAAY,GACZ,iBAAiB,GACjB,UAAU,GACV,gBAAgB,GAChB,aAAa,GACb,WAAW,CAAC;AAEhB,MAAM,CAAC,OAAO,WAAW,gBAAiB,SAAQ,QAAQ;IACxD,IAAI,EAAE,cAAc,CAAC,gBAAgB,CAAC;IACtC,IAAI,EAAE,UAAU,CAAC;IACjB,IAAI,EAAE,SAAS,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,WAAW,cAAe,SAAQ,QAAQ;IACtD,IAAI,EAAE,cAAc,CAAC,cAAc,CAAC;CACrC;AAED,MAAM,CAAC,OAAO,MAAM,UAAU,GAAG,UAAU,GAAG,eAAe,CAAC;AAE9D,MAAM,CAAC,OAAO,WAAW,oBAAqB,SAAQ,QAAQ;IAC5D,IAAI,EAAE,cAAc,CAAC,oBAAoB,CAAC;IAC1C,MAAM,EAAE,aAAa,GAAG,IAAI,CAAC;IAC7B,UAAU,EAAE,UAAU,CAAC;IACvB,QAAQ,EAAE,UAAU,GAAG,IAAI,CAAC;IAC5B,UAAU,EAAE,eAAe,EAAE,CAAC;CAC/B;AAED,OAAO,MAAM,mBAAmB,GAAG,MAAM,GAAG,OAAO,CAAC;AAEpD,MAAM,CAAC,OAAO,MAAM,iBAAiB,GACjC,gBAAgB,GAChB,eAAe,GACf,mBAAmB,GACnB,iBAAiB,GACjB,iBAAiB,GACjB,sBAAsB,GACtB,mBAAmB,GACnB,sBAAsB,GACtB,mBAAmB,CAAC;AAExB,MAAM,CAAC,OAAO,WAAW,wBAAyB,SAAQ,QAAQ;IAChE,IAAI,EAAE,cAAc,CAAC,wBAAwB,CAAC;IAC9C,WAAW,EAAE,iBAAiB,GAAG,UAAU,CAAC;IAC5C,UAAU,EAAE,UAAU,CAAC;CACxB;AAED,OAAO,MAAM,UAAU,GAAG,mBAAmB,CAAC;AAE9C,MAAM,CAAC,OAAO,WAAW,sBAAuB,SAAQ,QAAQ;IAC9D,IAAI,EAAE,cAAc,CAAC,sBAAsB,CAAC;IAC5C,WAAW,EAAE,iBAAiB,GAAG,IAAI,CAAC;IACtC,UAAU,EAAE,eAAe,EAAE,CAAC;IAC9B,MAAM,EAAE,aAAa,GAAG,IAAI,CAAC;IAC7B,UAAU,EAAE,UAAU,CAAC;IACvB,UAAU,EAAE,eAAe,EAAE,CAAC;CAC/B;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;IACrC,KAAK,EAAE,UAAU,CAAC;IAClB,QAAQ,EAAE,UAAU,CAAC;IACrB,UAAU,EAAE,UAAU,CAAC;CACxB;AAED,MAAM,CAAC,OAAO,MAAM,UAAU,GAC1B,eAAe,GACf,YAAY,GACZ,uBAAuB,GACvB,oBAAoB,GACpB,eAAe,GACf,gBAAgB,GAChB,cAAc,GACd,eAAe,GACf,eAAe,GACf,qBAAqB,GACrB,kBAAkB,GAClB,UAAU,GACV,gBAAgB,GAChB,UAAU,GACV,WAAW,GACX,iBAAiB,GACjB,iBAAiB,GACjB,gBAAgB,GAChB,YAAY,GACZ,aAAa,GACb,gBAAgB,GAChB,aAAa,GACb,kBAAkB,GAClB,KAAK,GACL,wBAAwB,GACxB,eAAe,GACf,cAAc,GACd,cAAc,GACd,mBAAmB,GACnB,eAAe,GACf,eAAe,GACf,gBAAgB,GAChB,eAAe,CAAC;AAEpB,MAAM,CAAC,OAAO,WAAW,mBAAoB,SAAQ,QAAQ;IAC3D,IAAI,EAAE,cAAc,CAAC,mBAAmB,CAAC;IACzC,UAAU,EAAE,UAAU,CAAC;IACvB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,CAAC,OAAO,MAAM,cAAc,GAAG,UAAU,GAAG,mBAAmB,CAAC;AAEtE,MAAM,CAAC,OAAO,WAAW,cAAe,SAAQ,QAAQ;IACtD,IAAI,EAAE,cAAc,CAAC,cAAc,CAAC;IACpC,IAAI,EAAE,cAAc,CAAC;IACrB,KAAK,EAAE,UAAU,CAAC;IAClB,IAAI,EAAE,SAAS,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,WAAW,cAAe,SAAQ,QAAQ;IACtD,IAAI,EAAE,cAAc,CAAC,cAAc,CAAC;IACpC,IAAI,EAAE,cAAc,CAAC;IACrB,KAAK,EAAE,UAAU,CAAC;IAClB,IAAI,EAAE,SAAS,CAAC;IAChB,KAAK,EAAE,OAAO,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,WAAW,YAAa,SAAQ,QAAQ;IACpD,IAAI,EAAE,cAAc,CAAC,YAAY,CAAC;IAClC,IAAI,EAAE,UAAU,GAAG,cAAc,GAAG,IAAI,CAAC;IACzC,IAAI,EAAE,UAAU,GAAG,IAAI,CAAC;IACxB,MAAM,EAAE,UAAU,GAAG,IAAI,CAAC;IAC1B,IAAI,EAAE,SAAS,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,WAAW,mBAAoB,SAAQ,uBAAuB;IAC1E,IAAI,EAAE,cAAc,CAAC,mBAAmB,CAAC;IACzC,IAAI,EAAE,cAAc,CAAC;CACtB;AAED,OAAO,WAAW,uBAAwB,SAAQ,QAAQ;IACxD,EAAE,EAAE,UAAU,GAAG,IAAI,CAAC;IACtB,SAAS,EAAE,OAAO,CAAC;IACnB,UAAU,EAAE,OAAO,CAAC;IACpB,KAAK,EAAE,OAAO,CAAC;IACf,MAAM,EAAE,SAAS,EAAE,CAAC;IACpB,IAAI,CAAC,EAAE,cAAc,GAAG,IAAI,CAAC;IAC7B,UAAU,CAAC,EAAE,gBAAgB,CAAC;IAC9B,cAAc,CAAC,EAAE,0BAA0B,CAAC;IAC5C,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB;AAED,MAAM,CAAC,OAAO,WAAW,kBAAmB,SAAQ,uBAAuB;IACzE,IAAI,EAAE,cAAc,CAAC,kBAAkB,CAAC;IACxC,IAAI,EAAE,cAAc,CAAC;CACtB;AAED,MAAM,CAAC,OAAO,MAAM,YAAY,GAC5B,uBAAuB,GACvB,mBAAmB,GACnB,kBAAkB,GAClB,iBAAiB,GACjB,6BAA6B,CAAC;AAElC,MAAM,CAAC,OAAO,WAAW,UAAW,SAAQ,QAAQ;IAClD,IAAI,EAAE,cAAc,CAAC,UAAU,CAAC;IAChC,IAAI,EAAE,MAAM,CAAC;IACb,cAAc,CAAC,EAAE,gBAAgB,CAAC;IAClC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,UAAU,CAAC,EAAE,SAAS,EAAE,CAAC;CAC1B;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,SAAS;IACxD,IAAI,EAAE,eAAe,CAAC,UAAU,CAAC;CAClC;AAED,MAAM,CAAC,OAAO,WAAW,WAAY,SAAQ,QAAQ;IACnD,IAAI,EAAE,cAAc,CAAC,WAAW,CAAC;IACjC,IAAI,EAAE,UAAU,CAAC;IACjB,UAAU,EAAE,SAAS,CAAC;IACtB,SAAS,EAAE,SAAS,GAAG,IAAI,CAAC;CAC7B;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;IACrC,GAAG,EAAE,UAAU,GAAG,OAAO,CAAC;IAC1B,KAAK,EAAE,OAAO,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,MAAM,YAAY,GAC5B,sBAAsB,GACtB,wBAAwB,GACxB,eAAe,CAAC;AAEpB,MAAM,CAAC,OAAO,WAAW,iBAAkB,SAAQ,QAAQ;IACzD,IAAI,EAAE,cAAc,CAAC,iBAAiB,CAAC;IACvC,MAAM,EAAE,aAAa,CAAC;IACtB,UAAU,EAAE,YAAY,EAAE,CAAC;IAC3B,UAAU,EAAE,UAAU,CAAC;IACvB,UAAU,EAAE,eAAe,EAAE,CAAC;CAC/B;AAED,MAAM,CAAC,OAAO,WAAW,sBAAuB,SAAQ,QAAQ;IAC9D,IAAI,EAAE,cAAc,CAAC,sBAAsB,CAAC;IAC5C,KAAK,EAAE,UAAU,CAAC;CACnB;AAED,MAAM,CAAC,OAAO,WAAW,gBAAiB,SAAQ,QAAQ;IACxD,IAAI,EAAE,cAAc,CAAC,gBAAgB,CAAC;IACtC,MAAM,EAAE,UAAU,CAAC;IACnB,UAAU,EAAE,UAAU,GAAG,IAAI,CAAC;CAC/B;AAED,OAAO,MAAM,UAAU,GAAG,mBAAmB,CAAC;AAE9C,MAAM,CAAC,OAAO,WAAW,wBAAyB,SAAQ,QAAQ;IAChE,IAAI,EAAE,cAAc,CAAC,wBAAwB,CAAC;IAC9C,KAAK,EAAE,UAAU,CAAC;CACnB;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;IACrC,KAAK,EAAE,UAAU,CAAC;IAClB,QAAQ,EAAE,UAAU,CAAC;IACrB,UAAU,EAAE,UAAU,CAAC;CACxB;AAED,MAAM,CAAC,OAAO,MAAM,kBAAkB,GAClC,gBAAgB,GAChB,cAAc,GACd,cAAc,GACd,YAAY,GACZ,cAAc,CAAC;AAEnB,MAAM,CAAC,OAAO,WAAW,YAAa,SAAQ,QAAQ;IACpD,IAAI,EAAE,cAAc,CAAC,YAAY,CAAC;IAClC,IAAI,EAAE,aAAa,GAAG,iBAAiB,CAAC;IACxC,KAAK,EAAE,aAAa,GAAG,OAAO,GAAG,IAAI,CAAC;CACvC;AAED,MAAM,CAAC,OAAO,MAAM,QAAQ,GACxB,UAAU,GACV,aAAa,GACb,WAAW,GACX,OAAO,CAAC;AAEZ,MAAM,CAAC,OAAO,WAAW,iBAAkB,SAAQ,QAAQ;IACzD,IAAI,EAAE,cAAc,CAAC,iBAAiB,CAAC;IACvC,IAAI,EAAE,oBAAoB,CAAC;CAC5B;AAED,MAAM,CAAC,OAAO,WAAW,kBAAmB,SAAQ,QAAQ;IAC1D,IAAI,EAAE,cAAc,CAAC,kBAAkB,CAAC;CACzC;AAED,MAAM,CAAC,OAAO,WAAW,UAAW,SAAQ,QAAQ;IAClD,IAAI,EAAE,cAAc,CAAC,UAAU,CAAC;IAChC,cAAc,EAAE,iBAAiB,CAAC;IAClC,cAAc,EAAE,iBAAiB,GAAG,IAAI,CAAC;IACzC,QAAQ,EAAE,QAAQ,EAAE,CAAC;CACtB;AAED,MAAM,CAAC,OAAO,WAAW,kBAAmB,SAAQ,QAAQ;IAC1D,IAAI,EAAE,cAAc,CAAC,kBAAkB,CAAC;CACzC;AAED,MAAM,CAAC,OAAO,MAAM,aAAa,GAC7B,kBAAkB,GAClB,sBAAsB,GACtB,cAAc,CAAC;AAEnB,MAAM,CAAC,OAAO,WAAW,sBAAuB,SAAQ,QAAQ;IAC9D,IAAI,EAAE,cAAc,CAAC,sBAAsB,CAAC;IAC5C,UAAU,EAAE,UAAU,GAAG,kBAAkB,CAAC;CAC7C;AAED,MAAM,CAAC,OAAO,WAAW,WAAY,SAAQ,QAAQ;IACnD,IAAI,EAAE,cAAc,CAAC,WAAW,CAAC;IACjC,eAAe,EAAE,kBAAkB,CAAC;IACpC,eAAe,EAAE,kBAAkB,CAAC;IACpC,QAAQ,EAAE,QAAQ,EAAE,CAAC;CACtB;AAED,MAAM,CAAC,OAAO,WAAW,aAAc,SAAQ,QAAQ;IACrD,IAAI,EAAE,cAAc,CAAC,aAAa,CAAC;IACnC,IAAI,EAAE,MAAM,CAAC;CACd;AAED,MAAM,CAAC,OAAO,WAAW,kBAAmB,SAAQ,SAAS;IAC3D,IAAI,EAAE,eAAe,CAAC,aAAa,CAAC;CACrC;AAED,MAAM,CAAC,OAAO,WAAW,mBAAoB,SAAQ,QAAQ;IAC3D,IAAI,EAAE,cAAc,CAAC,mBAAmB,CAAC;IACzC,MAAM,EAAE,oBAAoB,CAAC;IAC7B,QAAQ,EAAE,aAAa,CAAC;CACzB;AAED,MAAM,CAAC,OAAO,WAAW,iBAAkB,SAAQ,QAAQ;IACzD,IAAI,EAAE,cAAc,CAAC,iBAAiB,CAAC;IACvC,SAAS,EAAE,aAAa,CAAC;IACzB,IAAI,EAAE,aAAa,CAAC;CACrB;AAED,MAAM,CAAC,OAAO,WAAW,iBAAkB,SAAQ,QAAQ;IACzD,IAAI,EAAE,cAAc,CAAC,iBAAiB,CAAC;IACvC,cAAc,CAAC,EAAE,4BAA4B,CAAC;IAC9C,WAAW,EAAE,OAAO,CAAC;IACrB,IAAI,EAAE,oBAAoB,CAAC;IAC3B,UAAU,EAAE,CAAC,YAAY,GAAG,kBAAkB,CAAC,EAAE,CAAC;CACnD;AAED,MAAM,CAAC,OAAO,WAAW,kBAAmB,SAAQ,QAAQ;IAC1D,IAAI,EAAE,cAAc,CAAC,kBAAkB,CAAC;CACzC;AAED,MAAM,CAAC,OAAO,WAAW,kBAAmB,SAAQ,QAAQ;IAC1D,IAAI,EAAE,cAAc,CAAC,kBAAkB,CAAC;IACxC,QAAQ,EAAE,UAAU,CAAC;CACtB;AAED,MAAM,CAAC,OAAO,WAAW,cAAe,SAAQ,QAAQ;IACtD,IAAI,EAAE,cAAc,CAAC,cAAc,CAAC;IACpC,UAAU,EAAE,UAAU,GAAG,kBAAkB,CAAC;CAC7C;AAED,MAAM,CAAC,OAAO,MAAM,oBAAoB,GACpC,aAAa,GACb,mBAAmB,GACnB,iBAAiB,CAAC;AAEtB,MAAM,CAAC,OAAO,WAAW,OAAQ,SAAQ,QAAQ;IAC/C,IAAI,EAAE,cAAc,CAAC,OAAO,CAAC;IAC7B,KAAK,EAAE,MAAM,CAAC;IACd,GAAG,EAAE,MAAM,CAAC;CACb;AAED,MAAM,CAAC,OAAO,WAAW,YAAa,SAAQ,SAAS;IACrD,IAAI,EAAE,eAAe,CAAC,OAAO,CAAC;CAC/B;AAED,MAAM,CAAC,OAAO,WAAW,YAAa,SAAQ,SAAS;IACrD,IAAI,EAAE,eAAe,CAAC,OAAO,CAAC;CAC/B;AAED,MAAM,CAAC,OAAO,WAAW,gBAAiB,SAAQ,QAAQ;IACxD,IAAI,EAAE,cAAc,CAAC,gBAAgB,CAAC;IACtC,KAAK,EAAE,UAAU,CAAC;IAClB,IAAI,EAAE,SAAS,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,MAAM,sBAAsB,GACtC,eAAe,GACf,YAAY,GACZ,uBAAuB,GACvB,cAAc,GACd,eAAe,GACf,kBAAkB,GAClB,UAAU,GACV,UAAU,GACV,WAAW,GACX,iBAAiB,GACjB,gBAAgB,GAChB,YAAY,GACZ,gBAAgB,GAChB,aAAa,GACb,kBAAkB,GAClB,KAAK,GACL,wBAAwB,GACxB,cAAc,GACd,cAAc,GACd,mBAAmB,GACnB,eAAe,CAAC;AAEpB,MAAM,CAAC,OAAO,WAAW,WAAY,SAAQ,SAAS;IACpD,IAAI,EAAE,eAAe,CAAC,IAAI,CAAC;CAC5B;AAED,MAAM,CAAC,OAAO,MAAM,OAAO,GACvB,aAAa,GACb,cAAc,GACd,WAAW,GACX,aAAa,GACb,aAAa,GACb,aAAa,CAAC;AAElB,OAAO,WAAW,WAAY,SAAQ,QAAQ;IAC5C,IAAI,EAAE,cAAc,CAAC,OAAO,CAAC;IAC7B,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;CAC3D;AAED,MAAM,CAAC,OAAO,MAAM,iBAAiB,GAAG,OAAO,GAAG,eAAe,CAAC;AAElE,MAAM,CAAC,OAAO,WAAW,iBAAkB,SAAQ,QAAQ;IACzD,IAAI,EAAE,cAAc,CAAC,iBAAiB,CAAC;IACvC,QAAQ,EAAE,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;IAC7B,IAAI,EAAE,UAAU,CAAC;IACjB,KAAK,EAAE,UAAU,CAAC;CACnB;AAED,MAAM,CAAC,OAAO,MAAM,gBAAgB,GAChC,4BAA4B,GAC5B,+BAA+B,CAAC;AAEpC,OAAO,WAAW,oBAAqB,SAAQ,QAAQ;IACrD,MAAM,EAAE,sBAAsB,CAAC;IAC/B,QAAQ,EAAE,UAAU,GAAG,UAAU,GAAG,iBAAiB,CAAC;IACtD,QAAQ,EAAE,OAAO,CAAC;IAClB,QAAQ,EAAE,OAAO,CAAC;CACnB;AAED,MAAM,CAAC,OAAO,WAAW,4BACvB,SAAQ,oBAAoB;IAC5B,IAAI,EAAE,cAAc,CAAC,gBAAgB,CAAC;IACtC,QAAQ,EAAE,UAAU,CAAC;IACrB,QAAQ,EAAE,IAAI,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,WAAW,+BACvB,SAAQ,oBAAoB;IAC5B,IAAI,EAAE,cAAc,CAAC,gBAAgB,CAAC;IACtC,QAAQ,EAAE,UAAU,GAAG,iBAAiB,CAAC;IACzC,QAAQ,EAAE,KAAK,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,WAAW,YAAa,SAAQ,QAAQ;IACpD,IAAI,EAAE,cAAc,CAAC,YAAY,CAAC;IAClC,IAAI,EAAE,UAAU,CAAC;IACjB,QAAQ,EAAE,UAAU,CAAC;CACtB;AAED,MAAM,CAAC,OAAO,MAAM,gBAAgB,GAChC,4BAA4B,GAC5B,+BAA+B,CAAC;AAEpC,6HAA6H;AAC7H,OAAO,WAAW,oBAAqB,SAAQ,QAAQ;IACrD,GAAG,EAAE,YAAY,CAAC;IAClB,KAAK,EAAE,kBAAkB,GAAG,6BAA6B,CAAC;IAC1D,QAAQ,EAAE,OAAO,CAAC;IAClB,MAAM,EAAE,OAAO,CAAC;IAChB,IAAI,EAAE,aAAa,GAAG,KAAK,GAAG,QAAQ,GAAG,KAAK,CAAC;IAC/C,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,UAAU,CAAC,EAAE,SAAS,EAAE,CAAC;IACzB,aAAa,CAAC,EAAE,aAAa,CAAC;IAC9B,cAAc,CAAC,EAAE,0BAA0B,CAAC;IAC5C,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED,MAAM,CAAC,OAAO,WAAW,4BACvB,SAAQ,gCAAgC;IACxC,IAAI,EAAE,cAAc,CAAC,gBAAgB,CAAC;CACvC;AAED,OAAO,WAAW,gCAChB,SAAQ,oBAAoB;IAC5B,GAAG,EAAE,oBAAoB,CAAC;IAC1B,QAAQ,EAAE,IAAI,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,WAAW,+BACvB,SAAQ,wCAAwC;IAChD,IAAI,EAAE,cAAc,CAAC,gBAAgB,CAAC;CACvC;AAED,OAAO,WAAW,mCAChB,SAAQ,oBAAoB;IAC5B,GAAG,EAAE,uBAAuB,CAAC;IAC7B,QAAQ,EAAE,KAAK,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,MAAM,QAAQ,GACxB,iBAAiB,GACjB,cAAc,GACd,gBAAgB,GAChB,kBAAkB,GAClB,eAAe,GACf,iBAAiB,GACjB,eAAe,CAAC;AAEpB,MAAM,CAAC,OAAO,WAAW,aAAc,SAAQ,QAAQ;IACrD,IAAI,EAAE,cAAc,CAAC,aAAa,CAAC;IACnC,MAAM,EAAE,sBAAsB,CAAC;IAC/B,SAAS,EAAE,UAAU,EAAE,CAAC;IACxB,cAAc,CAAC,EAAE,4BAA4B,CAAC;CAC/C;AAED,MAAM,CAAC,OAAO,MAAM,IAAI,GACpB,eAAe,GACf,YAAY,GACZ,uBAAuB,GACvB,oBAAoB,GACpB,iBAAiB,GACjB,eAAe,GACf,gBAAgB,GAChB,cAAc,GACd,cAAc,GACd,cAAc,GACd,WAAW,GACX,eAAe,GACf,SAAS,GACT,gBAAgB,GAChB,eAAe,GACf,qBAAqB,GACrB,iBAAiB,GACjB,iBAAiB,GACjB,SAAS,GACT,gBAAgB,GAChB,cAAc,GACd,oBAAoB,GACpB,wBAAwB,GACxB,sBAAsB,GACtB,eAAe,GACf,mBAAmB,GACnB,cAAc,GACd,cAAc,GACd,YAAY,GACZ,mBAAmB,GACnB,kBAAkB,GAClB,UAAU,GACV,WAAW,GACX,eAAe,GACf,iBAAiB,GACjB,sBAAsB,GACtB,gBAAgB,GAChB,wBAAwB,GACxB,eAAe,GACf,YAAY,GACZ,iBAAiB,GACjB,kBAAkB,GAClB,UAAU,GACV,kBAAkB,GAClB,sBAAsB,GACtB,WAAW,GACX,aAAa,GACb,mBAAmB,GACnB,iBAAiB,GACjB,iBAAiB,GACjB,kBAAkB,GAClB,kBAAkB,GAClB,cAAc,GACd,OAAO,GACP,gBAAgB,GAChB,OAAO,GACP,iBAAiB,GACjB,gBAAgB,GAChB,YAAY,GACZ,gBAAgB,GAChB,aAAa,GACb,gBAAgB,GAChB,aAAa,GACb,iBAAiB,GACjB,OAAO,GACP,QAAQ,GACR,kBAAkB,GAClB,WAAW,GACX,eAAe,GACf,kBAAkB,GAClB,aAAa,GACb,WAAW,GACX,KAAK,GACL,UAAU,GACV,eAAe,GACf,wBAAwB,GACxB,eAAe,GACf,eAAe,GACf,cAAc,GACd,cAAc,GACd,YAAY,GACZ,iBAAiB,GACjB,0BAA0B,GAC1B,4BAA4B,GAC5B,YAAY,GACZ,WAAW,GACX,cAAc,GACd,cAAc,GACd,eAAe,GACf,gBAAgB,GAChB,0BAA0B,GAC1B,iBAAiB,GACjB,iBAAiB,GACjB,iBAAiB,GACjB,+BAA+B,GAC/B,iBAAiB,GACjB,gBAAgB,GAChB,6BAA6B,GAC7B,iBAAiB,GACjB,YAAY,GACZ,kBAAkB,GAClB,eAAe,GACf,yBAAyB,GACzB,cAAc,GACd,yBAAyB,GACzB,YAAY,GACZ,mBAAmB,GACnB,gBAAgB,GAChB,WAAW,GACX,eAAe,GACf,sBAAsB,GACtB,mBAAmB,GACnB,kBAAkB,GAClB,kBAAkB,GAClB,aAAa,GACb,YAAY,GACZ,iBAAiB,GACjB,aAAa,GACb,mBAAmB,GACnB,kBAAkB,GAClB,4BAA4B,GAC5B,cAAc,GACd,mBAAmB,GACnB,aAAa,GACb,eAAe,GACf,eAAe,GACf,cAAc,GACd,mBAAmB,GACnB,gBAAgB,GAChB,mBAAmB,GACnB,kBAAkB,GAClB,eAAe,GACf,eAAe,GACf,iBAAiB,GACjB,UAAU,GACV,eAAe,GACf,eAAe,GACf,eAAe,GACf,qBAAqB,GACrB,UAAU,GACV,WAAW,GACX,sBAAsB,GACtB,gBAAgB,GAChB,eAAe,GACf,aAAa,GACb,cAAc,GACd,eAAe,GACf,0BAA0B,GAC1B,4BAA4B,GAC5B,eAAe,GACf,WAAW,GACX,eAAe,GACf,kBAAkB,GAClB,WAAW,GACX,gBAAgB,GAChB,aAAa,GACb,eAAe,GACf,gBAAgB,GAChB,mBAAmB,GACnB,kBAAkB,GAClB,cAAc,GACd,aAAa,GACb,eAAe,CAAC;AAEpB,OAAO,WAAW,eAAe;IAC/B;;;;;;OAMG;IACH,GAAG,EAAE,cAAc,CAAC;IACpB;;OAEG;IACH,KAAK,EAAE,KAAK,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;CACd;AAED,MAAM,CAAC,OAAO,WAAW,WAAY,SAAQ,WAAW;IACtD,KAAK,EAAE,IAAI,CAAC;IACZ,GAAG,EAAE,MAAM,CAAC;CACb;AAED,MAAM,CAAC,OAAO,WAAW,SAAU,SAAQ,SAAS;IAClD,IAAI,EAAE,eAAe,CAAC,IAAI,CAAC;CAC5B;AAED,MAAM,CAAC,OAAO,WAAW,aAAc,SAAQ,WAAW;IACxD,KAAK,EAAE,MAAM,CAAC;CACf;AAED,MAAM,CAAC,OAAO,WAAW,YAAa,SAAQ,SAAS;IACrD,IAAI,EAAE,eAAe,CAAC,OAAO,CAAC;CAC/B;AAED,MAAM,CAAC,OAAO,WAAW,gBAAiB,SAAQ,QAAQ;IACxD,IAAI,EAAE,cAAc,CAAC,gBAAgB,CAAC;IACtC,UAAU,EAAE,oBAAoB,EAAE,CAAC;CACpC;AAED,MAAM,CAAC,OAAO,MAAM,oBAAoB,GACpC,gBAAgB,GAChB,QAAQ,GACR,aAAa,CAAC;AAElB,MAAM,CAAC,OAAO,MAAM,wBAAwB,GAAG,oBAAoB,CAAC;AAEpE,MAAM,CAAC,OAAO,WAAW,aAAc,SAAQ,QAAQ;IACrD,IAAI,EAAE,cAAc,CAAC,aAAa,CAAC;IACnC,UAAU,EAAE,CAAC,QAAQ,GAAG,WAAW,CAAC,EAAE,CAAC;IACvC,cAAc,CAAC,EAAE,gBAAgB,CAAC;IAClC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,UAAU,CAAC,EAAE,SAAS,EAAE,CAAC;CAC1B;AAED,MAAM,CAAC,OAAO,MAAM,mBAAmB,CAAC,CAAC,IAAI,IAAI,CAC/C,CAAC,EACD,OAAO,CAAC,MAAM,CAAC,EAAE,KAAK,GAAG,OAAO,CAAC,CAClC,GAAG;IACF,KAAK,CAAC,EAAE,KAAK,CAAC;IACd,GAAG,CAAC,EAAE,cAAc,CAAC;CACtB,CAAC;AAEF,MAAM,CAAC,OAAO,MAAM,SAAS,GACzB,YAAY,GACZ,iBAAiB,GACjB,UAAU,GACV,aAAa,GACb,WAAW,GACX,mBAAmB,CAAC;AAExB,MAAM,CAAC,OAAO,WAAW,QAAQ;IAC/B;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;IACb;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,MAAM,iBAAiB,GACjC,eAAe,GACf,YAAY,GACZ,eAAe,GACf,kBAAkB,GAClB,UAAU,GACV,UAAU,GACV,WAAW,GACX,iBAAiB,GACjB,iBAAiB,GACjB,YAAY,GACZ,gBAAgB,GAChB,aAAa,GACb,KAAK,GACL,eAAe,GACf,cAAc,GACd,aAAa,CAAC;AAElB,MAAM,CAAC,OAAO,WAAW,iBAAkB,SAAQ,QAAQ;IACzD,IAAI,EAAE,cAAc,CAAC,iBAAiB,CAAC;IACvC,IAAI,EAAE,MAAM,CAAC;CACd;AAED,MAAM,CAAC,OAAO,WAAW,OAAQ,SAAQ,QAAQ;IAC/C,IAAI,EAAE,cAAc,CAAC,OAAO,CAAC;IAC7B,IAAI,EAAE,gBAAgB,EAAE,CAAC;IACzB,UAAU,EAAE,QAAQ,GAAG,QAAQ,CAAC;IAChC,QAAQ,CAAC,EAAE,OAAO,EAAE,CAAC;IACrB,MAAM,CAAC,EAAE,KAAK,EAAE,CAAC;CAClB;AAED,MAAM,CAAC,OAAO,MAAM,gBAAgB,GAChC,oBAAoB,GACpB,wBAAwB,GACxB,sBAAsB,GACtB,iBAAiB,GACjB,SAAS,GACT,yBAAyB,GACzB,4BAA4B,CAAC;AAEjC,MAAM,CAAC,OAAO,MAAM,QAAQ,GAAG,oBAAoB,GAAG,uBAAuB,CAAC;AAE9E,OAAO,WAAW,YAAa,SAAQ,QAAQ;IAC7C,IAAI,EAAE,cAAc,CAAC,QAAQ,CAAC;IAC9B,GAAG,EAAE,YAAY,CAAC;IAClB,KAAK,EACD,iBAAiB,GACjB,WAAW,GACX,UAAU,GACV,6BAA6B,CAAC;IAClC,QAAQ,EAAE,OAAO,CAAC;IAClB,MAAM,EAAE,OAAO,CAAC;IAChB,SAAS,EAAE,OAAO,CAAC;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,IAAI,EAAE,KAAK,GAAG,MAAM,GAAG,KAAK,CAAC;CAC9B;AAED,MAAM,CAAC,OAAO,WAAW,oBAAqB,SAAQ,YAAY;IAChE,GAAG,EAAE,oBAAoB,CAAC;IAC1B,QAAQ,EAAE,IAAI,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,MAAM,kBAAkB,GAClC,8BAA8B,GAC9B,iCAAiC,CAAC;AAEtC,OAAO,WAAW,sBAAuB,SAAQ,QAAQ;IACvD,GAAG,EAAE,YAAY,CAAC;IAClB,KAAK,EAAE,UAAU,GAAG,IAAI,CAAC;IACzB,QAAQ,EAAE,OAAO,CAAC;IAClB,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,OAAO,CAAC;IACjB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,UAAU,CAAC,EAAE,SAAS,EAAE,CAAC;IACzB,aAAa,CAAC,EAAE,aAAa,CAAC;IAC9B,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,cAAc,CAAC,EAAE,gBAAgB,CAAC;IAClC,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED,MAAM,CAAC,OAAO,WAAW,8BACvB,SAAQ,kCAAkC;IAC1C,IAAI,EAAE,cAAc,CAAC,kBAAkB,CAAC;CACzC;AAED,OAAO,WAAW,kCAChB,SAAQ,sBAAsB;IAC9B,GAAG,EAAE,oBAAoB,CAAC;IAC1B,QAAQ,EAAE,IAAI,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,WAAW,iCACvB,SAAQ,0CAA0C;IAClD,IAAI,EAAE,cAAc,CAAC,kBAAkB,CAAC;CACzC;AAED,OAAO,WAAW,qCAChB,SAAQ,sBAAsB;IAC9B,GAAG,EAAE,uBAAuB,CAAC;IAC7B,QAAQ,EAAE,KAAK,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,MAAM,YAAY,GAC5B,4BAA4B,GAC5B,oBAAoB,GACpB,uBAAuB,CAAC;AAE5B,MAAM,CAAC,OAAO,MAAM,oBAAoB,GAAG,UAAU,CAAC;AAEtD,MAAM,CAAC,OAAO,MAAM,uBAAuB,GACvC,UAAU,GACV,aAAa,GACb,aAAa,CAAC;AAElB,MAAM,CAAC,OAAO,WAAW,uBAAwB,SAAQ,YAAY;IACnE,GAAG,EAAE,uBAAuB,CAAC;IAC7B,QAAQ,EAAE,KAAK,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,SAAS;IACxD,IAAI,EAAE,eAAe,CAAC,UAAU,CAAC;IACjC,KAAK,EAAE,OAAO,CAAC,qBAAqB,CAAC,CAAC;CACvC;AAED,MAAM,CAAC,OAAO,WAAW,qBAAqB;IAC5C,CAAC,UAAU,CAAC,cAAc,CAAC,EAAE,GAAG,CAAC;IACjC,CAAC,UAAU,CAAC,eAAe,CAAC,EAAE,GAAG,CAAC;IAClC,CAAC,UAAU,CAAC,cAAc,CAAC,EAAE,GAAG,CAAC;IACjC,CAAC,UAAU,CAAC,eAAe,CAAC,EAAE,GAAG,CAAC;IAClC,CAAC,UAAU,CAAC,gBAAgB,CAAC,EAAE,GAAG,CAAC;IACnC,CAAC,UAAU,CAAC,iBAAiB,CAAC,EAAE,GAAG,CAAC;IACpC,CAAC,UAAU,CAAC,QAAQ,CAAC,EAAE,GAAG,CAAC;IAC3B,CAAC,UAAU,CAAC,cAAc,CAAC,EAAE,KAAK,CAAC;IACnC,CAAC,UAAU,CAAC,cAAc,CAAC,EAAE,GAAG,CAAC;IACjC,CAAC,UAAU,CAAC,UAAU,CAAC,EAAE,GAAG,CAAC;IAC7B,CAAC,UAAU,CAAC,gBAAgB,CAAC,EAAE,IAAI,CAAC;IACpC,CAAC,UAAU,CAAC,aAAa,CAAC,EAAE,GAAG,CAAC;IAChC,CAAC,UAAU,CAAC,kBAAkB,CAAC,EAAE,IAAI,CAAC;IACtC,CAAC,UAAU,CAAC,gBAAgB,CAAC,EAAE,GAAG,CAAC;IACnC,CAAC,UAAU,CAAC,mBAAmB,CAAC,EAAE,IAAI,CAAC;IACvC,CAAC,UAAU,CAAC,sBAAsB,CAAC,EAAE,IAAI,CAAC;IAC1C,CAAC,UAAU,CAAC,iBAAiB,CAAC,EAAE,IAAI,CAAC;IACrC,CAAC,UAAU,CAAC,sBAAsB,CAAC,EAAE,IAAI,CAAC;IAC1C,CAAC,UAAU,CAAC,uBAAuB,CAAC,EAAE,KAAK,CAAC;IAC5C,CAAC,UAAU,CAAC,4BAA4B,CAAC,EAAE,KAAK,CAAC;IACjD,CAAC,UAAU,CAAC,sBAAsB,CAAC,EAAE,IAAI,CAAC;IAC1C,CAAC,UAAU,CAAC,SAAS,CAAC,EAAE,GAAG,CAAC;IAC5B,CAAC,UAAU,CAAC,UAAU,CAAC,EAAE,GAAG,CAAC;IAC7B,CAAC,UAAU,CAAC,aAAa,CAAC,EAAE,GAAG,CAAC;IAChC,CAAC,UAAU,CAAC,qBAAqB,CAAC,EAAE,IAAI,CAAC;IACzC,CAAC,UAAU,CAAC,UAAU,CAAC,EAAE,GAAG,CAAC;IAC7B,CAAC,UAAU,CAAC,YAAY,CAAC,EAAE,GAAG,CAAC;IAC/B,CAAC,UAAU,CAAC,aAAa,CAAC,EAAE,IAAI,CAAC;IACjC,CAAC,UAAU,CAAC,eAAe,CAAC,EAAE,IAAI,CAAC;IACnC,CAAC,UAAU,CAAC,qBAAqB,CAAC,EAAE,IAAI,CAAC;IACzC,CAAC,UAAU,CAAC,2BAA2B,CAAC,EAAE,IAAI,CAAC;IAC/C,CAAC,UAAU,CAAC,sCAAsC,CAAC,EAAE,KAAK,CAAC;IAC3D,CAAC,UAAU,CAAC,cAAc,CAAC,EAAE,GAAG,CAAC;IACjC,CAAC,UAAU,CAAC,QAAQ,CAAC,EAAE,GAAG,CAAC;IAC3B,CAAC,UAAU,CAAC,UAAU,CAAC,EAAE,GAAG,CAAC;IAC7B,CAAC,UAAU,CAAC,gBAAgB,CAAC,EAAE,GAAG,CAAC;IACnC,CAAC,UAAU,CAAC,UAAU,CAAC,EAAE,GAAG,CAAC;IAC7B,CAAC,UAAU,CAAC,uBAAuB,CAAC,EAAE,IAAI,CAAC;IAC3C,CAAC,UAAU,CAAC,WAAW,CAAC,EAAE,IAAI,CAAC;IAC/B,CAAC,UAAU,CAAC,aAAa,CAAC,EAAE,GAAG,CAAC;IAChC,CAAC,UAAU,CAAC,UAAU,CAAC,EAAE,GAAG,CAAC;IAC7B,CAAC,UAAU,CAAC,OAAO,CAAC,EAAE,GAAG,CAAC;IAC1B,CAAC,UAAU,CAAC,qBAAqB,CAAC,EAAE,IAAI,CAAC;IACzC,CAAC,UAAU,CAAC,aAAa,CAAC,EAAE,GAAG,CAAC;IAChC,CAAC,UAAU,CAAC,SAAS,CAAC,EAAE,GAAG,CAAC;IAC5B,CAAC,UAAU,CAAC,WAAW,CAAC,EAAE,GAAG,CAAC;IAC9B,CAAC,UAAU,CAAC,eAAe,CAAC,EAAE,IAAI,CAAC;IACnC,CAAC,UAAU,CAAC,gBAAgB,CAAC,EAAE,IAAI,CAAC;IACpC,CAAC,UAAU,CAAC,mBAAmB,CAAC,EAAE,IAAI,CAAC;IACvC,CAAC,UAAU,CAAC,2BAA2B,CAAC,EAAE,KAAK,CAAC;IAChD,CAAC,UAAU,CAAC,gBAAgB,CAAC,EAAE,IAAI,CAAC;IACpC,CAAC,UAAU,CAAC,kBAAkB,CAAC,EAAE,IAAI,CAAC;IACtC,CAAC,UAAU,CAAC,2BAA2B,CAAC,EAAE,KAAK,CAAC;IAChD,CAAC,UAAU,CAAC,iCAAiC,CAAC,EAAE,KAAK,CAAC;IACtD,CAAC,UAAU,CAAC,4CAA4C,CAAC,EAAE,MAAM,CAAC;IAClE,CAAC,UAAU,CAAC,oBAAoB,CAAC,EAAE,IAAI,CAAC;IACxC,CAAC,UAAU,CAAC,cAAc,CAAC,EAAE,IAAI,CAAC;IAClC,CAAC,UAAU,CAAC,iBAAiB,CAAC,EAAE,KAAK,CAAC;IACtC,CAAC,UAAU,CAAC,6BAA6B,CAAC,EAAE,KAAK,CAAC;IAClD,CAAC,UAAU,CAAC,2BAA2B,CAAC,EAAE,KAAK,CAAC;IAChD,CAAC,UAAU,CAAC,gBAAgB,CAAC,EAAE,IAAI,CAAC;CACrC;AAED;;;;GAIG;AACH,MAAM,CAAC,OAAO,MAAM,KAAK,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;AAE7C,MAAM,CAAC,OAAO,WAAW,aAAc,SAAQ,WAAW;IACxD,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,KAAK,EAAE;QACL,OAAO,EAAE,MAAM,CAAC;QAChB,KAAK,EAAE,MAAM,CAAC;KACf,CAAC;CACH;AAED,MAAM,CAAC,OAAO,WAAW,sBAAuB,SAAQ,SAAS;IAC/D,IAAI,EAAE,eAAe,CAAC,iBAAiB,CAAC;IACxC,KAAK,EAAE;QACL,OAAO,EAAE,MAAM,CAAC;QAChB,KAAK,EAAE,MAAM,CAAC;KACf,CAAC;CACH;AAED,MAAM,CAAC,OAAO,WAAW,WAAY,SAAQ,QAAQ;IACnD,IAAI,EAAE,cAAc,CAAC,WAAW,CAAC;IACjC,QAAQ,EAAE,oBAAoB,CAAC;IAC/B,cAAc,CAAC,EAAE,gBAAgB,CAAC;IAClC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,KAAK,CAAC,EAAE,iBAAiB,CAAC;IAC1B,UAAU,CAAC,EAAE,SAAS,EAAE,CAAC;CAC1B;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;IACrC,QAAQ,EAAE,UAAU,GAAG,IAAI,CAAC;CAC7B;AAED,MAAM,CAAC,OAAO,WAAW,kBAAmB,SAAQ,QAAQ;IAC1D,IAAI,EAAE,cAAc,CAAC,kBAAkB,CAAC;IACxC,WAAW,EAAE,UAAU,EAAE,CAAC;CAC3B;AAED,MAAM,CAAC,OAAO,WAAW,cAAc;IACrC;;OAEG;IACH,KAAK,EAAE,QAAQ,CAAC;IAChB;;OAEG;IACH,GAAG,EAAE,QAAQ,CAAC;CACf;AAED,MAAM,CAAC,OAAO,WAAW,aAAc,SAAQ,QAAQ;IACrD,IAAI,EAAE,cAAc,CAAC,aAAa,CAAC;IACnC,QAAQ,EAAE,UAAU,CAAC;CACtB;AAED,MAAM,CAAC,OAAO,MAAM,SAAS,GACzB,cAAc,GACd,cAAc,GACd,gBAAgB,GAChB,iBAAiB,GACjB,iBAAiB,GACjB,gBAAgB,GAChB,oBAAoB,GACpB,wBAAwB,GACxB,sBAAsB,GACtB,mBAAmB,GACnB,cAAc,GACd,cAAc,GACd,YAAY,GACZ,mBAAmB,GACnB,WAAW,GACX,iBAAiB,GACjB,gBAAgB,GAChB,eAAe,GACf,eAAe,GACf,cAAc,GACd,YAAY,GACZ,iBAAiB,GACjB,iBAAiB,GACjB,kBAAkB,GAClB,yBAAyB,GACzB,sBAAsB,GACtB,mBAAmB,GACnB,4BAA4B,GAC5B,sBAAsB,GACtB,mBAAmB,GACnB,cAAc,GACd,aAAa,CAAC;AAElB,MAAM,CAAC,OAAO,WAAW,WAAY,SAAQ,QAAQ;IACnD,IAAI,EAAE,cAAc,CAAC,WAAW,CAAC;IACjC,IAAI,EAAE,SAAS,EAAE,CAAC;CACnB;AAED,MAAM,CAAC,OAAO,WAAW,aAAc,SAAQ,WAAW;IACxD,KAAK,EAAE,MAAM,CAAC;CACf;AAED,MAAM,CAAC,OAAO,WAAW,WAAY,SAAQ,SAAS;IACpD,IAAI,EAAE,eAAe,CAAC,MAAM,CAAC;CAC9B;AAED,MAAM,CAAC,OAAO,WAAW,KAAM,SAAQ,QAAQ;IAC7C,IAAI,EAAE,cAAc,CAAC,KAAK,CAAC;CAC5B;AAED,MAAM,CAAC,OAAO,WAAW,UAAW,SAAQ,QAAQ;IAClD,IAAI,EAAE,cAAc,CAAC,UAAU,CAAC;IAChC,IAAI,EAAE,UAAU,GAAG,IAAI,CAAC;IACxB,UAAU,EAAE,SAAS,EAAE,CAAC;CACzB;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;IACrC,YAAY,EAAE,UAAU,CAAC;IACzB,KAAK,EAAE,UAAU,EAAE,CAAC;CACrB;AAED,MAAM,CAAC,OAAO,WAAW,wBAAyB,SAAQ,QAAQ;IAChE,IAAI,EAAE,cAAc,CAAC,wBAAwB,CAAC;IAC9C,cAAc,CAAC,EAAE,4BAA4B,CAAC;IAC9C,GAAG,EAAE,sBAAsB,CAAC;IAC5B,KAAK,EAAE,eAAe,CAAC;CACxB;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;IACrC,KAAK,EAAE;QACL,GAAG,EAAE,MAAM,CAAC;QACZ,MAAM,EAAE,MAAM,CAAC;KAChB,CAAC;IACF,IAAI,EAAE,OAAO,CAAC;CACf;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;IACrC,MAAM,EAAE,eAAe,EAAE,CAAC;IAC1B,WAAW,EAAE,UAAU,EAAE,CAAC;CAC3B;AAED,MAAM,CAAC,OAAO,WAAW,aAAc,SAAQ,SAAS;IACtD,IAAI,EAAE,eAAe,CAAC,QAAQ,CAAC;CAChC;AAED,MAAM,CAAC,OAAO,WAAW,cAAe,SAAQ,QAAQ;IACtD,IAAI,EAAE,cAAc,CAAC,cAAc,CAAC;CACrC;AAED,MAAM,CAAC,OAAO,WAAW,cAAe,SAAQ,QAAQ;IACtD,IAAI,EAAE,cAAc,CAAC,cAAc,CAAC;IACpC,QAAQ,EAAE,SAAS,GAAG,cAAc,GAAG,IAAI,CAAC;CAC7C;AAED,MAAM,CAAC,OAAO,MAAM,KAAK,GACrB,YAAY,GACZ,OAAO,GACP,eAAe,GACf,kBAAkB,GAClB,YAAY,GACZ,YAAY,GACZ,SAAS,GACT,YAAY,GACZ,eAAe,GACf,sBAAsB,GACtB,WAAW,GACX,aAAa,CAAC;AAElB,MAAM,CAAC,OAAO,WAAW,YAAa,SAAQ,QAAQ;IACpD,IAAI,EAAE,cAAc,CAAC,YAAY,CAAC;IAClC,KAAK,EAAE,cAAc,CAAC;IACtB,OAAO,EAAE,WAAW,GAAG,IAAI,CAAC;IAC5B,SAAS,EAAE,cAAc,GAAG,IAAI,CAAC;CAClC;AAED,MAAM,CAAC,OAAO,WAAW,iBAAkB,SAAQ,QAAQ;IACzD,IAAI,EAAE,cAAc,CAAC,iBAAiB,CAAC;CACxC;AAED,MAAM,CAAC,OAAO,MAAM,0BAA0B,GAC1C,sCAAsC,GACtC,yCAAyC,CAAC;AAE9C,MAAM,CAAC,OAAO,WAAW,sCACvB,SAAQ,gCAAgC;IACxC,IAAI,EAAE,cAAc,CAAC,0BAA0B,CAAC;CACjD;AAED,MAAM,CAAC,OAAO,WAAW,yCACvB,SAAQ,mCAAmC;IAC3C,IAAI,EAAE,cAAc,CAAC,0BAA0B,CAAC;CACjD;AAED,MAAM,CAAC,OAAO,MAAM,4BAA4B,GAC5C,wCAAwC,GACxC,2CAA2C,CAAC;AAEhD,MAAM,CAAC,OAAO,WAAW,wCACvB,SAAQ,kCAAkC;IAC1C,IAAI,EAAE,cAAc,CAAC,4BAA4B,CAAC;IAClD,KAAK,EAAE,IAAI,CAAC;CACb;AAED,MAAM,CAAC,OAAO,WAAW,2CACvB,SAAQ,qCAAqC;IAC7C,IAAI,EAAE,cAAc,CAAC,4BAA4B,CAAC;IAClD,KAAK,EAAE,IAAI,CAAC;CACb;AAED,MAAM,CAAC,OAAO,WAAW,YAAa,SAAQ,QAAQ;IACpD,IAAI,EAAE,cAAc,CAAC,YAAY,CAAC;CACnC;AAED,MAAM,CAAC,OAAO,WAAW,WAAY,SAAQ,QAAQ;IACnD,IAAI,EAAE,cAAc,CAAC,WAAW,CAAC;IACjC,WAAW,EAAE,QAAQ,CAAC;CACvB;AAED,MAAM,CAAC,OAAO,WAAW,cAAe,SAAQ,QAAQ;IACtD,IAAI,EAAE,cAAc,CAAC,cAAc,CAAC;IACpC,UAAU,EAAE,UAAU,CAAC;IACvB,cAAc,EAAE,QAAQ,CAAC;CAC1B;AAED,MAAM,CAAC,OAAO,WAAW,cAAe,SAAQ,QAAQ;IACtD,IAAI,EAAE,cAAc,CAAC,cAAc,CAAC;CACrC;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;CACtC;AAED,MAAM,CAAC,OAAO,WAAW,gBAAiB,SAAQ,QAAQ;IACxD,IAAI,EAAE,cAAc,CAAC,gBAAgB,CAAC;CACvC;AAED,MAAM,CAAC,OAAO,WAAW,0BACvB,SAAQ,uBAAuB;IAC/B,IAAI,EAAE,cAAc,CAAC,0BAA0B,CAAC;CACjD;AAED,MAAM,CAAC,OAAO,WAAW,iBAAkB,SAAQ,cAAc;IAC/D,IAAI,EAAE,cAAc,CAAC,iBAAiB,CAAC;CACxC;AAED,MAAM,CAAC,OAAO,WAAW,iBAAkB,SAAQ,QAAQ;IACzD,IAAI,EAAE,cAAc,CAAC,iBAAiB,CAAC;IACvC,SAAS,EAAE,QAAQ,CAAC;IACpB,WAAW,EAAE,QAAQ,CAAC;IACtB,QAAQ,EAAE,QAAQ,CAAC;IACnB,SAAS,EAAE,QAAQ,CAAC;CACrB;AAED,MAAM,CAAC,OAAO,WAAW,iBAAkB,SAAQ,uBAAuB;IACxE,IAAI,EAAE,cAAc,CAAC,iBAAiB,CAAC;IACvC,QAAQ,EAAE,OAAO,CAAC;CACnB;AAED,MAAM,CAAC,OAAO,WAAW,+BACvB,SAAQ,uBAAuB;IAC/B,IAAI,EAAE,cAAc,CAAC,+BAA+B,CAAC;CACtD;AAED,MAAM,CAAC,OAAO,WAAW,iBAAkB,SAAQ,uBAAuB;IACxE,IAAI,EAAE,cAAc,CAAC,iBAAiB,CAAC;CACxC;AAED,MAAM,CAAC,OAAO,WAAW,gBAAiB,SAAQ,QAAQ;IACxD,IAAI,EAAE,cAAc,CAAC,gBAAgB,CAAC;CACvC;AAED,MAAM,CAAC,OAAO,WAAW,6BACvB,SAAQ,uBAAuB;IAC/B,IAAI,EAAE,cAAc,CAAC,6BAA6B,CAAC;IACnD,IAAI,EAAE,IAAI,CAAC;CACZ;AAED,MAAM,CAAC,OAAO,WAAW,iBAAkB,SAAQ,QAAQ;IACzD,IAAI,EAAE,cAAc,CAAC,iBAAiB,CAAC;IACvC,EAAE,EAAE,UAAU,CAAC;IACf,OAAO,EAAE,YAAY,EAAE,CAAC;IACxB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,SAAS,CAAC,EAAE,QAAQ,EAAE,CAAC;CACxB;AAED,MAAM,CAAC,OAAO,MAAM,YAAY,GAC5B,wBAAwB,GACxB,2BAA2B,CAAC;AAEhC,OAAO,WAAW,gBAAiB,SAAQ,QAAQ;IACjD,IAAI,EAAE,cAAc,CAAC,YAAY,CAAC;IAClC,EAAE,EAAE,oBAAoB,GAAG,uBAAuB,CAAC;IACnD,WAAW,CAAC,EAAE,UAAU,CAAC;IACzB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED;;;;;;;;;;GAUG;AACH,MAAM,CAAC,OAAO,WAAW,wBAAyB,SAAQ,gBAAgB;IACxE,EAAE,EAAE,oBAAoB,CAAC;IACzB,QAAQ,EAAE,IAAI,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,WAAW,2BAA4B,SAAQ,gBAAgB;IAC3E,EAAE,EAAE,uBAAuB,CAAC;IAC5B,QAAQ,CAAC,EAAE,KAAK,CAAC;CAClB;AAED,MAAM,CAAC,OAAO,WAAW,kBAAmB,SAAQ,QAAQ;IAC1D,IAAI,EAAE,cAAc,CAAC,kBAAkB,CAAC;IACxC,UAAU,EAAE,UAAU,CAAC;CACxB;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;CACtC;AAED,MAAM,CAAC,OAAO,WAAW,yBAA0B,SAAQ,QAAQ;IACjE,IAAI,EAAE,cAAc,CAAC,yBAAyB,CAAC;IAC/C,UAAU,EAAE,UAAU,CAAC;CACxB;AAED,OAAO,WAAW,uBAAwB,SAAQ,QAAQ;IACxD,MAAM,EAAE,SAAS,EAAE,CAAC;IACpB,UAAU,CAAC,EAAE,gBAAgB,CAAC;IAC9B,cAAc,CAAC,EAAE,0BAA0B,CAAC;CAC7C;AAED,MAAM,CAAC,OAAO,WAAW,cAAe,SAAQ,uBAAuB;IACrE,IAAI,EAAE,cAAc,CAAC,cAAc,CAAC;CACrC;AAED,OAAO,WAAW,cAAe,SAAQ,QAAQ;IAC/C,UAAU,EAAE,UAAU,CAAC;IACvB,cAAc,CAAC,EAAE,4BAA4B,CAAC;CAC/C;AAED,MAAM,CAAC,OAAO,WAAW,yBAA0B,SAAQ,QAAQ;IACjE,IAAI,EAAE,cAAc,CAAC,yBAAyB,CAAC;IAC/C,EAAE,EAAE,UAAU,CAAC;IACf,eAAe,EAAE,UAAU,GAAG,yBAAyB,CAAC;IACxD,UAAU,EAAE,UAAU,CAAC;IACvB,QAAQ,EAAE,OAAO,CAAC;CACnB;AAED,MAAM,CAAC,OAAO,WAAW,YAAa,SAAQ,QAAQ;IACpD,IAAI,EAAE,cAAc,CAAC,YAAY,CAAC;IAClC,QAAQ,EAAE,OAAO,CAAC;IAClB,SAAS,EAAE,QAAQ,CAAC;IACpB,SAAS,EAAE,UAAU,GAAG,IAAI,CAAC;IAC7B,cAAc,EAAE,4BAA4B,GAAG,IAAI,CAAC;CACrD;AAED,MAAM,CAAC,OAAO,WAAW,mBAAoB,SAAQ,QAAQ;IAC3D,IAAI,EAAE,cAAc,CAAC,mBAAmB,CAAC;IACzC,UAAU,EAAE,QAAQ,CAAC;IACrB,SAAS,EAAE,QAAQ,CAAC;CACrB;AAED,MAAM,CAAC,OAAO,WAAW,gBAAiB,SAAQ,QAAQ;IACxD,IAAI,EAAE,cAAc,CAAC,gBAAgB,CAAC;IACtC,UAAU,EAAE,SAAS,EAAE,CAAC;IACxB,cAAc,CAAC,EAAE,gBAAgB,CAAC;IAClC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,aAAa,CAAC,EAAE,aAAa,CAAC;IAC9B,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB;AAED,MAAM,CAAC,OAAO,WAAW,WAAY,SAAQ,QAAQ;IACnD,IAAI,EAAE,cAAc,CAAC,WAAW,CAAC;IACjC,aAAa,EAAE,eAAe,CAAC;CAChC;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;IACrC,IAAI,EAAE,WAAW,EAAE,CAAC;CACrB;AAED,MAAM,CAAC,OAAO,WAAW,sBAAuB,SAAQ,QAAQ;IAC9D,IAAI,EAAE,cAAc,CAAC,sBAAsB,CAAC;IAC5C,IAAI,EAAE,eAAe,CAAC;IACtB,EAAE,EAAE,UAAU,CAAC;IACf,cAAc,CAAC,EAAE,0BAA0B,CAAC;IAC5C,OAAO,CAAC,EAAE,mBAAmB,EAAE,CAAC;IAChC,UAAU,CAAC,EAAE,mBAAmB,EAAE,CAAC;IACnC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB;AAED,MAAM,CAAC,OAAO,WAAW,mBAAoB,SAAQ,cAAc;IACjE,IAAI,EAAE,cAAc,CAAC,mBAAmB,CAAC;CAC1C;AAED,MAAM,CAAC,OAAO,WAAW,kBAAmB,SAAQ,QAAQ;IAC1D,IAAI,EAAE,cAAc,CAAC,kBAAkB,CAAC;IACxC,KAAK,EAAE,QAAQ,EAAE,CAAC;CACnB;AAED,OAAO,WAAW,kBAAmB,SAAQ,QAAQ;IACnD,IAAI,EAAE,cAAc,CAAC,kBAAkB,CAAC;CACzC;AAED,MAAM,CAAC,OAAO,WAAW,aAAc,SAAQ,QAAQ;IACrD,IAAI,EAAE,cAAc,CAAC,aAAa,CAAC;IACnC,OAAO,EAAE,iBAAiB,GAAG,eAAe,GAAG,gBAAgB,CAAC;CACjE;AAED,MAAM,CAAC,OAAO,WAAW,YAAa,SAAQ,QAAQ;IACpD,IAAI,EAAE,cAAc,CAAC,YAAY,CAAC;IAClC,aAAa,EAAE,eAAe,CAAC;IAC/B,QAAQ,CAAC,EAAE,OAAO,GAAG,GAAG,GAAG,GAAG,CAAC;IAC/B,QAAQ,CAAC,EAAE,OAAO,GAAG,GAAG,GAAG,GAAG,CAAC;IAC/B,cAAc,CAAC,EAAE,QAAQ,CAAC;IAC1B,QAAQ,EAAE,QAAQ,GAAG,IAAI,CAAC;CAC3B;AAED,MAAM,CAAC,OAAO,MAAM,iBAAiB,GACjC,6BAA6B,GAC7B,gCAAgC,CAAC;AAErC,OAAO,WAAW,qBAAsB,SAAQ,QAAQ;IACtD,IAAI,EAAE,cAAc,CAAC,iBAAiB,CAAC;IACvC,GAAG,EAAE,YAAY,CAAC;IAClB,QAAQ,EAAE,OAAO,CAAC;IAClB,MAAM,EAAE,SAAS,EAAE,CAAC;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,UAAU,CAAC,EAAE,gBAAgB,CAAC;IAC9B,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,cAAc,CAAC,EAAE,0BAA0B,CAAC;IAC5C,aAAa,CAAC,EAAE,aAAa,CAAC;IAC9B,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,IAAI,EAAE,KAAK,GAAG,QAAQ,GAAG,KAAK,CAAC;CAChC;AAED,MAAM,CAAC,OAAO,WAAW,6BACvB,SAAQ,qBAAqB;IAC7B,GAAG,EAAE,oBAAoB,CAAC;IAC1B,QAAQ,EAAE,IAAI,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,WAAW,gCACvB,SAAQ,qBAAqB;IAC7B,GAAG,EAAE,uBAAuB,CAAC;IAC7B,QAAQ,EAAE,KAAK,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,WAAW,aAAc,SAAQ,QAAQ;IACrD,IAAI,EAAE,cAAc,CAAC,aAAa,CAAC;IACnC,IAAI,EAAE,gBAAgB,EAAE,CAAC;CAC1B;AAED,MAAM,CAAC,OAAO,WAAW,mBAAoB,SAAQ,QAAQ;IAC3D,IAAI,EAAE,cAAc,CAAC,mBAAmB,CAAC;IACzC,EAAE,EAAE,UAAU,GAAG,OAAO,CAAC;IACzB,IAAI,CAAC,EAAE,aAAa,GAAG,mBAAmB,CAAC;IAC3C,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,SAAS,CAAC,EAAE,QAAQ,EAAE,CAAC;CACxB;AAED,MAAM,CAAC,OAAO,WAAW,kBAAmB,SAAQ,QAAQ;IAC1D,IAAI,EAAE,cAAc,CAAC,kBAAkB,CAAC;IACxC,WAAW,EAAE,QAAQ,CAAC;IACtB,KAAK,EAAE,UAAU,CAAC;IAClB,QAAQ,EAAE,OAAO,CAAC;CACnB;AAED,MAAM,CAAC,OAAO,WAAW,4BAA6B,SAAQ,QAAQ;IACpE,IAAI,EAAE,cAAc,CAAC,4BAA4B,CAAC;IAClD,EAAE,EAAE,UAAU,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,WAAW,cAAe,SAAQ,QAAQ;IACtD,IAAI,EAAE,cAAc,CAAC,cAAc,CAAC;CACrC;AAED,MAAM,CAAC,OAAO,WAAW,mBAAoB,SAAQ,QAAQ;IAC3D,IAAI,EAAE,cAAc,CAAC,mBAAmB,CAAC;IACzC,UAAU,EAAE,UAAU,CAAC;CACxB;AAED,MAAM,CAAC,OAAO,WAAW,aAAc,SAAQ,QAAQ;IACrD,IAAI,EAAE,cAAc,CAAC,aAAa,CAAC;CACpC;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;CACtC;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;CACtC;AAED,MAAM,CAAC,OAAO,WAAW,cAAe,SAAQ,QAAQ;IACtD,IAAI,EAAE,cAAc,CAAC,cAAc,CAAC;IACpC,cAAc,EAAE,QAAQ,CAAC;CAC1B;AAED,MAAM,CAAC,OAAO,WAAW,mBAAoB,SAAQ,QAAQ;IAC3D,IAAI,EAAE,cAAc,CAAC,mBAAmB,CAAC;IACzC,aAAa,CAAC,EAAE,aAAa,CAAC;IAC9B,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,SAAS,EAAE,iBAAiB,GAAG,WAAW,GAAG,WAAW,CAAC;IACzD,UAAU,CAAC,EAAE,SAAS,EAAE,CAAC;CAC1B;AAED,MAAM,CAAC,OAAO,WAAW,gBAAiB,SAAQ,QAAQ;IACxD,IAAI,EAAE,cAAc,CAAC,gBAAgB,CAAC;CACvC;AAED,MAAM,CAAC,OAAO,MAAM,mBAAmB,GACnC,+BAA+B,GAC/B,kCAAkC,CAAC;AAEvC,OAAO,WAAW,uBAAwB,SAAQ,QAAQ;IACxD,IAAI,EAAE,cAAc,CAAC,mBAAmB,CAAC;IACzC,GAAG,EAAE,YAAY,CAAC;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,EAAE,OAAO,CAAC;IAClB,cAAc,CAAC,EAAE,gBAAgB,CAAC;IAClC,WAAW,CAAC,EAAE,UAAU,CAAC;IACzB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,aAAa,CAAC,EAAE,aAAa,CAAC;CAC/B;AAED,MAAM,CAAC,OAAO,WAAW,+BACvB,SAAQ,uBAAuB;IAC/B,GAAG,EAAE,oBAAoB,CAAC;IAC1B,QAAQ,EAAE,IAAI,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,WAAW,kCACvB,SAAQ,uBAAuB;IAC/B,GAAG,EAAE,uBAAuB,CAAC;IAC7B,QAAQ,EAAE,KAAK,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,WAAW,kBAAmB,SAAQ,QAAQ;IAC1D,IAAI,EAAE,cAAc,CAAC,kBAAkB,CAAC;CACzC;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;CACtC;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;IACrC,IAAI,EAAE,UAAU,CAAC;IACjB,KAAK,EAAE,UAAU,CAAC;CACnB;AAED,MAAM,CAAC,OAAO,WAAW,iBAAkB,SAAQ,QAAQ;IACzD,IAAI,EAAE,cAAc,CAAC,iBAAiB,CAAC;CACxC;AAED,MAAM,CAAC,OAAO,WAAW,UAAW,SAAQ,QAAQ;IAClD,IAAI,EAAE,cAAc,CAAC,UAAU,CAAC;IAChC,cAAc,EAAE,QAAQ,CAAC;CAC1B;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;CACtC;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;CACtC;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;CACtC;AAED,MAAM,CAAC,OAAO,WAAW,qBAAsB,SAAQ,QAAQ;IAC7D,IAAI,EAAE,cAAc,CAAC,qBAAqB,CAAC;IAC3C,MAAM,EAAE,eAAe,EAAE,CAAC;IAC1B,KAAK,EAAE,QAAQ,EAAE,CAAC;CACnB;AAED,MAAM,CAAC,OAAO,WAAW,UAAW,SAAQ,QAAQ;IAClD,IAAI,EAAE,cAAc,CAAC,UAAU,CAAC;CACjC;AAED,MAAM,CAAC,OAAO,WAAW,WAAY,SAAQ,QAAQ;IACnD,IAAI,EAAE,cAAc,CAAC,WAAW,CAAC;IACjC,YAAY,EAAE,QAAQ,EAAE,CAAC;CAC1B;AAED,MAAM,CAAC,OAAO,WAAW,sBAAuB,SAAQ,QAAQ;IAC9D,IAAI,EAAE,cAAc,CAAC,sBAAsB,CAAC;IAC5C,EAAE,EAAE,UAAU,CAAC;IACf,cAAc,EAAE,QAAQ,CAAC;IACzB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,cAAc,CAAC,EAAE,0BAA0B,CAAC;CAC7C;AAED,MAAM,CAAC,OAAO,WAAW,gBAAiB,SAAQ,QAAQ;IACxD,IAAI,EAAE,cAAc,CAAC,gBAAgB,CAAC;IACtC,cAAc,EAAE,QAAQ,CAAC;CAC1B;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;IACrC,cAAc,EAAE,QAAQ,CAAC;IACzB,UAAU,EAAE,UAAU,CAAC;CACxB;AAED,MAAM,CAAC,OAAO,WAAW,aAAc,SAAQ,QAAQ;IACrD,IAAI,EAAE,cAAc,CAAC,aAAa,CAAC;IACnC,OAAO,EAAE,WAAW,EAAE,CAAC;CACxB;AAED,MAAM,CAAC,OAAO,WAAW,cAAe,SAAQ,QAAQ;IACtD,IAAI,EAAE,cAAc,CAAC,cAAc,CAAC;IACpC,QAAQ,EAAE,OAAO,GAAG,UAAU,GAAG,QAAQ,CAAC;IAC1C,cAAc,CAAC,EAAE,QAAQ,CAAC;CAC3B;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;IACrC,IAAI,EAAE,UAAU,CAAC;IACjB,UAAU,CAAC,EAAE,QAAQ,CAAC;IACtB,OAAO,CAAC,EAAE,QAAQ,CAAC;CACpB;AAED,MAAM,CAAC,OAAO,WAAW,0BAA2B,SAAQ,QAAQ;IAClE,IAAI,EAAE,cAAc,CAAC,0BAA0B,CAAC;IAChD,MAAM,EAAE,eAAe,EAAE,CAAC;CAC3B;AAED,MAAM,CAAC,OAAO,WAAW,4BAA6B,SAAQ,QAAQ;IACpE,IAAI,EAAE,cAAc,CAAC,4BAA4B,CAAC;IAClD,MAAM,EAAE,QAAQ,EAAE,CAAC;CACpB;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;IACrC,OAAO,EAAE,OAAO,CAAC;IACjB,aAAa,EAAE,UAAU,GAAG,UAAU,CAAC;IACvC,cAAc,EAAE,gBAAgB,GAAG,IAAI,CAAC;CACzC;AAED,MAAM,CAAC,OAAO,WAAW,WAAY,SAAQ,QAAQ;IACnD,IAAI,EAAE,cAAc,CAAC,WAAW,CAAC;IACjC,QAAQ,EAAE,UAAU,CAAC;CACtB;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;IACrC,QAAQ,EAAE,UAAU,CAAC;IACrB,cAAc,CAAC,EAAE,4BAA4B,CAAC;CAC/C;AAED,MAAM,CAAC,OAAO,MAAM,iBAAiB,GACjC,eAAe,GACf,sBAAsB,GACtB,eAAe,GACf,gBAAgB,CAAC;AAErB,MAAM,CAAC,OAAO,WAAW,kBAAmB,SAAQ,QAAQ;IAC1D,IAAI,EAAE,cAAc,CAAC,kBAAkB,CAAC;CACzC;AAED,MAAM,CAAC,OAAO,WAAW,WAAY,SAAQ,QAAQ;IACnD,IAAI,EAAE,cAAc,CAAC,WAAW,CAAC;IACjC,KAAK,EAAE,QAAQ,EAAE,CAAC;CACnB;AAED,MAAM,CAAC,OAAO,WAAW,gBAAiB,SAAQ,QAAQ;IACxD,IAAI,EAAE,cAAc,CAAC,gBAAgB,CAAC;CACvC;AAED,MAAM,CAAC,OAAO,WAAW,aAAc,SAAQ,QAAQ;IACrD,IAAI,EAAE,cAAc,CAAC,aAAa,CAAC;CACpC;AAED,MAAM,CAAC,OAAO,MAAM,WAAW,GAC3B,0BAA0B,GAC1B,+BAA+B,GAC/B,gBAAgB,GAChB,iBAAiB,GACjB,mBAAmB,CAAC;AAExB,MAAM,CAAC,OAAO,MAAM,QAAQ,GACxB,YAAY,GACZ,WAAW,GACX,eAAe,GACf,gBAAgB,GAChB,iBAAiB,GACjB,iBAAiB,GACjB,cAAc,GACd,YAAY,GACZ,mBAAmB,GACnB,WAAW,GACX,kBAAkB,GAClB,kBAAkB,GAClB,aAAa,GACb,YAAY,GACZ,kBAAkB,GAClB,cAAc,GACd,aAAa,GACb,eAAe,GACf,eAAe,GACf,cAAc,GACd,UAAU,GACV,eAAe,GACf,eAAe,GACf,qBAAqB,GACrB,UAAU,GACV,WAAW,GACX,aAAa,GACb,cAAc,GACd,eAAe,GACf,WAAW,GACX,eAAe,GACf,kBAAkB,GAClB,WAAW,GACX,gBAAgB,GAChB,aAAa,CAAC;AAElB,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,mBAAmB;IAClE,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;IACrC,QAAQ,EAAE,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,QAAQ,GAAG,QAAQ,GAAG,MAAM,CAAC;CAChE;AAED,OAAO,WAAW,mBAAoB,SAAQ,QAAQ;IACpD,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,OAAO,CAAC;IAChB,QAAQ,EAAE,sBAAsB,GAAG,OAAO,GAAG,eAAe,CAAC;CAC9D;AAED,MAAM,CAAC,OAAO,WAAW,gBAAiB,SAAQ,mBAAmB;IACnE,IAAI,EAAE,cAAc,CAAC,gBAAgB,CAAC;IACtC,QAAQ,EAAE,IAAI,GAAG,IAAI,CAAC;CACvB;AAED,OAAO,MAAM,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC;AAErC,MAAM,CAAC,OAAO,WAAW,mBAAoB,SAAQ,QAAQ;IAC3D,IAAI,EAAE,cAAc,CAAC,mBAAmB,CAAC;IACzC,YAAY,EAAE,kBAAkB,EAAE,CAAC;IACnC,IAAI,EAAE,OAAO,GAAG,KAAK,GAAG,KAAK,CAAC;IAC9B,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB;AAED,MAAM,CAAC,OAAO,WAAW,kBAAmB,SAAQ,QAAQ;IAC1D,IAAI,EAAE,cAAc,CAAC,kBAAkB,CAAC;IACxC,EAAE,EAAE,WAAW,CAAC;IAChB,IAAI,EAAE,UAAU,GAAG,IAAI,CAAC;IACxB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED,MAAM,CAAC,OAAO,WAAW,cAAe,SAAQ,QAAQ;IACtD,IAAI,EAAE,cAAc,CAAC,cAAc,CAAC;IACpC,IAAI,EAAE,UAAU,CAAC;IACjB,IAAI,EAAE,SAAS,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,WAAW,aAAc,SAAQ,QAAQ;IACrD,IAAI,EAAE,cAAc,CAAC,aAAa,CAAC;IACnC,MAAM,EAAE,UAAU,CAAC;IACnB,IAAI,EAAE,SAAS,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,WAAW,eAAgB,SAAQ,QAAQ;IACvD,IAAI,EAAE,cAAc,CAAC,eAAe,CAAC;IACrC,QAAQ,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,UAAU,CAAC;CACvB;AAED,OAAO,EAAE,CAAC"} \ No newline at end of file diff --git a/node_modules/@typescript-eslint/types/dist/generated/ast-spec.js b/node_modules/@typescript-eslint/types/dist/generated/ast-spec.js new file mode 100644 index 000000000..1da866757 --- /dev/null +++ b/node_modules/@typescript-eslint/types/dist/generated/ast-spec.js @@ -0,0 +1,198 @@ +"use strict"; +/********************************************** + * DO NOT MODIFY THIS FILE MANUALLY * + * * + * THIS FILE HAS BEEN COPIED FROM ast-spec. * + * ANY CHANGES WILL BE LOST ON THE NEXT BUILD * + * * + * MAKE CHANGES TO ast-spec AND THEN RUN * + * yarn build * + **********************************************/ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.AST_TOKEN_TYPES = exports.AST_NODE_TYPES = void 0; +var AST_NODE_TYPES; +(function (AST_NODE_TYPES) { + AST_NODE_TYPES["ArrayExpression"] = "ArrayExpression"; + AST_NODE_TYPES["ArrayPattern"] = "ArrayPattern"; + AST_NODE_TYPES["ArrowFunctionExpression"] = "ArrowFunctionExpression"; + AST_NODE_TYPES["AssignmentExpression"] = "AssignmentExpression"; + AST_NODE_TYPES["AssignmentPattern"] = "AssignmentPattern"; + AST_NODE_TYPES["AwaitExpression"] = "AwaitExpression"; + AST_NODE_TYPES["BinaryExpression"] = "BinaryExpression"; + AST_NODE_TYPES["BlockStatement"] = "BlockStatement"; + AST_NODE_TYPES["BreakStatement"] = "BreakStatement"; + AST_NODE_TYPES["CallExpression"] = "CallExpression"; + AST_NODE_TYPES["CatchClause"] = "CatchClause"; + AST_NODE_TYPES["ChainExpression"] = "ChainExpression"; + AST_NODE_TYPES["ClassBody"] = "ClassBody"; + AST_NODE_TYPES["ClassDeclaration"] = "ClassDeclaration"; + AST_NODE_TYPES["ClassExpression"] = "ClassExpression"; + AST_NODE_TYPES["ConditionalExpression"] = "ConditionalExpression"; + AST_NODE_TYPES["ContinueStatement"] = "ContinueStatement"; + AST_NODE_TYPES["DebuggerStatement"] = "DebuggerStatement"; + AST_NODE_TYPES["Decorator"] = "Decorator"; + AST_NODE_TYPES["DoWhileStatement"] = "DoWhileStatement"; + AST_NODE_TYPES["EmptyStatement"] = "EmptyStatement"; + AST_NODE_TYPES["ExportAllDeclaration"] = "ExportAllDeclaration"; + AST_NODE_TYPES["ExportDefaultDeclaration"] = "ExportDefaultDeclaration"; + AST_NODE_TYPES["ExportNamedDeclaration"] = "ExportNamedDeclaration"; + AST_NODE_TYPES["ExportSpecifier"] = "ExportSpecifier"; + AST_NODE_TYPES["ExpressionStatement"] = "ExpressionStatement"; + AST_NODE_TYPES["ForInStatement"] = "ForInStatement"; + AST_NODE_TYPES["ForOfStatement"] = "ForOfStatement"; + AST_NODE_TYPES["ForStatement"] = "ForStatement"; + AST_NODE_TYPES["FunctionDeclaration"] = "FunctionDeclaration"; + AST_NODE_TYPES["FunctionExpression"] = "FunctionExpression"; + AST_NODE_TYPES["Identifier"] = "Identifier"; + AST_NODE_TYPES["IfStatement"] = "IfStatement"; + AST_NODE_TYPES["ImportAttribute"] = "ImportAttribute"; + AST_NODE_TYPES["ImportDeclaration"] = "ImportDeclaration"; + AST_NODE_TYPES["ImportDefaultSpecifier"] = "ImportDefaultSpecifier"; + AST_NODE_TYPES["ImportExpression"] = "ImportExpression"; + AST_NODE_TYPES["ImportNamespaceSpecifier"] = "ImportNamespaceSpecifier"; + AST_NODE_TYPES["ImportSpecifier"] = "ImportSpecifier"; + AST_NODE_TYPES["JSXAttribute"] = "JSXAttribute"; + AST_NODE_TYPES["JSXClosingElement"] = "JSXClosingElement"; + AST_NODE_TYPES["JSXClosingFragment"] = "JSXClosingFragment"; + AST_NODE_TYPES["JSXElement"] = "JSXElement"; + AST_NODE_TYPES["JSXEmptyExpression"] = "JSXEmptyExpression"; + AST_NODE_TYPES["JSXExpressionContainer"] = "JSXExpressionContainer"; + AST_NODE_TYPES["JSXFragment"] = "JSXFragment"; + AST_NODE_TYPES["JSXIdentifier"] = "JSXIdentifier"; + AST_NODE_TYPES["JSXMemberExpression"] = "JSXMemberExpression"; + AST_NODE_TYPES["JSXNamespacedName"] = "JSXNamespacedName"; + AST_NODE_TYPES["JSXOpeningElement"] = "JSXOpeningElement"; + AST_NODE_TYPES["JSXOpeningFragment"] = "JSXOpeningFragment"; + AST_NODE_TYPES["JSXSpreadAttribute"] = "JSXSpreadAttribute"; + AST_NODE_TYPES["JSXSpreadChild"] = "JSXSpreadChild"; + AST_NODE_TYPES["JSXText"] = "JSXText"; + AST_NODE_TYPES["LabeledStatement"] = "LabeledStatement"; + AST_NODE_TYPES["Literal"] = "Literal"; + AST_NODE_TYPES["LogicalExpression"] = "LogicalExpression"; + AST_NODE_TYPES["MemberExpression"] = "MemberExpression"; + AST_NODE_TYPES["MetaProperty"] = "MetaProperty"; + AST_NODE_TYPES["MethodDefinition"] = "MethodDefinition"; + AST_NODE_TYPES["NewExpression"] = "NewExpression"; + AST_NODE_TYPES["ObjectExpression"] = "ObjectExpression"; + AST_NODE_TYPES["ObjectPattern"] = "ObjectPattern"; + AST_NODE_TYPES["PrivateIdentifier"] = "PrivateIdentifier"; + AST_NODE_TYPES["Program"] = "Program"; + AST_NODE_TYPES["Property"] = "Property"; + AST_NODE_TYPES["PropertyDefinition"] = "PropertyDefinition"; + AST_NODE_TYPES["RestElement"] = "RestElement"; + AST_NODE_TYPES["ReturnStatement"] = "ReturnStatement"; + AST_NODE_TYPES["SequenceExpression"] = "SequenceExpression"; + AST_NODE_TYPES["SpreadElement"] = "SpreadElement"; + AST_NODE_TYPES["StaticBlock"] = "StaticBlock"; + AST_NODE_TYPES["Super"] = "Super"; + AST_NODE_TYPES["SwitchCase"] = "SwitchCase"; + AST_NODE_TYPES["SwitchStatement"] = "SwitchStatement"; + AST_NODE_TYPES["TaggedTemplateExpression"] = "TaggedTemplateExpression"; + AST_NODE_TYPES["TemplateElement"] = "TemplateElement"; + AST_NODE_TYPES["TemplateLiteral"] = "TemplateLiteral"; + AST_NODE_TYPES["ThisExpression"] = "ThisExpression"; + AST_NODE_TYPES["ThrowStatement"] = "ThrowStatement"; + AST_NODE_TYPES["TryStatement"] = "TryStatement"; + AST_NODE_TYPES["UnaryExpression"] = "UnaryExpression"; + AST_NODE_TYPES["UpdateExpression"] = "UpdateExpression"; + AST_NODE_TYPES["VariableDeclaration"] = "VariableDeclaration"; + AST_NODE_TYPES["VariableDeclarator"] = "VariableDeclarator"; + AST_NODE_TYPES["WhileStatement"] = "WhileStatement"; + AST_NODE_TYPES["WithStatement"] = "WithStatement"; + AST_NODE_TYPES["YieldExpression"] = "YieldExpression"; + /** + * TS-prefixed nodes + */ + AST_NODE_TYPES["TSAbstractKeyword"] = "TSAbstractKeyword"; + AST_NODE_TYPES["TSAbstractMethodDefinition"] = "TSAbstractMethodDefinition"; + AST_NODE_TYPES["TSAbstractPropertyDefinition"] = "TSAbstractPropertyDefinition"; + AST_NODE_TYPES["TSAnyKeyword"] = "TSAnyKeyword"; + AST_NODE_TYPES["TSArrayType"] = "TSArrayType"; + AST_NODE_TYPES["TSAsExpression"] = "TSAsExpression"; + AST_NODE_TYPES["TSAsyncKeyword"] = "TSAsyncKeyword"; + AST_NODE_TYPES["TSBigIntKeyword"] = "TSBigIntKeyword"; + AST_NODE_TYPES["TSBooleanKeyword"] = "TSBooleanKeyword"; + AST_NODE_TYPES["TSCallSignatureDeclaration"] = "TSCallSignatureDeclaration"; + AST_NODE_TYPES["TSClassImplements"] = "TSClassImplements"; + AST_NODE_TYPES["TSConditionalType"] = "TSConditionalType"; + AST_NODE_TYPES["TSConstructorType"] = "TSConstructorType"; + AST_NODE_TYPES["TSConstructSignatureDeclaration"] = "TSConstructSignatureDeclaration"; + AST_NODE_TYPES["TSDeclareFunction"] = "TSDeclareFunction"; + AST_NODE_TYPES["TSDeclareKeyword"] = "TSDeclareKeyword"; + AST_NODE_TYPES["TSEmptyBodyFunctionExpression"] = "TSEmptyBodyFunctionExpression"; + AST_NODE_TYPES["TSEnumDeclaration"] = "TSEnumDeclaration"; + AST_NODE_TYPES["TSEnumMember"] = "TSEnumMember"; + AST_NODE_TYPES["TSExportAssignment"] = "TSExportAssignment"; + AST_NODE_TYPES["TSExportKeyword"] = "TSExportKeyword"; + AST_NODE_TYPES["TSExternalModuleReference"] = "TSExternalModuleReference"; + AST_NODE_TYPES["TSFunctionType"] = "TSFunctionType"; + AST_NODE_TYPES["TSImportEqualsDeclaration"] = "TSImportEqualsDeclaration"; + AST_NODE_TYPES["TSImportType"] = "TSImportType"; + AST_NODE_TYPES["TSIndexedAccessType"] = "TSIndexedAccessType"; + AST_NODE_TYPES["TSIndexSignature"] = "TSIndexSignature"; + AST_NODE_TYPES["TSInferType"] = "TSInferType"; + AST_NODE_TYPES["TSInterfaceBody"] = "TSInterfaceBody"; + AST_NODE_TYPES["TSInterfaceDeclaration"] = "TSInterfaceDeclaration"; + AST_NODE_TYPES["TSInterfaceHeritage"] = "TSInterfaceHeritage"; + AST_NODE_TYPES["TSIntersectionType"] = "TSIntersectionType"; + AST_NODE_TYPES["TSIntrinsicKeyword"] = "TSIntrinsicKeyword"; + AST_NODE_TYPES["TSLiteralType"] = "TSLiteralType"; + AST_NODE_TYPES["TSMappedType"] = "TSMappedType"; + AST_NODE_TYPES["TSMethodSignature"] = "TSMethodSignature"; + AST_NODE_TYPES["TSModuleBlock"] = "TSModuleBlock"; + AST_NODE_TYPES["TSModuleDeclaration"] = "TSModuleDeclaration"; + AST_NODE_TYPES["TSNamedTupleMember"] = "TSNamedTupleMember"; + AST_NODE_TYPES["TSNamespaceExportDeclaration"] = "TSNamespaceExportDeclaration"; + AST_NODE_TYPES["TSNeverKeyword"] = "TSNeverKeyword"; + AST_NODE_TYPES["TSNonNullExpression"] = "TSNonNullExpression"; + AST_NODE_TYPES["TSNullKeyword"] = "TSNullKeyword"; + AST_NODE_TYPES["TSNumberKeyword"] = "TSNumberKeyword"; + AST_NODE_TYPES["TSObjectKeyword"] = "TSObjectKeyword"; + AST_NODE_TYPES["TSOptionalType"] = "TSOptionalType"; + AST_NODE_TYPES["TSParameterProperty"] = "TSParameterProperty"; + AST_NODE_TYPES["TSPrivateKeyword"] = "TSPrivateKeyword"; + AST_NODE_TYPES["TSPropertySignature"] = "TSPropertySignature"; + AST_NODE_TYPES["TSProtectedKeyword"] = "TSProtectedKeyword"; + AST_NODE_TYPES["TSPublicKeyword"] = "TSPublicKeyword"; + AST_NODE_TYPES["TSQualifiedName"] = "TSQualifiedName"; + AST_NODE_TYPES["TSReadonlyKeyword"] = "TSReadonlyKeyword"; + AST_NODE_TYPES["TSRestType"] = "TSRestType"; + AST_NODE_TYPES["TSStaticKeyword"] = "TSStaticKeyword"; + AST_NODE_TYPES["TSStringKeyword"] = "TSStringKeyword"; + AST_NODE_TYPES["TSSymbolKeyword"] = "TSSymbolKeyword"; + AST_NODE_TYPES["TSTemplateLiteralType"] = "TSTemplateLiteralType"; + AST_NODE_TYPES["TSThisType"] = "TSThisType"; + AST_NODE_TYPES["TSTupleType"] = "TSTupleType"; + AST_NODE_TYPES["TSTypeAliasDeclaration"] = "TSTypeAliasDeclaration"; + AST_NODE_TYPES["TSTypeAnnotation"] = "TSTypeAnnotation"; + AST_NODE_TYPES["TSTypeAssertion"] = "TSTypeAssertion"; + AST_NODE_TYPES["TSTypeLiteral"] = "TSTypeLiteral"; + AST_NODE_TYPES["TSTypeOperator"] = "TSTypeOperator"; + AST_NODE_TYPES["TSTypeParameter"] = "TSTypeParameter"; + AST_NODE_TYPES["TSTypeParameterDeclaration"] = "TSTypeParameterDeclaration"; + AST_NODE_TYPES["TSTypeParameterInstantiation"] = "TSTypeParameterInstantiation"; + AST_NODE_TYPES["TSTypePredicate"] = "TSTypePredicate"; + AST_NODE_TYPES["TSTypeQuery"] = "TSTypeQuery"; + AST_NODE_TYPES["TSTypeReference"] = "TSTypeReference"; + AST_NODE_TYPES["TSUndefinedKeyword"] = "TSUndefinedKeyword"; + AST_NODE_TYPES["TSUnionType"] = "TSUnionType"; + AST_NODE_TYPES["TSUnknownKeyword"] = "TSUnknownKeyword"; + AST_NODE_TYPES["TSVoidKeyword"] = "TSVoidKeyword"; +})(AST_NODE_TYPES = exports.AST_NODE_TYPES || (exports.AST_NODE_TYPES = {})); +var AST_TOKEN_TYPES; +(function (AST_TOKEN_TYPES) { + AST_TOKEN_TYPES["Boolean"] = "Boolean"; + AST_TOKEN_TYPES["Identifier"] = "Identifier"; + AST_TOKEN_TYPES["JSXIdentifier"] = "JSXIdentifier"; + AST_TOKEN_TYPES["JSXText"] = "JSXText"; + AST_TOKEN_TYPES["Keyword"] = "Keyword"; + AST_TOKEN_TYPES["Null"] = "Null"; + AST_TOKEN_TYPES["Numeric"] = "Numeric"; + AST_TOKEN_TYPES["Punctuator"] = "Punctuator"; + AST_TOKEN_TYPES["RegularExpression"] = "RegularExpression"; + AST_TOKEN_TYPES["String"] = "String"; + AST_TOKEN_TYPES["Template"] = "Template"; + AST_TOKEN_TYPES["Block"] = "Block"; + AST_TOKEN_TYPES["Line"] = "Line"; +})(AST_TOKEN_TYPES = exports.AST_TOKEN_TYPES || (exports.AST_TOKEN_TYPES = {})); +//# sourceMappingURL=ast-spec.js.map \ No newline at end of file diff --git a/node_modules/@typescript-eslint/types/dist/generated/ast-spec.js.map b/node_modules/@typescript-eslint/types/dist/generated/ast-spec.js.map new file mode 100644 index 000000000..83ee68f94 --- /dev/null +++ b/node_modules/@typescript-eslint/types/dist/generated/ast-spec.js.map @@ -0,0 +1 @@ +{"version":3,"file":"ast-spec.js","sourceRoot":"","sources":["../../src/generated/ast-spec.ts"],"names":[],"mappings":";AAAA;;;;;;;;gDAQgD;;;AA+DhD,IAAY,cAuKX;AAvKD,WAAY,cAAc;IACxB,qDAAmC,CAAA;IACnC,+CAA6B,CAAA;IAC7B,qEAAmD,CAAA;IACnD,+DAA6C,CAAA;IAC7C,yDAAuC,CAAA;IACvC,qDAAmC,CAAA;IACnC,uDAAqC,CAAA;IACrC,mDAAiC,CAAA;IACjC,mDAAiC,CAAA;IACjC,mDAAiC,CAAA;IACjC,6CAA2B,CAAA;IAC3B,qDAAmC,CAAA;IACnC,yCAAuB,CAAA;IACvB,uDAAqC,CAAA;IACrC,qDAAmC,CAAA;IACnC,iEAA+C,CAAA;IAC/C,yDAAuC,CAAA;IACvC,yDAAuC,CAAA;IACvC,yCAAuB,CAAA;IACvB,uDAAqC,CAAA;IACrC,mDAAiC,CAAA;IACjC,+DAA6C,CAAA;IAC7C,uEAAqD,CAAA;IACrD,mEAAiD,CAAA;IACjD,qDAAmC,CAAA;IACnC,6DAA2C,CAAA;IAC3C,mDAAiC,CAAA;IACjC,mDAAiC,CAAA;IACjC,+CAA6B,CAAA;IAC7B,6DAA2C,CAAA;IAC3C,2DAAyC,CAAA;IACzC,2CAAyB,CAAA;IACzB,6CAA2B,CAAA;IAC3B,qDAAmC,CAAA;IACnC,yDAAuC,CAAA;IACvC,mEAAiD,CAAA;IACjD,uDAAqC,CAAA;IACrC,uEAAqD,CAAA;IACrD,qDAAmC,CAAA;IACnC,+CAA6B,CAAA;IAC7B,yDAAuC,CAAA;IACvC,2DAAyC,CAAA;IACzC,2CAAyB,CAAA;IACzB,2DAAyC,CAAA;IACzC,mEAAiD,CAAA;IACjD,6CAA2B,CAAA;IAC3B,iDAA+B,CAAA;IAC/B,6DAA2C,CAAA;IAC3C,yDAAuC,CAAA;IACvC,yDAAuC,CAAA;IACvC,2DAAyC,CAAA;IACzC,2DAAyC,CAAA;IACzC,mDAAiC,CAAA;IACjC,qCAAmB,CAAA;IACnB,uDAAqC,CAAA;IACrC,qCAAmB,CAAA;IACnB,yDAAuC,CAAA;IACvC,uDAAqC,CAAA;IACrC,+CAA6B,CAAA;IAC7B,uDAAqC,CAAA;IACrC,iDAA+B,CAAA;IAC/B,uDAAqC,CAAA;IACrC,iDAA+B,CAAA;IAC/B,yDAAuC,CAAA;IACvC,qCAAmB,CAAA;IACnB,uCAAqB,CAAA;IACrB,2DAAyC,CAAA;IACzC,6CAA2B,CAAA;IAC3B,qDAAmC,CAAA;IACnC,2DAAyC,CAAA;IACzC,iDAA+B,CAAA;IAC/B,6CAA2B,CAAA;IAC3B,iCAAe,CAAA;IACf,2CAAyB,CAAA;IACzB,qDAAmC,CAAA;IACnC,uEAAqD,CAAA;IACrD,qDAAmC,CAAA;IACnC,qDAAmC,CAAA;IACnC,mDAAiC,CAAA;IACjC,mDAAiC,CAAA;IACjC,+CAA6B,CAAA;IAC7B,qDAAmC,CAAA;IACnC,uDAAqC,CAAA;IACrC,6DAA2C,CAAA;IAC3C,2DAAyC,CAAA;IACzC,mDAAiC,CAAA;IACjC,iDAA+B,CAAA;IAC/B,qDAAmC,CAAA;IACnC;;OAEG;IACH,yDAAuC,CAAA;IACvC,2EAAyD,CAAA;IACzD,+EAA6D,CAAA;IAC7D,+CAA6B,CAAA;IAC7B,6CAA2B,CAAA;IAC3B,mDAAiC,CAAA;IACjC,mDAAiC,CAAA;IACjC,qDAAmC,CAAA;IACnC,uDAAqC,CAAA;IACrC,2EAAyD,CAAA;IACzD,yDAAuC,CAAA;IACvC,yDAAuC,CAAA;IACvC,yDAAuC,CAAA;IACvC,qFAAmE,CAAA;IACnE,yDAAuC,CAAA;IACvC,uDAAqC,CAAA;IACrC,iFAA+D,CAAA;IAC/D,yDAAuC,CAAA;IACvC,+CAA6B,CAAA;IAC7B,2DAAyC,CAAA;IACzC,qDAAmC,CAAA;IACnC,yEAAuD,CAAA;IACvD,mDAAiC,CAAA;IACjC,yEAAuD,CAAA;IACvD,+CAA6B,CAAA;IAC7B,6DAA2C,CAAA;IAC3C,uDAAqC,CAAA;IACrC,6CAA2B,CAAA;IAC3B,qDAAmC,CAAA;IACnC,mEAAiD,CAAA;IACjD,6DAA2C,CAAA;IAC3C,2DAAyC,CAAA;IACzC,2DAAyC,CAAA;IACzC,iDAA+B,CAAA;IAC/B,+CAA6B,CAAA;IAC7B,yDAAuC,CAAA;IACvC,iDAA+B,CAAA;IAC/B,6DAA2C,CAAA;IAC3C,2DAAyC,CAAA;IACzC,+EAA6D,CAAA;IAC7D,mDAAiC,CAAA;IACjC,6DAA2C,CAAA;IAC3C,iDAA+B,CAAA;IAC/B,qDAAmC,CAAA;IACnC,qDAAmC,CAAA;IACnC,mDAAiC,CAAA;IACjC,6DAA2C,CAAA;IAC3C,uDAAqC,CAAA;IACrC,6DAA2C,CAAA;IAC3C,2DAAyC,CAAA;IACzC,qDAAmC,CAAA;IACnC,qDAAmC,CAAA;IACnC,yDAAuC,CAAA;IACvC,2CAAyB,CAAA;IACzB,qDAAmC,CAAA;IACnC,qDAAmC,CAAA;IACnC,qDAAmC,CAAA;IACnC,iEAA+C,CAAA;IAC/C,2CAAyB,CAAA;IACzB,6CAA2B,CAAA;IAC3B,mEAAiD,CAAA;IACjD,uDAAqC,CAAA;IACrC,qDAAmC,CAAA;IACnC,iDAA+B,CAAA;IAC/B,mDAAiC,CAAA;IACjC,qDAAmC,CAAA;IACnC,2EAAyD,CAAA;IACzD,+EAA6D,CAAA;IAC7D,qDAAmC,CAAA;IACnC,6CAA2B,CAAA;IAC3B,qDAAmC,CAAA;IACnC,2DAAyC,CAAA;IACzC,6CAA2B,CAAA;IAC3B,uDAAqC,CAAA;IACrC,iDAA+B,CAAA;AACjC,CAAC,EAvKW,cAAc,GAAd,sBAAc,KAAd,sBAAc,QAuKzB;AAED,IAAY,eAcX;AAdD,WAAY,eAAe;IACzB,sCAAmB,CAAA;IACnB,4CAAyB,CAAA;IACzB,kDAA+B,CAAA;IAC/B,sCAAmB,CAAA;IACnB,sCAAmB,CAAA;IACnB,gCAAa,CAAA;IACb,sCAAmB,CAAA;IACnB,4CAAyB,CAAA;IACzB,0DAAuC,CAAA;IACvC,oCAAiB,CAAA;IACjB,wCAAqB,CAAA;IACrB,kCAAe,CAAA;IACf,gCAAa,CAAA;AACf,CAAC,EAdW,eAAe,GAAf,uBAAe,KAAf,uBAAe,QAc1B"} \ No newline at end of file diff --git a/node_modules/jsdom/lib/jsdom/living/generated/AbortController.js b/node_modules/jsdom/lib/jsdom/living/generated/AbortController.js new file mode 100644 index 000000000..9252c6d29 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/AbortController.js @@ -0,0 +1,130 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "AbortController"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'AbortController'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["AbortController"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor AbortController is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "Worker"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class AbortController { + constructor() { + return exports.setup(Object.create(new.target.prototype), globalObject, undefined); + } + + abort() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'abort' called on an object that is not a valid instance of AbortController."); + } + + return esValue[implSymbol].abort(); + } + + get signal() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get signal' called on an object that is not a valid instance of AbortController."); + } + + return utils.getSameObject(this, "signal", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["signal"]); + }); + } + } + Object.defineProperties(AbortController.prototype, { + abort: { enumerable: true }, + signal: { enumerable: true }, + [Symbol.toStringTag]: { value: "AbortController", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = AbortController; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: AbortController + }); +}; + +const Impl = require("../aborting/AbortController-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/AbortSignal.js b/node_modules/jsdom/lib/jsdom/living/generated/AbortSignal.js new file mode 100644 index 000000000..0dde62c5d --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/AbortSignal.js @@ -0,0 +1,159 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventHandlerNonNull = require("./EventHandlerNonNull.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const EventTarget = require("./EventTarget.js"); + +const interfaceName = "AbortSignal"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'AbortSignal'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["AbortSignal"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor AbortSignal is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + EventTarget._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "Worker"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.EventTarget === undefined) { + throw new Error("Internal error: attempting to evaluate AbortSignal before EventTarget"); + } + class AbortSignal extends globalObject.EventTarget { + constructor() { + throw new TypeError("Illegal constructor"); + } + + get aborted() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get aborted' called on an object that is not a valid instance of AbortSignal."); + } + + return esValue[implSymbol]["aborted"]; + } + + get onabort() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onabort' called on an object that is not a valid instance of AbortSignal."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onabort"]); + } + + set onabort(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onabort' called on an object that is not a valid instance of AbortSignal."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onabort' property on 'AbortSignal': The provided value" + }); + } + esValue[implSymbol]["onabort"] = V; + } + + static abort() { + return utils.tryWrapperForImpl(Impl.implementation.abort(globalObject)); + } + } + Object.defineProperties(AbortSignal.prototype, { + aborted: { enumerable: true }, + onabort: { enumerable: true }, + [Symbol.toStringTag]: { value: "AbortSignal", configurable: true } + }); + Object.defineProperties(AbortSignal, { abort: { enumerable: true } }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = AbortSignal; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: AbortSignal + }); +}; + +const Impl = require("../aborting/AbortSignal-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/AbstractRange.js b/node_modules/jsdom/lib/jsdom/living/generated/AbstractRange.js new file mode 100644 index 000000000..497223fa0 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/AbstractRange.js @@ -0,0 +1,162 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "AbstractRange"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'AbstractRange'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["AbstractRange"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor AbstractRange is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class AbstractRange { + constructor() { + throw new TypeError("Illegal constructor"); + } + + get startContainer() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get startContainer' called on an object that is not a valid instance of AbstractRange."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["startContainer"]); + } + + get startOffset() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get startOffset' called on an object that is not a valid instance of AbstractRange."); + } + + return esValue[implSymbol]["startOffset"]; + } + + get endContainer() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get endContainer' called on an object that is not a valid instance of AbstractRange."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["endContainer"]); + } + + get endOffset() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get endOffset' called on an object that is not a valid instance of AbstractRange."); + } + + return esValue[implSymbol]["endOffset"]; + } + + get collapsed() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get collapsed' called on an object that is not a valid instance of AbstractRange."); + } + + return esValue[implSymbol]["collapsed"]; + } + } + Object.defineProperties(AbstractRange.prototype, { + startContainer: { enumerable: true }, + startOffset: { enumerable: true }, + endContainer: { enumerable: true }, + endOffset: { enumerable: true }, + collapsed: { enumerable: true }, + [Symbol.toStringTag]: { value: "AbstractRange", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = AbstractRange; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: AbstractRange + }); +}; + +const Impl = require("../range/AbstractRange-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/AddEventListenerOptions.js b/node_modules/jsdom/lib/jsdom/living/generated/AddEventListenerOptions.js new file mode 100644 index 000000000..adea23246 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/AddEventListenerOptions.js @@ -0,0 +1,44 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventListenerOptions = require("./EventListenerOptions.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + EventListenerOptions._convertInherit(obj, ret, { context }); + + { + const key = "once"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'once' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "passive"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'passive' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/AssignedNodesOptions.js b/node_modules/jsdom/lib/jsdom/living/generated/AssignedNodesOptions.js new file mode 100644 index 000000000..42eae7770 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/AssignedNodesOptions.js @@ -0,0 +1,28 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + { + const key = "flatten"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'flatten' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/Attr.js b/node_modules/jsdom/lib/jsdom/living/generated/Attr.js new file mode 100644 index 000000000..476f17ab2 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/Attr.js @@ -0,0 +1,215 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const Node = require("./Node.js"); + +const interfaceName = "Attr"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'Attr'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["Attr"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor Attr is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Node._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Node === undefined) { + throw new Error("Internal error: attempting to evaluate Attr before Node"); + } + class Attr extends globalObject.Node { + constructor() { + throw new TypeError("Illegal constructor"); + } + + get namespaceURI() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get namespaceURI' called on an object that is not a valid instance of Attr."); + } + + return esValue[implSymbol]["namespaceURI"]; + } + + get prefix() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get prefix' called on an object that is not a valid instance of Attr."); + } + + return esValue[implSymbol]["prefix"]; + } + + get localName() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get localName' called on an object that is not a valid instance of Attr."); + } + + return esValue[implSymbol]["localName"]; + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of Attr."); + } + + return esValue[implSymbol]["name"]; + } + + get value() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get value' called on an object that is not a valid instance of Attr."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["value"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set value(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set value' called on an object that is not a valid instance of Attr."); + } + + V = conversions["DOMString"](V, { context: "Failed to set the 'value' property on 'Attr': The provided value" }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["value"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get ownerElement() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ownerElement' called on an object that is not a valid instance of Attr."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ownerElement"]); + } + + get specified() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get specified' called on an object that is not a valid instance of Attr."); + } + + return esValue[implSymbol]["specified"]; + } + } + Object.defineProperties(Attr.prototype, { + namespaceURI: { enumerable: true }, + prefix: { enumerable: true }, + localName: { enumerable: true }, + name: { enumerable: true }, + value: { enumerable: true }, + ownerElement: { enumerable: true }, + specified: { enumerable: true }, + [Symbol.toStringTag]: { value: "Attr", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = Attr; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: Attr + }); +}; + +const Impl = require("../attributes/Attr-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/BarProp.js b/node_modules/jsdom/lib/jsdom/living/generated/BarProp.js new file mode 100644 index 000000000..12ea9a665 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/BarProp.js @@ -0,0 +1,118 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "BarProp"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'BarProp'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["BarProp"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor BarProp is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class BarProp { + constructor() { + throw new TypeError("Illegal constructor"); + } + + get visible() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get visible' called on an object that is not a valid instance of BarProp."); + } + + return esValue[implSymbol]["visible"]; + } + } + Object.defineProperties(BarProp.prototype, { + visible: { enumerable: true }, + [Symbol.toStringTag]: { value: "BarProp", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = BarProp; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: BarProp + }); +}; + +const Impl = require("../window/BarProp-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/BinaryType.js b/node_modules/jsdom/lib/jsdom/living/generated/BinaryType.js new file mode 100644 index 000000000..1e3e7fcfa --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/BinaryType.js @@ -0,0 +1,12 @@ +"use strict"; + +const enumerationValues = new Set(["blob", "arraybuffer"]); +exports.enumerationValues = enumerationValues; + +exports.convert = function convert(value, { context = "The provided value" } = {}) { + const string = `${value}`; + if (!enumerationValues.has(string)) { + throw new TypeError(`${context} '${string}' is not a valid enumeration value for BinaryType`); + } + return string; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/Blob.js b/node_modules/jsdom/lib/jsdom/living/generated/Blob.js new file mode 100644 index 000000000..f1fba9c2d --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/Blob.js @@ -0,0 +1,198 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const BlobPropertyBag = require("./BlobPropertyBag.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "Blob"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'Blob'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["Blob"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor Blob is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "Worker"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class Blob { + constructor() { + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + if (!utils.isObject(curArg)) { + throw new TypeError("Failed to construct 'Blob': parameter 1" + " is not an iterable object."); + } else { + const V = []; + const tmp = curArg; + for (let nextItem of tmp) { + if (exports.is(nextItem)) { + nextItem = utils.implForWrapper(nextItem); + } else if (utils.isArrayBuffer(nextItem)) { + } else if (ArrayBuffer.isView(nextItem)) { + } else { + nextItem = conversions["USVString"](nextItem, { + context: "Failed to construct 'Blob': parameter 1" + "'s element" + }); + } + V.push(nextItem); + } + curArg = V; + } + } + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = BlobPropertyBag.convert(curArg, { context: "Failed to construct 'Blob': parameter 2" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + slice() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'slice' called on an object that is not a valid instance of Blob."); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + curArg = conversions["long long"](curArg, { + context: "Failed to execute 'slice' on 'Blob': parameter 1", + clamp: true + }); + } + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["long long"](curArg, { + context: "Failed to execute 'slice' on 'Blob': parameter 2", + clamp: true + }); + } + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + curArg = conversions["DOMString"](curArg, { context: "Failed to execute 'slice' on 'Blob': parameter 3" }); + } + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].slice(...args)); + } + + get size() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get size' called on an object that is not a valid instance of Blob."); + } + + return esValue[implSymbol]["size"]; + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of Blob."); + } + + return esValue[implSymbol]["type"]; + } + } + Object.defineProperties(Blob.prototype, { + slice: { enumerable: true }, + size: { enumerable: true }, + type: { enumerable: true }, + [Symbol.toStringTag]: { value: "Blob", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = Blob; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: Blob + }); +}; + +const Impl = require("../file-api/Blob-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/BlobCallback.js b/node_modules/jsdom/lib/jsdom/living/generated/BlobCallback.js new file mode 100644 index 000000000..979489fbd --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/BlobCallback.js @@ -0,0 +1,34 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +exports.convert = (value, { context = "The provided value" } = {}) => { + if (typeof value !== "function") { + throw new TypeError(context + " is not a function"); + } + + function invokeTheCallbackFunction(blob) { + if (new.target !== undefined) { + throw new Error("Internal error: invokeTheCallbackFunction is not a constructor"); + } + + const thisArg = utils.tryWrapperForImpl(this); + let callResult; + + blob = utils.tryWrapperForImpl(blob); + + callResult = Reflect.apply(value, thisArg, [blob]); + } + + invokeTheCallbackFunction.construct = blob => { + blob = utils.tryWrapperForImpl(blob); + + let callResult = Reflect.construct(value, [blob]); + }; + + invokeTheCallbackFunction[utils.wrapperSymbol] = value; + invokeTheCallbackFunction.objectReference = value; + + return invokeTheCallbackFunction; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/BlobPropertyBag.js b/node_modules/jsdom/lib/jsdom/living/generated/BlobPropertyBag.js new file mode 100644 index 000000000..611714215 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/BlobPropertyBag.js @@ -0,0 +1,42 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EndingType = require("./EndingType.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + { + const key = "endings"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = EndingType.convert(value, { context: context + " has member 'endings' that" }); + + ret[key] = value; + } else { + ret[key] = "transparent"; + } + } + + { + const key = "type"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["DOMString"](value, { context: context + " has member 'type' that" }); + + ret[key] = value; + } else { + ret[key] = ""; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/CDATASection.js b/node_modules/jsdom/lib/jsdom/living/generated/CDATASection.js new file mode 100644 index 000000000..d85da506b --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/CDATASection.js @@ -0,0 +1,114 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const Text = require("./Text.js"); + +const interfaceName = "CDATASection"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'CDATASection'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["CDATASection"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor CDATASection is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Text._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Text === undefined) { + throw new Error("Internal error: attempting to evaluate CDATASection before Text"); + } + class CDATASection extends globalObject.Text { + constructor() { + throw new TypeError("Illegal constructor"); + } + } + Object.defineProperties(CDATASection.prototype, { + [Symbol.toStringTag]: { value: "CDATASection", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = CDATASection; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: CDATASection + }); +}; + +const Impl = require("../nodes/CDATASection-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/CanPlayTypeResult.js b/node_modules/jsdom/lib/jsdom/living/generated/CanPlayTypeResult.js new file mode 100644 index 000000000..48dc3be1d --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/CanPlayTypeResult.js @@ -0,0 +1,12 @@ +"use strict"; + +const enumerationValues = new Set(["", "maybe", "probably"]); +exports.enumerationValues = enumerationValues; + +exports.convert = function convert(value, { context = "The provided value" } = {}) { + const string = `${value}`; + if (!enumerationValues.has(string)) { + throw new TypeError(`${context} '${string}' is not a valid enumeration value for CanPlayTypeResult`); + } + return string; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/CharacterData.js b/node_modules/jsdom/lib/jsdom/living/generated/CharacterData.js new file mode 100644 index 000000000..1ffa5c7da --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/CharacterData.js @@ -0,0 +1,436 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const Node = require("./Node.js"); +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "CharacterData"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'CharacterData'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["CharacterData"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor CharacterData is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Node._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Node === undefined) { + throw new Error("Internal error: attempting to evaluate CharacterData before Node"); + } + class CharacterData extends globalObject.Node { + constructor() { + throw new TypeError("Illegal constructor"); + } + + substringData(offset, count) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'substringData' called on an object that is not a valid instance of CharacterData."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'substringData' on 'CharacterData': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'substringData' on 'CharacterData': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'substringData' on 'CharacterData': parameter 2" + }); + args.push(curArg); + } + return esValue[implSymbol].substringData(...args); + } + + appendData(data) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'appendData' called on an object that is not a valid instance of CharacterData."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'appendData' on 'CharacterData': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'appendData' on 'CharacterData': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].appendData(...args); + } + + insertData(offset, data) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'insertData' called on an object that is not a valid instance of CharacterData."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'insertData' on 'CharacterData': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'insertData' on 'CharacterData': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'insertData' on 'CharacterData': parameter 2" + }); + args.push(curArg); + } + return esValue[implSymbol].insertData(...args); + } + + deleteData(offset, count) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'deleteData' called on an object that is not a valid instance of CharacterData."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'deleteData' on 'CharacterData': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'deleteData' on 'CharacterData': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'deleteData' on 'CharacterData': parameter 2" + }); + args.push(curArg); + } + return esValue[implSymbol].deleteData(...args); + } + + replaceData(offset, count, data) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'replaceData' called on an object that is not a valid instance of CharacterData."); + } + + if (arguments.length < 3) { + throw new TypeError( + "Failed to execute 'replaceData' on 'CharacterData': 3 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'replaceData' on 'CharacterData': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'replaceData' on 'CharacterData': parameter 2" + }); + args.push(curArg); + } + { + let curArg = arguments[2]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'replaceData' on 'CharacterData': parameter 3" + }); + args.push(curArg); + } + return esValue[implSymbol].replaceData(...args); + } + + before() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'before' called on an object that is not a valid instance of CharacterData."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + if (Node.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'before' on 'CharacterData': parameter " + (i + 1) + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].before(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + after() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'after' called on an object that is not a valid instance of CharacterData."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + if (Node.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'after' on 'CharacterData': parameter " + (i + 1) + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].after(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + replaceWith() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'replaceWith' called on an object that is not a valid instance of CharacterData."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + if (Node.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'replaceWith' on 'CharacterData': parameter " + (i + 1) + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].replaceWith(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + remove() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'remove' called on an object that is not a valid instance of CharacterData."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].remove(); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get data() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get data' called on an object that is not a valid instance of CharacterData."); + } + + return esValue[implSymbol]["data"]; + } + + set data(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set data' called on an object that is not a valid instance of CharacterData."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'data' property on 'CharacterData': The provided value", + treatNullAsEmptyString: true + }); + + esValue[implSymbol]["data"] = V; + } + + get length() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get length' called on an object that is not a valid instance of CharacterData."); + } + + return esValue[implSymbol]["length"]; + } + + get previousElementSibling() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get previousElementSibling' called on an object that is not a valid instance of CharacterData." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["previousElementSibling"]); + } + + get nextElementSibling() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get nextElementSibling' called on an object that is not a valid instance of CharacterData." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["nextElementSibling"]); + } + } + Object.defineProperties(CharacterData.prototype, { + substringData: { enumerable: true }, + appendData: { enumerable: true }, + insertData: { enumerable: true }, + deleteData: { enumerable: true }, + replaceData: { enumerable: true }, + before: { enumerable: true }, + after: { enumerable: true }, + replaceWith: { enumerable: true }, + remove: { enumerable: true }, + data: { enumerable: true }, + length: { enumerable: true }, + previousElementSibling: { enumerable: true }, + nextElementSibling: { enumerable: true }, + [Symbol.toStringTag]: { value: "CharacterData", configurable: true }, + [Symbol.unscopables]: { + value: { before: true, after: true, replaceWith: true, remove: true, __proto__: null }, + configurable: true + } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = CharacterData; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: CharacterData + }); +}; + +const Impl = require("../nodes/CharacterData-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/CloseEvent.js b/node_modules/jsdom/lib/jsdom/living/generated/CloseEvent.js new file mode 100644 index 000000000..64718b9a6 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/CloseEvent.js @@ -0,0 +1,164 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const CloseEventInit = require("./CloseEventInit.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const Event = require("./Event.js"); + +const interfaceName = "CloseEvent"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'CloseEvent'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["CloseEvent"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor CloseEvent is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Event._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "Worker"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Event === undefined) { + throw new Error("Internal error: attempting to evaluate CloseEvent before Event"); + } + class CloseEvent extends globalObject.Event { + constructor(type) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'CloseEvent': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'CloseEvent': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = CloseEventInit.convert(curArg, { context: "Failed to construct 'CloseEvent': parameter 2" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + get wasClean() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get wasClean' called on an object that is not a valid instance of CloseEvent."); + } + + return esValue[implSymbol]["wasClean"]; + } + + get code() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get code' called on an object that is not a valid instance of CloseEvent."); + } + + return esValue[implSymbol]["code"]; + } + + get reason() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get reason' called on an object that is not a valid instance of CloseEvent."); + } + + return esValue[implSymbol]["reason"]; + } + } + Object.defineProperties(CloseEvent.prototype, { + wasClean: { enumerable: true }, + code: { enumerable: true }, + reason: { enumerable: true }, + [Symbol.toStringTag]: { value: "CloseEvent", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = CloseEvent; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: CloseEvent + }); +}; + +const Impl = require("../events/CloseEvent-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/CloseEventInit.js b/node_modules/jsdom/lib/jsdom/living/generated/CloseEventInit.js new file mode 100644 index 000000000..e62f74dcd --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/CloseEventInit.js @@ -0,0 +1,56 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventInit = require("./EventInit.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + EventInit._convertInherit(obj, ret, { context }); + + { + const key = "code"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["unsigned short"](value, { context: context + " has member 'code' that" }); + + ret[key] = value; + } else { + ret[key] = 0; + } + } + + { + const key = "reason"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["USVString"](value, { context: context + " has member 'reason' that" }); + + ret[key] = value; + } else { + ret[key] = ""; + } + } + + { + const key = "wasClean"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'wasClean' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/Comment.js b/node_modules/jsdom/lib/jsdom/living/generated/Comment.js new file mode 100644 index 000000000..d60ee0324 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/Comment.js @@ -0,0 +1,122 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const CharacterData = require("./CharacterData.js"); + +const interfaceName = "Comment"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'Comment'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["Comment"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor Comment is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + CharacterData._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.CharacterData === undefined) { + throw new Error("Internal error: attempting to evaluate Comment before CharacterData"); + } + class Comment extends globalObject.CharacterData { + constructor() { + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'Comment': parameter 1" }); + } else { + curArg = ""; + } + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + } + Object.defineProperties(Comment.prototype, { [Symbol.toStringTag]: { value: "Comment", configurable: true } }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = Comment; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: Comment + }); +}; + +const Impl = require("../nodes/Comment-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/CompositionEvent.js b/node_modules/jsdom/lib/jsdom/living/generated/CompositionEvent.js new file mode 100644 index 000000000..ed89efc21 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/CompositionEvent.js @@ -0,0 +1,217 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const CompositionEventInit = require("./CompositionEventInit.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const UIEvent = require("./UIEvent.js"); + +const interfaceName = "CompositionEvent"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'CompositionEvent'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["CompositionEvent"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor CompositionEvent is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + UIEvent._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.UIEvent === undefined) { + throw new Error("Internal error: attempting to evaluate CompositionEvent before UIEvent"); + } + class CompositionEvent extends globalObject.UIEvent { + constructor(type) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'CompositionEvent': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'CompositionEvent': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = CompositionEventInit.convert(curArg, { + context: "Failed to construct 'CompositionEvent': parameter 2" + }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + initCompositionEvent(typeArg) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError( + "'initCompositionEvent' called on an object that is not a valid instance of CompositionEvent." + ); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'initCompositionEvent' on 'CompositionEvent': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'initCompositionEvent' on 'CompositionEvent': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initCompositionEvent' on 'CompositionEvent': parameter 2" + }); + } else { + curArg = false; + } + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initCompositionEvent' on 'CompositionEvent': parameter 3" + }); + } else { + curArg = false; + } + args.push(curArg); + } + { + let curArg = arguments[3]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = utils.tryImplForWrapper(curArg); + } + } else { + curArg = null; + } + args.push(curArg); + } + { + let curArg = arguments[4]; + if (curArg !== undefined) { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'initCompositionEvent' on 'CompositionEvent': parameter 5" + }); + } else { + curArg = ""; + } + args.push(curArg); + } + return esValue[implSymbol].initCompositionEvent(...args); + } + + get data() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get data' called on an object that is not a valid instance of CompositionEvent."); + } + + return esValue[implSymbol]["data"]; + } + } + Object.defineProperties(CompositionEvent.prototype, { + initCompositionEvent: { enumerable: true }, + data: { enumerable: true }, + [Symbol.toStringTag]: { value: "CompositionEvent", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = CompositionEvent; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: CompositionEvent + }); +}; + +const Impl = require("../events/CompositionEvent-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/CompositionEventInit.js b/node_modules/jsdom/lib/jsdom/living/generated/CompositionEventInit.js new file mode 100644 index 000000000..f3b8242a5 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/CompositionEventInit.js @@ -0,0 +1,32 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const UIEventInit = require("./UIEventInit.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + UIEventInit._convertInherit(obj, ret, { context }); + + { + const key = "data"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["DOMString"](value, { context: context + " has member 'data' that" }); + + ret[key] = value; + } else { + ret[key] = ""; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/CustomElementConstructor.js b/node_modules/jsdom/lib/jsdom/living/generated/CustomElementConstructor.js new file mode 100644 index 000000000..3371853a9 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/CustomElementConstructor.js @@ -0,0 +1,38 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +exports.convert = (value, { context = "The provided value" } = {}) => { + if (typeof value !== "function") { + throw new TypeError(context + " is not a function"); + } + + function invokeTheCallbackFunction() { + if (new.target !== undefined) { + throw new Error("Internal error: invokeTheCallbackFunction is not a constructor"); + } + + const thisArg = utils.tryWrapperForImpl(this); + let callResult; + + callResult = Reflect.apply(value, thisArg, []); + + callResult = conversions["any"](callResult, { context: context }); + + return callResult; + } + + invokeTheCallbackFunction.construct = () => { + let callResult = Reflect.construct(value, []); + + callResult = conversions["any"](callResult, { context: context }); + + return callResult; + }; + + invokeTheCallbackFunction[utils.wrapperSymbol] = value; + invokeTheCallbackFunction.objectReference = value; + + return invokeTheCallbackFunction; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/CustomElementRegistry.js b/node_modules/jsdom/lib/jsdom/living/generated/CustomElementRegistry.js new file mode 100644 index 000000000..39a6a1d3d --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/CustomElementRegistry.js @@ -0,0 +1,242 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const CustomElementConstructor = require("./CustomElementConstructor.js"); +const ElementDefinitionOptions = require("./ElementDefinitionOptions.js"); +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const Node = require("./Node.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "CustomElementRegistry"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'CustomElementRegistry'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["CustomElementRegistry"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor CustomElementRegistry is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class CustomElementRegistry { + constructor() { + throw new TypeError("Illegal constructor"); + } + + define(name, constructor) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'define' called on an object that is not a valid instance of CustomElementRegistry."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'define' on 'CustomElementRegistry': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'define' on 'CustomElementRegistry': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = CustomElementConstructor.convert(curArg, { + context: "Failed to execute 'define' on 'CustomElementRegistry': parameter 2" + }); + args.push(curArg); + } + { + let curArg = arguments[2]; + curArg = ElementDefinitionOptions.convert(curArg, { + context: "Failed to execute 'define' on 'CustomElementRegistry': parameter 3" + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].define(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get(name) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'get' called on an object that is not a valid instance of CustomElementRegistry."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'get' on 'CustomElementRegistry': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'get' on 'CustomElementRegistry': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].get(...args); + } + + whenDefined(name) { + try { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError( + "'whenDefined' called on an object that is not a valid instance of CustomElementRegistry." + ); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'whenDefined' on 'CustomElementRegistry': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'whenDefined' on 'CustomElementRegistry': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].whenDefined(...args)); + } catch (e) { + return Promise.reject(e); + } + } + + upgrade(root) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'upgrade' called on an object that is not a valid instance of CustomElementRegistry."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'upgrade' on 'CustomElementRegistry': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { + context: "Failed to execute 'upgrade' on 'CustomElementRegistry': parameter 1" + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].upgrade(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(CustomElementRegistry.prototype, { + define: { enumerable: true }, + get: { enumerable: true }, + whenDefined: { enumerable: true }, + upgrade: { enumerable: true }, + [Symbol.toStringTag]: { value: "CustomElementRegistry", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = CustomElementRegistry; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: CustomElementRegistry + }); +}; + +const Impl = require("../custom-elements/CustomElementRegistry-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/CustomEvent.js b/node_modules/jsdom/lib/jsdom/living/generated/CustomEvent.js new file mode 100644 index 000000000..84c2f2235 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/CustomEvent.js @@ -0,0 +1,200 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const CustomEventInit = require("./CustomEventInit.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const Event = require("./Event.js"); + +const interfaceName = "CustomEvent"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'CustomEvent'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["CustomEvent"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor CustomEvent is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Event._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "Worker"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Event === undefined) { + throw new Error("Internal error: attempting to evaluate CustomEvent before Event"); + } + class CustomEvent extends globalObject.Event { + constructor(type) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'CustomEvent': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'CustomEvent': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = CustomEventInit.convert(curArg, { context: "Failed to construct 'CustomEvent': parameter 2" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + initCustomEvent(type) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'initCustomEvent' called on an object that is not a valid instance of CustomEvent."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'initCustomEvent' on 'CustomEvent': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'initCustomEvent' on 'CustomEvent': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initCustomEvent' on 'CustomEvent': parameter 2" + }); + } else { + curArg = false; + } + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initCustomEvent' on 'CustomEvent': parameter 3" + }); + } else { + curArg = false; + } + args.push(curArg); + } + { + let curArg = arguments[3]; + if (curArg !== undefined) { + curArg = conversions["any"](curArg, { + context: "Failed to execute 'initCustomEvent' on 'CustomEvent': parameter 4" + }); + } else { + curArg = null; + } + args.push(curArg); + } + return esValue[implSymbol].initCustomEvent(...args); + } + + get detail() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get detail' called on an object that is not a valid instance of CustomEvent."); + } + + return esValue[implSymbol]["detail"]; + } + } + Object.defineProperties(CustomEvent.prototype, { + initCustomEvent: { enumerable: true }, + detail: { enumerable: true }, + [Symbol.toStringTag]: { value: "CustomEvent", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = CustomEvent; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: CustomEvent + }); +}; + +const Impl = require("../events/CustomEvent-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/CustomEventInit.js b/node_modules/jsdom/lib/jsdom/living/generated/CustomEventInit.js new file mode 100644 index 000000000..c241770e2 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/CustomEventInit.js @@ -0,0 +1,32 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventInit = require("./EventInit.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + EventInit._convertInherit(obj, ret, { context }); + + { + const key = "detail"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["any"](value, { context: context + " has member 'detail' that" }); + + ret[key] = value; + } else { + ret[key] = null; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/DOMImplementation.js b/node_modules/jsdom/lib/jsdom/living/generated/DOMImplementation.js new file mode 100644 index 000000000..1e4758cfc --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/DOMImplementation.js @@ -0,0 +1,232 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const DocumentType = require("./DocumentType.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "DOMImplementation"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'DOMImplementation'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["DOMImplementation"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor DOMImplementation is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class DOMImplementation { + constructor() { + throw new TypeError("Illegal constructor"); + } + + createDocumentType(qualifiedName, publicId, systemId) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError( + "'createDocumentType' called on an object that is not a valid instance of DOMImplementation." + ); + } + + if (arguments.length < 3) { + throw new TypeError( + "Failed to execute 'createDocumentType' on 'DOMImplementation': 3 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createDocumentType' on 'DOMImplementation': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createDocumentType' on 'DOMImplementation': parameter 2" + }); + args.push(curArg); + } + { + let curArg = arguments[2]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createDocumentType' on 'DOMImplementation': parameter 3" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].createDocumentType(...args)); + } + + createDocument(namespace, qualifiedName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'createDocument' called on an object that is not a valid instance of DOMImplementation."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'createDocument' on 'DOMImplementation': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createDocument' on 'DOMImplementation': parameter 1" + }); + } + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createDocument' on 'DOMImplementation': parameter 2", + treatNullAsEmptyString: true + }); + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = DocumentType.convert(curArg, { + context: "Failed to execute 'createDocument' on 'DOMImplementation': parameter 3" + }); + } + } else { + curArg = null; + } + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].createDocument(...args)); + } + + createHTMLDocument() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError( + "'createHTMLDocument' called on an object that is not a valid instance of DOMImplementation." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createHTMLDocument' on 'DOMImplementation': parameter 1" + }); + } + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].createHTMLDocument(...args)); + } + + hasFeature() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'hasFeature' called on an object that is not a valid instance of DOMImplementation."); + } + + return esValue[implSymbol].hasFeature(); + } + } + Object.defineProperties(DOMImplementation.prototype, { + createDocumentType: { enumerable: true }, + createDocument: { enumerable: true }, + createHTMLDocument: { enumerable: true }, + hasFeature: { enumerable: true }, + [Symbol.toStringTag]: { value: "DOMImplementation", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = DOMImplementation; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: DOMImplementation + }); +}; + +const Impl = require("../nodes/DOMImplementation-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/DOMParser.js b/node_modules/jsdom/lib/jsdom/living/generated/DOMParser.js new file mode 100644 index 000000000..cd146bae5 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/DOMParser.js @@ -0,0 +1,140 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const SupportedType = require("./SupportedType.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "DOMParser"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'DOMParser'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["DOMParser"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor DOMParser is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class DOMParser { + constructor() { + return exports.setup(Object.create(new.target.prototype), globalObject, undefined); + } + + parseFromString(str, type) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'parseFromString' called on an object that is not a valid instance of DOMParser."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'parseFromString' on 'DOMParser': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'parseFromString' on 'DOMParser': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = SupportedType.convert(curArg, { + context: "Failed to execute 'parseFromString' on 'DOMParser': parameter 2" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].parseFromString(...args)); + } + } + Object.defineProperties(DOMParser.prototype, { + parseFromString: { enumerable: true }, + [Symbol.toStringTag]: { value: "DOMParser", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = DOMParser; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: DOMParser + }); +}; + +const Impl = require("../domparsing/DOMParser-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/DOMStringMap.js b/node_modules/jsdom/lib/jsdom/living/generated/DOMStringMap.js new file mode 100644 index 000000000..2484c1fb1 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/DOMStringMap.js @@ -0,0 +1,322 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "DOMStringMap"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'DOMStringMap'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["DOMStringMap"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor DOMStringMap is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +function makeProxy(wrapper, globalObject) { + let proxyHandler = proxyHandlerCache.get(globalObject); + if (proxyHandler === undefined) { + proxyHandler = new ProxyHandler(globalObject); + proxyHandlerCache.set(globalObject, proxyHandler); + } + return new Proxy(wrapper, proxyHandler); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper = makeProxy(wrapper, globalObject); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + let wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper = makeProxy(wrapper, globalObject); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class DOMStringMap { + constructor() { + throw new TypeError("Illegal constructor"); + } + } + Object.defineProperties(DOMStringMap.prototype, { + [Symbol.toStringTag]: { value: "DOMStringMap", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = DOMStringMap; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: DOMStringMap + }); +}; + +const proxyHandlerCache = new WeakMap(); +class ProxyHandler { + constructor(globalObject) { + this._globalObject = globalObject; + } + + get(target, P, receiver) { + if (typeof P === "symbol") { + return Reflect.get(target, P, receiver); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc === undefined) { + const parent = Object.getPrototypeOf(target); + if (parent === null) { + return undefined; + } + return Reflect.get(target, P, receiver); + } + if (!desc.get && !desc.set) { + return desc.value; + } + const getter = desc.get; + if (getter === undefined) { + return undefined; + } + return Reflect.apply(getter, receiver, []); + } + + has(target, P) { + if (typeof P === "symbol") { + return Reflect.has(target, P); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc !== undefined) { + return true; + } + const parent = Object.getPrototypeOf(target); + if (parent !== null) { + return Reflect.has(parent, P); + } + return false; + } + + ownKeys(target) { + const keys = new Set(); + + for (const key of target[implSymbol][utils.supportedPropertyNames]) { + if (!utils.hasOwn(target, key)) { + keys.add(`${key}`); + } + } + + for (const key of Reflect.ownKeys(target)) { + keys.add(key); + } + return [...keys]; + } + + getOwnPropertyDescriptor(target, P) { + if (typeof P === "symbol") { + return Reflect.getOwnPropertyDescriptor(target, P); + } + let ignoreNamedProps = false; + + const namedValue = target[implSymbol][utils.namedGet](P); + + if (namedValue !== undefined && !utils.hasOwn(target, P) && !ignoreNamedProps) { + return { + writable: true, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(namedValue) + }; + } + + return Reflect.getOwnPropertyDescriptor(target, P); + } + + set(target, P, V, receiver) { + if (typeof P === "symbol") { + return Reflect.set(target, P, V, receiver); + } + // The `receiver` argument refers to the Proxy exotic object or an object + // that inherits from it, whereas `target` refers to the Proxy target: + if (target[implSymbol][utils.wrapperSymbol] === receiver) { + const globalObject = this._globalObject; + + if (typeof P === "string") { + let namedValue = V; + + namedValue = conversions["DOMString"](namedValue, { + context: "Failed to set the '" + P + "' property on 'DOMStringMap': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const creating = !(target[implSymbol][utils.namedGet](P) !== undefined); + if (creating) { + target[implSymbol][utils.namedSetNew](P, namedValue); + } else { + target[implSymbol][utils.namedSetExisting](P, namedValue); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + + return true; + } + } + let ownDesc; + + if (ownDesc === undefined) { + ownDesc = Reflect.getOwnPropertyDescriptor(target, P); + } + if (ownDesc === undefined) { + const parent = Reflect.getPrototypeOf(target); + if (parent !== null) { + return Reflect.set(parent, P, V, receiver); + } + ownDesc = { writable: true, enumerable: true, configurable: true, value: undefined }; + } + if (!ownDesc.writable) { + return false; + } + if (!utils.isObject(receiver)) { + return false; + } + const existingDesc = Reflect.getOwnPropertyDescriptor(receiver, P); + let valueDesc; + if (existingDesc !== undefined) { + if (existingDesc.get || existingDesc.set) { + return false; + } + if (!existingDesc.writable) { + return false; + } + valueDesc = { value: V }; + } else { + valueDesc = { writable: true, enumerable: true, configurable: true, value: V }; + } + return Reflect.defineProperty(receiver, P, valueDesc); + } + + defineProperty(target, P, desc) { + if (typeof P === "symbol") { + return Reflect.defineProperty(target, P, desc); + } + + const globalObject = this._globalObject; + + if (desc.get || desc.set) { + return false; + } + + let namedValue = desc.value; + + namedValue = conversions["DOMString"](namedValue, { + context: "Failed to set the '" + P + "' property on 'DOMStringMap': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const creating = !(target[implSymbol][utils.namedGet](P) !== undefined); + if (creating) { + target[implSymbol][utils.namedSetNew](P, namedValue); + } else { + target[implSymbol][utils.namedSetExisting](P, namedValue); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + + return true; + } + + deleteProperty(target, P) { + if (typeof P === "symbol") { + return Reflect.deleteProperty(target, P); + } + + const globalObject = this._globalObject; + + if (target[implSymbol][utils.namedGet](P) !== undefined && !utils.hasOwn(target, P)) { + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + target[implSymbol][utils.namedDelete](P); + return true; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + return Reflect.deleteProperty(target, P); + } + + preventExtensions() { + return false; + } +} + +const Impl = require("../nodes/DOMStringMap-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/DOMTokenList.js b/node_modules/jsdom/lib/jsdom/living/generated/DOMTokenList.js new file mode 100644 index 000000000..28feb55c6 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/DOMTokenList.js @@ -0,0 +1,531 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "DOMTokenList"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'DOMTokenList'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["DOMTokenList"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor DOMTokenList is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + let wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class DOMTokenList { + constructor() { + throw new TypeError("Illegal constructor"); + } + + item(index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'item' called on an object that is not a valid instance of DOMTokenList."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'item' on 'DOMTokenList': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'item' on 'DOMTokenList': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].item(...args); + } + + contains(token) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'contains' called on an object that is not a valid instance of DOMTokenList."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'contains' on 'DOMTokenList': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'contains' on 'DOMTokenList': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].contains(...args); + } + + add() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'add' called on an object that is not a valid instance of DOMTokenList."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'add' on 'DOMTokenList': parameter " + (i + 1) + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].add(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + remove() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'remove' called on an object that is not a valid instance of DOMTokenList."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'remove' on 'DOMTokenList': parameter " + (i + 1) + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].remove(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + toggle(token) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'toggle' called on an object that is not a valid instance of DOMTokenList."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'toggle' on 'DOMTokenList': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'toggle' on 'DOMTokenList': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'toggle' on 'DOMTokenList': parameter 2" + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].toggle(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + replace(token, newToken) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'replace' called on an object that is not a valid instance of DOMTokenList."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'replace' on 'DOMTokenList': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'replace' on 'DOMTokenList': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'replace' on 'DOMTokenList': parameter 2" + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].replace(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + supports(token) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'supports' called on an object that is not a valid instance of DOMTokenList."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'supports' on 'DOMTokenList': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'supports' on 'DOMTokenList': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].supports(...args); + } + + get length() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get length' called on an object that is not a valid instance of DOMTokenList."); + } + + return esValue[implSymbol]["length"]; + } + + get value() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get value' called on an object that is not a valid instance of DOMTokenList."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["value"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set value(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set value' called on an object that is not a valid instance of DOMTokenList."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'value' property on 'DOMTokenList': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["value"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + toString() { + const esValue = this; + if (!exports.is(esValue)) { + throw new TypeError("'toString' called on an object that is not a valid instance of DOMTokenList."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["value"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(DOMTokenList.prototype, { + item: { enumerable: true }, + contains: { enumerable: true }, + add: { enumerable: true }, + remove: { enumerable: true }, + toggle: { enumerable: true }, + replace: { enumerable: true }, + supports: { enumerable: true }, + length: { enumerable: true }, + value: { enumerable: true }, + toString: { enumerable: true }, + [Symbol.toStringTag]: { value: "DOMTokenList", configurable: true }, + [Symbol.iterator]: { value: Array.prototype[Symbol.iterator], configurable: true, writable: true }, + keys: { value: Array.prototype.keys, configurable: true, enumerable: true, writable: true }, + values: { value: Array.prototype[Symbol.iterator], configurable: true, enumerable: true, writable: true }, + entries: { value: Array.prototype.entries, configurable: true, enumerable: true, writable: true }, + forEach: { value: Array.prototype.forEach, configurable: true, enumerable: true, writable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = DOMTokenList; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: DOMTokenList + }); +}; + +const proxyHandler = { + get(target, P, receiver) { + if (typeof P === "symbol") { + return Reflect.get(target, P, receiver); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc === undefined) { + const parent = Object.getPrototypeOf(target); + if (parent === null) { + return undefined; + } + return Reflect.get(target, P, receiver); + } + if (!desc.get && !desc.set) { + return desc.value; + } + const getter = desc.get; + if (getter === undefined) { + return undefined; + } + return Reflect.apply(getter, receiver, []); + }, + + has(target, P) { + if (typeof P === "symbol") { + return Reflect.has(target, P); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc !== undefined) { + return true; + } + const parent = Object.getPrototypeOf(target); + if (parent !== null) { + return Reflect.has(parent, P); + } + return false; + }, + + ownKeys(target) { + const keys = new Set(); + + for (const key of target[implSymbol][utils.supportedPropertyIndices]) { + keys.add(`${key}`); + } + + for (const key of Reflect.ownKeys(target)) { + keys.add(key); + } + return [...keys]; + }, + + getOwnPropertyDescriptor(target, P) { + if (typeof P === "symbol") { + return Reflect.getOwnPropertyDescriptor(target, P); + } + let ignoreNamedProps = false; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + return { + writable: false, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + ignoreNamedProps = true; + } + + return Reflect.getOwnPropertyDescriptor(target, P); + }, + + set(target, P, V, receiver) { + if (typeof P === "symbol") { + return Reflect.set(target, P, V, receiver); + } + // The `receiver` argument refers to the Proxy exotic object or an object + // that inherits from it, whereas `target` refers to the Proxy target: + if (target[implSymbol][utils.wrapperSymbol] === receiver) { + } + let ownDesc; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + ownDesc = { + writable: false, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + } + + if (ownDesc === undefined) { + ownDesc = Reflect.getOwnPropertyDescriptor(target, P); + } + if (ownDesc === undefined) { + const parent = Reflect.getPrototypeOf(target); + if (parent !== null) { + return Reflect.set(parent, P, V, receiver); + } + ownDesc = { writable: true, enumerable: true, configurable: true, value: undefined }; + } + if (!ownDesc.writable) { + return false; + } + if (!utils.isObject(receiver)) { + return false; + } + const existingDesc = Reflect.getOwnPropertyDescriptor(receiver, P); + let valueDesc; + if (existingDesc !== undefined) { + if (existingDesc.get || existingDesc.set) { + return false; + } + if (!existingDesc.writable) { + return false; + } + valueDesc = { value: V }; + } else { + valueDesc = { writable: true, enumerable: true, configurable: true, value: V }; + } + return Reflect.defineProperty(receiver, P, valueDesc); + }, + + defineProperty(target, P, desc) { + if (typeof P === "symbol") { + return Reflect.defineProperty(target, P, desc); + } + + if (utils.isArrayIndexPropName(P)) { + return false; + } + + return Reflect.defineProperty(target, P, desc); + }, + + deleteProperty(target, P) { + if (typeof P === "symbol") { + return Reflect.deleteProperty(target, P); + } + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + return !(target[implSymbol].item(index) !== null); + } + + return Reflect.deleteProperty(target, P); + }, + + preventExtensions() { + return false; + } +}; + +const Impl = require("../nodes/DOMTokenList-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/Document.js b/node_modules/jsdom/lib/jsdom/living/generated/Document.js new file mode 100644 index 000000000..d61112447 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/Document.js @@ -0,0 +1,3322 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const ElementCreationOptions = require("./ElementCreationOptions.js"); +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const Node = require("./Node.js"); +const NodeFilter = require("./NodeFilter.js"); +const HTMLElement = require("./HTMLElement.js"); +const EventHandlerNonNull = require("./EventHandlerNonNull.js"); +const OnErrorEventHandlerNonNull = require("./OnErrorEventHandlerNonNull.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "Document"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'Document'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["Document"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor Document is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Node._internalSetup(wrapper, globalObject); + + Object.defineProperties( + wrapper, + Object.getOwnPropertyDescriptors({ + get location() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get location' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["location"]); + }, + set location(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set location' called on an object that is not a valid instance of Document."); + } + + const Q = esValue["location"]; + if (!utils.isObject(Q)) { + throw new TypeError("Property 'location' is not an object"); + } + Reflect.set(Q, "href", V); + } + }) + ); + + Object.defineProperties(wrapper, { location: { configurable: false } }); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Node === undefined) { + throw new Error("Internal error: attempting to evaluate Document before Node"); + } + class Document extends globalObject.Node { + constructor() { + return exports.setup(Object.create(new.target.prototype), globalObject, undefined); + } + + getElementsByTagName(qualifiedName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getElementsByTagName' called on an object that is not a valid instance of Document."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'getElementsByTagName' on 'Document': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getElementsByTagName' on 'Document': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].getElementsByTagName(...args)); + } + + getElementsByTagNameNS(namespace, localName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getElementsByTagNameNS' called on an object that is not a valid instance of Document."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'getElementsByTagNameNS' on 'Document': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getElementsByTagNameNS' on 'Document': parameter 1" + }); + } + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getElementsByTagNameNS' on 'Document': parameter 2" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].getElementsByTagNameNS(...args)); + } + + getElementsByClassName(classNames) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getElementsByClassName' called on an object that is not a valid instance of Document."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'getElementsByClassName' on 'Document': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getElementsByClassName' on 'Document': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].getElementsByClassName(...args)); + } + + createElement(localName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'createElement' called on an object that is not a valid instance of Document."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'createElement' on 'Document': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createElement' on 'Document': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = ElementCreationOptions.convert(curArg, { + context: "Failed to execute 'createElement' on 'Document': parameter 2" + }); + } else if (utils.isObject(curArg)) { + curArg = ElementCreationOptions.convert(curArg, { + context: "Failed to execute 'createElement' on 'Document': parameter 2" + " dictionary" + }); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createElement' on 'Document': parameter 2" + }); + } + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].createElement(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + createElementNS(namespace, qualifiedName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'createElementNS' called on an object that is not a valid instance of Document."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'createElementNS' on 'Document': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createElementNS' on 'Document': parameter 1" + }); + } + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createElementNS' on 'Document': parameter 2" + }); + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = ElementCreationOptions.convert(curArg, { + context: "Failed to execute 'createElementNS' on 'Document': parameter 3" + }); + } else if (utils.isObject(curArg)) { + curArg = ElementCreationOptions.convert(curArg, { + context: "Failed to execute 'createElementNS' on 'Document': parameter 3" + " dictionary" + }); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createElementNS' on 'Document': parameter 3" + }); + } + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].createElementNS(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + createDocumentFragment() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'createDocumentFragment' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].createDocumentFragment()); + } + + createTextNode(data) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'createTextNode' called on an object that is not a valid instance of Document."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'createTextNode' on 'Document': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createTextNode' on 'Document': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].createTextNode(...args)); + } + + createCDATASection(data) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'createCDATASection' called on an object that is not a valid instance of Document."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'createCDATASection' on 'Document': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createCDATASection' on 'Document': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].createCDATASection(...args)); + } + + createComment(data) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'createComment' called on an object that is not a valid instance of Document."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'createComment' on 'Document': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createComment' on 'Document': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].createComment(...args)); + } + + createProcessingInstruction(target, data) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError( + "'createProcessingInstruction' called on an object that is not a valid instance of Document." + ); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'createProcessingInstruction' on 'Document': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createProcessingInstruction' on 'Document': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createProcessingInstruction' on 'Document': parameter 2" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].createProcessingInstruction(...args)); + } + + importNode(node) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'importNode' called on an object that is not a valid instance of Document."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'importNode' on 'Document': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'importNode' on 'Document': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'importNode' on 'Document': parameter 2" + }); + } else { + curArg = false; + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].importNode(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + adoptNode(node) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'adoptNode' called on an object that is not a valid instance of Document."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'adoptNode' on 'Document': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'adoptNode' on 'Document': parameter 1" }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].adoptNode(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + createAttribute(localName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'createAttribute' called on an object that is not a valid instance of Document."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'createAttribute' on 'Document': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createAttribute' on 'Document': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].createAttribute(...args)); + } + + createAttributeNS(namespace, qualifiedName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'createAttributeNS' called on an object that is not a valid instance of Document."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'createAttributeNS' on 'Document': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createAttributeNS' on 'Document': parameter 1" + }); + } + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createAttributeNS' on 'Document': parameter 2" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].createAttributeNS(...args)); + } + + createEvent(interface_) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'createEvent' called on an object that is not a valid instance of Document."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'createEvent' on 'Document': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createEvent' on 'Document': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].createEvent(...args)); + } + + createRange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'createRange' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].createRange()); + } + + createNodeIterator(root) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'createNodeIterator' called on an object that is not a valid instance of Document."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'createNodeIterator' on 'Document': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'createNodeIterator' on 'Document': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'createNodeIterator' on 'Document': parameter 2" + }); + } else { + curArg = 0xffffffff; + } + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = NodeFilter.convert(curArg, { + context: "Failed to execute 'createNodeIterator' on 'Document': parameter 3" + }); + } + } else { + curArg = null; + } + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].createNodeIterator(...args)); + } + + createTreeWalker(root) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'createTreeWalker' called on an object that is not a valid instance of Document."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'createTreeWalker' on 'Document': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'createTreeWalker' on 'Document': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'createTreeWalker' on 'Document': parameter 2" + }); + } else { + curArg = 0xffffffff; + } + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = NodeFilter.convert(curArg, { + context: "Failed to execute 'createTreeWalker' on 'Document': parameter 3" + }); + } + } else { + curArg = null; + } + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].createTreeWalker(...args)); + } + + getElementsByName(elementName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getElementsByName' called on an object that is not a valid instance of Document."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'getElementsByName' on 'Document': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getElementsByName' on 'Document': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].getElementsByName(...args)); + } + + open() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'open' called on an object that is not a valid instance of Document."); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + curArg = conversions["DOMString"](curArg, { context: "Failed to execute 'open' on 'Document': parameter 1" }); + } else { + curArg = "text/html"; + } + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["DOMString"](curArg, { context: "Failed to execute 'open' on 'Document': parameter 2" }); + } else { + curArg = ""; + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].open(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + close() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'close' called on an object that is not a valid instance of Document."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].close(); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + write() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'write' called on an object that is not a valid instance of Document."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'write' on 'Document': parameter " + (i + 1) + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].write(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + writeln() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'writeln' called on an object that is not a valid instance of Document."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'writeln' on 'Document': parameter " + (i + 1) + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].writeln(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + hasFocus() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'hasFocus' called on an object that is not a valid instance of Document."); + } + + return esValue[implSymbol].hasFocus(); + } + + clear() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'clear' called on an object that is not a valid instance of Document."); + } + + return esValue[implSymbol].clear(); + } + + captureEvents() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'captureEvents' called on an object that is not a valid instance of Document."); + } + + return esValue[implSymbol].captureEvents(); + } + + releaseEvents() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'releaseEvents' called on an object that is not a valid instance of Document."); + } + + return esValue[implSymbol].releaseEvents(); + } + + getSelection() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getSelection' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].getSelection()); + } + + getElementById(elementId) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getElementById' called on an object that is not a valid instance of Document."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'getElementById' on 'Document': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getElementById' on 'Document': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].getElementById(...args)); + } + + prepend() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'prepend' called on an object that is not a valid instance of Document."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + if (Node.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'prepend' on 'Document': parameter " + (i + 1) + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].prepend(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + append() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'append' called on an object that is not a valid instance of Document."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + if (Node.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'append' on 'Document': parameter " + (i + 1) + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].append(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + replaceChildren() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'replaceChildren' called on an object that is not a valid instance of Document."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + if (Node.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'replaceChildren' on 'Document': parameter " + (i + 1) + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].replaceChildren(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + querySelector(selectors) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'querySelector' called on an object that is not a valid instance of Document."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'querySelector' on 'Document': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'querySelector' on 'Document': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].querySelector(...args)); + } + + querySelectorAll(selectors) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'querySelectorAll' called on an object that is not a valid instance of Document."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'querySelectorAll' on 'Document': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'querySelectorAll' on 'Document': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].querySelectorAll(...args)); + } + + get implementation() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get implementation' called on an object that is not a valid instance of Document."); + } + + return utils.getSameObject(this, "implementation", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["implementation"]); + }); + } + + get URL() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get URL' called on an object that is not a valid instance of Document."); + } + + return esValue[implSymbol]["URL"]; + } + + get documentURI() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get documentURI' called on an object that is not a valid instance of Document."); + } + + return esValue[implSymbol]["documentURI"]; + } + + get compatMode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get compatMode' called on an object that is not a valid instance of Document."); + } + + return esValue[implSymbol]["compatMode"]; + } + + get characterSet() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get characterSet' called on an object that is not a valid instance of Document."); + } + + return esValue[implSymbol]["characterSet"]; + } + + get charset() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get charset' called on an object that is not a valid instance of Document."); + } + + return esValue[implSymbol]["charset"]; + } + + get inputEncoding() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get inputEncoding' called on an object that is not a valid instance of Document."); + } + + return esValue[implSymbol]["inputEncoding"]; + } + + get contentType() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get contentType' called on an object that is not a valid instance of Document."); + } + + return esValue[implSymbol]["contentType"]; + } + + get doctype() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get doctype' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["doctype"]); + } + + get documentElement() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get documentElement' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["documentElement"]); + } + + get referrer() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get referrer' called on an object that is not a valid instance of Document."); + } + + return esValue[implSymbol]["referrer"]; + } + + get cookie() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get cookie' called on an object that is not a valid instance of Document."); + } + + return esValue[implSymbol]["cookie"]; + } + + set cookie(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set cookie' called on an object that is not a valid instance of Document."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'cookie' property on 'Document': The provided value" + }); + + esValue[implSymbol]["cookie"] = V; + } + + get lastModified() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get lastModified' called on an object that is not a valid instance of Document."); + } + + return esValue[implSymbol]["lastModified"]; + } + + get readyState() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get readyState' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["readyState"]); + } + + get title() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get title' called on an object that is not a valid instance of Document."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["title"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set title(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set title' called on an object that is not a valid instance of Document."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'title' property on 'Document': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["title"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get dir() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get dir' called on an object that is not a valid instance of Document."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["dir"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set dir(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set dir' called on an object that is not a valid instance of Document."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'dir' property on 'Document': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["dir"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get body() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get body' called on an object that is not a valid instance of Document."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol]["body"]); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set body(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set body' called on an object that is not a valid instance of Document."); + } + + if (V === null || V === undefined) { + V = null; + } else { + V = HTMLElement.convert(V, { context: "Failed to set the 'body' property on 'Document': The provided value" }); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["body"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get head() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get head' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["head"]); + } + + get images() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get images' called on an object that is not a valid instance of Document."); + } + + return utils.getSameObject(this, "images", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["images"]); + }); + } + + get embeds() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get embeds' called on an object that is not a valid instance of Document."); + } + + return utils.getSameObject(this, "embeds", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["embeds"]); + }); + } + + get plugins() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get plugins' called on an object that is not a valid instance of Document."); + } + + return utils.getSameObject(this, "plugins", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["plugins"]); + }); + } + + get links() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get links' called on an object that is not a valid instance of Document."); + } + + return utils.getSameObject(this, "links", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["links"]); + }); + } + + get forms() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get forms' called on an object that is not a valid instance of Document."); + } + + return utils.getSameObject(this, "forms", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["forms"]); + }); + } + + get scripts() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get scripts' called on an object that is not a valid instance of Document."); + } + + return utils.getSameObject(this, "scripts", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["scripts"]); + }); + } + + get currentScript() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get currentScript' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["currentScript"]); + } + + get defaultView() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get defaultView' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["defaultView"]); + } + + get onreadystatechange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + return; + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onreadystatechange"]); + } + + set onreadystatechange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + return; + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onreadystatechange' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onreadystatechange"] = V; + } + + get anchors() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get anchors' called on an object that is not a valid instance of Document."); + } + + return utils.getSameObject(this, "anchors", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["anchors"]); + }); + } + + get applets() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get applets' called on an object that is not a valid instance of Document."); + } + + return utils.getSameObject(this, "applets", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["applets"]); + }); + } + + get styleSheets() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get styleSheets' called on an object that is not a valid instance of Document."); + } + + return utils.getSameObject(this, "styleSheets", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["styleSheets"]); + }); + } + + get hidden() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get hidden' called on an object that is not a valid instance of Document."); + } + + return esValue[implSymbol]["hidden"]; + } + + get visibilityState() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get visibilityState' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["visibilityState"]); + } + + get onvisibilitychange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onvisibilitychange' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onvisibilitychange"]); + } + + set onvisibilitychange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onvisibilitychange' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onvisibilitychange' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onvisibilitychange"] = V; + } + + get onabort() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onabort' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onabort"]); + } + + set onabort(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onabort' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onabort' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onabort"] = V; + } + + get onauxclick() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onauxclick' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onauxclick"]); + } + + set onauxclick(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onauxclick' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onauxclick' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onauxclick"] = V; + } + + get onblur() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onblur' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onblur"]); + } + + set onblur(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onblur' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onblur' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onblur"] = V; + } + + get oncancel() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oncancel' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oncancel"]); + } + + set oncancel(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oncancel' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oncancel' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["oncancel"] = V; + } + + get oncanplay() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oncanplay' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oncanplay"]); + } + + set oncanplay(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oncanplay' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oncanplay' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["oncanplay"] = V; + } + + get oncanplaythrough() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oncanplaythrough' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oncanplaythrough"]); + } + + set oncanplaythrough(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oncanplaythrough' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oncanplaythrough' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["oncanplaythrough"] = V; + } + + get onchange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onchange' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onchange"]); + } + + set onchange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onchange' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onchange' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onchange"] = V; + } + + get onclick() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onclick' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onclick"]); + } + + set onclick(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onclick' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onclick' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onclick"] = V; + } + + get onclose() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onclose' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onclose"]); + } + + set onclose(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onclose' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onclose' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onclose"] = V; + } + + get oncontextmenu() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oncontextmenu' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oncontextmenu"]); + } + + set oncontextmenu(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oncontextmenu' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oncontextmenu' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["oncontextmenu"] = V; + } + + get oncuechange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oncuechange' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oncuechange"]); + } + + set oncuechange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oncuechange' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oncuechange' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["oncuechange"] = V; + } + + get ondblclick() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondblclick' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondblclick"]); + } + + set ondblclick(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondblclick' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondblclick' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["ondblclick"] = V; + } + + get ondrag() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondrag' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondrag"]); + } + + set ondrag(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondrag' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondrag' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["ondrag"] = V; + } + + get ondragend() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondragend' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondragend"]); + } + + set ondragend(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondragend' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondragend' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["ondragend"] = V; + } + + get ondragenter() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondragenter' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondragenter"]); + } + + set ondragenter(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondragenter' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondragenter' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["ondragenter"] = V; + } + + get ondragleave() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondragleave' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondragleave"]); + } + + set ondragleave(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondragleave' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondragleave' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["ondragleave"] = V; + } + + get ondragover() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondragover' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondragover"]); + } + + set ondragover(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondragover' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondragover' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["ondragover"] = V; + } + + get ondragstart() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondragstart' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondragstart"]); + } + + set ondragstart(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondragstart' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondragstart' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["ondragstart"] = V; + } + + get ondrop() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondrop' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondrop"]); + } + + set ondrop(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondrop' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondrop' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["ondrop"] = V; + } + + get ondurationchange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondurationchange' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondurationchange"]); + } + + set ondurationchange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondurationchange' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondurationchange' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["ondurationchange"] = V; + } + + get onemptied() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onemptied' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onemptied"]); + } + + set onemptied(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onemptied' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onemptied' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onemptied"] = V; + } + + get onended() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onended' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onended"]); + } + + set onended(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onended' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onended' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onended"] = V; + } + + get onerror() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onerror' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onerror"]); + } + + set onerror(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onerror' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = OnErrorEventHandlerNonNull.convert(V, { + context: "Failed to set the 'onerror' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onerror"] = V; + } + + get onfocus() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onfocus' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onfocus"]); + } + + set onfocus(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onfocus' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onfocus' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onfocus"] = V; + } + + get oninput() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oninput' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oninput"]); + } + + set oninput(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oninput' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oninput' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["oninput"] = V; + } + + get oninvalid() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oninvalid' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oninvalid"]); + } + + set oninvalid(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oninvalid' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oninvalid' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["oninvalid"] = V; + } + + get onkeydown() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onkeydown' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onkeydown"]); + } + + set onkeydown(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onkeydown' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onkeydown' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onkeydown"] = V; + } + + get onkeypress() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onkeypress' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onkeypress"]); + } + + set onkeypress(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onkeypress' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onkeypress' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onkeypress"] = V; + } + + get onkeyup() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onkeyup' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onkeyup"]); + } + + set onkeyup(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onkeyup' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onkeyup' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onkeyup"] = V; + } + + get onload() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onload' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onload"]); + } + + set onload(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onload' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onload' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onload"] = V; + } + + get onloadeddata() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onloadeddata' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onloadeddata"]); + } + + set onloadeddata(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onloadeddata' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onloadeddata' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onloadeddata"] = V; + } + + get onloadedmetadata() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onloadedmetadata' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onloadedmetadata"]); + } + + set onloadedmetadata(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onloadedmetadata' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onloadedmetadata' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onloadedmetadata"] = V; + } + + get onloadend() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onloadend' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onloadend"]); + } + + set onloadend(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onloadend' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onloadend' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onloadend"] = V; + } + + get onloadstart() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onloadstart' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onloadstart"]); + } + + set onloadstart(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onloadstart' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onloadstart' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onloadstart"] = V; + } + + get onmousedown() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmousedown' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmousedown"]); + } + + set onmousedown(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmousedown' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmousedown' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onmousedown"] = V; + } + + get onmouseenter() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + return; + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmouseenter"]); + } + + set onmouseenter(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + return; + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmouseenter' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onmouseenter"] = V; + } + + get onmouseleave() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + return; + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmouseleave"]); + } + + set onmouseleave(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + return; + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmouseleave' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onmouseleave"] = V; + } + + get onmousemove() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmousemove' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmousemove"]); + } + + set onmousemove(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmousemove' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmousemove' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onmousemove"] = V; + } + + get onmouseout() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmouseout' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmouseout"]); + } + + set onmouseout(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmouseout' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmouseout' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onmouseout"] = V; + } + + get onmouseover() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmouseover' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmouseover"]); + } + + set onmouseover(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmouseover' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmouseover' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onmouseover"] = V; + } + + get onmouseup() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmouseup' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmouseup"]); + } + + set onmouseup(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmouseup' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmouseup' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onmouseup"] = V; + } + + get onwheel() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onwheel' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onwheel"]); + } + + set onwheel(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onwheel' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onwheel' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onwheel"] = V; + } + + get onpause() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onpause' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onpause"]); + } + + set onpause(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onpause' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onpause' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onpause"] = V; + } + + get onplay() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onplay' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onplay"]); + } + + set onplay(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onplay' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onplay' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onplay"] = V; + } + + get onplaying() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onplaying' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onplaying"]); + } + + set onplaying(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onplaying' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onplaying' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onplaying"] = V; + } + + get onprogress() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onprogress' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onprogress"]); + } + + set onprogress(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onprogress' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onprogress' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onprogress"] = V; + } + + get onratechange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onratechange' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onratechange"]); + } + + set onratechange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onratechange' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onratechange' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onratechange"] = V; + } + + get onreset() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onreset' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onreset"]); + } + + set onreset(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onreset' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onreset' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onreset"] = V; + } + + get onresize() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onresize' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onresize"]); + } + + set onresize(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onresize' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onresize' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onresize"] = V; + } + + get onscroll() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onscroll' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onscroll"]); + } + + set onscroll(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onscroll' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onscroll' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onscroll"] = V; + } + + get onsecuritypolicyviolation() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onsecuritypolicyviolation' called on an object that is not a valid instance of Document." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onsecuritypolicyviolation"]); + } + + set onsecuritypolicyviolation(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onsecuritypolicyviolation' called on an object that is not a valid instance of Document." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onsecuritypolicyviolation' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onsecuritypolicyviolation"] = V; + } + + get onseeked() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onseeked' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onseeked"]); + } + + set onseeked(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onseeked' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onseeked' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onseeked"] = V; + } + + get onseeking() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onseeking' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onseeking"]); + } + + set onseeking(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onseeking' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onseeking' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onseeking"] = V; + } + + get onselect() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onselect' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onselect"]); + } + + set onselect(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onselect' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onselect' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onselect"] = V; + } + + get onstalled() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onstalled' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onstalled"]); + } + + set onstalled(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onstalled' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onstalled' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onstalled"] = V; + } + + get onsubmit() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onsubmit' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onsubmit"]); + } + + set onsubmit(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onsubmit' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onsubmit' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onsubmit"] = V; + } + + get onsuspend() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onsuspend' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onsuspend"]); + } + + set onsuspend(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onsuspend' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onsuspend' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onsuspend"] = V; + } + + get ontimeupdate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ontimeupdate' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ontimeupdate"]); + } + + set ontimeupdate(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ontimeupdate' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ontimeupdate' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["ontimeupdate"] = V; + } + + get ontoggle() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ontoggle' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ontoggle"]); + } + + set ontoggle(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ontoggle' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ontoggle' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["ontoggle"] = V; + } + + get onvolumechange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onvolumechange' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onvolumechange"]); + } + + set onvolumechange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onvolumechange' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onvolumechange' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onvolumechange"] = V; + } + + get onwaiting() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onwaiting' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onwaiting"]); + } + + set onwaiting(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onwaiting' called on an object that is not a valid instance of Document."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onwaiting' property on 'Document': The provided value" + }); + } + esValue[implSymbol]["onwaiting"] = V; + } + + get activeElement() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get activeElement' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["activeElement"]); + } + + get children() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get children' called on an object that is not a valid instance of Document."); + } + + return utils.getSameObject(this, "children", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["children"]); + }); + } + + get firstElementChild() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get firstElementChild' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["firstElementChild"]); + } + + get lastElementChild() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get lastElementChild' called on an object that is not a valid instance of Document."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["lastElementChild"]); + } + + get childElementCount() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get childElementCount' called on an object that is not a valid instance of Document."); + } + + return esValue[implSymbol]["childElementCount"]; + } + } + Object.defineProperties(Document.prototype, { + getElementsByTagName: { enumerable: true }, + getElementsByTagNameNS: { enumerable: true }, + getElementsByClassName: { enumerable: true }, + createElement: { enumerable: true }, + createElementNS: { enumerable: true }, + createDocumentFragment: { enumerable: true }, + createTextNode: { enumerable: true }, + createCDATASection: { enumerable: true }, + createComment: { enumerable: true }, + createProcessingInstruction: { enumerable: true }, + importNode: { enumerable: true }, + adoptNode: { enumerable: true }, + createAttribute: { enumerable: true }, + createAttributeNS: { enumerable: true }, + createEvent: { enumerable: true }, + createRange: { enumerable: true }, + createNodeIterator: { enumerable: true }, + createTreeWalker: { enumerable: true }, + getElementsByName: { enumerable: true }, + open: { enumerable: true }, + close: { enumerable: true }, + write: { enumerable: true }, + writeln: { enumerable: true }, + hasFocus: { enumerable: true }, + clear: { enumerable: true }, + captureEvents: { enumerable: true }, + releaseEvents: { enumerable: true }, + getSelection: { enumerable: true }, + getElementById: { enumerable: true }, + prepend: { enumerable: true }, + append: { enumerable: true }, + replaceChildren: { enumerable: true }, + querySelector: { enumerable: true }, + querySelectorAll: { enumerable: true }, + implementation: { enumerable: true }, + URL: { enumerable: true }, + documentURI: { enumerable: true }, + compatMode: { enumerable: true }, + characterSet: { enumerable: true }, + charset: { enumerable: true }, + inputEncoding: { enumerable: true }, + contentType: { enumerable: true }, + doctype: { enumerable: true }, + documentElement: { enumerable: true }, + referrer: { enumerable: true }, + cookie: { enumerable: true }, + lastModified: { enumerable: true }, + readyState: { enumerable: true }, + title: { enumerable: true }, + dir: { enumerable: true }, + body: { enumerable: true }, + head: { enumerable: true }, + images: { enumerable: true }, + embeds: { enumerable: true }, + plugins: { enumerable: true }, + links: { enumerable: true }, + forms: { enumerable: true }, + scripts: { enumerable: true }, + currentScript: { enumerable: true }, + defaultView: { enumerable: true }, + onreadystatechange: { enumerable: true }, + anchors: { enumerable: true }, + applets: { enumerable: true }, + styleSheets: { enumerable: true }, + hidden: { enumerable: true }, + visibilityState: { enumerable: true }, + onvisibilitychange: { enumerable: true }, + onabort: { enumerable: true }, + onauxclick: { enumerable: true }, + onblur: { enumerable: true }, + oncancel: { enumerable: true }, + oncanplay: { enumerable: true }, + oncanplaythrough: { enumerable: true }, + onchange: { enumerable: true }, + onclick: { enumerable: true }, + onclose: { enumerable: true }, + oncontextmenu: { enumerable: true }, + oncuechange: { enumerable: true }, + ondblclick: { enumerable: true }, + ondrag: { enumerable: true }, + ondragend: { enumerable: true }, + ondragenter: { enumerable: true }, + ondragleave: { enumerable: true }, + ondragover: { enumerable: true }, + ondragstart: { enumerable: true }, + ondrop: { enumerable: true }, + ondurationchange: { enumerable: true }, + onemptied: { enumerable: true }, + onended: { enumerable: true }, + onerror: { enumerable: true }, + onfocus: { enumerable: true }, + oninput: { enumerable: true }, + oninvalid: { enumerable: true }, + onkeydown: { enumerable: true }, + onkeypress: { enumerable: true }, + onkeyup: { enumerable: true }, + onload: { enumerable: true }, + onloadeddata: { enumerable: true }, + onloadedmetadata: { enumerable: true }, + onloadend: { enumerable: true }, + onloadstart: { enumerable: true }, + onmousedown: { enumerable: true }, + onmouseenter: { enumerable: true }, + onmouseleave: { enumerable: true }, + onmousemove: { enumerable: true }, + onmouseout: { enumerable: true }, + onmouseover: { enumerable: true }, + onmouseup: { enumerable: true }, + onwheel: { enumerable: true }, + onpause: { enumerable: true }, + onplay: { enumerable: true }, + onplaying: { enumerable: true }, + onprogress: { enumerable: true }, + onratechange: { enumerable: true }, + onreset: { enumerable: true }, + onresize: { enumerable: true }, + onscroll: { enumerable: true }, + onsecuritypolicyviolation: { enumerable: true }, + onseeked: { enumerable: true }, + onseeking: { enumerable: true }, + onselect: { enumerable: true }, + onstalled: { enumerable: true }, + onsubmit: { enumerable: true }, + onsuspend: { enumerable: true }, + ontimeupdate: { enumerable: true }, + ontoggle: { enumerable: true }, + onvolumechange: { enumerable: true }, + onwaiting: { enumerable: true }, + activeElement: { enumerable: true }, + children: { enumerable: true }, + firstElementChild: { enumerable: true }, + lastElementChild: { enumerable: true }, + childElementCount: { enumerable: true }, + [Symbol.toStringTag]: { value: "Document", configurable: true }, + [Symbol.unscopables]: { + value: { prepend: true, append: true, replaceChildren: true, __proto__: null }, + configurable: true + } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = Document; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: Document + }); +}; + +const Impl = require("../nodes/Document-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/DocumentFragment.js b/node_modules/jsdom/lib/jsdom/living/generated/DocumentFragment.js new file mode 100644 index 000000000..de3275556 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/DocumentFragment.js @@ -0,0 +1,325 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const Node = require("./Node.js"); +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "DocumentFragment"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'DocumentFragment'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["DocumentFragment"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor DocumentFragment is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Node._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Node === undefined) { + throw new Error("Internal error: attempting to evaluate DocumentFragment before Node"); + } + class DocumentFragment extends globalObject.Node { + constructor() { + return exports.setup(Object.create(new.target.prototype), globalObject, undefined); + } + + getElementById(elementId) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getElementById' called on an object that is not a valid instance of DocumentFragment."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'getElementById' on 'DocumentFragment': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getElementById' on 'DocumentFragment': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].getElementById(...args)); + } + + prepend() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'prepend' called on an object that is not a valid instance of DocumentFragment."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + if (Node.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'prepend' on 'DocumentFragment': parameter " + (i + 1) + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].prepend(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + append() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'append' called on an object that is not a valid instance of DocumentFragment."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + if (Node.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'append' on 'DocumentFragment': parameter " + (i + 1) + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].append(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + replaceChildren() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'replaceChildren' called on an object that is not a valid instance of DocumentFragment."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + if (Node.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'replaceChildren' on 'DocumentFragment': parameter " + (i + 1) + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].replaceChildren(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + querySelector(selectors) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'querySelector' called on an object that is not a valid instance of DocumentFragment."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'querySelector' on 'DocumentFragment': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'querySelector' on 'DocumentFragment': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].querySelector(...args)); + } + + querySelectorAll(selectors) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'querySelectorAll' called on an object that is not a valid instance of DocumentFragment."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'querySelectorAll' on 'DocumentFragment': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'querySelectorAll' on 'DocumentFragment': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].querySelectorAll(...args)); + } + + get children() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get children' called on an object that is not a valid instance of DocumentFragment."); + } + + return utils.getSameObject(this, "children", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["children"]); + }); + } + + get firstElementChild() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get firstElementChild' called on an object that is not a valid instance of DocumentFragment." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["firstElementChild"]); + } + + get lastElementChild() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get lastElementChild' called on an object that is not a valid instance of DocumentFragment." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["lastElementChild"]); + } + + get childElementCount() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get childElementCount' called on an object that is not a valid instance of DocumentFragment." + ); + } + + return esValue[implSymbol]["childElementCount"]; + } + } + Object.defineProperties(DocumentFragment.prototype, { + getElementById: { enumerable: true }, + prepend: { enumerable: true }, + append: { enumerable: true }, + replaceChildren: { enumerable: true }, + querySelector: { enumerable: true }, + querySelectorAll: { enumerable: true }, + children: { enumerable: true }, + firstElementChild: { enumerable: true }, + lastElementChild: { enumerable: true }, + childElementCount: { enumerable: true }, + [Symbol.toStringTag]: { value: "DocumentFragment", configurable: true }, + [Symbol.unscopables]: { + value: { prepend: true, append: true, replaceChildren: true, __proto__: null }, + configurable: true + } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = DocumentFragment; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: DocumentFragment + }); +}; + +const Impl = require("../nodes/DocumentFragment-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/DocumentReadyState.js b/node_modules/jsdom/lib/jsdom/living/generated/DocumentReadyState.js new file mode 100644 index 000000000..da0f75c7a --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/DocumentReadyState.js @@ -0,0 +1,12 @@ +"use strict"; + +const enumerationValues = new Set(["loading", "interactive", "complete"]); +exports.enumerationValues = enumerationValues; + +exports.convert = function convert(value, { context = "The provided value" } = {}) { + const string = `${value}`; + if (!enumerationValues.has(string)) { + throw new TypeError(`${context} '${string}' is not a valid enumeration value for DocumentReadyState`); + } + return string; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/DocumentType.js b/node_modules/jsdom/lib/jsdom/living/generated/DocumentType.js new file mode 100644 index 000000000..d757bccb0 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/DocumentType.js @@ -0,0 +1,246 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const Node = require("./Node.js"); +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "DocumentType"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'DocumentType'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["DocumentType"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor DocumentType is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Node._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Node === undefined) { + throw new Error("Internal error: attempting to evaluate DocumentType before Node"); + } + class DocumentType extends globalObject.Node { + constructor() { + throw new TypeError("Illegal constructor"); + } + + before() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'before' called on an object that is not a valid instance of DocumentType."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + if (Node.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'before' on 'DocumentType': parameter " + (i + 1) + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].before(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + after() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'after' called on an object that is not a valid instance of DocumentType."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + if (Node.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'after' on 'DocumentType': parameter " + (i + 1) + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].after(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + replaceWith() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'replaceWith' called on an object that is not a valid instance of DocumentType."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + if (Node.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'replaceWith' on 'DocumentType': parameter " + (i + 1) + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].replaceWith(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + remove() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'remove' called on an object that is not a valid instance of DocumentType."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].remove(); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of DocumentType."); + } + + return esValue[implSymbol]["name"]; + } + + get publicId() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get publicId' called on an object that is not a valid instance of DocumentType."); + } + + return esValue[implSymbol]["publicId"]; + } + + get systemId() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get systemId' called on an object that is not a valid instance of DocumentType."); + } + + return esValue[implSymbol]["systemId"]; + } + } + Object.defineProperties(DocumentType.prototype, { + before: { enumerable: true }, + after: { enumerable: true }, + replaceWith: { enumerable: true }, + remove: { enumerable: true }, + name: { enumerable: true }, + publicId: { enumerable: true }, + systemId: { enumerable: true }, + [Symbol.toStringTag]: { value: "DocumentType", configurable: true }, + [Symbol.unscopables]: { + value: { before: true, after: true, replaceWith: true, remove: true, __proto__: null }, + configurable: true + } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = DocumentType; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: DocumentType + }); +}; + +const Impl = require("../nodes/DocumentType-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/Element.js b/node_modules/jsdom/lib/jsdom/living/generated/Element.js new file mode 100644 index 000000000..1b13049cf --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/Element.js @@ -0,0 +1,1609 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const Attr = require("./Attr.js"); +const ShadowRootInit = require("./ShadowRootInit.js"); +const Node = require("./Node.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "Element"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'Element'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["Element"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor Element is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Node._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Node === undefined) { + throw new Error("Internal error: attempting to evaluate Element before Node"); + } + class Element extends globalObject.Node { + constructor() { + throw new TypeError("Illegal constructor"); + } + + hasAttributes() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'hasAttributes' called on an object that is not a valid instance of Element."); + } + + return esValue[implSymbol].hasAttributes(); + } + + getAttributeNames() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getAttributeNames' called on an object that is not a valid instance of Element."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].getAttributeNames()); + } + + getAttribute(qualifiedName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getAttribute' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'getAttribute' on 'Element': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getAttribute' on 'Element': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].getAttribute(...args); + } + + getAttributeNS(namespace, localName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getAttributeNS' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'getAttributeNS' on 'Element': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getAttributeNS' on 'Element': parameter 1" + }); + } + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getAttributeNS' on 'Element': parameter 2" + }); + args.push(curArg); + } + return esValue[implSymbol].getAttributeNS(...args); + } + + setAttribute(qualifiedName, value) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'setAttribute' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'setAttribute' on 'Element': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setAttribute' on 'Element': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setAttribute' on 'Element': parameter 2" + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].setAttribute(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + setAttributeNS(namespace, qualifiedName, value) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'setAttributeNS' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 3) { + throw new TypeError( + "Failed to execute 'setAttributeNS' on 'Element': 3 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setAttributeNS' on 'Element': parameter 1" + }); + } + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setAttributeNS' on 'Element': parameter 2" + }); + args.push(curArg); + } + { + let curArg = arguments[2]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setAttributeNS' on 'Element': parameter 3" + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].setAttributeNS(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + removeAttribute(qualifiedName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'removeAttribute' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'removeAttribute' on 'Element': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'removeAttribute' on 'Element': parameter 1" + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].removeAttribute(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + removeAttributeNS(namespace, localName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'removeAttributeNS' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'removeAttributeNS' on 'Element': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'removeAttributeNS' on 'Element': parameter 1" + }); + } + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'removeAttributeNS' on 'Element': parameter 2" + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].removeAttributeNS(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + toggleAttribute(qualifiedName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'toggleAttribute' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'toggleAttribute' on 'Element': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'toggleAttribute' on 'Element': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'toggleAttribute' on 'Element': parameter 2" + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].toggleAttribute(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + hasAttribute(qualifiedName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'hasAttribute' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'hasAttribute' on 'Element': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'hasAttribute' on 'Element': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].hasAttribute(...args); + } + + hasAttributeNS(namespace, localName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'hasAttributeNS' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'hasAttributeNS' on 'Element': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'hasAttributeNS' on 'Element': parameter 1" + }); + } + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'hasAttributeNS' on 'Element': parameter 2" + }); + args.push(curArg); + } + return esValue[implSymbol].hasAttributeNS(...args); + } + + getAttributeNode(qualifiedName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getAttributeNode' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'getAttributeNode' on 'Element': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getAttributeNode' on 'Element': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].getAttributeNode(...args)); + } + + getAttributeNodeNS(namespace, localName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getAttributeNodeNS' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'getAttributeNodeNS' on 'Element': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getAttributeNodeNS' on 'Element': parameter 1" + }); + } + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getAttributeNodeNS' on 'Element': parameter 2" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].getAttributeNodeNS(...args)); + } + + setAttributeNode(attr) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'setAttributeNode' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'setAttributeNode' on 'Element': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Attr.convert(curArg, { context: "Failed to execute 'setAttributeNode' on 'Element': parameter 1" }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].setAttributeNode(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + setAttributeNodeNS(attr) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'setAttributeNodeNS' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'setAttributeNodeNS' on 'Element': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Attr.convert(curArg, { context: "Failed to execute 'setAttributeNodeNS' on 'Element': parameter 1" }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].setAttributeNodeNS(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + removeAttributeNode(attr) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'removeAttributeNode' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'removeAttributeNode' on 'Element': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Attr.convert(curArg, { context: "Failed to execute 'removeAttributeNode' on 'Element': parameter 1" }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].removeAttributeNode(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + attachShadow(init) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'attachShadow' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'attachShadow' on 'Element': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = ShadowRootInit.convert(curArg, { + context: "Failed to execute 'attachShadow' on 'Element': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].attachShadow(...args)); + } + + closest(selectors) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'closest' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'closest' on 'Element': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to execute 'closest' on 'Element': parameter 1" }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].closest(...args)); + } + + matches(selectors) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'matches' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'matches' on 'Element': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to execute 'matches' on 'Element': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].matches(...args); + } + + webkitMatchesSelector(selectors) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'webkitMatchesSelector' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'webkitMatchesSelector' on 'Element': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'webkitMatchesSelector' on 'Element': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].webkitMatchesSelector(...args); + } + + getElementsByTagName(qualifiedName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getElementsByTagName' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'getElementsByTagName' on 'Element': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getElementsByTagName' on 'Element': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].getElementsByTagName(...args)); + } + + getElementsByTagNameNS(namespace, localName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getElementsByTagNameNS' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'getElementsByTagNameNS' on 'Element': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getElementsByTagNameNS' on 'Element': parameter 1" + }); + } + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getElementsByTagNameNS' on 'Element': parameter 2" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].getElementsByTagNameNS(...args)); + } + + getElementsByClassName(classNames) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getElementsByClassName' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'getElementsByClassName' on 'Element': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getElementsByClassName' on 'Element': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].getElementsByClassName(...args)); + } + + insertAdjacentElement(where, element) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'insertAdjacentElement' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'insertAdjacentElement' on 'Element': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'insertAdjacentElement' on 'Element': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = exports.convert(curArg, { + context: "Failed to execute 'insertAdjacentElement' on 'Element': parameter 2" + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].insertAdjacentElement(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + insertAdjacentText(where, data) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'insertAdjacentText' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'insertAdjacentText' on 'Element': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'insertAdjacentText' on 'Element': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'insertAdjacentText' on 'Element': parameter 2" + }); + args.push(curArg); + } + return esValue[implSymbol].insertAdjacentText(...args); + } + + insertAdjacentHTML(position, text) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'insertAdjacentHTML' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'insertAdjacentHTML' on 'Element': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'insertAdjacentHTML' on 'Element': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'insertAdjacentHTML' on 'Element': parameter 2" + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].insertAdjacentHTML(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + getClientRects() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getClientRects' called on an object that is not a valid instance of Element."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].getClientRects()); + } + + getBoundingClientRect() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getBoundingClientRect' called on an object that is not a valid instance of Element."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].getBoundingClientRect()); + } + + before() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'before' called on an object that is not a valid instance of Element."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + if (Node.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'before' on 'Element': parameter " + (i + 1) + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].before(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + after() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'after' called on an object that is not a valid instance of Element."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + if (Node.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'after' on 'Element': parameter " + (i + 1) + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].after(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + replaceWith() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'replaceWith' called on an object that is not a valid instance of Element."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + if (Node.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'replaceWith' on 'Element': parameter " + (i + 1) + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].replaceWith(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + remove() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'remove' called on an object that is not a valid instance of Element."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].remove(); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + prepend() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'prepend' called on an object that is not a valid instance of Element."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + if (Node.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'prepend' on 'Element': parameter " + (i + 1) + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].prepend(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + append() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'append' called on an object that is not a valid instance of Element."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + if (Node.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'append' on 'Element': parameter " + (i + 1) + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].append(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + replaceChildren() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'replaceChildren' called on an object that is not a valid instance of Element."); + } + const args = []; + for (let i = 0; i < arguments.length; i++) { + let curArg = arguments[i]; + if (Node.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'replaceChildren' on 'Element': parameter " + (i + 1) + }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].replaceChildren(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + querySelector(selectors) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'querySelector' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'querySelector' on 'Element': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'querySelector' on 'Element': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].querySelector(...args)); + } + + querySelectorAll(selectors) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'querySelectorAll' called on an object that is not a valid instance of Element."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'querySelectorAll' on 'Element': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'querySelectorAll' on 'Element': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].querySelectorAll(...args)); + } + + get namespaceURI() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get namespaceURI' called on an object that is not a valid instance of Element."); + } + + return esValue[implSymbol]["namespaceURI"]; + } + + get prefix() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get prefix' called on an object that is not a valid instance of Element."); + } + + return esValue[implSymbol]["prefix"]; + } + + get localName() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get localName' called on an object that is not a valid instance of Element."); + } + + return esValue[implSymbol]["localName"]; + } + + get tagName() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get tagName' called on an object that is not a valid instance of Element."); + } + + return esValue[implSymbol]["tagName"]; + } + + get id() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get id' called on an object that is not a valid instance of Element."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "id"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set id(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set id' called on an object that is not a valid instance of Element."); + } + + V = conversions["DOMString"](V, { context: "Failed to set the 'id' property on 'Element': The provided value" }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "id", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get className() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get className' called on an object that is not a valid instance of Element."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "class"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set className(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set className' called on an object that is not a valid instance of Element."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'className' property on 'Element': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "class", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get classList() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get classList' called on an object that is not a valid instance of Element."); + } + + return utils.getSameObject(this, "classList", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["classList"]); + }); + } + + set classList(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set classList' called on an object that is not a valid instance of Element."); + } + + const Q = esValue["classList"]; + if (!utils.isObject(Q)) { + throw new TypeError("Property 'classList' is not an object"); + } + Reflect.set(Q, "value", V); + } + + get slot() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get slot' called on an object that is not a valid instance of Element."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "slot"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set slot(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set slot' called on an object that is not a valid instance of Element."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'slot' property on 'Element': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "slot", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get attributes() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get attributes' called on an object that is not a valid instance of Element."); + } + + return utils.getSameObject(this, "attributes", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["attributes"]); + }); + } + + get shadowRoot() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get shadowRoot' called on an object that is not a valid instance of Element."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["shadowRoot"]); + } + + get outerHTML() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get outerHTML' called on an object that is not a valid instance of Element."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["outerHTML"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set outerHTML(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set outerHTML' called on an object that is not a valid instance of Element."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'outerHTML' property on 'Element': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["outerHTML"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get scrollTop() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get scrollTop' called on an object that is not a valid instance of Element."); + } + + return esValue[implSymbol]["scrollTop"]; + } + + set scrollTop(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set scrollTop' called on an object that is not a valid instance of Element."); + } + + V = conversions["unrestricted double"](V, { + context: "Failed to set the 'scrollTop' property on 'Element': The provided value" + }); + + esValue[implSymbol]["scrollTop"] = V; + } + + get scrollLeft() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get scrollLeft' called on an object that is not a valid instance of Element."); + } + + return esValue[implSymbol]["scrollLeft"]; + } + + set scrollLeft(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set scrollLeft' called on an object that is not a valid instance of Element."); + } + + V = conversions["unrestricted double"](V, { + context: "Failed to set the 'scrollLeft' property on 'Element': The provided value" + }); + + esValue[implSymbol]["scrollLeft"] = V; + } + + get scrollWidth() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get scrollWidth' called on an object that is not a valid instance of Element."); + } + + return esValue[implSymbol]["scrollWidth"]; + } + + get scrollHeight() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get scrollHeight' called on an object that is not a valid instance of Element."); + } + + return esValue[implSymbol]["scrollHeight"]; + } + + get clientTop() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get clientTop' called on an object that is not a valid instance of Element."); + } + + return esValue[implSymbol]["clientTop"]; + } + + get clientLeft() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get clientLeft' called on an object that is not a valid instance of Element."); + } + + return esValue[implSymbol]["clientLeft"]; + } + + get clientWidth() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get clientWidth' called on an object that is not a valid instance of Element."); + } + + return esValue[implSymbol]["clientWidth"]; + } + + get clientHeight() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get clientHeight' called on an object that is not a valid instance of Element."); + } + + return esValue[implSymbol]["clientHeight"]; + } + + get innerHTML() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get innerHTML' called on an object that is not a valid instance of Element."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["innerHTML"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set innerHTML(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set innerHTML' called on an object that is not a valid instance of Element."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'innerHTML' property on 'Element': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["innerHTML"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get previousElementSibling() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get previousElementSibling' called on an object that is not a valid instance of Element." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["previousElementSibling"]); + } + + get nextElementSibling() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get nextElementSibling' called on an object that is not a valid instance of Element."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["nextElementSibling"]); + } + + get children() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get children' called on an object that is not a valid instance of Element."); + } + + return utils.getSameObject(this, "children", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["children"]); + }); + } + + get firstElementChild() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get firstElementChild' called on an object that is not a valid instance of Element."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["firstElementChild"]); + } + + get lastElementChild() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get lastElementChild' called on an object that is not a valid instance of Element."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["lastElementChild"]); + } + + get childElementCount() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get childElementCount' called on an object that is not a valid instance of Element."); + } + + return esValue[implSymbol]["childElementCount"]; + } + + get assignedSlot() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get assignedSlot' called on an object that is not a valid instance of Element."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["assignedSlot"]); + } + } + Object.defineProperties(Element.prototype, { + hasAttributes: { enumerable: true }, + getAttributeNames: { enumerable: true }, + getAttribute: { enumerable: true }, + getAttributeNS: { enumerable: true }, + setAttribute: { enumerable: true }, + setAttributeNS: { enumerable: true }, + removeAttribute: { enumerable: true }, + removeAttributeNS: { enumerable: true }, + toggleAttribute: { enumerable: true }, + hasAttribute: { enumerable: true }, + hasAttributeNS: { enumerable: true }, + getAttributeNode: { enumerable: true }, + getAttributeNodeNS: { enumerable: true }, + setAttributeNode: { enumerable: true }, + setAttributeNodeNS: { enumerable: true }, + removeAttributeNode: { enumerable: true }, + attachShadow: { enumerable: true }, + closest: { enumerable: true }, + matches: { enumerable: true }, + webkitMatchesSelector: { enumerable: true }, + getElementsByTagName: { enumerable: true }, + getElementsByTagNameNS: { enumerable: true }, + getElementsByClassName: { enumerable: true }, + insertAdjacentElement: { enumerable: true }, + insertAdjacentText: { enumerable: true }, + insertAdjacentHTML: { enumerable: true }, + getClientRects: { enumerable: true }, + getBoundingClientRect: { enumerable: true }, + before: { enumerable: true }, + after: { enumerable: true }, + replaceWith: { enumerable: true }, + remove: { enumerable: true }, + prepend: { enumerable: true }, + append: { enumerable: true }, + replaceChildren: { enumerable: true }, + querySelector: { enumerable: true }, + querySelectorAll: { enumerable: true }, + namespaceURI: { enumerable: true }, + prefix: { enumerable: true }, + localName: { enumerable: true }, + tagName: { enumerable: true }, + id: { enumerable: true }, + className: { enumerable: true }, + classList: { enumerable: true }, + slot: { enumerable: true }, + attributes: { enumerable: true }, + shadowRoot: { enumerable: true }, + outerHTML: { enumerable: true }, + scrollTop: { enumerable: true }, + scrollLeft: { enumerable: true }, + scrollWidth: { enumerable: true }, + scrollHeight: { enumerable: true }, + clientTop: { enumerable: true }, + clientLeft: { enumerable: true }, + clientWidth: { enumerable: true }, + clientHeight: { enumerable: true }, + innerHTML: { enumerable: true }, + previousElementSibling: { enumerable: true }, + nextElementSibling: { enumerable: true }, + children: { enumerable: true }, + firstElementChild: { enumerable: true }, + lastElementChild: { enumerable: true }, + childElementCount: { enumerable: true }, + assignedSlot: { enumerable: true }, + [Symbol.toStringTag]: { value: "Element", configurable: true }, + [Symbol.unscopables]: { + value: { + slot: true, + before: true, + after: true, + replaceWith: true, + remove: true, + prepend: true, + append: true, + replaceChildren: true, + __proto__: null + }, + configurable: true + } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = Element; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: Element + }); +}; + +const Impl = require("../nodes/Element-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/ElementCreationOptions.js b/node_modules/jsdom/lib/jsdom/living/generated/ElementCreationOptions.js new file mode 100644 index 000000000..991bab0d8 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/ElementCreationOptions.js @@ -0,0 +1,26 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + { + const key = "is"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["DOMString"](value, { context: context + " has member 'is' that" }); + + ret[key] = value; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/ElementDefinitionOptions.js b/node_modules/jsdom/lib/jsdom/living/generated/ElementDefinitionOptions.js new file mode 100644 index 000000000..ff147674c --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/ElementDefinitionOptions.js @@ -0,0 +1,26 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + { + const key = "extends"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["DOMString"](value, { context: context + " has member 'extends' that" }); + + ret[key] = value; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/EndingType.js b/node_modules/jsdom/lib/jsdom/living/generated/EndingType.js new file mode 100644 index 000000000..940ed760f --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/EndingType.js @@ -0,0 +1,12 @@ +"use strict"; + +const enumerationValues = new Set(["transparent", "native"]); +exports.enumerationValues = enumerationValues; + +exports.convert = function convert(value, { context = "The provided value" } = {}) { + const string = `${value}`; + if (!enumerationValues.has(string)) { + throw new TypeError(`${context} '${string}' is not a valid enumeration value for EndingType`); + } + return string; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/ErrorEvent.js b/node_modules/jsdom/lib/jsdom/living/generated/ErrorEvent.js new file mode 100644 index 000000000..f63a6931f --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/ErrorEvent.js @@ -0,0 +1,186 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const ErrorEventInit = require("./ErrorEventInit.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const Event = require("./Event.js"); + +const interfaceName = "ErrorEvent"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'ErrorEvent'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["ErrorEvent"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor ErrorEvent is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Event._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "Worker"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Event === undefined) { + throw new Error("Internal error: attempting to evaluate ErrorEvent before Event"); + } + class ErrorEvent extends globalObject.Event { + constructor(type) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'ErrorEvent': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'ErrorEvent': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = ErrorEventInit.convert(curArg, { context: "Failed to construct 'ErrorEvent': parameter 2" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + get message() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get message' called on an object that is not a valid instance of ErrorEvent."); + } + + return esValue[implSymbol]["message"]; + } + + get filename() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get filename' called on an object that is not a valid instance of ErrorEvent."); + } + + return esValue[implSymbol]["filename"]; + } + + get lineno() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get lineno' called on an object that is not a valid instance of ErrorEvent."); + } + + return esValue[implSymbol]["lineno"]; + } + + get colno() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get colno' called on an object that is not a valid instance of ErrorEvent."); + } + + return esValue[implSymbol]["colno"]; + } + + get error() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get error' called on an object that is not a valid instance of ErrorEvent."); + } + + return esValue[implSymbol]["error"]; + } + } + Object.defineProperties(ErrorEvent.prototype, { + message: { enumerable: true }, + filename: { enumerable: true }, + lineno: { enumerable: true }, + colno: { enumerable: true }, + error: { enumerable: true }, + [Symbol.toStringTag]: { value: "ErrorEvent", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = ErrorEvent; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: ErrorEvent + }); +}; + +const Impl = require("../events/ErrorEvent-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/ErrorEventInit.js b/node_modules/jsdom/lib/jsdom/living/generated/ErrorEventInit.js new file mode 100644 index 000000000..389a3842d --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/ErrorEventInit.js @@ -0,0 +1,80 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventInit = require("./EventInit.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + EventInit._convertInherit(obj, ret, { context }); + + { + const key = "colno"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["unsigned long"](value, { context: context + " has member 'colno' that" }); + + ret[key] = value; + } else { + ret[key] = 0; + } + } + + { + const key = "error"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["any"](value, { context: context + " has member 'error' that" }); + + ret[key] = value; + } else { + ret[key] = null; + } + } + + { + const key = "filename"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["USVString"](value, { context: context + " has member 'filename' that" }); + + ret[key] = value; + } else { + ret[key] = ""; + } + } + + { + const key = "lineno"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["unsigned long"](value, { context: context + " has member 'lineno' that" }); + + ret[key] = value; + } else { + ret[key] = 0; + } + } + + { + const key = "message"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["DOMString"](value, { context: context + " has member 'message' that" }); + + ret[key] = value; + } else { + ret[key] = ""; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/Event.js b/node_modules/jsdom/lib/jsdom/living/generated/Event.js new file mode 100644 index 000000000..eb5d865b9 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/Event.js @@ -0,0 +1,390 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventInit = require("./EventInit.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "Event"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'Event'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["Event"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor Event is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Object.defineProperties( + wrapper, + Object.getOwnPropertyDescriptors({ + get isTrusted() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get isTrusted' called on an object that is not a valid instance of Event."); + } + + return esValue[implSymbol]["isTrusted"]; + } + }) + ); + + Object.defineProperties(wrapper, { isTrusted: { configurable: false } }); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "Worker", "AudioWorklet"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class Event { + constructor(type) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'Event': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'Event': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = EventInit.convert(curArg, { context: "Failed to construct 'Event': parameter 2" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + composedPath() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'composedPath' called on an object that is not a valid instance of Event."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].composedPath()); + } + + stopPropagation() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'stopPropagation' called on an object that is not a valid instance of Event."); + } + + return esValue[implSymbol].stopPropagation(); + } + + stopImmediatePropagation() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'stopImmediatePropagation' called on an object that is not a valid instance of Event."); + } + + return esValue[implSymbol].stopImmediatePropagation(); + } + + preventDefault() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'preventDefault' called on an object that is not a valid instance of Event."); + } + + return esValue[implSymbol].preventDefault(); + } + + initEvent(type) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'initEvent' called on an object that is not a valid instance of Event."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'initEvent' on 'Event': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to execute 'initEvent' on 'Event': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { context: "Failed to execute 'initEvent' on 'Event': parameter 2" }); + } else { + curArg = false; + } + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { context: "Failed to execute 'initEvent' on 'Event': parameter 3" }); + } else { + curArg = false; + } + args.push(curArg); + } + return esValue[implSymbol].initEvent(...args); + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of Event."); + } + + return esValue[implSymbol]["type"]; + } + + get target() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get target' called on an object that is not a valid instance of Event."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["target"]); + } + + get srcElement() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get srcElement' called on an object that is not a valid instance of Event."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["srcElement"]); + } + + get currentTarget() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get currentTarget' called on an object that is not a valid instance of Event."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["currentTarget"]); + } + + get eventPhase() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get eventPhase' called on an object that is not a valid instance of Event."); + } + + return esValue[implSymbol]["eventPhase"]; + } + + get cancelBubble() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get cancelBubble' called on an object that is not a valid instance of Event."); + } + + return esValue[implSymbol]["cancelBubble"]; + } + + set cancelBubble(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set cancelBubble' called on an object that is not a valid instance of Event."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'cancelBubble' property on 'Event': The provided value" + }); + + esValue[implSymbol]["cancelBubble"] = V; + } + + get bubbles() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get bubbles' called on an object that is not a valid instance of Event."); + } + + return esValue[implSymbol]["bubbles"]; + } + + get cancelable() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get cancelable' called on an object that is not a valid instance of Event."); + } + + return esValue[implSymbol]["cancelable"]; + } + + get returnValue() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get returnValue' called on an object that is not a valid instance of Event."); + } + + return esValue[implSymbol]["returnValue"]; + } + + set returnValue(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set returnValue' called on an object that is not a valid instance of Event."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'returnValue' property on 'Event': The provided value" + }); + + esValue[implSymbol]["returnValue"] = V; + } + + get defaultPrevented() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get defaultPrevented' called on an object that is not a valid instance of Event."); + } + + return esValue[implSymbol]["defaultPrevented"]; + } + + get composed() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get composed' called on an object that is not a valid instance of Event."); + } + + return esValue[implSymbol]["composed"]; + } + + get timeStamp() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get timeStamp' called on an object that is not a valid instance of Event."); + } + + return esValue[implSymbol]["timeStamp"]; + } + } + Object.defineProperties(Event.prototype, { + composedPath: { enumerable: true }, + stopPropagation: { enumerable: true }, + stopImmediatePropagation: { enumerable: true }, + preventDefault: { enumerable: true }, + initEvent: { enumerable: true }, + type: { enumerable: true }, + target: { enumerable: true }, + srcElement: { enumerable: true }, + currentTarget: { enumerable: true }, + eventPhase: { enumerable: true }, + cancelBubble: { enumerable: true }, + bubbles: { enumerable: true }, + cancelable: { enumerable: true }, + returnValue: { enumerable: true }, + defaultPrevented: { enumerable: true }, + composed: { enumerable: true }, + timeStamp: { enumerable: true }, + [Symbol.toStringTag]: { value: "Event", configurable: true }, + NONE: { value: 0, enumerable: true }, + CAPTURING_PHASE: { value: 1, enumerable: true }, + AT_TARGET: { value: 2, enumerable: true }, + BUBBLING_PHASE: { value: 3, enumerable: true } + }); + Object.defineProperties(Event, { + NONE: { value: 0, enumerable: true }, + CAPTURING_PHASE: { value: 1, enumerable: true }, + AT_TARGET: { value: 2, enumerable: true }, + BUBBLING_PHASE: { value: 3, enumerable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = Event; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: Event + }); +}; + +const Impl = require("../events/Event-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/EventHandlerNonNull.js b/node_modules/jsdom/lib/jsdom/living/generated/EventHandlerNonNull.js new file mode 100644 index 000000000..6e2fa6da0 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/EventHandlerNonNull.js @@ -0,0 +1,40 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +exports.convert = (value, { context = "The provided value" } = {}) => { + function invokeTheCallbackFunction(event) { + if (new.target !== undefined) { + throw new Error("Internal error: invokeTheCallbackFunction is not a constructor"); + } + + const thisArg = utils.tryWrapperForImpl(this); + let callResult; + + if (typeof value === "function") { + event = utils.tryWrapperForImpl(event); + + callResult = Reflect.apply(value, thisArg, [event]); + } + + callResult = conversions["any"](callResult, { context: context }); + + return callResult; + } + + invokeTheCallbackFunction.construct = event => { + event = utils.tryWrapperForImpl(event); + + let callResult = Reflect.construct(value, [event]); + + callResult = conversions["any"](callResult, { context: context }); + + return callResult; + }; + + invokeTheCallbackFunction[utils.wrapperSymbol] = value; + invokeTheCallbackFunction.objectReference = value; + + return invokeTheCallbackFunction; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/EventInit.js b/node_modules/jsdom/lib/jsdom/living/generated/EventInit.js new file mode 100644 index 000000000..6bc3e0ad5 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/EventInit.js @@ -0,0 +1,52 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + { + const key = "bubbles"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'bubbles' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "cancelable"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'cancelable' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "composed"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'composed' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/EventListener.js b/node_modules/jsdom/lib/jsdom/living/generated/EventListener.js new file mode 100644 index 000000000..e8b609953 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/EventListener.js @@ -0,0 +1,35 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +exports.convert = function convert(value, { context = "The provided value" } = {}) { + if (!utils.isObject(value)) { + throw new TypeError(`${context} is not an object.`); + } + + function callTheUserObjectsOperation(event) { + let thisArg = utils.tryWrapperForImpl(this); + let O = value; + let X = O; + + if (typeof O !== "function") { + X = O["handleEvent"]; + if (typeof X !== "function") { + throw new TypeError(`${context} does not correctly implement EventListener.`); + } + thisArg = O; + } + + event = utils.tryWrapperForImpl(event); + + let callResult = Reflect.apply(X, thisArg, [event]); + } + + callTheUserObjectsOperation[utils.wrapperSymbol] = value; + callTheUserObjectsOperation.objectReference = value; + + return callTheUserObjectsOperation; +}; + +exports.install = (globalObject, globalNames) => {}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/EventListenerOptions.js b/node_modules/jsdom/lib/jsdom/living/generated/EventListenerOptions.js new file mode 100644 index 000000000..f7c5d8b1e --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/EventListenerOptions.js @@ -0,0 +1,28 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + { + const key = "capture"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'capture' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/EventModifierInit.js b/node_modules/jsdom/lib/jsdom/living/generated/EventModifierInit.js new file mode 100644 index 000000000..beba571c1 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/EventModifierInit.js @@ -0,0 +1,188 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const UIEventInit = require("./UIEventInit.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + UIEventInit._convertInherit(obj, ret, { context }); + + { + const key = "altKey"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'altKey' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "ctrlKey"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'ctrlKey' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "metaKey"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'metaKey' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "modifierAltGraph"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'modifierAltGraph' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "modifierCapsLock"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'modifierCapsLock' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "modifierFn"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'modifierFn' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "modifierFnLock"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'modifierFnLock' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "modifierHyper"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'modifierHyper' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "modifierNumLock"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'modifierNumLock' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "modifierScrollLock"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'modifierScrollLock' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "modifierSuper"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'modifierSuper' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "modifierSymbol"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'modifierSymbol' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "modifierSymbolLock"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'modifierSymbolLock' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "shiftKey"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'shiftKey' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/EventTarget.js b/node_modules/jsdom/lib/jsdom/living/generated/EventTarget.js new file mode 100644 index 000000000..7e3990f98 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/EventTarget.js @@ -0,0 +1,252 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventListener = require("./EventListener.js"); +const AddEventListenerOptions = require("./AddEventListenerOptions.js"); +const EventListenerOptions = require("./EventListenerOptions.js"); +const Event = require("./Event.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "EventTarget"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'EventTarget'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["EventTarget"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor EventTarget is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "Worker", "AudioWorklet"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class EventTarget { + constructor() { + return exports.setup(Object.create(new.target.prototype), globalObject, undefined); + } + + addEventListener(type, callback) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'addEventListener' called on an object that is not a valid instance of EventTarget."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'addEventListener' on 'EventTarget': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'addEventListener' on 'EventTarget': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = EventListener.convert(curArg, { + context: "Failed to execute 'addEventListener' on 'EventTarget': parameter 2" + }); + } + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = AddEventListenerOptions.convert(curArg, { + context: "Failed to execute 'addEventListener' on 'EventTarget': parameter 3" + }); + } else if (utils.isObject(curArg)) { + curArg = AddEventListenerOptions.convert(curArg, { + context: "Failed to execute 'addEventListener' on 'EventTarget': parameter 3" + " dictionary" + }); + } else if (typeof curArg === "boolean") { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'addEventListener' on 'EventTarget': parameter 3" + }); + } else { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'addEventListener' on 'EventTarget': parameter 3" + }); + } + } + args.push(curArg); + } + return esValue[implSymbol].addEventListener(...args); + } + + removeEventListener(type, callback) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'removeEventListener' called on an object that is not a valid instance of EventTarget."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'removeEventListener' on 'EventTarget': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'removeEventListener' on 'EventTarget': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = EventListener.convert(curArg, { + context: "Failed to execute 'removeEventListener' on 'EventTarget': parameter 2" + }); + } + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = EventListenerOptions.convert(curArg, { + context: "Failed to execute 'removeEventListener' on 'EventTarget': parameter 3" + }); + } else if (utils.isObject(curArg)) { + curArg = EventListenerOptions.convert(curArg, { + context: "Failed to execute 'removeEventListener' on 'EventTarget': parameter 3" + " dictionary" + }); + } else if (typeof curArg === "boolean") { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'removeEventListener' on 'EventTarget': parameter 3" + }); + } else { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'removeEventListener' on 'EventTarget': parameter 3" + }); + } + } + args.push(curArg); + } + return esValue[implSymbol].removeEventListener(...args); + } + + dispatchEvent(event) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'dispatchEvent' called on an object that is not a valid instance of EventTarget."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'dispatchEvent' on 'EventTarget': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Event.convert(curArg, { context: "Failed to execute 'dispatchEvent' on 'EventTarget': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].dispatchEvent(...args); + } + } + Object.defineProperties(EventTarget.prototype, { + addEventListener: { enumerable: true }, + removeEventListener: { enumerable: true }, + dispatchEvent: { enumerable: true }, + [Symbol.toStringTag]: { value: "EventTarget", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = EventTarget; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: EventTarget + }); +}; + +const Impl = require("../events/EventTarget-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/External.js b/node_modules/jsdom/lib/jsdom/living/generated/External.js new file mode 100644 index 000000000..f7c351c18 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/External.js @@ -0,0 +1,129 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "External"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'External'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["External"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor External is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class External { + constructor() { + throw new TypeError("Illegal constructor"); + } + + AddSearchProvider() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'AddSearchProvider' called on an object that is not a valid instance of External."); + } + + return esValue[implSymbol].AddSearchProvider(); + } + + IsSearchProviderInstalled() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError( + "'IsSearchProviderInstalled' called on an object that is not a valid instance of External." + ); + } + + return esValue[implSymbol].IsSearchProviderInstalled(); + } + } + Object.defineProperties(External.prototype, { + AddSearchProvider: { enumerable: true }, + IsSearchProviderInstalled: { enumerable: true }, + [Symbol.toStringTag]: { value: "External", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = External; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: External + }); +}; + +const Impl = require("../window/External-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/File.js b/node_modules/jsdom/lib/jsdom/living/generated/File.js new file mode 100644 index 000000000..a88bac1f9 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/File.js @@ -0,0 +1,176 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const Blob = require("./Blob.js"); +const FilePropertyBag = require("./FilePropertyBag.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "File"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'File'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["File"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor File is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Blob._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "Worker"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Blob === undefined) { + throw new Error("Internal error: attempting to evaluate File before Blob"); + } + class File extends globalObject.Blob { + constructor(fileBits, fileName) { + if (arguments.length < 2) { + throw new TypeError( + "Failed to construct 'File': 2 arguments required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (!utils.isObject(curArg)) { + throw new TypeError("Failed to construct 'File': parameter 1" + " is not an iterable object."); + } else { + const V = []; + const tmp = curArg; + for (let nextItem of tmp) { + if (Blob.is(nextItem)) { + nextItem = utils.implForWrapper(nextItem); + } else if (utils.isArrayBuffer(nextItem)) { + } else if (ArrayBuffer.isView(nextItem)) { + } else { + nextItem = conversions["USVString"](nextItem, { + context: "Failed to construct 'File': parameter 1" + "'s element" + }); + } + V.push(nextItem); + } + curArg = V; + } + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["USVString"](curArg, { context: "Failed to construct 'File': parameter 2" }); + args.push(curArg); + } + { + let curArg = arguments[2]; + curArg = FilePropertyBag.convert(curArg, { context: "Failed to construct 'File': parameter 3" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of File."); + } + + return esValue[implSymbol]["name"]; + } + + get lastModified() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get lastModified' called on an object that is not a valid instance of File."); + } + + return esValue[implSymbol]["lastModified"]; + } + } + Object.defineProperties(File.prototype, { + name: { enumerable: true }, + lastModified: { enumerable: true }, + [Symbol.toStringTag]: { value: "File", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = File; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: File + }); +}; + +const Impl = require("../file-api/File-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/FileList.js b/node_modules/jsdom/lib/jsdom/living/generated/FileList.js new file mode 100644 index 000000000..962ba24d4 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/FileList.js @@ -0,0 +1,305 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "FileList"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'FileList'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["FileList"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor FileList is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + let wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "Worker"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class FileList { + constructor() { + throw new TypeError("Illegal constructor"); + } + + item(index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'item' called on an object that is not a valid instance of FileList."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'item' on 'FileList': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'item' on 'FileList': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].item(...args)); + } + + get length() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get length' called on an object that is not a valid instance of FileList."); + } + + return esValue[implSymbol]["length"]; + } + } + Object.defineProperties(FileList.prototype, { + item: { enumerable: true }, + length: { enumerable: true }, + [Symbol.toStringTag]: { value: "FileList", configurable: true }, + [Symbol.iterator]: { value: Array.prototype[Symbol.iterator], configurable: true, writable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = FileList; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: FileList + }); +}; + +const proxyHandler = { + get(target, P, receiver) { + if (typeof P === "symbol") { + return Reflect.get(target, P, receiver); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc === undefined) { + const parent = Object.getPrototypeOf(target); + if (parent === null) { + return undefined; + } + return Reflect.get(target, P, receiver); + } + if (!desc.get && !desc.set) { + return desc.value; + } + const getter = desc.get; + if (getter === undefined) { + return undefined; + } + return Reflect.apply(getter, receiver, []); + }, + + has(target, P) { + if (typeof P === "symbol") { + return Reflect.has(target, P); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc !== undefined) { + return true; + } + const parent = Object.getPrototypeOf(target); + if (parent !== null) { + return Reflect.has(parent, P); + } + return false; + }, + + ownKeys(target) { + const keys = new Set(); + + for (const key of target[implSymbol][utils.supportedPropertyIndices]) { + keys.add(`${key}`); + } + + for (const key of Reflect.ownKeys(target)) { + keys.add(key); + } + return [...keys]; + }, + + getOwnPropertyDescriptor(target, P) { + if (typeof P === "symbol") { + return Reflect.getOwnPropertyDescriptor(target, P); + } + let ignoreNamedProps = false; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + return { + writable: false, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + ignoreNamedProps = true; + } + + return Reflect.getOwnPropertyDescriptor(target, P); + }, + + set(target, P, V, receiver) { + if (typeof P === "symbol") { + return Reflect.set(target, P, V, receiver); + } + // The `receiver` argument refers to the Proxy exotic object or an object + // that inherits from it, whereas `target` refers to the Proxy target: + if (target[implSymbol][utils.wrapperSymbol] === receiver) { + } + let ownDesc; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + ownDesc = { + writable: false, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + } + + if (ownDesc === undefined) { + ownDesc = Reflect.getOwnPropertyDescriptor(target, P); + } + if (ownDesc === undefined) { + const parent = Reflect.getPrototypeOf(target); + if (parent !== null) { + return Reflect.set(parent, P, V, receiver); + } + ownDesc = { writable: true, enumerable: true, configurable: true, value: undefined }; + } + if (!ownDesc.writable) { + return false; + } + if (!utils.isObject(receiver)) { + return false; + } + const existingDesc = Reflect.getOwnPropertyDescriptor(receiver, P); + let valueDesc; + if (existingDesc !== undefined) { + if (existingDesc.get || existingDesc.set) { + return false; + } + if (!existingDesc.writable) { + return false; + } + valueDesc = { value: V }; + } else { + valueDesc = { writable: true, enumerable: true, configurable: true, value: V }; + } + return Reflect.defineProperty(receiver, P, valueDesc); + }, + + defineProperty(target, P, desc) { + if (typeof P === "symbol") { + return Reflect.defineProperty(target, P, desc); + } + + if (utils.isArrayIndexPropName(P)) { + return false; + } + + return Reflect.defineProperty(target, P, desc); + }, + + deleteProperty(target, P) { + if (typeof P === "symbol") { + return Reflect.deleteProperty(target, P); + } + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + return !(target[implSymbol].item(index) !== null); + } + + return Reflect.deleteProperty(target, P); + }, + + preventExtensions() { + return false; + } +}; + +const Impl = require("../file-api/FileList-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/FilePropertyBag.js b/node_modules/jsdom/lib/jsdom/living/generated/FilePropertyBag.js new file mode 100644 index 000000000..322775279 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/FilePropertyBag.js @@ -0,0 +1,30 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const BlobPropertyBag = require("./BlobPropertyBag.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + BlobPropertyBag._convertInherit(obj, ret, { context }); + + { + const key = "lastModified"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["long long"](value, { context: context + " has member 'lastModified' that" }); + + ret[key] = value; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/FileReader.js b/node_modules/jsdom/lib/jsdom/living/generated/FileReader.js new file mode 100644 index 000000000..4fc133db1 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/FileReader.js @@ -0,0 +1,440 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const Blob = require("./Blob.js"); +const EventHandlerNonNull = require("./EventHandlerNonNull.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const EventTarget = require("./EventTarget.js"); + +const interfaceName = "FileReader"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'FileReader'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["FileReader"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor FileReader is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + EventTarget._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "Worker"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.EventTarget === undefined) { + throw new Error("Internal error: attempting to evaluate FileReader before EventTarget"); + } + class FileReader extends globalObject.EventTarget { + constructor() { + return exports.setup(Object.create(new.target.prototype), globalObject, undefined); + } + + readAsArrayBuffer(blob) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'readAsArrayBuffer' called on an object that is not a valid instance of FileReader."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'readAsArrayBuffer' on 'FileReader': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Blob.convert(curArg, { + context: "Failed to execute 'readAsArrayBuffer' on 'FileReader': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].readAsArrayBuffer(...args); + } + + readAsBinaryString(blob) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'readAsBinaryString' called on an object that is not a valid instance of FileReader."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'readAsBinaryString' on 'FileReader': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Blob.convert(curArg, { + context: "Failed to execute 'readAsBinaryString' on 'FileReader': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].readAsBinaryString(...args); + } + + readAsText(blob) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'readAsText' called on an object that is not a valid instance of FileReader."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'readAsText' on 'FileReader': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Blob.convert(curArg, { context: "Failed to execute 'readAsText' on 'FileReader': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'readAsText' on 'FileReader': parameter 2" + }); + } + args.push(curArg); + } + return esValue[implSymbol].readAsText(...args); + } + + readAsDataURL(blob) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'readAsDataURL' called on an object that is not a valid instance of FileReader."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'readAsDataURL' on 'FileReader': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Blob.convert(curArg, { context: "Failed to execute 'readAsDataURL' on 'FileReader': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].readAsDataURL(...args); + } + + abort() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'abort' called on an object that is not a valid instance of FileReader."); + } + + return esValue[implSymbol].abort(); + } + + get readyState() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get readyState' called on an object that is not a valid instance of FileReader."); + } + + return esValue[implSymbol]["readyState"]; + } + + get result() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get result' called on an object that is not a valid instance of FileReader."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["result"]); + } + + get error() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get error' called on an object that is not a valid instance of FileReader."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["error"]); + } + + get onloadstart() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onloadstart' called on an object that is not a valid instance of FileReader."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onloadstart"]); + } + + set onloadstart(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onloadstart' called on an object that is not a valid instance of FileReader."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onloadstart' property on 'FileReader': The provided value" + }); + } + esValue[implSymbol]["onloadstart"] = V; + } + + get onprogress() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onprogress' called on an object that is not a valid instance of FileReader."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onprogress"]); + } + + set onprogress(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onprogress' called on an object that is not a valid instance of FileReader."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onprogress' property on 'FileReader': The provided value" + }); + } + esValue[implSymbol]["onprogress"] = V; + } + + get onload() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onload' called on an object that is not a valid instance of FileReader."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onload"]); + } + + set onload(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onload' called on an object that is not a valid instance of FileReader."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onload' property on 'FileReader': The provided value" + }); + } + esValue[implSymbol]["onload"] = V; + } + + get onabort() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onabort' called on an object that is not a valid instance of FileReader."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onabort"]); + } + + set onabort(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onabort' called on an object that is not a valid instance of FileReader."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onabort' property on 'FileReader': The provided value" + }); + } + esValue[implSymbol]["onabort"] = V; + } + + get onerror() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onerror' called on an object that is not a valid instance of FileReader."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onerror"]); + } + + set onerror(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onerror' called on an object that is not a valid instance of FileReader."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onerror' property on 'FileReader': The provided value" + }); + } + esValue[implSymbol]["onerror"] = V; + } + + get onloadend() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onloadend' called on an object that is not a valid instance of FileReader."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onloadend"]); + } + + set onloadend(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onloadend' called on an object that is not a valid instance of FileReader."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onloadend' property on 'FileReader': The provided value" + }); + } + esValue[implSymbol]["onloadend"] = V; + } + } + Object.defineProperties(FileReader.prototype, { + readAsArrayBuffer: { enumerable: true }, + readAsBinaryString: { enumerable: true }, + readAsText: { enumerable: true }, + readAsDataURL: { enumerable: true }, + abort: { enumerable: true }, + readyState: { enumerable: true }, + result: { enumerable: true }, + error: { enumerable: true }, + onloadstart: { enumerable: true }, + onprogress: { enumerable: true }, + onload: { enumerable: true }, + onabort: { enumerable: true }, + onerror: { enumerable: true }, + onloadend: { enumerable: true }, + [Symbol.toStringTag]: { value: "FileReader", configurable: true }, + EMPTY: { value: 0, enumerable: true }, + LOADING: { value: 1, enumerable: true }, + DONE: { value: 2, enumerable: true } + }); + Object.defineProperties(FileReader, { + EMPTY: { value: 0, enumerable: true }, + LOADING: { value: 1, enumerable: true }, + DONE: { value: 2, enumerable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = FileReader; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: FileReader + }); +}; + +const Impl = require("../file-api/FileReader-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/FocusEvent.js b/node_modules/jsdom/lib/jsdom/living/generated/FocusEvent.js new file mode 100644 index 000000000..62348e47b --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/FocusEvent.js @@ -0,0 +1,142 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const FocusEventInit = require("./FocusEventInit.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const UIEvent = require("./UIEvent.js"); + +const interfaceName = "FocusEvent"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'FocusEvent'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["FocusEvent"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor FocusEvent is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + UIEvent._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.UIEvent === undefined) { + throw new Error("Internal error: attempting to evaluate FocusEvent before UIEvent"); + } + class FocusEvent extends globalObject.UIEvent { + constructor(type) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'FocusEvent': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'FocusEvent': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = FocusEventInit.convert(curArg, { context: "Failed to construct 'FocusEvent': parameter 2" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + get relatedTarget() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get relatedTarget' called on an object that is not a valid instance of FocusEvent."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["relatedTarget"]); + } + } + Object.defineProperties(FocusEvent.prototype, { + relatedTarget: { enumerable: true }, + [Symbol.toStringTag]: { value: "FocusEvent", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = FocusEvent; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: FocusEvent + }); +}; + +const Impl = require("../events/FocusEvent-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/FocusEventInit.js b/node_modules/jsdom/lib/jsdom/living/generated/FocusEventInit.js new file mode 100644 index 000000000..7f226e323 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/FocusEventInit.js @@ -0,0 +1,36 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventTarget = require("./EventTarget.js"); +const UIEventInit = require("./UIEventInit.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + UIEventInit._convertInherit(obj, ret, { context }); + + { + const key = "relatedTarget"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + if (value === null || value === undefined) { + value = null; + } else { + value = EventTarget.convert(value, { context: context + " has member 'relatedTarget' that" }); + } + ret[key] = value; + } else { + ret[key] = null; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/FormData.js b/node_modules/jsdom/lib/jsdom/living/generated/FormData.js new file mode 100644 index 000000000..8b2e22a2c --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/FormData.js @@ -0,0 +1,421 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLFormElement = require("./HTMLFormElement.js"); +const Blob = require("./Blob.js"); +const Function = require("./Function.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "FormData"; + +const IteratorPrototype = Object.create(utils.IteratorPrototype, { + next: { + value: function next() { + const internal = this && this[utils.iterInternalSymbol]; + if (!internal) { + throw new TypeError("next() called on a value that is not an iterator prototype object"); + } + + const { target, kind, index } = internal; + const values = Array.from(target[implSymbol]); + const len = values.length; + if (index >= len) { + return { value: undefined, done: true }; + } + + const pair = values[index]; + internal.index = index + 1; + return utils.iteratorResult(pair.map(utils.tryWrapperForImpl), kind); + }, + writable: true, + enumerable: true, + configurable: true + }, + [Symbol.toStringTag]: { + value: "FormData Iterator", + configurable: true + } +}); + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'FormData'.`); +}; + +exports.createDefaultIterator = (target, kind) => { + const iterator = Object.create(IteratorPrototype); + Object.defineProperty(iterator, utils.iterInternalSymbol, { + value: { target, kind, index: 0 }, + configurable: true + }); + return iterator; +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["FormData"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor FormData is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "Worker"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class FormData { + constructor() { + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + curArg = HTMLFormElement.convert(curArg, { context: "Failed to construct 'FormData': parameter 1" }); + } + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + append(name, value) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'append' called on an object that is not a valid instance of FormData."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'append' on 'FormData': 2 arguments required, but only " + arguments.length + " present." + ); + } + const args = []; + switch (arguments.length) { + case 2: + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'append' on 'FormData': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (Blob.is(curArg)) { + { + let curArg = arguments[1]; + curArg = Blob.convert(curArg, { context: "Failed to execute 'append' on 'FormData': parameter 2" }); + args.push(curArg); + } + } else { + { + let curArg = arguments[1]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'append' on 'FormData': parameter 2" + }); + args.push(curArg); + } + } + } + break; + default: + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'append' on 'FormData': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = Blob.convert(curArg, { context: "Failed to execute 'append' on 'FormData': parameter 2" }); + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'append' on 'FormData': parameter 3" + }); + } + args.push(curArg); + } + } + return esValue[implSymbol].append(...args); + } + + delete(name) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'delete' called on an object that is not a valid instance of FormData."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'delete' on 'FormData': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { context: "Failed to execute 'delete' on 'FormData': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].delete(...args); + } + + get(name) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'get' called on an object that is not a valid instance of FormData."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'get' on 'FormData': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { context: "Failed to execute 'get' on 'FormData': parameter 1" }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].get(...args)); + } + + getAll(name) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getAll' called on an object that is not a valid instance of FormData."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'getAll' on 'FormData': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { context: "Failed to execute 'getAll' on 'FormData': parameter 1" }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].getAll(...args)); + } + + has(name) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'has' called on an object that is not a valid instance of FormData."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'has' on 'FormData': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { context: "Failed to execute 'has' on 'FormData': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].has(...args); + } + + set(name, value) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'set' called on an object that is not a valid instance of FormData."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'set' on 'FormData': 2 arguments required, but only " + arguments.length + " present." + ); + } + const args = []; + switch (arguments.length) { + case 2: + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'set' on 'FormData': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (Blob.is(curArg)) { + { + let curArg = arguments[1]; + curArg = Blob.convert(curArg, { context: "Failed to execute 'set' on 'FormData': parameter 2" }); + args.push(curArg); + } + } else { + { + let curArg = arguments[1]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'set' on 'FormData': parameter 2" + }); + args.push(curArg); + } + } + } + break; + default: + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'set' on 'FormData': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = Blob.convert(curArg, { context: "Failed to execute 'set' on 'FormData': parameter 2" }); + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'set' on 'FormData': parameter 3" + }); + } + args.push(curArg); + } + } + return esValue[implSymbol].set(...args); + } + + keys() { + if (!exports.is(this)) { + throw new TypeError("'keys' called on an object that is not a valid instance of FormData."); + } + return exports.createDefaultIterator(this, "key"); + } + + values() { + if (!exports.is(this)) { + throw new TypeError("'values' called on an object that is not a valid instance of FormData."); + } + return exports.createDefaultIterator(this, "value"); + } + + entries() { + if (!exports.is(this)) { + throw new TypeError("'entries' called on an object that is not a valid instance of FormData."); + } + return exports.createDefaultIterator(this, "key+value"); + } + + forEach(callback) { + if (!exports.is(this)) { + throw new TypeError("'forEach' called on an object that is not a valid instance of FormData."); + } + if (arguments.length < 1) { + throw new TypeError("Failed to execute 'forEach' on 'iterable': 1 argument required, " + "but only 0 present."); + } + callback = Function.convert(callback, { + context: "Failed to execute 'forEach' on 'iterable': The callback provided as parameter 1" + }); + const thisArg = arguments[1]; + let pairs = Array.from(this[implSymbol]); + let i = 0; + while (i < pairs.length) { + const [key, value] = pairs[i].map(utils.tryWrapperForImpl); + callback.call(thisArg, value, key, this); + pairs = Array.from(this[implSymbol]); + i++; + } + } + } + Object.defineProperties(FormData.prototype, { + append: { enumerable: true }, + delete: { enumerable: true }, + get: { enumerable: true }, + getAll: { enumerable: true }, + has: { enumerable: true }, + set: { enumerable: true }, + keys: { enumerable: true }, + values: { enumerable: true }, + entries: { enumerable: true }, + forEach: { enumerable: true }, + [Symbol.toStringTag]: { value: "FormData", configurable: true }, + [Symbol.iterator]: { value: FormData.prototype.entries, configurable: true, writable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = FormData; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: FormData + }); +}; + +const Impl = require("../xhr/FormData-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/Function.js b/node_modules/jsdom/lib/jsdom/living/generated/Function.js new file mode 100644 index 000000000..bf5c80898 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/Function.js @@ -0,0 +1,46 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +exports.convert = (value, { context = "The provided value" } = {}) => { + if (typeof value !== "function") { + throw new TypeError(context + " is not a function"); + } + + function invokeTheCallbackFunction(...args) { + if (new.target !== undefined) { + throw new Error("Internal error: invokeTheCallbackFunction is not a constructor"); + } + + const thisArg = utils.tryWrapperForImpl(this); + let callResult; + + for (let i = 0; i < args.length; i++) { + args[i] = utils.tryWrapperForImpl(args[i]); + } + + callResult = Reflect.apply(value, thisArg, args); + + callResult = conversions["any"](callResult, { context: context }); + + return callResult; + } + + invokeTheCallbackFunction.construct = (...args) => { + for (let i = 0; i < args.length; i++) { + args[i] = utils.tryWrapperForImpl(args[i]); + } + + let callResult = Reflect.construct(value, args); + + callResult = conversions["any"](callResult, { context: context }); + + return callResult; + }; + + invokeTheCallbackFunction[utils.wrapperSymbol] = value; + invokeTheCallbackFunction.objectReference = value; + + return invokeTheCallbackFunction; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/GetRootNodeOptions.js b/node_modules/jsdom/lib/jsdom/living/generated/GetRootNodeOptions.js new file mode 100644 index 000000000..4d60bd5b7 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/GetRootNodeOptions.js @@ -0,0 +1,28 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + { + const key = "composed"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'composed' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLAnchorElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLAnchorElement.js new file mode 100644 index 000000000..0f66b64f6 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLAnchorElement.js @@ -0,0 +1,915 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLAnchorElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLAnchorElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLAnchorElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLAnchorElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLAnchorElement before HTMLElement"); + } + class HTMLAnchorElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get target() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get target' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "target"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set target(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set target' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'target' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "target", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get download() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get download' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "download"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set download(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set download' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'download' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "download", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get rel() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get rel' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "rel"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set rel(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set rel' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'rel' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "rel", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get relList() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get relList' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + return utils.getSameObject(this, "relList", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["relList"]); + }); + } + + set relList(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set relList' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + const Q = esValue["relList"]; + if (!utils.isObject(Q)) { + throw new TypeError("Property 'relList' is not an object"); + } + Reflect.set(Q, "value", V); + } + + get hreflang() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get hreflang' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "hreflang"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set hreflang(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set hreflang' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'hreflang' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "hreflang", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "type"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set type(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set type' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'type' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "type", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get text() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get text' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["text"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set text(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set text' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'text' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["text"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get coords() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get coords' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "coords"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set coords(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set coords' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'coords' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "coords", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get charset() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get charset' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "charset"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set charset(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set charset' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'charset' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "charset", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "name"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set name(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set name' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'name' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "name", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get rev() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get rev' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "rev"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set rev(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set rev' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'rev' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "rev", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get shape() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get shape' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "shape"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set shape(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set shape' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'shape' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "shape", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get href() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get href' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["href"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set href(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set href' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'href' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["href"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + toString() { + const esValue = this; + if (!exports.is(esValue)) { + throw new TypeError("'toString' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["href"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get origin() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get origin' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + return esValue[implSymbol]["origin"]; + } + + get protocol() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get protocol' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["protocol"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set protocol(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set protocol' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'protocol' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["protocol"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get username() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get username' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["username"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set username(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set username' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'username' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["username"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get password() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get password' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["password"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set password(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set password' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'password' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["password"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get host() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get host' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["host"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set host(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set host' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'host' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["host"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get hostname() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get hostname' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["hostname"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set hostname(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set hostname' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'hostname' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["hostname"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get port() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get port' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["port"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set port(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set port' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'port' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["port"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get pathname() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get pathname' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["pathname"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set pathname(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set pathname' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'pathname' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["pathname"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get search() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get search' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["search"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set search(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set search' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'search' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["search"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get hash() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get hash' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["hash"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set hash(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set hash' called on an object that is not a valid instance of HTMLAnchorElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'hash' property on 'HTMLAnchorElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["hash"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLAnchorElement.prototype, { + target: { enumerable: true }, + download: { enumerable: true }, + rel: { enumerable: true }, + relList: { enumerable: true }, + hreflang: { enumerable: true }, + type: { enumerable: true }, + text: { enumerable: true }, + coords: { enumerable: true }, + charset: { enumerable: true }, + name: { enumerable: true }, + rev: { enumerable: true }, + shape: { enumerable: true }, + href: { enumerable: true }, + toString: { enumerable: true }, + origin: { enumerable: true }, + protocol: { enumerable: true }, + username: { enumerable: true }, + password: { enumerable: true }, + host: { enumerable: true }, + hostname: { enumerable: true }, + port: { enumerable: true }, + pathname: { enumerable: true }, + search: { enumerable: true }, + hash: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLAnchorElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLAnchorElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLAnchorElement + }); +}; + +const Impl = require("../nodes/HTMLAnchorElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLAreaElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLAreaElement.js new file mode 100644 index 000000000..6f6c0e87f --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLAreaElement.js @@ -0,0 +1,739 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLAreaElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLAreaElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLAreaElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLAreaElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLAreaElement before HTMLElement"); + } + class HTMLAreaElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get alt() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get alt' called on an object that is not a valid instance of HTMLAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "alt"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set alt(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set alt' called on an object that is not a valid instance of HTMLAreaElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'alt' property on 'HTMLAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "alt", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get coords() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get coords' called on an object that is not a valid instance of HTMLAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "coords"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set coords(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set coords' called on an object that is not a valid instance of HTMLAreaElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'coords' property on 'HTMLAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "coords", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get shape() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get shape' called on an object that is not a valid instance of HTMLAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "shape"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set shape(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set shape' called on an object that is not a valid instance of HTMLAreaElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'shape' property on 'HTMLAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "shape", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get target() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get target' called on an object that is not a valid instance of HTMLAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "target"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set target(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set target' called on an object that is not a valid instance of HTMLAreaElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'target' property on 'HTMLAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "target", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get rel() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get rel' called on an object that is not a valid instance of HTMLAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "rel"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set rel(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set rel' called on an object that is not a valid instance of HTMLAreaElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'rel' property on 'HTMLAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "rel", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get relList() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get relList' called on an object that is not a valid instance of HTMLAreaElement."); + } + + return utils.getSameObject(this, "relList", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["relList"]); + }); + } + + set relList(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set relList' called on an object that is not a valid instance of HTMLAreaElement."); + } + + const Q = esValue["relList"]; + if (!utils.isObject(Q)) { + throw new TypeError("Property 'relList' is not an object"); + } + Reflect.set(Q, "value", V); + } + + get noHref() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get noHref' called on an object that is not a valid instance of HTMLAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "nohref"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set noHref(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set noHref' called on an object that is not a valid instance of HTMLAreaElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'noHref' property on 'HTMLAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "nohref", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "nohref"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get href() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get href' called on an object that is not a valid instance of HTMLAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["href"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set href(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set href' called on an object that is not a valid instance of HTMLAreaElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'href' property on 'HTMLAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["href"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + toString() { + const esValue = this; + if (!exports.is(esValue)) { + throw new TypeError("'toString' called on an object that is not a valid instance of HTMLAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["href"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get origin() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get origin' called on an object that is not a valid instance of HTMLAreaElement."); + } + + return esValue[implSymbol]["origin"]; + } + + get protocol() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get protocol' called on an object that is not a valid instance of HTMLAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["protocol"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set protocol(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set protocol' called on an object that is not a valid instance of HTMLAreaElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'protocol' property on 'HTMLAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["protocol"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get username() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get username' called on an object that is not a valid instance of HTMLAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["username"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set username(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set username' called on an object that is not a valid instance of HTMLAreaElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'username' property on 'HTMLAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["username"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get password() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get password' called on an object that is not a valid instance of HTMLAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["password"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set password(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set password' called on an object that is not a valid instance of HTMLAreaElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'password' property on 'HTMLAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["password"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get host() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get host' called on an object that is not a valid instance of HTMLAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["host"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set host(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set host' called on an object that is not a valid instance of HTMLAreaElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'host' property on 'HTMLAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["host"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get hostname() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get hostname' called on an object that is not a valid instance of HTMLAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["hostname"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set hostname(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set hostname' called on an object that is not a valid instance of HTMLAreaElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'hostname' property on 'HTMLAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["hostname"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get port() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get port' called on an object that is not a valid instance of HTMLAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["port"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set port(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set port' called on an object that is not a valid instance of HTMLAreaElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'port' property on 'HTMLAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["port"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get pathname() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get pathname' called on an object that is not a valid instance of HTMLAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["pathname"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set pathname(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set pathname' called on an object that is not a valid instance of HTMLAreaElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'pathname' property on 'HTMLAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["pathname"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get search() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get search' called on an object that is not a valid instance of HTMLAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["search"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set search(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set search' called on an object that is not a valid instance of HTMLAreaElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'search' property on 'HTMLAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["search"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get hash() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get hash' called on an object that is not a valid instance of HTMLAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["hash"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set hash(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set hash' called on an object that is not a valid instance of HTMLAreaElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'hash' property on 'HTMLAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["hash"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLAreaElement.prototype, { + alt: { enumerable: true }, + coords: { enumerable: true }, + shape: { enumerable: true }, + target: { enumerable: true }, + rel: { enumerable: true }, + relList: { enumerable: true }, + noHref: { enumerable: true }, + href: { enumerable: true }, + toString: { enumerable: true }, + origin: { enumerable: true }, + protocol: { enumerable: true }, + username: { enumerable: true }, + password: { enumerable: true }, + host: { enumerable: true }, + hostname: { enumerable: true }, + port: { enumerable: true }, + pathname: { enumerable: true }, + search: { enumerable: true }, + hash: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLAreaElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLAreaElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLAreaElement + }); +}; + +const Impl = require("../nodes/HTMLAreaElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLAudioElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLAudioElement.js new file mode 100644 index 000000000..7d8074288 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLAudioElement.js @@ -0,0 +1,115 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLMediaElement = require("./HTMLMediaElement.js"); + +const interfaceName = "HTMLAudioElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLAudioElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLAudioElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLAudioElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLMediaElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLMediaElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLAudioElement before HTMLMediaElement"); + } + class HTMLAudioElement extends globalObject.HTMLMediaElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + } + Object.defineProperties(HTMLAudioElement.prototype, { + [Symbol.toStringTag]: { value: "HTMLAudioElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLAudioElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLAudioElement + }); +}; + +const Impl = require("../nodes/HTMLAudioElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLBRElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLBRElement.js new file mode 100644 index 000000000..649d2a9c6 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLBRElement.js @@ -0,0 +1,153 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLBRElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLBRElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLBRElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLBRElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLBRElement before HTMLElement"); + } + class HTMLBRElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get clear() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get clear' called on an object that is not a valid instance of HTMLBRElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "clear"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set clear(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set clear' called on an object that is not a valid instance of HTMLBRElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'clear' property on 'HTMLBRElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "clear", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLBRElement.prototype, { + clear: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLBRElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLBRElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLBRElement + }); +}; + +const Impl = require("../nodes/HTMLBRElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLBaseElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLBaseElement.js new file mode 100644 index 000000000..807e89e64 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLBaseElement.js @@ -0,0 +1,188 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLBaseElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLBaseElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLBaseElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLBaseElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLBaseElement before HTMLElement"); + } + class HTMLBaseElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get href() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get href' called on an object that is not a valid instance of HTMLBaseElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["href"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set href(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set href' called on an object that is not a valid instance of HTMLBaseElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'href' property on 'HTMLBaseElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["href"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get target() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get target' called on an object that is not a valid instance of HTMLBaseElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "target"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set target(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set target' called on an object that is not a valid instance of HTMLBaseElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'target' property on 'HTMLBaseElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "target", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLBaseElement.prototype, { + href: { enumerable: true }, + target: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLBaseElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLBaseElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLBaseElement + }); +}; + +const Impl = require("../nodes/HTMLBaseElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLBodyElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLBodyElement.js new file mode 100644 index 000000000..6e32b0c6a --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLBodyElement.js @@ -0,0 +1,808 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const EventHandlerNonNull = require("./EventHandlerNonNull.js"); +const OnBeforeUnloadEventHandlerNonNull = require("./OnBeforeUnloadEventHandlerNonNull.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLBodyElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLBodyElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLBodyElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLBodyElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLBodyElement before HTMLElement"); + } + class HTMLBodyElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get text() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get text' called on an object that is not a valid instance of HTMLBodyElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "text"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set text(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set text' called on an object that is not a valid instance of HTMLBodyElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'text' property on 'HTMLBodyElement': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "text", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get link() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get link' called on an object that is not a valid instance of HTMLBodyElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "link"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set link(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set link' called on an object that is not a valid instance of HTMLBodyElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'link' property on 'HTMLBodyElement': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "link", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get vLink() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get vLink' called on an object that is not a valid instance of HTMLBodyElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "vlink"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set vLink(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set vLink' called on an object that is not a valid instance of HTMLBodyElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'vLink' property on 'HTMLBodyElement': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "vlink", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get aLink() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get aLink' called on an object that is not a valid instance of HTMLBodyElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "alink"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set aLink(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set aLink' called on an object that is not a valid instance of HTMLBodyElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'aLink' property on 'HTMLBodyElement': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "alink", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get bgColor() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get bgColor' called on an object that is not a valid instance of HTMLBodyElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "bgcolor"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set bgColor(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set bgColor' called on an object that is not a valid instance of HTMLBodyElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'bgColor' property on 'HTMLBodyElement': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "bgcolor", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get background() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get background' called on an object that is not a valid instance of HTMLBodyElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "background"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set background(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set background' called on an object that is not a valid instance of HTMLBodyElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'background' property on 'HTMLBodyElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "background", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get onafterprint() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onafterprint' called on an object that is not a valid instance of HTMLBodyElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onafterprint"]); + } + + set onafterprint(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onafterprint' called on an object that is not a valid instance of HTMLBodyElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onafterprint' property on 'HTMLBodyElement': The provided value" + }); + } + esValue[implSymbol]["onafterprint"] = V; + } + + get onbeforeprint() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onbeforeprint' called on an object that is not a valid instance of HTMLBodyElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onbeforeprint"]); + } + + set onbeforeprint(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onbeforeprint' called on an object that is not a valid instance of HTMLBodyElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onbeforeprint' property on 'HTMLBodyElement': The provided value" + }); + } + esValue[implSymbol]["onbeforeprint"] = V; + } + + get onbeforeunload() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onbeforeunload' called on an object that is not a valid instance of HTMLBodyElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onbeforeunload"]); + } + + set onbeforeunload(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onbeforeunload' called on an object that is not a valid instance of HTMLBodyElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = OnBeforeUnloadEventHandlerNonNull.convert(V, { + context: "Failed to set the 'onbeforeunload' property on 'HTMLBodyElement': The provided value" + }); + } + esValue[implSymbol]["onbeforeunload"] = V; + } + + get onhashchange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onhashchange' called on an object that is not a valid instance of HTMLBodyElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onhashchange"]); + } + + set onhashchange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onhashchange' called on an object that is not a valid instance of HTMLBodyElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onhashchange' property on 'HTMLBodyElement': The provided value" + }); + } + esValue[implSymbol]["onhashchange"] = V; + } + + get onlanguagechange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onlanguagechange' called on an object that is not a valid instance of HTMLBodyElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onlanguagechange"]); + } + + set onlanguagechange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onlanguagechange' called on an object that is not a valid instance of HTMLBodyElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onlanguagechange' property on 'HTMLBodyElement': The provided value" + }); + } + esValue[implSymbol]["onlanguagechange"] = V; + } + + get onmessage() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmessage' called on an object that is not a valid instance of HTMLBodyElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmessage"]); + } + + set onmessage(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmessage' called on an object that is not a valid instance of HTMLBodyElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmessage' property on 'HTMLBodyElement': The provided value" + }); + } + esValue[implSymbol]["onmessage"] = V; + } + + get onmessageerror() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onmessageerror' called on an object that is not a valid instance of HTMLBodyElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmessageerror"]); + } + + set onmessageerror(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onmessageerror' called on an object that is not a valid instance of HTMLBodyElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmessageerror' property on 'HTMLBodyElement': The provided value" + }); + } + esValue[implSymbol]["onmessageerror"] = V; + } + + get onoffline() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onoffline' called on an object that is not a valid instance of HTMLBodyElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onoffline"]); + } + + set onoffline(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onoffline' called on an object that is not a valid instance of HTMLBodyElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onoffline' property on 'HTMLBodyElement': The provided value" + }); + } + esValue[implSymbol]["onoffline"] = V; + } + + get ononline() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ononline' called on an object that is not a valid instance of HTMLBodyElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ononline"]); + } + + set ononline(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ononline' called on an object that is not a valid instance of HTMLBodyElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ononline' property on 'HTMLBodyElement': The provided value" + }); + } + esValue[implSymbol]["ononline"] = V; + } + + get onpagehide() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onpagehide' called on an object that is not a valid instance of HTMLBodyElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onpagehide"]); + } + + set onpagehide(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onpagehide' called on an object that is not a valid instance of HTMLBodyElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onpagehide' property on 'HTMLBodyElement': The provided value" + }); + } + esValue[implSymbol]["onpagehide"] = V; + } + + get onpageshow() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onpageshow' called on an object that is not a valid instance of HTMLBodyElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onpageshow"]); + } + + set onpageshow(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onpageshow' called on an object that is not a valid instance of HTMLBodyElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onpageshow' property on 'HTMLBodyElement': The provided value" + }); + } + esValue[implSymbol]["onpageshow"] = V; + } + + get onpopstate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onpopstate' called on an object that is not a valid instance of HTMLBodyElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onpopstate"]); + } + + set onpopstate(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onpopstate' called on an object that is not a valid instance of HTMLBodyElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onpopstate' property on 'HTMLBodyElement': The provided value" + }); + } + esValue[implSymbol]["onpopstate"] = V; + } + + get onrejectionhandled() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onrejectionhandled' called on an object that is not a valid instance of HTMLBodyElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onrejectionhandled"]); + } + + set onrejectionhandled(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onrejectionhandled' called on an object that is not a valid instance of HTMLBodyElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onrejectionhandled' property on 'HTMLBodyElement': The provided value" + }); + } + esValue[implSymbol]["onrejectionhandled"] = V; + } + + get onstorage() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onstorage' called on an object that is not a valid instance of HTMLBodyElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onstorage"]); + } + + set onstorage(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onstorage' called on an object that is not a valid instance of HTMLBodyElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onstorage' property on 'HTMLBodyElement': The provided value" + }); + } + esValue[implSymbol]["onstorage"] = V; + } + + get onunhandledrejection() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onunhandledrejection' called on an object that is not a valid instance of HTMLBodyElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onunhandledrejection"]); + } + + set onunhandledrejection(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onunhandledrejection' called on an object that is not a valid instance of HTMLBodyElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onunhandledrejection' property on 'HTMLBodyElement': The provided value" + }); + } + esValue[implSymbol]["onunhandledrejection"] = V; + } + + get onunload() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onunload' called on an object that is not a valid instance of HTMLBodyElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onunload"]); + } + + set onunload(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onunload' called on an object that is not a valid instance of HTMLBodyElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onunload' property on 'HTMLBodyElement': The provided value" + }); + } + esValue[implSymbol]["onunload"] = V; + } + } + Object.defineProperties(HTMLBodyElement.prototype, { + text: { enumerable: true }, + link: { enumerable: true }, + vLink: { enumerable: true }, + aLink: { enumerable: true }, + bgColor: { enumerable: true }, + background: { enumerable: true }, + onafterprint: { enumerable: true }, + onbeforeprint: { enumerable: true }, + onbeforeunload: { enumerable: true }, + onhashchange: { enumerable: true }, + onlanguagechange: { enumerable: true }, + onmessage: { enumerable: true }, + onmessageerror: { enumerable: true }, + onoffline: { enumerable: true }, + ononline: { enumerable: true }, + onpagehide: { enumerable: true }, + onpageshow: { enumerable: true }, + onpopstate: { enumerable: true }, + onrejectionhandled: { enumerable: true }, + onstorage: { enumerable: true }, + onunhandledrejection: { enumerable: true }, + onunload: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLBodyElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLBodyElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLBodyElement + }); +}; + +const Impl = require("../nodes/HTMLBodyElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLButtonElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLButtonElement.js new file mode 100644 index 000000000..9cb960e34 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLButtonElement.js @@ -0,0 +1,487 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLButtonElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLButtonElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLButtonElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLButtonElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLButtonElement before HTMLElement"); + } + class HTMLButtonElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + checkValidity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'checkValidity' called on an object that is not a valid instance of HTMLButtonElement."); + } + + return esValue[implSymbol].checkValidity(); + } + + reportValidity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'reportValidity' called on an object that is not a valid instance of HTMLButtonElement."); + } + + return esValue[implSymbol].reportValidity(); + } + + setCustomValidity(error) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError( + "'setCustomValidity' called on an object that is not a valid instance of HTMLButtonElement." + ); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'setCustomValidity' on 'HTMLButtonElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setCustomValidity' on 'HTMLButtonElement': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].setCustomValidity(...args); + } + + get autofocus() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get autofocus' called on an object that is not a valid instance of HTMLButtonElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "autofocus"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set autofocus(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set autofocus' called on an object that is not a valid instance of HTMLButtonElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'autofocus' property on 'HTMLButtonElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "autofocus", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "autofocus"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get disabled() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get disabled' called on an object that is not a valid instance of HTMLButtonElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "disabled"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set disabled(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set disabled' called on an object that is not a valid instance of HTMLButtonElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'disabled' property on 'HTMLButtonElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "disabled", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "disabled"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get form() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get form' called on an object that is not a valid instance of HTMLButtonElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["form"]); + } + + get formNoValidate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get formNoValidate' called on an object that is not a valid instance of HTMLButtonElement." + ); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "formnovalidate"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set formNoValidate(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set formNoValidate' called on an object that is not a valid instance of HTMLButtonElement." + ); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'formNoValidate' property on 'HTMLButtonElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "formnovalidate", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "formnovalidate"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get formTarget() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get formTarget' called on an object that is not a valid instance of HTMLButtonElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "formtarget"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set formTarget(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set formTarget' called on an object that is not a valid instance of HTMLButtonElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'formTarget' property on 'HTMLButtonElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "formtarget", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of HTMLButtonElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "name"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set name(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set name' called on an object that is not a valid instance of HTMLButtonElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'name' property on 'HTMLButtonElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "name", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of HTMLButtonElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["type"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set type(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set type' called on an object that is not a valid instance of HTMLButtonElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'type' property on 'HTMLButtonElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["type"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get value() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get value' called on an object that is not a valid instance of HTMLButtonElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "value"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set value(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set value' called on an object that is not a valid instance of HTMLButtonElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'value' property on 'HTMLButtonElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "value", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get willValidate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get willValidate' called on an object that is not a valid instance of HTMLButtonElement." + ); + } + + return esValue[implSymbol]["willValidate"]; + } + + get validity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get validity' called on an object that is not a valid instance of HTMLButtonElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["validity"]); + } + + get validationMessage() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get validationMessage' called on an object that is not a valid instance of HTMLButtonElement." + ); + } + + return esValue[implSymbol]["validationMessage"]; + } + + get labels() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get labels' called on an object that is not a valid instance of HTMLButtonElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["labels"]); + } + } + Object.defineProperties(HTMLButtonElement.prototype, { + checkValidity: { enumerable: true }, + reportValidity: { enumerable: true }, + setCustomValidity: { enumerable: true }, + autofocus: { enumerable: true }, + disabled: { enumerable: true }, + form: { enumerable: true }, + formNoValidate: { enumerable: true }, + formTarget: { enumerable: true }, + name: { enumerable: true }, + type: { enumerable: true }, + value: { enumerable: true }, + willValidate: { enumerable: true }, + validity: { enumerable: true }, + validationMessage: { enumerable: true }, + labels: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLButtonElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLButtonElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLButtonElement + }); +}; + +const Impl = require("../nodes/HTMLButtonElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLCanvasElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLCanvasElement.js new file mode 100644 index 000000000..fcef3dcd3 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLCanvasElement.js @@ -0,0 +1,291 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const BlobCallback = require("./BlobCallback.js"); +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLCanvasElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLCanvasElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLCanvasElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLCanvasElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLCanvasElement before HTMLElement"); + } + class HTMLCanvasElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + getContext(contextId) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getContext' called on an object that is not a valid instance of HTMLCanvasElement."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'getContext' on 'HTMLCanvasElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getContext' on 'HTMLCanvasElement': parameter 1" + }); + args.push(curArg); + } + for (let i = 1; i < arguments.length; i++) { + let curArg = arguments[i]; + curArg = conversions["any"](curArg, { + context: "Failed to execute 'getContext' on 'HTMLCanvasElement': parameter " + (i + 1) + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].getContext(...args)); + } + + toDataURL() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'toDataURL' called on an object that is not a valid instance of HTMLCanvasElement."); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'toDataURL' on 'HTMLCanvasElement': parameter 1" + }); + } + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["any"](curArg, { + context: "Failed to execute 'toDataURL' on 'HTMLCanvasElement': parameter 2" + }); + } + args.push(curArg); + } + return esValue[implSymbol].toDataURL(...args); + } + + toBlob(callback) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'toBlob' called on an object that is not a valid instance of HTMLCanvasElement."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'toBlob' on 'HTMLCanvasElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = BlobCallback.convert(curArg, { + context: "Failed to execute 'toBlob' on 'HTMLCanvasElement': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'toBlob' on 'HTMLCanvasElement': parameter 2" + }); + } + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + curArg = conversions["any"](curArg, { + context: "Failed to execute 'toBlob' on 'HTMLCanvasElement': parameter 3" + }); + } + args.push(curArg); + } + return esValue[implSymbol].toBlob(...args); + } + + get width() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get width' called on an object that is not a valid instance of HTMLCanvasElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["width"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set width(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set width' called on an object that is not a valid instance of HTMLCanvasElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'width' property on 'HTMLCanvasElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["width"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get height() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get height' called on an object that is not a valid instance of HTMLCanvasElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["height"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set height(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set height' called on an object that is not a valid instance of HTMLCanvasElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'height' property on 'HTMLCanvasElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["height"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLCanvasElement.prototype, { + getContext: { enumerable: true }, + toDataURL: { enumerable: true }, + toBlob: { enumerable: true }, + width: { enumerable: true }, + height: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLCanvasElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLCanvasElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLCanvasElement + }); +}; + +const Impl = require("../nodes/HTMLCanvasElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLCollection.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLCollection.js new file mode 100644 index 000000000..100c3208e --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLCollection.js @@ -0,0 +1,358 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "HTMLCollection"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLCollection'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLCollection"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLCollection is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + let wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class HTMLCollection { + constructor() { + throw new TypeError("Illegal constructor"); + } + + item(index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'item' called on an object that is not a valid instance of HTMLCollection."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'item' on 'HTMLCollection': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'item' on 'HTMLCollection': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].item(...args)); + } + + namedItem(name) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'namedItem' called on an object that is not a valid instance of HTMLCollection."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'namedItem' on 'HTMLCollection': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'namedItem' on 'HTMLCollection': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].namedItem(...args)); + } + + get length() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get length' called on an object that is not a valid instance of HTMLCollection."); + } + + return esValue[implSymbol]["length"]; + } + } + Object.defineProperties(HTMLCollection.prototype, { + item: { enumerable: true }, + namedItem: { enumerable: true }, + length: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLCollection", configurable: true }, + [Symbol.iterator]: { value: Array.prototype[Symbol.iterator], configurable: true, writable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLCollection; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLCollection + }); +}; + +const proxyHandler = { + get(target, P, receiver) { + if (typeof P === "symbol") { + return Reflect.get(target, P, receiver); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc === undefined) { + const parent = Object.getPrototypeOf(target); + if (parent === null) { + return undefined; + } + return Reflect.get(target, P, receiver); + } + if (!desc.get && !desc.set) { + return desc.value; + } + const getter = desc.get; + if (getter === undefined) { + return undefined; + } + return Reflect.apply(getter, receiver, []); + }, + + has(target, P) { + if (typeof P === "symbol") { + return Reflect.has(target, P); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc !== undefined) { + return true; + } + const parent = Object.getPrototypeOf(target); + if (parent !== null) { + return Reflect.has(parent, P); + } + return false; + }, + + ownKeys(target) { + const keys = new Set(); + + for (const key of target[implSymbol][utils.supportedPropertyIndices]) { + keys.add(`${key}`); + } + + for (const key of target[implSymbol][utils.supportedPropertyNames]) { + if (!(key in target)) { + keys.add(`${key}`); + } + } + + for (const key of Reflect.ownKeys(target)) { + keys.add(key); + } + return [...keys]; + }, + + getOwnPropertyDescriptor(target, P) { + if (typeof P === "symbol") { + return Reflect.getOwnPropertyDescriptor(target, P); + } + let ignoreNamedProps = false; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + return { + writable: false, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + ignoreNamedProps = true; + } + + const namedValue = target[implSymbol].namedItem(P); + + if (namedValue !== null && !(P in target) && !ignoreNamedProps) { + return { + writable: false, + enumerable: false, + configurable: true, + value: utils.tryWrapperForImpl(namedValue) + }; + } + + return Reflect.getOwnPropertyDescriptor(target, P); + }, + + set(target, P, V, receiver) { + if (typeof P === "symbol") { + return Reflect.set(target, P, V, receiver); + } + // The `receiver` argument refers to the Proxy exotic object or an object + // that inherits from it, whereas `target` refers to the Proxy target: + if (target[implSymbol][utils.wrapperSymbol] === receiver) { + } + let ownDesc; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + ownDesc = { + writable: false, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + } + + if (ownDesc === undefined) { + ownDesc = Reflect.getOwnPropertyDescriptor(target, P); + } + if (ownDesc === undefined) { + const parent = Reflect.getPrototypeOf(target); + if (parent !== null) { + return Reflect.set(parent, P, V, receiver); + } + ownDesc = { writable: true, enumerable: true, configurable: true, value: undefined }; + } + if (!ownDesc.writable) { + return false; + } + if (!utils.isObject(receiver)) { + return false; + } + const existingDesc = Reflect.getOwnPropertyDescriptor(receiver, P); + let valueDesc; + if (existingDesc !== undefined) { + if (existingDesc.get || existingDesc.set) { + return false; + } + if (!existingDesc.writable) { + return false; + } + valueDesc = { value: V }; + } else { + valueDesc = { writable: true, enumerable: true, configurable: true, value: V }; + } + return Reflect.defineProperty(receiver, P, valueDesc); + }, + + defineProperty(target, P, desc) { + if (typeof P === "symbol") { + return Reflect.defineProperty(target, P, desc); + } + + if (utils.isArrayIndexPropName(P)) { + return false; + } + if (!utils.hasOwn(target, P)) { + const creating = !(target[implSymbol].namedItem(P) !== null); + if (!creating) { + return false; + } + } + return Reflect.defineProperty(target, P, desc); + }, + + deleteProperty(target, P) { + if (typeof P === "symbol") { + return Reflect.deleteProperty(target, P); + } + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + return !(target[implSymbol].item(index) !== null); + } + + if (target[implSymbol].namedItem(P) !== null && !(P in target)) { + return false; + } + + return Reflect.deleteProperty(target, P); + }, + + preventExtensions() { + return false; + } +}; + +const Impl = require("../nodes/HTMLCollection-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLDListElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLDListElement.js new file mode 100644 index 000000000..933b1b378 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLDListElement.js @@ -0,0 +1,156 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLDListElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLDListElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLDListElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLDListElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLDListElement before HTMLElement"); + } + class HTMLDListElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get compact() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get compact' called on an object that is not a valid instance of HTMLDListElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "compact"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set compact(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set compact' called on an object that is not a valid instance of HTMLDListElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'compact' property on 'HTMLDListElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "compact", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "compact"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLDListElement.prototype, { + compact: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLDListElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLDListElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLDListElement + }); +}; + +const Impl = require("../nodes/HTMLDListElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLDataElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLDataElement.js new file mode 100644 index 000000000..a621d8028 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLDataElement.js @@ -0,0 +1,153 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLDataElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLDataElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLDataElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLDataElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLDataElement before HTMLElement"); + } + class HTMLDataElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get value() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get value' called on an object that is not a valid instance of HTMLDataElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "value"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set value(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set value' called on an object that is not a valid instance of HTMLDataElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'value' property on 'HTMLDataElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "value", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLDataElement.prototype, { + value: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLDataElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLDataElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLDataElement + }); +}; + +const Impl = require("../nodes/HTMLDataElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLDataListElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLDataListElement.js new file mode 100644 index 000000000..a3e6302b8 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLDataListElement.js @@ -0,0 +1,128 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLDataListElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLDataListElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLDataListElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLDataListElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLDataListElement before HTMLElement"); + } + class HTMLDataListElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get options() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get options' called on an object that is not a valid instance of HTMLDataListElement."); + } + + return utils.getSameObject(this, "options", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["options"]); + }); + } + } + Object.defineProperties(HTMLDataListElement.prototype, { + options: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLDataListElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLDataListElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLDataListElement + }); +}; + +const Impl = require("../nodes/HTMLDataListElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLDetailsElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLDetailsElement.js new file mode 100644 index 000000000..ce7c9eef2 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLDetailsElement.js @@ -0,0 +1,156 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLDetailsElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLDetailsElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLDetailsElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLDetailsElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLDetailsElement before HTMLElement"); + } + class HTMLDetailsElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get open() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get open' called on an object that is not a valid instance of HTMLDetailsElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "open"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set open(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set open' called on an object that is not a valid instance of HTMLDetailsElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'open' property on 'HTMLDetailsElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "open", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "open"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLDetailsElement.prototype, { + open: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLDetailsElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLDetailsElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLDetailsElement + }); +}; + +const Impl = require("../nodes/HTMLDetailsElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLDialogElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLDialogElement.js new file mode 100644 index 000000000..6ac903030 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLDialogElement.js @@ -0,0 +1,156 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLDialogElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLDialogElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLDialogElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLDialogElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLDialogElement before HTMLElement"); + } + class HTMLDialogElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get open() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get open' called on an object that is not a valid instance of HTMLDialogElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "open"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set open(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set open' called on an object that is not a valid instance of HTMLDialogElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'open' property on 'HTMLDialogElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "open", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "open"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLDialogElement.prototype, { + open: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLDialogElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLDialogElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLDialogElement + }); +}; + +const Impl = require("../nodes/HTMLDialogElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLDirectoryElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLDirectoryElement.js new file mode 100644 index 000000000..68eb0efa0 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLDirectoryElement.js @@ -0,0 +1,156 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLDirectoryElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLDirectoryElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLDirectoryElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLDirectoryElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLDirectoryElement before HTMLElement"); + } + class HTMLDirectoryElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get compact() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get compact' called on an object that is not a valid instance of HTMLDirectoryElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "compact"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set compact(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set compact' called on an object that is not a valid instance of HTMLDirectoryElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'compact' property on 'HTMLDirectoryElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "compact", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "compact"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLDirectoryElement.prototype, { + compact: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLDirectoryElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLDirectoryElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLDirectoryElement + }); +}; + +const Impl = require("../nodes/HTMLDirectoryElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLDivElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLDivElement.js new file mode 100644 index 000000000..e74a2c538 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLDivElement.js @@ -0,0 +1,153 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLDivElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLDivElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLDivElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLDivElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLDivElement before HTMLElement"); + } + class HTMLDivElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get align() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get align' called on an object that is not a valid instance of HTMLDivElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "align"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set align(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set align' called on an object that is not a valid instance of HTMLDivElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'align' property on 'HTMLDivElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "align", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLDivElement.prototype, { + align: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLDivElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLDivElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLDivElement + }); +}; + +const Impl = require("../nodes/HTMLDivElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLElement.js new file mode 100644 index 000000000..22c369e5e --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLElement.js @@ -0,0 +1,2269 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const EventHandlerNonNull = require("./EventHandlerNonNull.js"); +const OnErrorEventHandlerNonNull = require("./OnErrorEventHandlerNonNull.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const Element = require("./Element.js"); + +const interfaceName = "HTMLElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Element._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Element === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLElement before Element"); + } + class HTMLElement extends globalObject.Element { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + click() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'click' called on an object that is not a valid instance of HTMLElement."); + } + + return esValue[implSymbol].click(); + } + + focus() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'focus' called on an object that is not a valid instance of HTMLElement."); + } + + return esValue[implSymbol].focus(); + } + + blur() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'blur' called on an object that is not a valid instance of HTMLElement."); + } + + return esValue[implSymbol].blur(); + } + + get title() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get title' called on an object that is not a valid instance of HTMLElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "title"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set title(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set title' called on an object that is not a valid instance of HTMLElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'title' property on 'HTMLElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "title", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get lang() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get lang' called on an object that is not a valid instance of HTMLElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "lang"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set lang(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set lang' called on an object that is not a valid instance of HTMLElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'lang' property on 'HTMLElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "lang", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get translate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get translate' called on an object that is not a valid instance of HTMLElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["translate"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set translate(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set translate' called on an object that is not a valid instance of HTMLElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'translate' property on 'HTMLElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["translate"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get dir() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get dir' called on an object that is not a valid instance of HTMLElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["dir"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set dir(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set dir' called on an object that is not a valid instance of HTMLElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'dir' property on 'HTMLElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["dir"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get hidden() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get hidden' called on an object that is not a valid instance of HTMLElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "hidden"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set hidden(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set hidden' called on an object that is not a valid instance of HTMLElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'hidden' property on 'HTMLElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "hidden", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "hidden"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get accessKey() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get accessKey' called on an object that is not a valid instance of HTMLElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "accesskey"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set accessKey(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set accessKey' called on an object that is not a valid instance of HTMLElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'accessKey' property on 'HTMLElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "accesskey", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get draggable() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get draggable' called on an object that is not a valid instance of HTMLElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["draggable"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set draggable(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set draggable' called on an object that is not a valid instance of HTMLElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'draggable' property on 'HTMLElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["draggable"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get offsetParent() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get offsetParent' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["offsetParent"]); + } + + get offsetTop() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get offsetTop' called on an object that is not a valid instance of HTMLElement."); + } + + return esValue[implSymbol]["offsetTop"]; + } + + get offsetLeft() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get offsetLeft' called on an object that is not a valid instance of HTMLElement."); + } + + return esValue[implSymbol]["offsetLeft"]; + } + + get offsetWidth() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get offsetWidth' called on an object that is not a valid instance of HTMLElement."); + } + + return esValue[implSymbol]["offsetWidth"]; + } + + get offsetHeight() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get offsetHeight' called on an object that is not a valid instance of HTMLElement."); + } + + return esValue[implSymbol]["offsetHeight"]; + } + + get style() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get style' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.getSameObject(this, "style", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["style"]); + }); + } + + set style(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set style' called on an object that is not a valid instance of HTMLElement."); + } + + const Q = esValue["style"]; + if (!utils.isObject(Q)) { + throw new TypeError("Property 'style' is not an object"); + } + Reflect.set(Q, "cssText", V); + } + + get onabort() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onabort' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onabort"]); + } + + set onabort(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onabort' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onabort' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onabort"] = V; + } + + get onauxclick() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onauxclick' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onauxclick"]); + } + + set onauxclick(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onauxclick' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onauxclick' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onauxclick"] = V; + } + + get onblur() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onblur' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onblur"]); + } + + set onblur(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onblur' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onblur' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onblur"] = V; + } + + get oncancel() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oncancel' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oncancel"]); + } + + set oncancel(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oncancel' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oncancel' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["oncancel"] = V; + } + + get oncanplay() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oncanplay' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oncanplay"]); + } + + set oncanplay(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oncanplay' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oncanplay' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["oncanplay"] = V; + } + + get oncanplaythrough() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oncanplaythrough' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oncanplaythrough"]); + } + + set oncanplaythrough(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oncanplaythrough' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oncanplaythrough' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["oncanplaythrough"] = V; + } + + get onchange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onchange' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onchange"]); + } + + set onchange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onchange' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onchange' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onchange"] = V; + } + + get onclick() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onclick' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onclick"]); + } + + set onclick(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onclick' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onclick' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onclick"] = V; + } + + get onclose() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onclose' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onclose"]); + } + + set onclose(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onclose' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onclose' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onclose"] = V; + } + + get oncontextmenu() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oncontextmenu' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oncontextmenu"]); + } + + set oncontextmenu(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oncontextmenu' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oncontextmenu' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["oncontextmenu"] = V; + } + + get oncuechange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oncuechange' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oncuechange"]); + } + + set oncuechange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oncuechange' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oncuechange' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["oncuechange"] = V; + } + + get ondblclick() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondblclick' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondblclick"]); + } + + set ondblclick(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondblclick' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondblclick' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["ondblclick"] = V; + } + + get ondrag() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondrag' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondrag"]); + } + + set ondrag(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondrag' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondrag' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["ondrag"] = V; + } + + get ondragend() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondragend' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondragend"]); + } + + set ondragend(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondragend' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondragend' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["ondragend"] = V; + } + + get ondragenter() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondragenter' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondragenter"]); + } + + set ondragenter(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondragenter' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondragenter' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["ondragenter"] = V; + } + + get ondragleave() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondragleave' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondragleave"]); + } + + set ondragleave(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondragleave' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondragleave' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["ondragleave"] = V; + } + + get ondragover() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondragover' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondragover"]); + } + + set ondragover(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondragover' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondragover' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["ondragover"] = V; + } + + get ondragstart() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondragstart' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondragstart"]); + } + + set ondragstart(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondragstart' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondragstart' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["ondragstart"] = V; + } + + get ondrop() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondrop' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondrop"]); + } + + set ondrop(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondrop' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondrop' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["ondrop"] = V; + } + + get ondurationchange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondurationchange' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondurationchange"]); + } + + set ondurationchange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondurationchange' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondurationchange' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["ondurationchange"] = V; + } + + get onemptied() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onemptied' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onemptied"]); + } + + set onemptied(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onemptied' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onemptied' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onemptied"] = V; + } + + get onended() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onended' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onended"]); + } + + set onended(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onended' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onended' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onended"] = V; + } + + get onerror() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onerror' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onerror"]); + } + + set onerror(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onerror' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = OnErrorEventHandlerNonNull.convert(V, { + context: "Failed to set the 'onerror' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onerror"] = V; + } + + get onfocus() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onfocus' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onfocus"]); + } + + set onfocus(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onfocus' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onfocus' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onfocus"] = V; + } + + get oninput() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oninput' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oninput"]); + } + + set oninput(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oninput' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oninput' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["oninput"] = V; + } + + get oninvalid() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oninvalid' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oninvalid"]); + } + + set oninvalid(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oninvalid' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oninvalid' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["oninvalid"] = V; + } + + get onkeydown() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onkeydown' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onkeydown"]); + } + + set onkeydown(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onkeydown' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onkeydown' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onkeydown"] = V; + } + + get onkeypress() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onkeypress' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onkeypress"]); + } + + set onkeypress(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onkeypress' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onkeypress' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onkeypress"] = V; + } + + get onkeyup() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onkeyup' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onkeyup"]); + } + + set onkeyup(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onkeyup' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onkeyup' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onkeyup"] = V; + } + + get onload() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onload' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onload"]); + } + + set onload(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onload' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onload' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onload"] = V; + } + + get onloadeddata() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onloadeddata' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onloadeddata"]); + } + + set onloadeddata(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onloadeddata' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onloadeddata' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onloadeddata"] = V; + } + + get onloadedmetadata() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onloadedmetadata' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onloadedmetadata"]); + } + + set onloadedmetadata(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onloadedmetadata' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onloadedmetadata' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onloadedmetadata"] = V; + } + + get onloadend() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onloadend' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onloadend"]); + } + + set onloadend(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onloadend' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onloadend' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onloadend"] = V; + } + + get onloadstart() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onloadstart' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onloadstart"]); + } + + set onloadstart(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onloadstart' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onloadstart' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onloadstart"] = V; + } + + get onmousedown() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmousedown' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmousedown"]); + } + + set onmousedown(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmousedown' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmousedown' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onmousedown"] = V; + } + + get onmouseenter() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + return; + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmouseenter"]); + } + + set onmouseenter(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + return; + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmouseenter' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onmouseenter"] = V; + } + + get onmouseleave() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + return; + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmouseleave"]); + } + + set onmouseleave(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + return; + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmouseleave' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onmouseleave"] = V; + } + + get onmousemove() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmousemove' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmousemove"]); + } + + set onmousemove(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmousemove' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmousemove' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onmousemove"] = V; + } + + get onmouseout() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmouseout' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmouseout"]); + } + + set onmouseout(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmouseout' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmouseout' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onmouseout"] = V; + } + + get onmouseover() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmouseover' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmouseover"]); + } + + set onmouseover(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmouseover' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmouseover' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onmouseover"] = V; + } + + get onmouseup() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmouseup' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmouseup"]); + } + + set onmouseup(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmouseup' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmouseup' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onmouseup"] = V; + } + + get onwheel() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onwheel' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onwheel"]); + } + + set onwheel(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onwheel' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onwheel' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onwheel"] = V; + } + + get onpause() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onpause' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onpause"]); + } + + set onpause(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onpause' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onpause' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onpause"] = V; + } + + get onplay() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onplay' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onplay"]); + } + + set onplay(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onplay' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onplay' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onplay"] = V; + } + + get onplaying() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onplaying' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onplaying"]); + } + + set onplaying(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onplaying' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onplaying' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onplaying"] = V; + } + + get onprogress() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onprogress' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onprogress"]); + } + + set onprogress(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onprogress' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onprogress' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onprogress"] = V; + } + + get onratechange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onratechange' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onratechange"]); + } + + set onratechange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onratechange' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onratechange' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onratechange"] = V; + } + + get onreset() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onreset' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onreset"]); + } + + set onreset(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onreset' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onreset' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onreset"] = V; + } + + get onresize() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onresize' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onresize"]); + } + + set onresize(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onresize' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onresize' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onresize"] = V; + } + + get onscroll() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onscroll' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onscroll"]); + } + + set onscroll(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onscroll' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onscroll' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onscroll"] = V; + } + + get onsecuritypolicyviolation() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onsecuritypolicyviolation' called on an object that is not a valid instance of HTMLElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onsecuritypolicyviolation"]); + } + + set onsecuritypolicyviolation(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onsecuritypolicyviolation' called on an object that is not a valid instance of HTMLElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onsecuritypolicyviolation' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onsecuritypolicyviolation"] = V; + } + + get onseeked() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onseeked' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onseeked"]); + } + + set onseeked(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onseeked' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onseeked' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onseeked"] = V; + } + + get onseeking() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onseeking' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onseeking"]); + } + + set onseeking(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onseeking' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onseeking' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onseeking"] = V; + } + + get onselect() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onselect' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onselect"]); + } + + set onselect(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onselect' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onselect' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onselect"] = V; + } + + get onstalled() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onstalled' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onstalled"]); + } + + set onstalled(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onstalled' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onstalled' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onstalled"] = V; + } + + get onsubmit() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onsubmit' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onsubmit"]); + } + + set onsubmit(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onsubmit' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onsubmit' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onsubmit"] = V; + } + + get onsuspend() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onsuspend' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onsuspend"]); + } + + set onsuspend(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onsuspend' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onsuspend' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onsuspend"] = V; + } + + get ontimeupdate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ontimeupdate' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ontimeupdate"]); + } + + set ontimeupdate(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ontimeupdate' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ontimeupdate' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["ontimeupdate"] = V; + } + + get ontoggle() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ontoggle' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ontoggle"]); + } + + set ontoggle(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ontoggle' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ontoggle' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["ontoggle"] = V; + } + + get onvolumechange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onvolumechange' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onvolumechange"]); + } + + set onvolumechange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onvolumechange' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onvolumechange' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onvolumechange"] = V; + } + + get onwaiting() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onwaiting' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onwaiting"]); + } + + set onwaiting(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onwaiting' called on an object that is not a valid instance of HTMLElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onwaiting' property on 'HTMLElement': The provided value" + }); + } + esValue[implSymbol]["onwaiting"] = V; + } + + get dataset() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get dataset' called on an object that is not a valid instance of HTMLElement."); + } + + return utils.getSameObject(this, "dataset", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["dataset"]); + }); + } + + get nonce() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get nonce' called on an object that is not a valid instance of HTMLElement."); + } + + const value = esValue[implSymbol].getAttributeNS(null, "nonce"); + return value === null ? "" : value; + } + + set nonce(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set nonce' called on an object that is not a valid instance of HTMLElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'nonce' property on 'HTMLElement': The provided value" + }); + + esValue[implSymbol].setAttributeNS(null, "nonce", V); + } + + get tabIndex() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get tabIndex' called on an object that is not a valid instance of HTMLElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["tabIndex"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set tabIndex(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set tabIndex' called on an object that is not a valid instance of HTMLElement."); + } + + V = conversions["long"](V, { + context: "Failed to set the 'tabIndex' property on 'HTMLElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["tabIndex"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLElement.prototype, { + click: { enumerable: true }, + focus: { enumerable: true }, + blur: { enumerable: true }, + title: { enumerable: true }, + lang: { enumerable: true }, + translate: { enumerable: true }, + dir: { enumerable: true }, + hidden: { enumerable: true }, + accessKey: { enumerable: true }, + draggable: { enumerable: true }, + offsetParent: { enumerable: true }, + offsetTop: { enumerable: true }, + offsetLeft: { enumerable: true }, + offsetWidth: { enumerable: true }, + offsetHeight: { enumerable: true }, + style: { enumerable: true }, + onabort: { enumerable: true }, + onauxclick: { enumerable: true }, + onblur: { enumerable: true }, + oncancel: { enumerable: true }, + oncanplay: { enumerable: true }, + oncanplaythrough: { enumerable: true }, + onchange: { enumerable: true }, + onclick: { enumerable: true }, + onclose: { enumerable: true }, + oncontextmenu: { enumerable: true }, + oncuechange: { enumerable: true }, + ondblclick: { enumerable: true }, + ondrag: { enumerable: true }, + ondragend: { enumerable: true }, + ondragenter: { enumerable: true }, + ondragleave: { enumerable: true }, + ondragover: { enumerable: true }, + ondragstart: { enumerable: true }, + ondrop: { enumerable: true }, + ondurationchange: { enumerable: true }, + onemptied: { enumerable: true }, + onended: { enumerable: true }, + onerror: { enumerable: true }, + onfocus: { enumerable: true }, + oninput: { enumerable: true }, + oninvalid: { enumerable: true }, + onkeydown: { enumerable: true }, + onkeypress: { enumerable: true }, + onkeyup: { enumerable: true }, + onload: { enumerable: true }, + onloadeddata: { enumerable: true }, + onloadedmetadata: { enumerable: true }, + onloadend: { enumerable: true }, + onloadstart: { enumerable: true }, + onmousedown: { enumerable: true }, + onmouseenter: { enumerable: true }, + onmouseleave: { enumerable: true }, + onmousemove: { enumerable: true }, + onmouseout: { enumerable: true }, + onmouseover: { enumerable: true }, + onmouseup: { enumerable: true }, + onwheel: { enumerable: true }, + onpause: { enumerable: true }, + onplay: { enumerable: true }, + onplaying: { enumerable: true }, + onprogress: { enumerable: true }, + onratechange: { enumerable: true }, + onreset: { enumerable: true }, + onresize: { enumerable: true }, + onscroll: { enumerable: true }, + onsecuritypolicyviolation: { enumerable: true }, + onseeked: { enumerable: true }, + onseeking: { enumerable: true }, + onselect: { enumerable: true }, + onstalled: { enumerable: true }, + onsubmit: { enumerable: true }, + onsuspend: { enumerable: true }, + ontimeupdate: { enumerable: true }, + ontoggle: { enumerable: true }, + onvolumechange: { enumerable: true }, + onwaiting: { enumerable: true }, + dataset: { enumerable: true }, + nonce: { enumerable: true }, + tabIndex: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLElement + }); +}; + +const Impl = require("../nodes/HTMLElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLEmbedElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLEmbedElement.js new file mode 100644 index 000000000..54a7108d7 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLEmbedElement.js @@ -0,0 +1,346 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const parseURLToResultingURLRecord_helpers_document_base_url = + require("../helpers/document-base-url.js").parseURLToResultingURLRecord; +const serializeURLwhatwg_url = require("whatwg-url").serializeURL; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLEmbedElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLEmbedElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLEmbedElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLEmbedElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLEmbedElement before HTMLElement"); + } + class HTMLEmbedElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get src() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get src' called on an object that is not a valid instance of HTMLEmbedElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "src"); + if (value === null) { + return ""; + } + const urlRecord = parseURLToResultingURLRecord_helpers_document_base_url( + value, + esValue[implSymbol]._ownerDocument + ); + if (urlRecord !== null) { + return serializeURLwhatwg_url(urlRecord); + } + return conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set src(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set src' called on an object that is not a valid instance of HTMLEmbedElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'src' property on 'HTMLEmbedElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "src", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of HTMLEmbedElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "type"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set type(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set type' called on an object that is not a valid instance of HTMLEmbedElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'type' property on 'HTMLEmbedElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "type", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get width() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get width' called on an object that is not a valid instance of HTMLEmbedElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "width"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set width(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set width' called on an object that is not a valid instance of HTMLEmbedElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'width' property on 'HTMLEmbedElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "width", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get height() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get height' called on an object that is not a valid instance of HTMLEmbedElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "height"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set height(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set height' called on an object that is not a valid instance of HTMLEmbedElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'height' property on 'HTMLEmbedElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "height", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get align() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get align' called on an object that is not a valid instance of HTMLEmbedElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "align"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set align(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set align' called on an object that is not a valid instance of HTMLEmbedElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'align' property on 'HTMLEmbedElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "align", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of HTMLEmbedElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "name"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set name(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set name' called on an object that is not a valid instance of HTMLEmbedElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'name' property on 'HTMLEmbedElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "name", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLEmbedElement.prototype, { + src: { enumerable: true }, + type: { enumerable: true }, + width: { enumerable: true }, + height: { enumerable: true }, + align: { enumerable: true }, + name: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLEmbedElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLEmbedElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLEmbedElement + }); +}; + +const Impl = require("../nodes/HTMLEmbedElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLFieldSetElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLFieldSetElement.js new file mode 100644 index 000000000..12403c5a5 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLFieldSetElement.js @@ -0,0 +1,315 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLFieldSetElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLFieldSetElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLFieldSetElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLFieldSetElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLFieldSetElement before HTMLElement"); + } + class HTMLFieldSetElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + checkValidity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'checkValidity' called on an object that is not a valid instance of HTMLFieldSetElement."); + } + + return esValue[implSymbol].checkValidity(); + } + + reportValidity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError( + "'reportValidity' called on an object that is not a valid instance of HTMLFieldSetElement." + ); + } + + return esValue[implSymbol].reportValidity(); + } + + setCustomValidity(error) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError( + "'setCustomValidity' called on an object that is not a valid instance of HTMLFieldSetElement." + ); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'setCustomValidity' on 'HTMLFieldSetElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setCustomValidity' on 'HTMLFieldSetElement': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].setCustomValidity(...args); + } + + get disabled() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get disabled' called on an object that is not a valid instance of HTMLFieldSetElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "disabled"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set disabled(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set disabled' called on an object that is not a valid instance of HTMLFieldSetElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'disabled' property on 'HTMLFieldSetElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "disabled", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "disabled"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get form() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get form' called on an object that is not a valid instance of HTMLFieldSetElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["form"]); + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of HTMLFieldSetElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "name"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set name(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set name' called on an object that is not a valid instance of HTMLFieldSetElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'name' property on 'HTMLFieldSetElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "name", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of HTMLFieldSetElement."); + } + + return esValue[implSymbol]["type"]; + } + + get elements() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get elements' called on an object that is not a valid instance of HTMLFieldSetElement."); + } + + return utils.getSameObject(this, "elements", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["elements"]); + }); + } + + get willValidate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get willValidate' called on an object that is not a valid instance of HTMLFieldSetElement." + ); + } + + return esValue[implSymbol]["willValidate"]; + } + + get validity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get validity' called on an object that is not a valid instance of HTMLFieldSetElement."); + } + + return utils.getSameObject(this, "validity", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["validity"]); + }); + } + + get validationMessage() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get validationMessage' called on an object that is not a valid instance of HTMLFieldSetElement." + ); + } + + return esValue[implSymbol]["validationMessage"]; + } + } + Object.defineProperties(HTMLFieldSetElement.prototype, { + checkValidity: { enumerable: true }, + reportValidity: { enumerable: true }, + setCustomValidity: { enumerable: true }, + disabled: { enumerable: true }, + form: { enumerable: true }, + name: { enumerable: true }, + type: { enumerable: true }, + elements: { enumerable: true }, + willValidate: { enumerable: true }, + validity: { enumerable: true }, + validationMessage: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLFieldSetElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLFieldSetElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLFieldSetElement + }); +}; + +const Impl = require("../nodes/HTMLFieldSetElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLFontElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLFontElement.js new file mode 100644 index 000000000..e72e99947 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLFontElement.js @@ -0,0 +1,226 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLFontElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLFontElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLFontElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLFontElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLFontElement before HTMLElement"); + } + class HTMLFontElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get color() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get color' called on an object that is not a valid instance of HTMLFontElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "color"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set color(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set color' called on an object that is not a valid instance of HTMLFontElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'color' property on 'HTMLFontElement': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "color", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get face() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get face' called on an object that is not a valid instance of HTMLFontElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "face"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set face(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set face' called on an object that is not a valid instance of HTMLFontElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'face' property on 'HTMLFontElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "face", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get size() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get size' called on an object that is not a valid instance of HTMLFontElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "size"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set size(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set size' called on an object that is not a valid instance of HTMLFontElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'size' property on 'HTMLFontElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "size", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLFontElement.prototype, { + color: { enumerable: true }, + face: { enumerable: true }, + size: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLFontElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLFontElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLFontElement + }); +}; + +const Impl = require("../nodes/HTMLFontElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLFormElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLFormElement.js new file mode 100644 index 000000000..4d578607a --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLFormElement.js @@ -0,0 +1,457 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const HTMLElement = require("./HTMLElement.js"); +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "HTMLFormElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLFormElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLFormElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLFormElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLFormElement before HTMLElement"); + } + class HTMLFormElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + submit() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'submit' called on an object that is not a valid instance of HTMLFormElement."); + } + + return esValue[implSymbol].submit(); + } + + requestSubmit() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'requestSubmit' called on an object that is not a valid instance of HTMLFormElement."); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + curArg = HTMLElement.convert(curArg, { + context: "Failed to execute 'requestSubmit' on 'HTMLFormElement': parameter 1" + }); + } + args.push(curArg); + } + return esValue[implSymbol].requestSubmit(...args); + } + + reset() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'reset' called on an object that is not a valid instance of HTMLFormElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].reset(); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + checkValidity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'checkValidity' called on an object that is not a valid instance of HTMLFormElement."); + } + + return esValue[implSymbol].checkValidity(); + } + + reportValidity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'reportValidity' called on an object that is not a valid instance of HTMLFormElement."); + } + + return esValue[implSymbol].reportValidity(); + } + + get acceptCharset() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get acceptCharset' called on an object that is not a valid instance of HTMLFormElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "accept-charset"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set acceptCharset(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set acceptCharset' called on an object that is not a valid instance of HTMLFormElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'acceptCharset' property on 'HTMLFormElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "accept-charset", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get action() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get action' called on an object that is not a valid instance of HTMLFormElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["action"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set action(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set action' called on an object that is not a valid instance of HTMLFormElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'action' property on 'HTMLFormElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["action"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get enctype() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get enctype' called on an object that is not a valid instance of HTMLFormElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["enctype"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set enctype(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set enctype' called on an object that is not a valid instance of HTMLFormElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'enctype' property on 'HTMLFormElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["enctype"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get method() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get method' called on an object that is not a valid instance of HTMLFormElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["method"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set method(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set method' called on an object that is not a valid instance of HTMLFormElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'method' property on 'HTMLFormElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["method"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of HTMLFormElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "name"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set name(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set name' called on an object that is not a valid instance of HTMLFormElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'name' property on 'HTMLFormElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "name", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get noValidate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get noValidate' called on an object that is not a valid instance of HTMLFormElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "novalidate"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set noValidate(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set noValidate' called on an object that is not a valid instance of HTMLFormElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'noValidate' property on 'HTMLFormElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "novalidate", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "novalidate"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get target() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get target' called on an object that is not a valid instance of HTMLFormElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "target"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set target(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set target' called on an object that is not a valid instance of HTMLFormElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'target' property on 'HTMLFormElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "target", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get elements() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get elements' called on an object that is not a valid instance of HTMLFormElement."); + } + + return utils.getSameObject(this, "elements", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["elements"]); + }); + } + + get length() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get length' called on an object that is not a valid instance of HTMLFormElement."); + } + + return esValue[implSymbol]["length"]; + } + } + Object.defineProperties(HTMLFormElement.prototype, { + submit: { enumerable: true }, + requestSubmit: { enumerable: true }, + reset: { enumerable: true }, + checkValidity: { enumerable: true }, + reportValidity: { enumerable: true }, + acceptCharset: { enumerable: true }, + action: { enumerable: true }, + enctype: { enumerable: true }, + method: { enumerable: true }, + name: { enumerable: true }, + noValidate: { enumerable: true }, + target: { enumerable: true }, + elements: { enumerable: true }, + length: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLFormElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLFormElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLFormElement + }); +}; + +const Impl = require("../nodes/HTMLFormElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLFrameElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLFrameElement.js new file mode 100644 index 000000000..9115a3698 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLFrameElement.js @@ -0,0 +1,459 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const parseURLToResultingURLRecord_helpers_document_base_url = + require("../helpers/document-base-url.js").parseURLToResultingURLRecord; +const serializeURLwhatwg_url = require("whatwg-url").serializeURL; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLFrameElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLFrameElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLFrameElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLFrameElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLFrameElement before HTMLElement"); + } + class HTMLFrameElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of HTMLFrameElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "name"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set name(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set name' called on an object that is not a valid instance of HTMLFrameElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'name' property on 'HTMLFrameElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "name", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get scrolling() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get scrolling' called on an object that is not a valid instance of HTMLFrameElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "scrolling"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set scrolling(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set scrolling' called on an object that is not a valid instance of HTMLFrameElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'scrolling' property on 'HTMLFrameElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "scrolling", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get src() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get src' called on an object that is not a valid instance of HTMLFrameElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "src"); + if (value === null) { + return ""; + } + const urlRecord = parseURLToResultingURLRecord_helpers_document_base_url( + value, + esValue[implSymbol]._ownerDocument + ); + if (urlRecord !== null) { + return serializeURLwhatwg_url(urlRecord); + } + return conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set src(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set src' called on an object that is not a valid instance of HTMLFrameElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'src' property on 'HTMLFrameElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "src", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get frameBorder() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get frameBorder' called on an object that is not a valid instance of HTMLFrameElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "frameborder"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set frameBorder(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set frameBorder' called on an object that is not a valid instance of HTMLFrameElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'frameBorder' property on 'HTMLFrameElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "frameborder", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get longDesc() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get longDesc' called on an object that is not a valid instance of HTMLFrameElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "longdesc"); + if (value === null) { + return ""; + } + const urlRecord = parseURLToResultingURLRecord_helpers_document_base_url( + value, + esValue[implSymbol]._ownerDocument + ); + if (urlRecord !== null) { + return serializeURLwhatwg_url(urlRecord); + } + return conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set longDesc(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set longDesc' called on an object that is not a valid instance of HTMLFrameElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'longDesc' property on 'HTMLFrameElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "longdesc", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get noResize() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get noResize' called on an object that is not a valid instance of HTMLFrameElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "noresize"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set noResize(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set noResize' called on an object that is not a valid instance of HTMLFrameElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'noResize' property on 'HTMLFrameElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "noresize", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "noresize"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get contentDocument() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get contentDocument' called on an object that is not a valid instance of HTMLFrameElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["contentDocument"]); + } + + get contentWindow() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get contentWindow' called on an object that is not a valid instance of HTMLFrameElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["contentWindow"]); + } + + get marginHeight() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get marginHeight' called on an object that is not a valid instance of HTMLFrameElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "marginheight"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set marginHeight(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set marginHeight' called on an object that is not a valid instance of HTMLFrameElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'marginHeight' property on 'HTMLFrameElement': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "marginheight", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get marginWidth() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get marginWidth' called on an object that is not a valid instance of HTMLFrameElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "marginwidth"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set marginWidth(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set marginWidth' called on an object that is not a valid instance of HTMLFrameElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'marginWidth' property on 'HTMLFrameElement': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "marginwidth", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLFrameElement.prototype, { + name: { enumerable: true }, + scrolling: { enumerable: true }, + src: { enumerable: true }, + frameBorder: { enumerable: true }, + longDesc: { enumerable: true }, + noResize: { enumerable: true }, + contentDocument: { enumerable: true }, + contentWindow: { enumerable: true }, + marginHeight: { enumerable: true }, + marginWidth: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLFrameElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLFrameElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLFrameElement + }); +}; + +const Impl = require("../nodes/HTMLFrameElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLFrameSetElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLFrameSetElement.js new file mode 100644 index 000000000..9af15545a --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLFrameSetElement.js @@ -0,0 +1,683 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const EventHandlerNonNull = require("./EventHandlerNonNull.js"); +const OnBeforeUnloadEventHandlerNonNull = require("./OnBeforeUnloadEventHandlerNonNull.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLFrameSetElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLFrameSetElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLFrameSetElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLFrameSetElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLFrameSetElement before HTMLElement"); + } + class HTMLFrameSetElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get cols() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get cols' called on an object that is not a valid instance of HTMLFrameSetElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "cols"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set cols(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set cols' called on an object that is not a valid instance of HTMLFrameSetElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'cols' property on 'HTMLFrameSetElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "cols", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get rows() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get rows' called on an object that is not a valid instance of HTMLFrameSetElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "rows"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set rows(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set rows' called on an object that is not a valid instance of HTMLFrameSetElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'rows' property on 'HTMLFrameSetElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "rows", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get onafterprint() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onafterprint' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onafterprint"]); + } + + set onafterprint(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onafterprint' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onafterprint' property on 'HTMLFrameSetElement': The provided value" + }); + } + esValue[implSymbol]["onafterprint"] = V; + } + + get onbeforeprint() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onbeforeprint' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onbeforeprint"]); + } + + set onbeforeprint(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onbeforeprint' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onbeforeprint' property on 'HTMLFrameSetElement': The provided value" + }); + } + esValue[implSymbol]["onbeforeprint"] = V; + } + + get onbeforeunload() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onbeforeunload' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onbeforeunload"]); + } + + set onbeforeunload(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onbeforeunload' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = OnBeforeUnloadEventHandlerNonNull.convert(V, { + context: "Failed to set the 'onbeforeunload' property on 'HTMLFrameSetElement': The provided value" + }); + } + esValue[implSymbol]["onbeforeunload"] = V; + } + + get onhashchange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onhashchange' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onhashchange"]); + } + + set onhashchange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onhashchange' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onhashchange' property on 'HTMLFrameSetElement': The provided value" + }); + } + esValue[implSymbol]["onhashchange"] = V; + } + + get onlanguagechange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onlanguagechange' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onlanguagechange"]); + } + + set onlanguagechange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onlanguagechange' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onlanguagechange' property on 'HTMLFrameSetElement': The provided value" + }); + } + esValue[implSymbol]["onlanguagechange"] = V; + } + + get onmessage() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmessage' called on an object that is not a valid instance of HTMLFrameSetElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmessage"]); + } + + set onmessage(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmessage' called on an object that is not a valid instance of HTMLFrameSetElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmessage' property on 'HTMLFrameSetElement': The provided value" + }); + } + esValue[implSymbol]["onmessage"] = V; + } + + get onmessageerror() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onmessageerror' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmessageerror"]); + } + + set onmessageerror(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onmessageerror' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmessageerror' property on 'HTMLFrameSetElement': The provided value" + }); + } + esValue[implSymbol]["onmessageerror"] = V; + } + + get onoffline() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onoffline' called on an object that is not a valid instance of HTMLFrameSetElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onoffline"]); + } + + set onoffline(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onoffline' called on an object that is not a valid instance of HTMLFrameSetElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onoffline' property on 'HTMLFrameSetElement': The provided value" + }); + } + esValue[implSymbol]["onoffline"] = V; + } + + get ononline() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ononline' called on an object that is not a valid instance of HTMLFrameSetElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ononline"]); + } + + set ononline(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ononline' called on an object that is not a valid instance of HTMLFrameSetElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ononline' property on 'HTMLFrameSetElement': The provided value" + }); + } + esValue[implSymbol]["ononline"] = V; + } + + get onpagehide() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onpagehide' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onpagehide"]); + } + + set onpagehide(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onpagehide' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onpagehide' property on 'HTMLFrameSetElement': The provided value" + }); + } + esValue[implSymbol]["onpagehide"] = V; + } + + get onpageshow() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onpageshow' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onpageshow"]); + } + + set onpageshow(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onpageshow' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onpageshow' property on 'HTMLFrameSetElement': The provided value" + }); + } + esValue[implSymbol]["onpageshow"] = V; + } + + get onpopstate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onpopstate' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onpopstate"]); + } + + set onpopstate(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onpopstate' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onpopstate' property on 'HTMLFrameSetElement': The provided value" + }); + } + esValue[implSymbol]["onpopstate"] = V; + } + + get onrejectionhandled() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onrejectionhandled' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onrejectionhandled"]); + } + + set onrejectionhandled(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onrejectionhandled' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onrejectionhandled' property on 'HTMLFrameSetElement': The provided value" + }); + } + esValue[implSymbol]["onrejectionhandled"] = V; + } + + get onstorage() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onstorage' called on an object that is not a valid instance of HTMLFrameSetElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onstorage"]); + } + + set onstorage(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onstorage' called on an object that is not a valid instance of HTMLFrameSetElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onstorage' property on 'HTMLFrameSetElement': The provided value" + }); + } + esValue[implSymbol]["onstorage"] = V; + } + + get onunhandledrejection() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onunhandledrejection' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onunhandledrejection"]); + } + + set onunhandledrejection(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onunhandledrejection' called on an object that is not a valid instance of HTMLFrameSetElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onunhandledrejection' property on 'HTMLFrameSetElement': The provided value" + }); + } + esValue[implSymbol]["onunhandledrejection"] = V; + } + + get onunload() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onunload' called on an object that is not a valid instance of HTMLFrameSetElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onunload"]); + } + + set onunload(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onunload' called on an object that is not a valid instance of HTMLFrameSetElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onunload' property on 'HTMLFrameSetElement': The provided value" + }); + } + esValue[implSymbol]["onunload"] = V; + } + } + Object.defineProperties(HTMLFrameSetElement.prototype, { + cols: { enumerable: true }, + rows: { enumerable: true }, + onafterprint: { enumerable: true }, + onbeforeprint: { enumerable: true }, + onbeforeunload: { enumerable: true }, + onhashchange: { enumerable: true }, + onlanguagechange: { enumerable: true }, + onmessage: { enumerable: true }, + onmessageerror: { enumerable: true }, + onoffline: { enumerable: true }, + ononline: { enumerable: true }, + onpagehide: { enumerable: true }, + onpageshow: { enumerable: true }, + onpopstate: { enumerable: true }, + onrejectionhandled: { enumerable: true }, + onstorage: { enumerable: true }, + onunhandledrejection: { enumerable: true }, + onunload: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLFrameSetElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLFrameSetElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLFrameSetElement + }); +}; + +const Impl = require("../nodes/HTMLFrameSetElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLHRElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLHRElement.js new file mode 100644 index 000000000..9cd244504 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLHRElement.js @@ -0,0 +1,300 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLHRElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLHRElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLHRElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLHRElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLHRElement before HTMLElement"); + } + class HTMLHRElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get align() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get align' called on an object that is not a valid instance of HTMLHRElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "align"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set align(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set align' called on an object that is not a valid instance of HTMLHRElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'align' property on 'HTMLHRElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "align", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get color() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get color' called on an object that is not a valid instance of HTMLHRElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "color"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set color(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set color' called on an object that is not a valid instance of HTMLHRElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'color' property on 'HTMLHRElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "color", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get noShade() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get noShade' called on an object that is not a valid instance of HTMLHRElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "noshade"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set noShade(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set noShade' called on an object that is not a valid instance of HTMLHRElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'noShade' property on 'HTMLHRElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "noshade", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "noshade"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get size() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get size' called on an object that is not a valid instance of HTMLHRElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "size"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set size(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set size' called on an object that is not a valid instance of HTMLHRElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'size' property on 'HTMLHRElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "size", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get width() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get width' called on an object that is not a valid instance of HTMLHRElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "width"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set width(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set width' called on an object that is not a valid instance of HTMLHRElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'width' property on 'HTMLHRElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "width", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLHRElement.prototype, { + align: { enumerable: true }, + color: { enumerable: true }, + noShade: { enumerable: true }, + size: { enumerable: true }, + width: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLHRElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLHRElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLHRElement + }); +}; + +const Impl = require("../nodes/HTMLHRElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLHeadElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLHeadElement.js new file mode 100644 index 000000000..1bc6646f2 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLHeadElement.js @@ -0,0 +1,115 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLHeadElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLHeadElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLHeadElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLHeadElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLHeadElement before HTMLElement"); + } + class HTMLHeadElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + } + Object.defineProperties(HTMLHeadElement.prototype, { + [Symbol.toStringTag]: { value: "HTMLHeadElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLHeadElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLHeadElement + }); +}; + +const Impl = require("../nodes/HTMLHeadElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLHeadingElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLHeadingElement.js new file mode 100644 index 000000000..8075ec4f2 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLHeadingElement.js @@ -0,0 +1,153 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLHeadingElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLHeadingElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLHeadingElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLHeadingElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLHeadingElement before HTMLElement"); + } + class HTMLHeadingElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get align() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get align' called on an object that is not a valid instance of HTMLHeadingElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "align"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set align(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set align' called on an object that is not a valid instance of HTMLHeadingElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'align' property on 'HTMLHeadingElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "align", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLHeadingElement.prototype, { + align: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLHeadingElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLHeadingElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLHeadingElement + }); +}; + +const Impl = require("../nodes/HTMLHeadingElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLHtmlElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLHtmlElement.js new file mode 100644 index 000000000..78824082f --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLHtmlElement.js @@ -0,0 +1,153 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLHtmlElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLHtmlElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLHtmlElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLHtmlElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLHtmlElement before HTMLElement"); + } + class HTMLHtmlElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get version() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get version' called on an object that is not a valid instance of HTMLHtmlElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "version"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set version(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set version' called on an object that is not a valid instance of HTMLHtmlElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'version' property on 'HTMLHtmlElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "version", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLHtmlElement.prototype, { + version: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLHtmlElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLHtmlElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLHtmlElement + }); +}; + +const Impl = require("../nodes/HTMLHtmlElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLIFrameElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLIFrameElement.js new file mode 100644 index 000000000..c9a8793a6 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLIFrameElement.js @@ -0,0 +1,621 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const parseURLToResultingURLRecord_helpers_document_base_url = + require("../helpers/document-base-url.js").parseURLToResultingURLRecord; +const serializeURLwhatwg_url = require("whatwg-url").serializeURL; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLIFrameElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLIFrameElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLIFrameElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLIFrameElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLIFrameElement before HTMLElement"); + } + class HTMLIFrameElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + getSVGDocument() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getSVGDocument' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].getSVGDocument()); + } + + get src() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get src' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "src"); + if (value === null) { + return ""; + } + const urlRecord = parseURLToResultingURLRecord_helpers_document_base_url( + value, + esValue[implSymbol]._ownerDocument + ); + if (urlRecord !== null) { + return serializeURLwhatwg_url(urlRecord); + } + return conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set src(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set src' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'src' property on 'HTMLIFrameElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "src", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get srcdoc() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get srcdoc' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "srcdoc"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set srcdoc(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set srcdoc' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'srcdoc' property on 'HTMLIFrameElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "srcdoc", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "name"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set name(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set name' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'name' property on 'HTMLIFrameElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "name", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get allowFullscreen() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get allowFullscreen' called on an object that is not a valid instance of HTMLIFrameElement." + ); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "allowfullscreen"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set allowFullscreen(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set allowFullscreen' called on an object that is not a valid instance of HTMLIFrameElement." + ); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'allowFullscreen' property on 'HTMLIFrameElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "allowfullscreen", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "allowfullscreen"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get width() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get width' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "width"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set width(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set width' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'width' property on 'HTMLIFrameElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "width", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get height() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get height' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "height"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set height(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set height' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'height' property on 'HTMLIFrameElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "height", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get contentDocument() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get contentDocument' called on an object that is not a valid instance of HTMLIFrameElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["contentDocument"]); + } + + get contentWindow() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get contentWindow' called on an object that is not a valid instance of HTMLIFrameElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["contentWindow"]); + } + + get align() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get align' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "align"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set align(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set align' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'align' property on 'HTMLIFrameElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "align", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get scrolling() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get scrolling' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "scrolling"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set scrolling(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set scrolling' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'scrolling' property on 'HTMLIFrameElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "scrolling", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get frameBorder() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get frameBorder' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "frameborder"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set frameBorder(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set frameBorder' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'frameBorder' property on 'HTMLIFrameElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "frameborder", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get longDesc() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get longDesc' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "longdesc"); + if (value === null) { + return ""; + } + const urlRecord = parseURLToResultingURLRecord_helpers_document_base_url( + value, + esValue[implSymbol]._ownerDocument + ); + if (urlRecord !== null) { + return serializeURLwhatwg_url(urlRecord); + } + return conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set longDesc(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set longDesc' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'longDesc' property on 'HTMLIFrameElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "longdesc", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get marginHeight() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get marginHeight' called on an object that is not a valid instance of HTMLIFrameElement." + ); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "marginheight"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set marginHeight(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set marginHeight' called on an object that is not a valid instance of HTMLIFrameElement." + ); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'marginHeight' property on 'HTMLIFrameElement': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "marginheight", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get marginWidth() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get marginWidth' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "marginwidth"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set marginWidth(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set marginWidth' called on an object that is not a valid instance of HTMLIFrameElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'marginWidth' property on 'HTMLIFrameElement': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "marginwidth", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLIFrameElement.prototype, { + getSVGDocument: { enumerable: true }, + src: { enumerable: true }, + srcdoc: { enumerable: true }, + name: { enumerable: true }, + allowFullscreen: { enumerable: true }, + width: { enumerable: true }, + height: { enumerable: true }, + contentDocument: { enumerable: true }, + contentWindow: { enumerable: true }, + align: { enumerable: true }, + scrolling: { enumerable: true }, + frameBorder: { enumerable: true }, + longDesc: { enumerable: true }, + marginHeight: { enumerable: true }, + marginWidth: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLIFrameElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLIFrameElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLIFrameElement + }); +}; + +const Impl = require("../nodes/HTMLIFrameElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLImageElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLImageElement.js new file mode 100644 index 000000000..dfa1082b0 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLImageElement.js @@ -0,0 +1,789 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const parseURLToResultingURLRecord_helpers_document_base_url = + require("../helpers/document-base-url.js").parseURLToResultingURLRecord; +const serializeURLwhatwg_url = require("whatwg-url").serializeURL; +const parseNonNegativeInteger_helpers_strings = require("../helpers/strings.js").parseNonNegativeInteger; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLImageElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLImageElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLImageElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLImageElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLImageElement before HTMLElement"); + } + class HTMLImageElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get alt() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get alt' called on an object that is not a valid instance of HTMLImageElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "alt"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set alt(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set alt' called on an object that is not a valid instance of HTMLImageElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'alt' property on 'HTMLImageElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "alt", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get src() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get src' called on an object that is not a valid instance of HTMLImageElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "src"); + if (value === null) { + return ""; + } + const urlRecord = parseURLToResultingURLRecord_helpers_document_base_url( + value, + esValue[implSymbol]._ownerDocument + ); + if (urlRecord !== null) { + return serializeURLwhatwg_url(urlRecord); + } + return conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set src(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set src' called on an object that is not a valid instance of HTMLImageElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'src' property on 'HTMLImageElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "src", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get srcset() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get srcset' called on an object that is not a valid instance of HTMLImageElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "srcset"); + return value === null ? "" : conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set srcset(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set srcset' called on an object that is not a valid instance of HTMLImageElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'srcset' property on 'HTMLImageElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "srcset", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get sizes() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get sizes' called on an object that is not a valid instance of HTMLImageElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "sizes"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set sizes(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set sizes' called on an object that is not a valid instance of HTMLImageElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'sizes' property on 'HTMLImageElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "sizes", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get crossOrigin() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get crossOrigin' called on an object that is not a valid instance of HTMLImageElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "crossorigin"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set crossOrigin(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set crossOrigin' called on an object that is not a valid instance of HTMLImageElement."); + } + + if (V === null || V === undefined) { + V = null; + } else { + V = conversions["DOMString"](V, { + context: "Failed to set the 'crossOrigin' property on 'HTMLImageElement': The provided value" + }); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "crossorigin", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get useMap() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get useMap' called on an object that is not a valid instance of HTMLImageElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "usemap"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set useMap(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set useMap' called on an object that is not a valid instance of HTMLImageElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'useMap' property on 'HTMLImageElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "usemap", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get isMap() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get isMap' called on an object that is not a valid instance of HTMLImageElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "ismap"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set isMap(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set isMap' called on an object that is not a valid instance of HTMLImageElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'isMap' property on 'HTMLImageElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "ismap", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "ismap"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get width() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get width' called on an object that is not a valid instance of HTMLImageElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["width"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set width(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set width' called on an object that is not a valid instance of HTMLImageElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'width' property on 'HTMLImageElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["width"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get height() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get height' called on an object that is not a valid instance of HTMLImageElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["height"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set height(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set height' called on an object that is not a valid instance of HTMLImageElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'height' property on 'HTMLImageElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["height"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get naturalWidth() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get naturalWidth' called on an object that is not a valid instance of HTMLImageElement."); + } + + return esValue[implSymbol]["naturalWidth"]; + } + + get naturalHeight() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get naturalHeight' called on an object that is not a valid instance of HTMLImageElement." + ); + } + + return esValue[implSymbol]["naturalHeight"]; + } + + get complete() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get complete' called on an object that is not a valid instance of HTMLImageElement."); + } + + return esValue[implSymbol]["complete"]; + } + + get currentSrc() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get currentSrc' called on an object that is not a valid instance of HTMLImageElement."); + } + + return esValue[implSymbol]["currentSrc"]; + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of HTMLImageElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "name"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set name(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set name' called on an object that is not a valid instance of HTMLImageElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'name' property on 'HTMLImageElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "name", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get lowsrc() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get lowsrc' called on an object that is not a valid instance of HTMLImageElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "lowsrc"); + if (value === null) { + return ""; + } + const urlRecord = parseURLToResultingURLRecord_helpers_document_base_url( + value, + esValue[implSymbol]._ownerDocument + ); + if (urlRecord !== null) { + return serializeURLwhatwg_url(urlRecord); + } + return conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set lowsrc(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set lowsrc' called on an object that is not a valid instance of HTMLImageElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'lowsrc' property on 'HTMLImageElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "lowsrc", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get align() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get align' called on an object that is not a valid instance of HTMLImageElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "align"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set align(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set align' called on an object that is not a valid instance of HTMLImageElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'align' property on 'HTMLImageElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "align", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get hspace() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get hspace' called on an object that is not a valid instance of HTMLImageElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + let value = esValue[implSymbol].getAttributeNS(null, "hspace"); + if (value === null) { + return 0; + } + value = parseNonNegativeInteger_helpers_strings(value); + return value !== null && value >= 0 && value <= 2147483647 ? value : 0; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set hspace(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set hspace' called on an object that is not a valid instance of HTMLImageElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'hspace' property on 'HTMLImageElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const n = V <= 2147483647 ? V : 0; + esValue[implSymbol].setAttributeNS(null, "hspace", String(n)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get vspace() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get vspace' called on an object that is not a valid instance of HTMLImageElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + let value = esValue[implSymbol].getAttributeNS(null, "vspace"); + if (value === null) { + return 0; + } + value = parseNonNegativeInteger_helpers_strings(value); + return value !== null && value >= 0 && value <= 2147483647 ? value : 0; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set vspace(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set vspace' called on an object that is not a valid instance of HTMLImageElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'vspace' property on 'HTMLImageElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const n = V <= 2147483647 ? V : 0; + esValue[implSymbol].setAttributeNS(null, "vspace", String(n)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get longDesc() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get longDesc' called on an object that is not a valid instance of HTMLImageElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "longdesc"); + if (value === null) { + return ""; + } + const urlRecord = parseURLToResultingURLRecord_helpers_document_base_url( + value, + esValue[implSymbol]._ownerDocument + ); + if (urlRecord !== null) { + return serializeURLwhatwg_url(urlRecord); + } + return conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set longDesc(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set longDesc' called on an object that is not a valid instance of HTMLImageElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'longDesc' property on 'HTMLImageElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "longdesc", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get border() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get border' called on an object that is not a valid instance of HTMLImageElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "border"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set border(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set border' called on an object that is not a valid instance of HTMLImageElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'border' property on 'HTMLImageElement': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "border", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLImageElement.prototype, { + alt: { enumerable: true }, + src: { enumerable: true }, + srcset: { enumerable: true }, + sizes: { enumerable: true }, + crossOrigin: { enumerable: true }, + useMap: { enumerable: true }, + isMap: { enumerable: true }, + width: { enumerable: true }, + height: { enumerable: true }, + naturalWidth: { enumerable: true }, + naturalHeight: { enumerable: true }, + complete: { enumerable: true }, + currentSrc: { enumerable: true }, + name: { enumerable: true }, + lowsrc: { enumerable: true }, + align: { enumerable: true }, + hspace: { enumerable: true }, + vspace: { enumerable: true }, + longDesc: { enumerable: true }, + border: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLImageElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLImageElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLImageElement + }); +}; + +const Impl = require("../nodes/HTMLImageElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js new file mode 100644 index 000000000..8fa012ee9 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js @@ -0,0 +1,1696 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const SelectionMode = require("./SelectionMode.js"); +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const FileList = require("./FileList.js"); +const parseURLToResultingURLRecord_helpers_document_base_url = + require("../helpers/document-base-url.js").parseURLToResultingURLRecord; +const serializeURLwhatwg_url = require("whatwg-url").serializeURL; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLInputElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLInputElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLInputElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLInputElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLInputElement before HTMLElement"); + } + class HTMLInputElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + stepUp() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'stepUp' called on an object that is not a valid instance of HTMLInputElement."); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + curArg = conversions["long"](curArg, { + context: "Failed to execute 'stepUp' on 'HTMLInputElement': parameter 1" + }); + } else { + curArg = 1; + } + args.push(curArg); + } + return esValue[implSymbol].stepUp(...args); + } + + stepDown() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'stepDown' called on an object that is not a valid instance of HTMLInputElement."); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + curArg = conversions["long"](curArg, { + context: "Failed to execute 'stepDown' on 'HTMLInputElement': parameter 1" + }); + } else { + curArg = 1; + } + args.push(curArg); + } + return esValue[implSymbol].stepDown(...args); + } + + checkValidity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'checkValidity' called on an object that is not a valid instance of HTMLInputElement."); + } + + return esValue[implSymbol].checkValidity(); + } + + reportValidity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'reportValidity' called on an object that is not a valid instance of HTMLInputElement."); + } + + return esValue[implSymbol].reportValidity(); + } + + setCustomValidity(error) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError( + "'setCustomValidity' called on an object that is not a valid instance of HTMLInputElement." + ); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'setCustomValidity' on 'HTMLInputElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setCustomValidity' on 'HTMLInputElement': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].setCustomValidity(...args); + } + + select() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'select' called on an object that is not a valid instance of HTMLInputElement."); + } + + return esValue[implSymbol].select(); + } + + setRangeText(replacement) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'setRangeText' called on an object that is not a valid instance of HTMLInputElement."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'setRangeText' on 'HTMLInputElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + switch (arguments.length) { + case 1: + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setRangeText' on 'HTMLInputElement': parameter 1" + }); + args.push(curArg); + } + break; + case 2: + throw new TypeError( + "Failed to execute 'setRangeText' on 'HTMLInputElement': only " + arguments.length + " arguments present." + ); + break; + case 3: + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setRangeText' on 'HTMLInputElement': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'setRangeText' on 'HTMLInputElement': parameter 2" + }); + args.push(curArg); + } + { + let curArg = arguments[2]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'setRangeText' on 'HTMLInputElement': parameter 3" + }); + args.push(curArg); + } + break; + default: + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setRangeText' on 'HTMLInputElement': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'setRangeText' on 'HTMLInputElement': parameter 2" + }); + args.push(curArg); + } + { + let curArg = arguments[2]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'setRangeText' on 'HTMLInputElement': parameter 3" + }); + args.push(curArg); + } + { + let curArg = arguments[3]; + if (curArg !== undefined) { + curArg = SelectionMode.convert(curArg, { + context: "Failed to execute 'setRangeText' on 'HTMLInputElement': parameter 4" + }); + } else { + curArg = "preserve"; + } + args.push(curArg); + } + } + return esValue[implSymbol].setRangeText(...args); + } + + setSelectionRange(start, end) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError( + "'setSelectionRange' called on an object that is not a valid instance of HTMLInputElement." + ); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'setSelectionRange' on 'HTMLInputElement': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'setSelectionRange' on 'HTMLInputElement': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'setSelectionRange' on 'HTMLInputElement': parameter 2" + }); + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setSelectionRange' on 'HTMLInputElement': parameter 3" + }); + } + args.push(curArg); + } + return esValue[implSymbol].setSelectionRange(...args); + } + + get accept() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get accept' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "accept"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set accept(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set accept' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'accept' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "accept", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get alt() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get alt' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "alt"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set alt(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set alt' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'alt' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "alt", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get autocomplete() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get autocomplete' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "autocomplete"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set autocomplete(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set autocomplete' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'autocomplete' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "autocomplete", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get autofocus() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get autofocus' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "autofocus"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set autofocus(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set autofocus' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'autofocus' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "autofocus", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "autofocus"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get defaultChecked() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get defaultChecked' called on an object that is not a valid instance of HTMLInputElement." + ); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "checked"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set defaultChecked(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set defaultChecked' called on an object that is not a valid instance of HTMLInputElement." + ); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'defaultChecked' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "checked", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "checked"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get checked() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get checked' called on an object that is not a valid instance of HTMLInputElement."); + } + + return esValue[implSymbol]["checked"]; + } + + set checked(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set checked' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'checked' property on 'HTMLInputElement': The provided value" + }); + + esValue[implSymbol]["checked"] = V; + } + + get dirName() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get dirName' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "dirname"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set dirName(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set dirName' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'dirName' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "dirname", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get disabled() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get disabled' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "disabled"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set disabled(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set disabled' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'disabled' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "disabled", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "disabled"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get form() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get form' called on an object that is not a valid instance of HTMLInputElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["form"]); + } + + get files() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get files' called on an object that is not a valid instance of HTMLInputElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["files"]); + } + + set files(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set files' called on an object that is not a valid instance of HTMLInputElement."); + } + + if (V === null || V === undefined) { + V = null; + } else { + V = FileList.convert(V, { + context: "Failed to set the 'files' property on 'HTMLInputElement': The provided value" + }); + } + esValue[implSymbol]["files"] = V; + } + + get formNoValidate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get formNoValidate' called on an object that is not a valid instance of HTMLInputElement." + ); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "formnovalidate"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set formNoValidate(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set formNoValidate' called on an object that is not a valid instance of HTMLInputElement." + ); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'formNoValidate' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "formnovalidate", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "formnovalidate"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get formTarget() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get formTarget' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "formtarget"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set formTarget(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set formTarget' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'formTarget' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "formtarget", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get indeterminate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get indeterminate' called on an object that is not a valid instance of HTMLInputElement." + ); + } + + return esValue[implSymbol]["indeterminate"]; + } + + set indeterminate(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set indeterminate' called on an object that is not a valid instance of HTMLInputElement." + ); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'indeterminate' property on 'HTMLInputElement': The provided value" + }); + + esValue[implSymbol]["indeterminate"] = V; + } + + get inputMode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get inputMode' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "inputmode"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set inputMode(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set inputMode' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'inputMode' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "inputmode", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get list() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get list' called on an object that is not a valid instance of HTMLInputElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["list"]); + } + + get max() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get max' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "max"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set max(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set max' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'max' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "max", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get maxLength() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get maxLength' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["maxLength"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set maxLength(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set maxLength' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["long"](V, { + context: "Failed to set the 'maxLength' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["maxLength"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get min() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get min' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "min"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set min(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set min' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'min' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "min", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get minLength() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get minLength' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["minLength"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set minLength(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set minLength' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["long"](V, { + context: "Failed to set the 'minLength' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["minLength"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get multiple() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get multiple' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "multiple"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set multiple(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set multiple' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'multiple' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "multiple", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "multiple"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "name"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set name(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set name' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'name' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "name", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get pattern() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get pattern' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "pattern"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set pattern(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set pattern' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'pattern' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "pattern", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get placeholder() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get placeholder' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "placeholder"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set placeholder(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set placeholder' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'placeholder' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "placeholder", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get readOnly() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get readOnly' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "readonly"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set readOnly(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set readOnly' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'readOnly' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "readonly", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "readonly"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get required() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get required' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "required"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set required(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set required' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'required' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "required", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "required"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get size() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get size' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["size"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set size(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set size' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'size' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["size"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get src() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get src' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "src"); + if (value === null) { + return ""; + } + const urlRecord = parseURLToResultingURLRecord_helpers_document_base_url( + value, + esValue[implSymbol]._ownerDocument + ); + if (urlRecord !== null) { + return serializeURLwhatwg_url(urlRecord); + } + return conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set src(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set src' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'src' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "src", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get step() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get step' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "step"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set step(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set step' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'step' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "step", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["type"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set type(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set type' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'type' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["type"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get defaultValue() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get defaultValue' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "value"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set defaultValue(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set defaultValue' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'defaultValue' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "value", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get value() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get value' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["value"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set value(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set value' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'value' property on 'HTMLInputElement': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["value"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get valueAsDate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get valueAsDate' called on an object that is not a valid instance of HTMLInputElement."); + } + + return esValue[implSymbol]["valueAsDate"]; + } + + set valueAsDate(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set valueAsDate' called on an object that is not a valid instance of HTMLInputElement."); + } + + if (V === null || V === undefined) { + V = null; + } else { + V = conversions["object"](V, { + context: "Failed to set the 'valueAsDate' property on 'HTMLInputElement': The provided value" + }); + } + esValue[implSymbol]["valueAsDate"] = V; + } + + get valueAsNumber() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get valueAsNumber' called on an object that is not a valid instance of HTMLInputElement." + ); + } + + return esValue[implSymbol]["valueAsNumber"]; + } + + set valueAsNumber(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set valueAsNumber' called on an object that is not a valid instance of HTMLInputElement." + ); + } + + V = conversions["unrestricted double"](V, { + context: "Failed to set the 'valueAsNumber' property on 'HTMLInputElement': The provided value" + }); + + esValue[implSymbol]["valueAsNumber"] = V; + } + + get willValidate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get willValidate' called on an object that is not a valid instance of HTMLInputElement."); + } + + return esValue[implSymbol]["willValidate"]; + } + + get validity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get validity' called on an object that is not a valid instance of HTMLInputElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["validity"]); + } + + get validationMessage() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get validationMessage' called on an object that is not a valid instance of HTMLInputElement." + ); + } + + return esValue[implSymbol]["validationMessage"]; + } + + get labels() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get labels' called on an object that is not a valid instance of HTMLInputElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["labels"]); + } + + get selectionStart() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get selectionStart' called on an object that is not a valid instance of HTMLInputElement." + ); + } + + return esValue[implSymbol]["selectionStart"]; + } + + set selectionStart(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set selectionStart' called on an object that is not a valid instance of HTMLInputElement." + ); + } + + if (V === null || V === undefined) { + V = null; + } else { + V = conversions["unsigned long"](V, { + context: "Failed to set the 'selectionStart' property on 'HTMLInputElement': The provided value" + }); + } + esValue[implSymbol]["selectionStart"] = V; + } + + get selectionEnd() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get selectionEnd' called on an object that is not a valid instance of HTMLInputElement."); + } + + return esValue[implSymbol]["selectionEnd"]; + } + + set selectionEnd(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set selectionEnd' called on an object that is not a valid instance of HTMLInputElement."); + } + + if (V === null || V === undefined) { + V = null; + } else { + V = conversions["unsigned long"](V, { + context: "Failed to set the 'selectionEnd' property on 'HTMLInputElement': The provided value" + }); + } + esValue[implSymbol]["selectionEnd"] = V; + } + + get selectionDirection() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get selectionDirection' called on an object that is not a valid instance of HTMLInputElement." + ); + } + + return esValue[implSymbol]["selectionDirection"]; + } + + set selectionDirection(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set selectionDirection' called on an object that is not a valid instance of HTMLInputElement." + ); + } + + if (V === null || V === undefined) { + V = null; + } else { + V = conversions["DOMString"](V, { + context: "Failed to set the 'selectionDirection' property on 'HTMLInputElement': The provided value" + }); + } + esValue[implSymbol]["selectionDirection"] = V; + } + + get align() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get align' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "align"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set align(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set align' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'align' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "align", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get useMap() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get useMap' called on an object that is not a valid instance of HTMLInputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "usemap"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set useMap(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set useMap' called on an object that is not a valid instance of HTMLInputElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'useMap' property on 'HTMLInputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "usemap", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLInputElement.prototype, { + stepUp: { enumerable: true }, + stepDown: { enumerable: true }, + checkValidity: { enumerable: true }, + reportValidity: { enumerable: true }, + setCustomValidity: { enumerable: true }, + select: { enumerable: true }, + setRangeText: { enumerable: true }, + setSelectionRange: { enumerable: true }, + accept: { enumerable: true }, + alt: { enumerable: true }, + autocomplete: { enumerable: true }, + autofocus: { enumerable: true }, + defaultChecked: { enumerable: true }, + checked: { enumerable: true }, + dirName: { enumerable: true }, + disabled: { enumerable: true }, + form: { enumerable: true }, + files: { enumerable: true }, + formNoValidate: { enumerable: true }, + formTarget: { enumerable: true }, + indeterminate: { enumerable: true }, + inputMode: { enumerable: true }, + list: { enumerable: true }, + max: { enumerable: true }, + maxLength: { enumerable: true }, + min: { enumerable: true }, + minLength: { enumerable: true }, + multiple: { enumerable: true }, + name: { enumerable: true }, + pattern: { enumerable: true }, + placeholder: { enumerable: true }, + readOnly: { enumerable: true }, + required: { enumerable: true }, + size: { enumerable: true }, + src: { enumerable: true }, + step: { enumerable: true }, + type: { enumerable: true }, + defaultValue: { enumerable: true }, + value: { enumerable: true }, + valueAsDate: { enumerable: true }, + valueAsNumber: { enumerable: true }, + willValidate: { enumerable: true }, + validity: { enumerable: true }, + validationMessage: { enumerable: true }, + labels: { enumerable: true }, + selectionStart: { enumerable: true }, + selectionEnd: { enumerable: true }, + selectionDirection: { enumerable: true }, + align: { enumerable: true }, + useMap: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLInputElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLInputElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLInputElement + }); +}; + +const Impl = require("../nodes/HTMLInputElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLLIElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLLIElement.js new file mode 100644 index 000000000..e4893c4c6 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLLIElement.js @@ -0,0 +1,194 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const parseInteger_helpers_strings = require("../helpers/strings.js").parseInteger; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLLIElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLLIElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLLIElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLLIElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLLIElement before HTMLElement"); + } + class HTMLLIElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get value() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get value' called on an object that is not a valid instance of HTMLLIElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + let value = esValue[implSymbol].getAttributeNS(null, "value"); + if (value === null) { + return 0; + } + value = parseInteger_helpers_strings(value); + return value !== null && conversions.long(value) === value ? value : 0; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set value(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set value' called on an object that is not a valid instance of HTMLLIElement."); + } + + V = conversions["long"](V, { + context: "Failed to set the 'value' property on 'HTMLLIElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "value", String(V)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of HTMLLIElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "type"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set type(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set type' called on an object that is not a valid instance of HTMLLIElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'type' property on 'HTMLLIElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "type", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLLIElement.prototype, { + value: { enumerable: true }, + type: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLLIElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLLIElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLLIElement + }); +}; + +const Impl = require("../nodes/HTMLLIElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLLabelElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLLabelElement.js new file mode 100644 index 000000000..2ae5df02c --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLLabelElement.js @@ -0,0 +1,175 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLLabelElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLLabelElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLLabelElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLLabelElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLLabelElement before HTMLElement"); + } + class HTMLLabelElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get form() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get form' called on an object that is not a valid instance of HTMLLabelElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["form"]); + } + + get htmlFor() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get htmlFor' called on an object that is not a valid instance of HTMLLabelElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "for"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set htmlFor(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set htmlFor' called on an object that is not a valid instance of HTMLLabelElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'htmlFor' property on 'HTMLLabelElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "for", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get control() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get control' called on an object that is not a valid instance of HTMLLabelElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["control"]); + } + } + Object.defineProperties(HTMLLabelElement.prototype, { + form: { enumerable: true }, + htmlFor: { enumerable: true }, + control: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLLabelElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLLabelElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLLabelElement + }); +}; + +const Impl = require("../nodes/HTMLLabelElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLLegendElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLLegendElement.js new file mode 100644 index 000000000..d995529d7 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLLegendElement.js @@ -0,0 +1,164 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLLegendElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLLegendElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLLegendElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLLegendElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLLegendElement before HTMLElement"); + } + class HTMLLegendElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get form() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get form' called on an object that is not a valid instance of HTMLLegendElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["form"]); + } + + get align() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get align' called on an object that is not a valid instance of HTMLLegendElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "align"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set align(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set align' called on an object that is not a valid instance of HTMLLegendElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'align' property on 'HTMLLegendElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "align", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLLegendElement.prototype, { + form: { enumerable: true }, + align: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLLegendElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLLegendElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLLegendElement + }); +}; + +const Impl = require("../nodes/HTMLLegendElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLLinkElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLLinkElement.js new file mode 100644 index 000000000..5984f2e31 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLLinkElement.js @@ -0,0 +1,496 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const parseURLToResultingURLRecord_helpers_document_base_url = + require("../helpers/document-base-url.js").parseURLToResultingURLRecord; +const serializeURLwhatwg_url = require("whatwg-url").serializeURL; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLLinkElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLLinkElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLLinkElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLLinkElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLLinkElement before HTMLElement"); + } + class HTMLLinkElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get href() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get href' called on an object that is not a valid instance of HTMLLinkElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "href"); + if (value === null) { + return ""; + } + const urlRecord = parseURLToResultingURLRecord_helpers_document_base_url( + value, + esValue[implSymbol]._ownerDocument + ); + if (urlRecord !== null) { + return serializeURLwhatwg_url(urlRecord); + } + return conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set href(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set href' called on an object that is not a valid instance of HTMLLinkElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'href' property on 'HTMLLinkElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "href", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get crossOrigin() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get crossOrigin' called on an object that is not a valid instance of HTMLLinkElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "crossorigin"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set crossOrigin(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set crossOrigin' called on an object that is not a valid instance of HTMLLinkElement."); + } + + if (V === null || V === undefined) { + V = null; + } else { + V = conversions["DOMString"](V, { + context: "Failed to set the 'crossOrigin' property on 'HTMLLinkElement': The provided value" + }); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "crossorigin", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get rel() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get rel' called on an object that is not a valid instance of HTMLLinkElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "rel"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set rel(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set rel' called on an object that is not a valid instance of HTMLLinkElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'rel' property on 'HTMLLinkElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "rel", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get relList() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get relList' called on an object that is not a valid instance of HTMLLinkElement."); + } + + return utils.getSameObject(this, "relList", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["relList"]); + }); + } + + set relList(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set relList' called on an object that is not a valid instance of HTMLLinkElement."); + } + + const Q = esValue["relList"]; + if (!utils.isObject(Q)) { + throw new TypeError("Property 'relList' is not an object"); + } + Reflect.set(Q, "value", V); + } + + get media() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get media' called on an object that is not a valid instance of HTMLLinkElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "media"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set media(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set media' called on an object that is not a valid instance of HTMLLinkElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'media' property on 'HTMLLinkElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "media", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get hreflang() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get hreflang' called on an object that is not a valid instance of HTMLLinkElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "hreflang"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set hreflang(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set hreflang' called on an object that is not a valid instance of HTMLLinkElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'hreflang' property on 'HTMLLinkElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "hreflang", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of HTMLLinkElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "type"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set type(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set type' called on an object that is not a valid instance of HTMLLinkElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'type' property on 'HTMLLinkElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "type", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get charset() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get charset' called on an object that is not a valid instance of HTMLLinkElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "charset"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set charset(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set charset' called on an object that is not a valid instance of HTMLLinkElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'charset' property on 'HTMLLinkElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "charset", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get rev() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get rev' called on an object that is not a valid instance of HTMLLinkElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "rev"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set rev(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set rev' called on an object that is not a valid instance of HTMLLinkElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'rev' property on 'HTMLLinkElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "rev", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get target() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get target' called on an object that is not a valid instance of HTMLLinkElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "target"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set target(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set target' called on an object that is not a valid instance of HTMLLinkElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'target' property on 'HTMLLinkElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "target", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get sheet() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get sheet' called on an object that is not a valid instance of HTMLLinkElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["sheet"]); + } + } + Object.defineProperties(HTMLLinkElement.prototype, { + href: { enumerable: true }, + crossOrigin: { enumerable: true }, + rel: { enumerable: true }, + relList: { enumerable: true }, + media: { enumerable: true }, + hreflang: { enumerable: true }, + type: { enumerable: true }, + charset: { enumerable: true }, + rev: { enumerable: true }, + target: { enumerable: true }, + sheet: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLLinkElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLLinkElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLLinkElement + }); +}; + +const Impl = require("../nodes/HTMLLinkElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLMapElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLMapElement.js new file mode 100644 index 000000000..fae64bd90 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLMapElement.js @@ -0,0 +1,166 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLMapElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLMapElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLMapElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLMapElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLMapElement before HTMLElement"); + } + class HTMLMapElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of HTMLMapElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "name"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set name(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set name' called on an object that is not a valid instance of HTMLMapElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'name' property on 'HTMLMapElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "name", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get areas() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get areas' called on an object that is not a valid instance of HTMLMapElement."); + } + + return utils.getSameObject(this, "areas", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["areas"]); + }); + } + } + Object.defineProperties(HTMLMapElement.prototype, { + name: { enumerable: true }, + areas: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLMapElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLMapElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLMapElement + }); +}; + +const Impl = require("../nodes/HTMLMapElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLMarqueeElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLMarqueeElement.js new file mode 100644 index 000000000..6c7762bad --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLMarqueeElement.js @@ -0,0 +1,509 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const parseNonNegativeInteger_helpers_strings = require("../helpers/strings.js").parseNonNegativeInteger; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLMarqueeElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLMarqueeElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLMarqueeElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLMarqueeElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLMarqueeElement before HTMLElement"); + } + class HTMLMarqueeElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get behavior() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get behavior' called on an object that is not a valid instance of HTMLMarqueeElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "behavior"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set behavior(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set behavior' called on an object that is not a valid instance of HTMLMarqueeElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'behavior' property on 'HTMLMarqueeElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "behavior", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get bgColor() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get bgColor' called on an object that is not a valid instance of HTMLMarqueeElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "bgcolor"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set bgColor(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set bgColor' called on an object that is not a valid instance of HTMLMarqueeElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'bgColor' property on 'HTMLMarqueeElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "bgcolor", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get direction() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get direction' called on an object that is not a valid instance of HTMLMarqueeElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "direction"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set direction(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set direction' called on an object that is not a valid instance of HTMLMarqueeElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'direction' property on 'HTMLMarqueeElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "direction", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get height() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get height' called on an object that is not a valid instance of HTMLMarqueeElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "height"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set height(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set height' called on an object that is not a valid instance of HTMLMarqueeElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'height' property on 'HTMLMarqueeElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "height", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get hspace() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get hspace' called on an object that is not a valid instance of HTMLMarqueeElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + let value = esValue[implSymbol].getAttributeNS(null, "hspace"); + if (value === null) { + return 0; + } + value = parseNonNegativeInteger_helpers_strings(value); + return value !== null && value >= 0 && value <= 2147483647 ? value : 0; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set hspace(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set hspace' called on an object that is not a valid instance of HTMLMarqueeElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'hspace' property on 'HTMLMarqueeElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const n = V <= 2147483647 ? V : 0; + esValue[implSymbol].setAttributeNS(null, "hspace", String(n)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get scrollAmount() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get scrollAmount' called on an object that is not a valid instance of HTMLMarqueeElement." + ); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + let value = esValue[implSymbol].getAttributeNS(null, "scrollamount"); + if (value === null) { + return 0; + } + value = parseNonNegativeInteger_helpers_strings(value); + return value !== null && value >= 0 && value <= 2147483647 ? value : 0; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set scrollAmount(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set scrollAmount' called on an object that is not a valid instance of HTMLMarqueeElement." + ); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'scrollAmount' property on 'HTMLMarqueeElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const n = V <= 2147483647 ? V : 0; + esValue[implSymbol].setAttributeNS(null, "scrollamount", String(n)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get scrollDelay() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get scrollDelay' called on an object that is not a valid instance of HTMLMarqueeElement." + ); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + let value = esValue[implSymbol].getAttributeNS(null, "scrolldelay"); + if (value === null) { + return 0; + } + value = parseNonNegativeInteger_helpers_strings(value); + return value !== null && value >= 0 && value <= 2147483647 ? value : 0; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set scrollDelay(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set scrollDelay' called on an object that is not a valid instance of HTMLMarqueeElement." + ); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'scrollDelay' property on 'HTMLMarqueeElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const n = V <= 2147483647 ? V : 0; + esValue[implSymbol].setAttributeNS(null, "scrolldelay", String(n)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get trueSpeed() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get trueSpeed' called on an object that is not a valid instance of HTMLMarqueeElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "truespeed"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set trueSpeed(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set trueSpeed' called on an object that is not a valid instance of HTMLMarqueeElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'trueSpeed' property on 'HTMLMarqueeElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "truespeed", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "truespeed"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get vspace() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get vspace' called on an object that is not a valid instance of HTMLMarqueeElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + let value = esValue[implSymbol].getAttributeNS(null, "vspace"); + if (value === null) { + return 0; + } + value = parseNonNegativeInteger_helpers_strings(value); + return value !== null && value >= 0 && value <= 2147483647 ? value : 0; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set vspace(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set vspace' called on an object that is not a valid instance of HTMLMarqueeElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'vspace' property on 'HTMLMarqueeElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const n = V <= 2147483647 ? V : 0; + esValue[implSymbol].setAttributeNS(null, "vspace", String(n)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get width() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get width' called on an object that is not a valid instance of HTMLMarqueeElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "width"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set width(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set width' called on an object that is not a valid instance of HTMLMarqueeElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'width' property on 'HTMLMarqueeElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "width", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLMarqueeElement.prototype, { + behavior: { enumerable: true }, + bgColor: { enumerable: true }, + direction: { enumerable: true }, + height: { enumerable: true }, + hspace: { enumerable: true }, + scrollAmount: { enumerable: true }, + scrollDelay: { enumerable: true }, + trueSpeed: { enumerable: true }, + vspace: { enumerable: true }, + width: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLMarqueeElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLMarqueeElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLMarqueeElement + }); +}; + +const Impl = require("../nodes/HTMLMarqueeElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLMediaElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLMediaElement.js new file mode 100644 index 000000000..6c0c668e3 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLMediaElement.js @@ -0,0 +1,802 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const TextTrackKind = require("./TextTrackKind.js"); +const parseURLToResultingURLRecord_helpers_document_base_url = + require("../helpers/document-base-url.js").parseURLToResultingURLRecord; +const serializeURLwhatwg_url = require("whatwg-url").serializeURL; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLMediaElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLMediaElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLMediaElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLMediaElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLMediaElement before HTMLElement"); + } + class HTMLMediaElement extends globalObject.HTMLElement { + constructor() { + throw new TypeError("Illegal constructor"); + } + + load() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'load' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return esValue[implSymbol].load(); + } + + canPlayType(type) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'canPlayType' called on an object that is not a valid instance of HTMLMediaElement."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'canPlayType' on 'HTMLMediaElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'canPlayType' on 'HTMLMediaElement': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].canPlayType(...args)); + } + + play() { + try { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'play' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].play()); + } catch (e) { + return Promise.reject(e); + } + } + + pause() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'pause' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return esValue[implSymbol].pause(); + } + + addTextTrack(kind) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'addTextTrack' called on an object that is not a valid instance of HTMLMediaElement."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'addTextTrack' on 'HTMLMediaElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = TextTrackKind.convert(curArg, { + context: "Failed to execute 'addTextTrack' on 'HTMLMediaElement': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'addTextTrack' on 'HTMLMediaElement': parameter 2" + }); + } else { + curArg = ""; + } + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'addTextTrack' on 'HTMLMediaElement': parameter 3" + }); + } else { + curArg = ""; + } + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].addTextTrack(...args)); + } + + get src() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get src' called on an object that is not a valid instance of HTMLMediaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "src"); + if (value === null) { + return ""; + } + const urlRecord = parseURLToResultingURLRecord_helpers_document_base_url( + value, + esValue[implSymbol]._ownerDocument + ); + if (urlRecord !== null) { + return serializeURLwhatwg_url(urlRecord); + } + return conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set src(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set src' called on an object that is not a valid instance of HTMLMediaElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'src' property on 'HTMLMediaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "src", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get currentSrc() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get currentSrc' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return esValue[implSymbol]["currentSrc"]; + } + + get crossOrigin() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get crossOrigin' called on an object that is not a valid instance of HTMLMediaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "crossorigin"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set crossOrigin(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set crossOrigin' called on an object that is not a valid instance of HTMLMediaElement."); + } + + if (V === null || V === undefined) { + V = null; + } else { + V = conversions["DOMString"](V, { + context: "Failed to set the 'crossOrigin' property on 'HTMLMediaElement': The provided value" + }); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "crossorigin", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get networkState() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get networkState' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return esValue[implSymbol]["networkState"]; + } + + get preload() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get preload' called on an object that is not a valid instance of HTMLMediaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "preload"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set preload(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set preload' called on an object that is not a valid instance of HTMLMediaElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'preload' property on 'HTMLMediaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "preload", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get buffered() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get buffered' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["buffered"]); + } + + get readyState() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get readyState' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return esValue[implSymbol]["readyState"]; + } + + get seeking() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get seeking' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return esValue[implSymbol]["seeking"]; + } + + get currentTime() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get currentTime' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return esValue[implSymbol]["currentTime"]; + } + + set currentTime(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set currentTime' called on an object that is not a valid instance of HTMLMediaElement."); + } + + V = conversions["double"](V, { + context: "Failed to set the 'currentTime' property on 'HTMLMediaElement': The provided value" + }); + + esValue[implSymbol]["currentTime"] = V; + } + + get duration() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get duration' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return esValue[implSymbol]["duration"]; + } + + get paused() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get paused' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return esValue[implSymbol]["paused"]; + } + + get defaultPlaybackRate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get defaultPlaybackRate' called on an object that is not a valid instance of HTMLMediaElement." + ); + } + + return esValue[implSymbol]["defaultPlaybackRate"]; + } + + set defaultPlaybackRate(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set defaultPlaybackRate' called on an object that is not a valid instance of HTMLMediaElement." + ); + } + + V = conversions["double"](V, { + context: "Failed to set the 'defaultPlaybackRate' property on 'HTMLMediaElement': The provided value" + }); + + esValue[implSymbol]["defaultPlaybackRate"] = V; + } + + get playbackRate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get playbackRate' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return esValue[implSymbol]["playbackRate"]; + } + + set playbackRate(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set playbackRate' called on an object that is not a valid instance of HTMLMediaElement."); + } + + V = conversions["double"](V, { + context: "Failed to set the 'playbackRate' property on 'HTMLMediaElement': The provided value" + }); + + esValue[implSymbol]["playbackRate"] = V; + } + + get played() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get played' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["played"]); + } + + get seekable() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get seekable' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["seekable"]); + } + + get ended() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ended' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return esValue[implSymbol]["ended"]; + } + + get autoplay() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get autoplay' called on an object that is not a valid instance of HTMLMediaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "autoplay"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set autoplay(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set autoplay' called on an object that is not a valid instance of HTMLMediaElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'autoplay' property on 'HTMLMediaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "autoplay", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "autoplay"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get loop() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get loop' called on an object that is not a valid instance of HTMLMediaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "loop"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set loop(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set loop' called on an object that is not a valid instance of HTMLMediaElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'loop' property on 'HTMLMediaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "loop", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "loop"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get controls() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get controls' called on an object that is not a valid instance of HTMLMediaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "controls"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set controls(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set controls' called on an object that is not a valid instance of HTMLMediaElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'controls' property on 'HTMLMediaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "controls", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "controls"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get volume() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get volume' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return esValue[implSymbol]["volume"]; + } + + set volume(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set volume' called on an object that is not a valid instance of HTMLMediaElement."); + } + + V = conversions["double"](V, { + context: "Failed to set the 'volume' property on 'HTMLMediaElement': The provided value" + }); + + esValue[implSymbol]["volume"] = V; + } + + get muted() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get muted' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return esValue[implSymbol]["muted"]; + } + + set muted(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set muted' called on an object that is not a valid instance of HTMLMediaElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'muted' property on 'HTMLMediaElement': The provided value" + }); + + esValue[implSymbol]["muted"] = V; + } + + get defaultMuted() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get defaultMuted' called on an object that is not a valid instance of HTMLMediaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "muted"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set defaultMuted(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set defaultMuted' called on an object that is not a valid instance of HTMLMediaElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'defaultMuted' property on 'HTMLMediaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "muted", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "muted"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get audioTracks() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get audioTracks' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return utils.getSameObject(this, "audioTracks", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["audioTracks"]); + }); + } + + get videoTracks() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get videoTracks' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return utils.getSameObject(this, "videoTracks", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["videoTracks"]); + }); + } + + get textTracks() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get textTracks' called on an object that is not a valid instance of HTMLMediaElement."); + } + + return utils.getSameObject(this, "textTracks", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["textTracks"]); + }); + } + } + Object.defineProperties(HTMLMediaElement.prototype, { + load: { enumerable: true }, + canPlayType: { enumerable: true }, + play: { enumerable: true }, + pause: { enumerable: true }, + addTextTrack: { enumerable: true }, + src: { enumerable: true }, + currentSrc: { enumerable: true }, + crossOrigin: { enumerable: true }, + networkState: { enumerable: true }, + preload: { enumerable: true }, + buffered: { enumerable: true }, + readyState: { enumerable: true }, + seeking: { enumerable: true }, + currentTime: { enumerable: true }, + duration: { enumerable: true }, + paused: { enumerable: true }, + defaultPlaybackRate: { enumerable: true }, + playbackRate: { enumerable: true }, + played: { enumerable: true }, + seekable: { enumerable: true }, + ended: { enumerable: true }, + autoplay: { enumerable: true }, + loop: { enumerable: true }, + controls: { enumerable: true }, + volume: { enumerable: true }, + muted: { enumerable: true }, + defaultMuted: { enumerable: true }, + audioTracks: { enumerable: true }, + videoTracks: { enumerable: true }, + textTracks: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLMediaElement", configurable: true }, + NETWORK_EMPTY: { value: 0, enumerable: true }, + NETWORK_IDLE: { value: 1, enumerable: true }, + NETWORK_LOADING: { value: 2, enumerable: true }, + NETWORK_NO_SOURCE: { value: 3, enumerable: true }, + HAVE_NOTHING: { value: 0, enumerable: true }, + HAVE_METADATA: { value: 1, enumerable: true }, + HAVE_CURRENT_DATA: { value: 2, enumerable: true }, + HAVE_FUTURE_DATA: { value: 3, enumerable: true }, + HAVE_ENOUGH_DATA: { value: 4, enumerable: true } + }); + Object.defineProperties(HTMLMediaElement, { + NETWORK_EMPTY: { value: 0, enumerable: true }, + NETWORK_IDLE: { value: 1, enumerable: true }, + NETWORK_LOADING: { value: 2, enumerable: true }, + NETWORK_NO_SOURCE: { value: 3, enumerable: true }, + HAVE_NOTHING: { value: 0, enumerable: true }, + HAVE_METADATA: { value: 1, enumerable: true }, + HAVE_CURRENT_DATA: { value: 2, enumerable: true }, + HAVE_FUTURE_DATA: { value: 3, enumerable: true }, + HAVE_ENOUGH_DATA: { value: 4, enumerable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLMediaElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLMediaElement + }); +}; + +const Impl = require("../nodes/HTMLMediaElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLMenuElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLMenuElement.js new file mode 100644 index 000000000..571c84b23 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLMenuElement.js @@ -0,0 +1,156 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLMenuElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLMenuElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLMenuElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLMenuElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLMenuElement before HTMLElement"); + } + class HTMLMenuElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get compact() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get compact' called on an object that is not a valid instance of HTMLMenuElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "compact"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set compact(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set compact' called on an object that is not a valid instance of HTMLMenuElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'compact' property on 'HTMLMenuElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "compact", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "compact"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLMenuElement.prototype, { + compact: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLMenuElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLMenuElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLMenuElement + }); +}; + +const Impl = require("../nodes/HTMLMenuElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLMetaElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLMetaElement.js new file mode 100644 index 000000000..40ff3f0cf --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLMetaElement.js @@ -0,0 +1,261 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLMetaElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLMetaElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLMetaElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLMetaElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLMetaElement before HTMLElement"); + } + class HTMLMetaElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of HTMLMetaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "name"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set name(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set name' called on an object that is not a valid instance of HTMLMetaElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'name' property on 'HTMLMetaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "name", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get httpEquiv() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get httpEquiv' called on an object that is not a valid instance of HTMLMetaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "http-equiv"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set httpEquiv(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set httpEquiv' called on an object that is not a valid instance of HTMLMetaElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'httpEquiv' property on 'HTMLMetaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "http-equiv", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get content() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get content' called on an object that is not a valid instance of HTMLMetaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "content"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set content(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set content' called on an object that is not a valid instance of HTMLMetaElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'content' property on 'HTMLMetaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "content", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get scheme() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get scheme' called on an object that is not a valid instance of HTMLMetaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "scheme"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set scheme(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set scheme' called on an object that is not a valid instance of HTMLMetaElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'scheme' property on 'HTMLMetaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "scheme", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLMetaElement.prototype, { + name: { enumerable: true }, + httpEquiv: { enumerable: true }, + content: { enumerable: true }, + scheme: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLMetaElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLMetaElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLMetaElement + }); +}; + +const Impl = require("../nodes/HTMLMetaElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLMeterElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLMeterElement.js new file mode 100644 index 000000000..b55dc2f5c --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLMeterElement.js @@ -0,0 +1,338 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLMeterElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLMeterElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLMeterElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLMeterElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLMeterElement before HTMLElement"); + } + class HTMLMeterElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get value() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get value' called on an object that is not a valid instance of HTMLMeterElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["value"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set value(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set value' called on an object that is not a valid instance of HTMLMeterElement."); + } + + V = conversions["double"](V, { + context: "Failed to set the 'value' property on 'HTMLMeterElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["value"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get min() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get min' called on an object that is not a valid instance of HTMLMeterElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["min"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set min(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set min' called on an object that is not a valid instance of HTMLMeterElement."); + } + + V = conversions["double"](V, { + context: "Failed to set the 'min' property on 'HTMLMeterElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["min"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get max() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get max' called on an object that is not a valid instance of HTMLMeterElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["max"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set max(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set max' called on an object that is not a valid instance of HTMLMeterElement."); + } + + V = conversions["double"](V, { + context: "Failed to set the 'max' property on 'HTMLMeterElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["max"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get low() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get low' called on an object that is not a valid instance of HTMLMeterElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["low"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set low(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set low' called on an object that is not a valid instance of HTMLMeterElement."); + } + + V = conversions["double"](V, { + context: "Failed to set the 'low' property on 'HTMLMeterElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["low"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get high() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get high' called on an object that is not a valid instance of HTMLMeterElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["high"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set high(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set high' called on an object that is not a valid instance of HTMLMeterElement."); + } + + V = conversions["double"](V, { + context: "Failed to set the 'high' property on 'HTMLMeterElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["high"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get optimum() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get optimum' called on an object that is not a valid instance of HTMLMeterElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["optimum"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set optimum(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set optimum' called on an object that is not a valid instance of HTMLMeterElement."); + } + + V = conversions["double"](V, { + context: "Failed to set the 'optimum' property on 'HTMLMeterElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["optimum"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get labels() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get labels' called on an object that is not a valid instance of HTMLMeterElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["labels"]); + } + } + Object.defineProperties(HTMLMeterElement.prototype, { + value: { enumerable: true }, + min: { enumerable: true }, + max: { enumerable: true }, + low: { enumerable: true }, + high: { enumerable: true }, + optimum: { enumerable: true }, + labels: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLMeterElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLMeterElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLMeterElement + }); +}; + +const Impl = require("../nodes/HTMLMeterElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLModElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLModElement.js new file mode 100644 index 000000000..3249397b8 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLModElement.js @@ -0,0 +1,202 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const parseURLToResultingURLRecord_helpers_document_base_url = + require("../helpers/document-base-url.js").parseURLToResultingURLRecord; +const serializeURLwhatwg_url = require("whatwg-url").serializeURL; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLModElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLModElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLModElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLModElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLModElement before HTMLElement"); + } + class HTMLModElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get cite() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get cite' called on an object that is not a valid instance of HTMLModElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "cite"); + if (value === null) { + return ""; + } + const urlRecord = parseURLToResultingURLRecord_helpers_document_base_url( + value, + esValue[implSymbol]._ownerDocument + ); + if (urlRecord !== null) { + return serializeURLwhatwg_url(urlRecord); + } + return conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set cite(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set cite' called on an object that is not a valid instance of HTMLModElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'cite' property on 'HTMLModElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "cite", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get dateTime() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get dateTime' called on an object that is not a valid instance of HTMLModElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "datetime"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set dateTime(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set dateTime' called on an object that is not a valid instance of HTMLModElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'dateTime' property on 'HTMLModElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "datetime", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLModElement.prototype, { + cite: { enumerable: true }, + dateTime: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLModElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLModElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLModElement + }); +}; + +const Impl = require("../nodes/HTMLModElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLOListElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLOListElement.js new file mode 100644 index 000000000..3d4e9f10e --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLOListElement.js @@ -0,0 +1,266 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLOListElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLOListElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLOListElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLOListElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLOListElement before HTMLElement"); + } + class HTMLOListElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get reversed() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get reversed' called on an object that is not a valid instance of HTMLOListElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "reversed"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set reversed(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set reversed' called on an object that is not a valid instance of HTMLOListElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'reversed' property on 'HTMLOListElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "reversed", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "reversed"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get start() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get start' called on an object that is not a valid instance of HTMLOListElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["start"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set start(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set start' called on an object that is not a valid instance of HTMLOListElement."); + } + + V = conversions["long"](V, { + context: "Failed to set the 'start' property on 'HTMLOListElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["start"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of HTMLOListElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "type"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set type(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set type' called on an object that is not a valid instance of HTMLOListElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'type' property on 'HTMLOListElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "type", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get compact() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get compact' called on an object that is not a valid instance of HTMLOListElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "compact"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set compact(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set compact' called on an object that is not a valid instance of HTMLOListElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'compact' property on 'HTMLOListElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "compact", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "compact"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLOListElement.prototype, { + reversed: { enumerable: true }, + start: { enumerable: true }, + type: { enumerable: true }, + compact: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLOListElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLOListElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLOListElement + }); +}; + +const Impl = require("../nodes/HTMLOListElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLObjectElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLObjectElement.js new file mode 100644 index 000000000..03b901efe --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLObjectElement.js @@ -0,0 +1,839 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const parseURLToResultingURLRecord_helpers_document_base_url = + require("../helpers/document-base-url.js").parseURLToResultingURLRecord; +const serializeURLwhatwg_url = require("whatwg-url").serializeURL; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const parseNonNegativeInteger_helpers_strings = require("../helpers/strings.js").parseNonNegativeInteger; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLObjectElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLObjectElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLObjectElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLObjectElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLObjectElement before HTMLElement"); + } + class HTMLObjectElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + checkValidity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'checkValidity' called on an object that is not a valid instance of HTMLObjectElement."); + } + + return esValue[implSymbol].checkValidity(); + } + + reportValidity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'reportValidity' called on an object that is not a valid instance of HTMLObjectElement."); + } + + return esValue[implSymbol].reportValidity(); + } + + setCustomValidity(error) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError( + "'setCustomValidity' called on an object that is not a valid instance of HTMLObjectElement." + ); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'setCustomValidity' on 'HTMLObjectElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setCustomValidity' on 'HTMLObjectElement': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].setCustomValidity(...args); + } + + get data() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get data' called on an object that is not a valid instance of HTMLObjectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "data"); + if (value === null) { + return ""; + } + const urlRecord = parseURLToResultingURLRecord_helpers_document_base_url( + value, + esValue[implSymbol]._ownerDocument + ); + if (urlRecord !== null) { + return serializeURLwhatwg_url(urlRecord); + } + return conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set data(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set data' called on an object that is not a valid instance of HTMLObjectElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'data' property on 'HTMLObjectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "data", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of HTMLObjectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "type"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set type(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set type' called on an object that is not a valid instance of HTMLObjectElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'type' property on 'HTMLObjectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "type", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of HTMLObjectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "name"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set name(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set name' called on an object that is not a valid instance of HTMLObjectElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'name' property on 'HTMLObjectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "name", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get useMap() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get useMap' called on an object that is not a valid instance of HTMLObjectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "usemap"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set useMap(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set useMap' called on an object that is not a valid instance of HTMLObjectElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'useMap' property on 'HTMLObjectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "usemap", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get form() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get form' called on an object that is not a valid instance of HTMLObjectElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["form"]); + } + + get width() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get width' called on an object that is not a valid instance of HTMLObjectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "width"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set width(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set width' called on an object that is not a valid instance of HTMLObjectElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'width' property on 'HTMLObjectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "width", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get height() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get height' called on an object that is not a valid instance of HTMLObjectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "height"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set height(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set height' called on an object that is not a valid instance of HTMLObjectElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'height' property on 'HTMLObjectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "height", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get contentDocument() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get contentDocument' called on an object that is not a valid instance of HTMLObjectElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["contentDocument"]); + } + + get willValidate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get willValidate' called on an object that is not a valid instance of HTMLObjectElement." + ); + } + + return esValue[implSymbol]["willValidate"]; + } + + get validity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get validity' called on an object that is not a valid instance of HTMLObjectElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["validity"]); + } + + get validationMessage() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get validationMessage' called on an object that is not a valid instance of HTMLObjectElement." + ); + } + + return esValue[implSymbol]["validationMessage"]; + } + + get align() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get align' called on an object that is not a valid instance of HTMLObjectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "align"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set align(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set align' called on an object that is not a valid instance of HTMLObjectElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'align' property on 'HTMLObjectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "align", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get archive() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get archive' called on an object that is not a valid instance of HTMLObjectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "archive"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set archive(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set archive' called on an object that is not a valid instance of HTMLObjectElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'archive' property on 'HTMLObjectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "archive", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get code() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get code' called on an object that is not a valid instance of HTMLObjectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "code"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set code(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set code' called on an object that is not a valid instance of HTMLObjectElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'code' property on 'HTMLObjectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "code", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get declare() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get declare' called on an object that is not a valid instance of HTMLObjectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "declare"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set declare(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set declare' called on an object that is not a valid instance of HTMLObjectElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'declare' property on 'HTMLObjectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "declare", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "declare"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get hspace() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get hspace' called on an object that is not a valid instance of HTMLObjectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + let value = esValue[implSymbol].getAttributeNS(null, "hspace"); + if (value === null) { + return 0; + } + value = parseNonNegativeInteger_helpers_strings(value); + return value !== null && value >= 0 && value <= 2147483647 ? value : 0; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set hspace(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set hspace' called on an object that is not a valid instance of HTMLObjectElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'hspace' property on 'HTMLObjectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const n = V <= 2147483647 ? V : 0; + esValue[implSymbol].setAttributeNS(null, "hspace", String(n)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get standby() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get standby' called on an object that is not a valid instance of HTMLObjectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "standby"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set standby(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set standby' called on an object that is not a valid instance of HTMLObjectElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'standby' property on 'HTMLObjectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "standby", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get vspace() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get vspace' called on an object that is not a valid instance of HTMLObjectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + let value = esValue[implSymbol].getAttributeNS(null, "vspace"); + if (value === null) { + return 0; + } + value = parseNonNegativeInteger_helpers_strings(value); + return value !== null && value >= 0 && value <= 2147483647 ? value : 0; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set vspace(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set vspace' called on an object that is not a valid instance of HTMLObjectElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'vspace' property on 'HTMLObjectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const n = V <= 2147483647 ? V : 0; + esValue[implSymbol].setAttributeNS(null, "vspace", String(n)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get codeBase() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get codeBase' called on an object that is not a valid instance of HTMLObjectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "codebase"); + if (value === null) { + return ""; + } + const urlRecord = parseURLToResultingURLRecord_helpers_document_base_url( + value, + esValue[implSymbol]._ownerDocument + ); + if (urlRecord !== null) { + return serializeURLwhatwg_url(urlRecord); + } + return conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set codeBase(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set codeBase' called on an object that is not a valid instance of HTMLObjectElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'codeBase' property on 'HTMLObjectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "codebase", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get codeType() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get codeType' called on an object that is not a valid instance of HTMLObjectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "codetype"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set codeType(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set codeType' called on an object that is not a valid instance of HTMLObjectElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'codeType' property on 'HTMLObjectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "codetype", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get border() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get border' called on an object that is not a valid instance of HTMLObjectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "border"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set border(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set border' called on an object that is not a valid instance of HTMLObjectElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'border' property on 'HTMLObjectElement': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "border", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLObjectElement.prototype, { + checkValidity: { enumerable: true }, + reportValidity: { enumerable: true }, + setCustomValidity: { enumerable: true }, + data: { enumerable: true }, + type: { enumerable: true }, + name: { enumerable: true }, + useMap: { enumerable: true }, + form: { enumerable: true }, + width: { enumerable: true }, + height: { enumerable: true }, + contentDocument: { enumerable: true }, + willValidate: { enumerable: true }, + validity: { enumerable: true }, + validationMessage: { enumerable: true }, + align: { enumerable: true }, + archive: { enumerable: true }, + code: { enumerable: true }, + declare: { enumerable: true }, + hspace: { enumerable: true }, + standby: { enumerable: true }, + vspace: { enumerable: true }, + codeBase: { enumerable: true }, + codeType: { enumerable: true }, + border: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLObjectElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLObjectElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLObjectElement + }); +}; + +const Impl = require("../nodes/HTMLObjectElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLOptGroupElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLOptGroupElement.js new file mode 100644 index 000000000..be5da0e5a --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLOptGroupElement.js @@ -0,0 +1,192 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLOptGroupElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLOptGroupElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLOptGroupElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLOptGroupElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLOptGroupElement before HTMLElement"); + } + class HTMLOptGroupElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get disabled() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get disabled' called on an object that is not a valid instance of HTMLOptGroupElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "disabled"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set disabled(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set disabled' called on an object that is not a valid instance of HTMLOptGroupElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'disabled' property on 'HTMLOptGroupElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "disabled", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "disabled"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get label() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get label' called on an object that is not a valid instance of HTMLOptGroupElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "label"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set label(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set label' called on an object that is not a valid instance of HTMLOptGroupElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'label' property on 'HTMLOptGroupElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "label", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLOptGroupElement.prototype, { + disabled: { enumerable: true }, + label: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLOptGroupElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLOptGroupElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLOptGroupElement + }); +}; + +const Impl = require("../nodes/HTMLOptGroupElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLOptionElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLOptionElement.js new file mode 100644 index 000000000..f3fd0f597 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLOptionElement.js @@ -0,0 +1,351 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLOptionElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLOptionElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLOptionElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLOptionElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLOptionElement before HTMLElement"); + } + class HTMLOptionElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get disabled() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get disabled' called on an object that is not a valid instance of HTMLOptionElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "disabled"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set disabled(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set disabled' called on an object that is not a valid instance of HTMLOptionElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'disabled' property on 'HTMLOptionElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "disabled", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "disabled"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get form() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get form' called on an object that is not a valid instance of HTMLOptionElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["form"]); + } + + get label() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get label' called on an object that is not a valid instance of HTMLOptionElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["label"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set label(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set label' called on an object that is not a valid instance of HTMLOptionElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'label' property on 'HTMLOptionElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["label"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get defaultSelected() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get defaultSelected' called on an object that is not a valid instance of HTMLOptionElement." + ); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "selected"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set defaultSelected(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set defaultSelected' called on an object that is not a valid instance of HTMLOptionElement." + ); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'defaultSelected' property on 'HTMLOptionElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "selected", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "selected"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get selected() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get selected' called on an object that is not a valid instance of HTMLOptionElement."); + } + + return esValue[implSymbol]["selected"]; + } + + set selected(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set selected' called on an object that is not a valid instance of HTMLOptionElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'selected' property on 'HTMLOptionElement': The provided value" + }); + + esValue[implSymbol]["selected"] = V; + } + + get value() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get value' called on an object that is not a valid instance of HTMLOptionElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["value"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set value(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set value' called on an object that is not a valid instance of HTMLOptionElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'value' property on 'HTMLOptionElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["value"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get text() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get text' called on an object that is not a valid instance of HTMLOptionElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["text"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set text(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set text' called on an object that is not a valid instance of HTMLOptionElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'text' property on 'HTMLOptionElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["text"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get index() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get index' called on an object that is not a valid instance of HTMLOptionElement."); + } + + return esValue[implSymbol]["index"]; + } + } + Object.defineProperties(HTMLOptionElement.prototype, { + disabled: { enumerable: true }, + form: { enumerable: true }, + label: { enumerable: true }, + defaultSelected: { enumerable: true }, + selected: { enumerable: true }, + value: { enumerable: true }, + text: { enumerable: true }, + index: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLOptionElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLOptionElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLOptionElement + }); +}; + +const Impl = require("../nodes/HTMLOptionElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLOptionsCollection.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLOptionsCollection.js new file mode 100644 index 000000000..f4d2ce605 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLOptionsCollection.js @@ -0,0 +1,533 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLOptionElement = require("./HTMLOptionElement.js"); +const HTMLOptGroupElement = require("./HTMLOptGroupElement.js"); +const HTMLElement = require("./HTMLElement.js"); +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLCollection = require("./HTMLCollection.js"); + +const interfaceName = "HTMLOptionsCollection"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLOptionsCollection'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLOptionsCollection"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLOptionsCollection is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +function makeProxy(wrapper, globalObject) { + let proxyHandler = proxyHandlerCache.get(globalObject); + if (proxyHandler === undefined) { + proxyHandler = new ProxyHandler(globalObject); + proxyHandlerCache.set(globalObject, proxyHandler); + } + return new Proxy(wrapper, proxyHandler); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLCollection._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper = makeProxy(wrapper, globalObject); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + let wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper = makeProxy(wrapper, globalObject); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLCollection === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLOptionsCollection before HTMLCollection"); + } + class HTMLOptionsCollection extends globalObject.HTMLCollection { + constructor() { + throw new TypeError("Illegal constructor"); + } + + add(element) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'add' called on an object that is not a valid instance of HTMLOptionsCollection."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'add' on 'HTMLOptionsCollection': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (HTMLOptionElement.is(curArg) || HTMLOptGroupElement.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + throw new TypeError( + "Failed to execute 'add' on 'HTMLOptionsCollection': parameter 1" + " is not of any supported type." + ); + } + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + if (HTMLElement.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else if (typeof curArg === "number") { + curArg = conversions["long"](curArg, { + context: "Failed to execute 'add' on 'HTMLOptionsCollection': parameter 2" + }); + } else { + curArg = conversions["long"](curArg, { + context: "Failed to execute 'add' on 'HTMLOptionsCollection': parameter 2" + }); + } + } + } else { + curArg = null; + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].add(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + remove(index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'remove' called on an object that is not a valid instance of HTMLOptionsCollection."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'remove' on 'HTMLOptionsCollection': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["long"](curArg, { + context: "Failed to execute 'remove' on 'HTMLOptionsCollection': parameter 1" + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].remove(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get length() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get length' called on an object that is not a valid instance of HTMLOptionsCollection."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["length"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set length(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set length' called on an object that is not a valid instance of HTMLOptionsCollection."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'length' property on 'HTMLOptionsCollection': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["length"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get selectedIndex() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get selectedIndex' called on an object that is not a valid instance of HTMLOptionsCollection." + ); + } + + return esValue[implSymbol]["selectedIndex"]; + } + + set selectedIndex(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set selectedIndex' called on an object that is not a valid instance of HTMLOptionsCollection." + ); + } + + V = conversions["long"](V, { + context: "Failed to set the 'selectedIndex' property on 'HTMLOptionsCollection': The provided value" + }); + + esValue[implSymbol]["selectedIndex"] = V; + } + } + Object.defineProperties(HTMLOptionsCollection.prototype, { + add: { enumerable: true }, + remove: { enumerable: true }, + length: { enumerable: true }, + selectedIndex: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLOptionsCollection", configurable: true }, + [Symbol.iterator]: { value: Array.prototype[Symbol.iterator], configurable: true, writable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLOptionsCollection; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLOptionsCollection + }); +}; + +const proxyHandlerCache = new WeakMap(); +class ProxyHandler { + constructor(globalObject) { + this._globalObject = globalObject; + } + + get(target, P, receiver) { + if (typeof P === "symbol") { + return Reflect.get(target, P, receiver); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc === undefined) { + const parent = Object.getPrototypeOf(target); + if (parent === null) { + return undefined; + } + return Reflect.get(target, P, receiver); + } + if (!desc.get && !desc.set) { + return desc.value; + } + const getter = desc.get; + if (getter === undefined) { + return undefined; + } + return Reflect.apply(getter, receiver, []); + } + + has(target, P) { + if (typeof P === "symbol") { + return Reflect.has(target, P); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc !== undefined) { + return true; + } + const parent = Object.getPrototypeOf(target); + if (parent !== null) { + return Reflect.has(parent, P); + } + return false; + } + + ownKeys(target) { + const keys = new Set(); + + for (const key of target[implSymbol][utils.supportedPropertyIndices]) { + keys.add(`${key}`); + } + + for (const key of target[implSymbol][utils.supportedPropertyNames]) { + if (!(key in target)) { + keys.add(`${key}`); + } + } + + for (const key of Reflect.ownKeys(target)) { + keys.add(key); + } + return [...keys]; + } + + getOwnPropertyDescriptor(target, P) { + if (typeof P === "symbol") { + return Reflect.getOwnPropertyDescriptor(target, P); + } + let ignoreNamedProps = false; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + return { + writable: true, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + ignoreNamedProps = true; + } + + const namedValue = target[implSymbol].namedItem(P); + + if (namedValue !== null && !(P in target) && !ignoreNamedProps) { + return { + writable: false, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(namedValue) + }; + } + + return Reflect.getOwnPropertyDescriptor(target, P); + } + + set(target, P, V, receiver) { + if (typeof P === "symbol") { + return Reflect.set(target, P, V, receiver); + } + // The `receiver` argument refers to the Proxy exotic object or an object + // that inherits from it, whereas `target` refers to the Proxy target: + if (target[implSymbol][utils.wrapperSymbol] === receiver) { + const globalObject = this._globalObject; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + let indexedValue = V; + + if (indexedValue === null || indexedValue === undefined) { + indexedValue = null; + } else { + indexedValue = HTMLOptionElement.convert(indexedValue, { + context: "Failed to set the " + index + " property on 'HTMLOptionsCollection': The provided value" + }); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const creating = !(target[implSymbol].item(index) !== null); + if (creating) { + target[implSymbol][utils.indexedSetNew](index, indexedValue); + } else { + target[implSymbol][utils.indexedSetExisting](index, indexedValue); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + + return true; + } + } + let ownDesc; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + ownDesc = { + writable: true, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + } + + if (ownDesc === undefined) { + ownDesc = Reflect.getOwnPropertyDescriptor(target, P); + } + if (ownDesc === undefined) { + const parent = Reflect.getPrototypeOf(target); + if (parent !== null) { + return Reflect.set(parent, P, V, receiver); + } + ownDesc = { writable: true, enumerable: true, configurable: true, value: undefined }; + } + if (!ownDesc.writable) { + return false; + } + if (!utils.isObject(receiver)) { + return false; + } + const existingDesc = Reflect.getOwnPropertyDescriptor(receiver, P); + let valueDesc; + if (existingDesc !== undefined) { + if (existingDesc.get || existingDesc.set) { + return false; + } + if (!existingDesc.writable) { + return false; + } + valueDesc = { value: V }; + } else { + valueDesc = { writable: true, enumerable: true, configurable: true, value: V }; + } + return Reflect.defineProperty(receiver, P, valueDesc); + } + + defineProperty(target, P, desc) { + if (typeof P === "symbol") { + return Reflect.defineProperty(target, P, desc); + } + + const globalObject = this._globalObject; + + if (utils.isArrayIndexPropName(P)) { + if (desc.get || desc.set) { + return false; + } + + const index = P >>> 0; + let indexedValue = desc.value; + + if (indexedValue === null || indexedValue === undefined) { + indexedValue = null; + } else { + indexedValue = HTMLOptionElement.convert(indexedValue, { + context: "Failed to set the " + index + " property on 'HTMLOptionsCollection': The provided value" + }); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const creating = !(target[implSymbol].item(index) !== null); + if (creating) { + target[implSymbol][utils.indexedSetNew](index, indexedValue); + } else { + target[implSymbol][utils.indexedSetExisting](index, indexedValue); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + + return true; + } + if (!utils.hasOwn(target, P)) { + const creating = !(target[implSymbol].namedItem(P) !== null); + if (!creating) { + return false; + } + } + return Reflect.defineProperty(target, P, desc); + } + + deleteProperty(target, P) { + if (typeof P === "symbol") { + return Reflect.deleteProperty(target, P); + } + + const globalObject = this._globalObject; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + return !(target[implSymbol].item(index) !== null); + } + + if (target[implSymbol].namedItem(P) !== null && !(P in target)) { + return false; + } + + return Reflect.deleteProperty(target, P); + } + + preventExtensions() { + return false; + } +} + +const Impl = require("../nodes/HTMLOptionsCollection-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLOutputElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLOutputElement.js new file mode 100644 index 000000000..b29f28e3c --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLOutputElement.js @@ -0,0 +1,371 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLOutputElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLOutputElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLOutputElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLOutputElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLOutputElement before HTMLElement"); + } + class HTMLOutputElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + checkValidity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'checkValidity' called on an object that is not a valid instance of HTMLOutputElement."); + } + + return esValue[implSymbol].checkValidity(); + } + + reportValidity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'reportValidity' called on an object that is not a valid instance of HTMLOutputElement."); + } + + return esValue[implSymbol].reportValidity(); + } + + setCustomValidity(error) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError( + "'setCustomValidity' called on an object that is not a valid instance of HTMLOutputElement." + ); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'setCustomValidity' on 'HTMLOutputElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setCustomValidity' on 'HTMLOutputElement': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].setCustomValidity(...args); + } + + get htmlFor() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get htmlFor' called on an object that is not a valid instance of HTMLOutputElement."); + } + + return utils.getSameObject(this, "htmlFor", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["htmlFor"]); + }); + } + + set htmlFor(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set htmlFor' called on an object that is not a valid instance of HTMLOutputElement."); + } + + const Q = esValue["htmlFor"]; + if (!utils.isObject(Q)) { + throw new TypeError("Property 'htmlFor' is not an object"); + } + Reflect.set(Q, "value", V); + } + + get form() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get form' called on an object that is not a valid instance of HTMLOutputElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["form"]); + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of HTMLOutputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "name"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set name(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set name' called on an object that is not a valid instance of HTMLOutputElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'name' property on 'HTMLOutputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "name", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of HTMLOutputElement."); + } + + return esValue[implSymbol]["type"]; + } + + get defaultValue() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get defaultValue' called on an object that is not a valid instance of HTMLOutputElement." + ); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["defaultValue"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set defaultValue(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set defaultValue' called on an object that is not a valid instance of HTMLOutputElement." + ); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'defaultValue' property on 'HTMLOutputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["defaultValue"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get value() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get value' called on an object that is not a valid instance of HTMLOutputElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["value"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set value(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set value' called on an object that is not a valid instance of HTMLOutputElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'value' property on 'HTMLOutputElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["value"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get willValidate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get willValidate' called on an object that is not a valid instance of HTMLOutputElement." + ); + } + + return esValue[implSymbol]["willValidate"]; + } + + get validity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get validity' called on an object that is not a valid instance of HTMLOutputElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["validity"]); + } + + get validationMessage() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get validationMessage' called on an object that is not a valid instance of HTMLOutputElement." + ); + } + + return esValue[implSymbol]["validationMessage"]; + } + + get labels() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get labels' called on an object that is not a valid instance of HTMLOutputElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["labels"]); + } + } + Object.defineProperties(HTMLOutputElement.prototype, { + checkValidity: { enumerable: true }, + reportValidity: { enumerable: true }, + setCustomValidity: { enumerable: true }, + htmlFor: { enumerable: true }, + form: { enumerable: true }, + name: { enumerable: true }, + type: { enumerable: true }, + defaultValue: { enumerable: true }, + value: { enumerable: true }, + willValidate: { enumerable: true }, + validity: { enumerable: true }, + validationMessage: { enumerable: true }, + labels: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLOutputElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLOutputElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLOutputElement + }); +}; + +const Impl = require("../nodes/HTMLOutputElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLParagraphElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLParagraphElement.js new file mode 100644 index 000000000..8f733cc34 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLParagraphElement.js @@ -0,0 +1,153 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLParagraphElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLParagraphElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLParagraphElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLParagraphElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLParagraphElement before HTMLElement"); + } + class HTMLParagraphElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get align() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get align' called on an object that is not a valid instance of HTMLParagraphElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "align"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set align(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set align' called on an object that is not a valid instance of HTMLParagraphElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'align' property on 'HTMLParagraphElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "align", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLParagraphElement.prototype, { + align: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLParagraphElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLParagraphElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLParagraphElement + }); +}; + +const Impl = require("../nodes/HTMLParagraphElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLParamElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLParamElement.js new file mode 100644 index 000000000..363554deb --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLParamElement.js @@ -0,0 +1,261 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLParamElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLParamElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLParamElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLParamElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLParamElement before HTMLElement"); + } + class HTMLParamElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of HTMLParamElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "name"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set name(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set name' called on an object that is not a valid instance of HTMLParamElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'name' property on 'HTMLParamElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "name", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get value() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get value' called on an object that is not a valid instance of HTMLParamElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "value"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set value(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set value' called on an object that is not a valid instance of HTMLParamElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'value' property on 'HTMLParamElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "value", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of HTMLParamElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "type"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set type(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set type' called on an object that is not a valid instance of HTMLParamElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'type' property on 'HTMLParamElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "type", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get valueType() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get valueType' called on an object that is not a valid instance of HTMLParamElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "valuetype"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set valueType(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set valueType' called on an object that is not a valid instance of HTMLParamElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'valueType' property on 'HTMLParamElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "valuetype", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLParamElement.prototype, { + name: { enumerable: true }, + value: { enumerable: true }, + type: { enumerable: true }, + valueType: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLParamElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLParamElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLParamElement + }); +}; + +const Impl = require("../nodes/HTMLParamElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLPictureElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLPictureElement.js new file mode 100644 index 000000000..9834a44a8 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLPictureElement.js @@ -0,0 +1,115 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLPictureElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLPictureElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLPictureElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLPictureElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLPictureElement before HTMLElement"); + } + class HTMLPictureElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + } + Object.defineProperties(HTMLPictureElement.prototype, { + [Symbol.toStringTag]: { value: "HTMLPictureElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLPictureElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLPictureElement + }); +}; + +const Impl = require("../nodes/HTMLPictureElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLPreElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLPreElement.js new file mode 100644 index 000000000..1714d267f --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLPreElement.js @@ -0,0 +1,158 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const parseInteger_helpers_strings = require("../helpers/strings.js").parseInteger; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLPreElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLPreElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLPreElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLPreElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLPreElement before HTMLElement"); + } + class HTMLPreElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get width() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get width' called on an object that is not a valid instance of HTMLPreElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + let value = esValue[implSymbol].getAttributeNS(null, "width"); + if (value === null) { + return 0; + } + value = parseInteger_helpers_strings(value); + return value !== null && conversions.long(value) === value ? value : 0; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set width(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set width' called on an object that is not a valid instance of HTMLPreElement."); + } + + V = conversions["long"](V, { + context: "Failed to set the 'width' property on 'HTMLPreElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "width", String(V)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLPreElement.prototype, { + width: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLPreElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLPreElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLPreElement + }); +}; + +const Impl = require("../nodes/HTMLPreElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLProgressElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLProgressElement.js new file mode 100644 index 000000000..5a037f138 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLProgressElement.js @@ -0,0 +1,209 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLProgressElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLProgressElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLProgressElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLProgressElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLProgressElement before HTMLElement"); + } + class HTMLProgressElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get value() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get value' called on an object that is not a valid instance of HTMLProgressElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["value"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set value(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set value' called on an object that is not a valid instance of HTMLProgressElement."); + } + + V = conversions["double"](V, { + context: "Failed to set the 'value' property on 'HTMLProgressElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["value"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get max() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get max' called on an object that is not a valid instance of HTMLProgressElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["max"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set max(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set max' called on an object that is not a valid instance of HTMLProgressElement."); + } + + V = conversions["double"](V, { + context: "Failed to set the 'max' property on 'HTMLProgressElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["max"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get position() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get position' called on an object that is not a valid instance of HTMLProgressElement."); + } + + return esValue[implSymbol]["position"]; + } + + get labels() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get labels' called on an object that is not a valid instance of HTMLProgressElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["labels"]); + } + } + Object.defineProperties(HTMLProgressElement.prototype, { + value: { enumerable: true }, + max: { enumerable: true }, + position: { enumerable: true }, + labels: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLProgressElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLProgressElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLProgressElement + }); +}; + +const Impl = require("../nodes/HTMLProgressElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLQuoteElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLQuoteElement.js new file mode 100644 index 000000000..e750046f2 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLQuoteElement.js @@ -0,0 +1,166 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const parseURLToResultingURLRecord_helpers_document_base_url = + require("../helpers/document-base-url.js").parseURLToResultingURLRecord; +const serializeURLwhatwg_url = require("whatwg-url").serializeURL; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLQuoteElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLQuoteElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLQuoteElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLQuoteElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLQuoteElement before HTMLElement"); + } + class HTMLQuoteElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get cite() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get cite' called on an object that is not a valid instance of HTMLQuoteElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "cite"); + if (value === null) { + return ""; + } + const urlRecord = parseURLToResultingURLRecord_helpers_document_base_url( + value, + esValue[implSymbol]._ownerDocument + ); + if (urlRecord !== null) { + return serializeURLwhatwg_url(urlRecord); + } + return conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set cite(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set cite' called on an object that is not a valid instance of HTMLQuoteElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'cite' property on 'HTMLQuoteElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "cite", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLQuoteElement.prototype, { + cite: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLQuoteElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLQuoteElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLQuoteElement + }); +}; + +const Impl = require("../nodes/HTMLQuoteElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLScriptElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLScriptElement.js new file mode 100644 index 000000000..bf4281dcc --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLScriptElement.js @@ -0,0 +1,424 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const parseURLToResultingURLRecord_helpers_document_base_url = + require("../helpers/document-base-url.js").parseURLToResultingURLRecord; +const serializeURLwhatwg_url = require("whatwg-url").serializeURL; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLScriptElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLScriptElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLScriptElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLScriptElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLScriptElement before HTMLElement"); + } + class HTMLScriptElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get src() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get src' called on an object that is not a valid instance of HTMLScriptElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "src"); + if (value === null) { + return ""; + } + const urlRecord = parseURLToResultingURLRecord_helpers_document_base_url( + value, + esValue[implSymbol]._ownerDocument + ); + if (urlRecord !== null) { + return serializeURLwhatwg_url(urlRecord); + } + return conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set src(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set src' called on an object that is not a valid instance of HTMLScriptElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'src' property on 'HTMLScriptElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "src", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of HTMLScriptElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "type"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set type(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set type' called on an object that is not a valid instance of HTMLScriptElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'type' property on 'HTMLScriptElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "type", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get defer() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get defer' called on an object that is not a valid instance of HTMLScriptElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "defer"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set defer(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set defer' called on an object that is not a valid instance of HTMLScriptElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'defer' property on 'HTMLScriptElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "defer", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "defer"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get crossOrigin() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get crossOrigin' called on an object that is not a valid instance of HTMLScriptElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "crossorigin"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set crossOrigin(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set crossOrigin' called on an object that is not a valid instance of HTMLScriptElement."); + } + + if (V === null || V === undefined) { + V = null; + } else { + V = conversions["DOMString"](V, { + context: "Failed to set the 'crossOrigin' property on 'HTMLScriptElement': The provided value" + }); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "crossorigin", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get text() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get text' called on an object that is not a valid instance of HTMLScriptElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["text"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set text(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set text' called on an object that is not a valid instance of HTMLScriptElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'text' property on 'HTMLScriptElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["text"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get charset() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get charset' called on an object that is not a valid instance of HTMLScriptElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "charset"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set charset(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set charset' called on an object that is not a valid instance of HTMLScriptElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'charset' property on 'HTMLScriptElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "charset", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get event() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get event' called on an object that is not a valid instance of HTMLScriptElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "event"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set event(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set event' called on an object that is not a valid instance of HTMLScriptElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'event' property on 'HTMLScriptElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "event", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get htmlFor() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get htmlFor' called on an object that is not a valid instance of HTMLScriptElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "for"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set htmlFor(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set htmlFor' called on an object that is not a valid instance of HTMLScriptElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'htmlFor' property on 'HTMLScriptElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "for", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLScriptElement.prototype, { + src: { enumerable: true }, + type: { enumerable: true }, + defer: { enumerable: true }, + crossOrigin: { enumerable: true }, + text: { enumerable: true }, + charset: { enumerable: true }, + event: { enumerable: true }, + htmlFor: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLScriptElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLScriptElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLScriptElement + }); +}; + +const Impl = require("../nodes/HTMLScriptElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLSelectElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLSelectElement.js new file mode 100644 index 000000000..1e5e2cf35 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLSelectElement.js @@ -0,0 +1,957 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const HTMLOptionElement = require("./HTMLOptionElement.js"); +const HTMLOptGroupElement = require("./HTMLOptGroupElement.js"); +const HTMLElement = require("./HTMLElement.js"); +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const parseNonNegativeInteger_helpers_strings = require("../helpers/strings.js").parseNonNegativeInteger; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "HTMLSelectElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLSelectElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLSelectElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLSelectElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +function makeProxy(wrapper, globalObject) { + let proxyHandler = proxyHandlerCache.get(globalObject); + if (proxyHandler === undefined) { + proxyHandler = new ProxyHandler(globalObject); + proxyHandlerCache.set(globalObject, proxyHandler); + } + return new Proxy(wrapper, proxyHandler); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper = makeProxy(wrapper, globalObject); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + let wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper = makeProxy(wrapper, globalObject); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLSelectElement before HTMLElement"); + } + class HTMLSelectElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + item(index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'item' called on an object that is not a valid instance of HTMLSelectElement."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'item' on 'HTMLSelectElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'item' on 'HTMLSelectElement': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].item(...args)); + } + + namedItem(name) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'namedItem' called on an object that is not a valid instance of HTMLSelectElement."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'namedItem' on 'HTMLSelectElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'namedItem' on 'HTMLSelectElement': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].namedItem(...args)); + } + + add(element) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'add' called on an object that is not a valid instance of HTMLSelectElement."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'add' on 'HTMLSelectElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (HTMLOptionElement.is(curArg) || HTMLOptGroupElement.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else { + throw new TypeError( + "Failed to execute 'add' on 'HTMLSelectElement': parameter 1" + " is not of any supported type." + ); + } + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + if (HTMLElement.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else if (typeof curArg === "number") { + curArg = conversions["long"](curArg, { + context: "Failed to execute 'add' on 'HTMLSelectElement': parameter 2" + }); + } else { + curArg = conversions["long"](curArg, { + context: "Failed to execute 'add' on 'HTMLSelectElement': parameter 2" + }); + } + } + } else { + curArg = null; + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].add(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + remove() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'remove' called on an object that is not a valid instance of HTMLSelectElement."); + } + const args = []; + switch (arguments.length) { + case 0: + break; + default: { + let curArg = arguments[0]; + curArg = conversions["long"](curArg, { + context: "Failed to execute 'remove' on 'HTMLSelectElement': parameter 1" + }); + args.push(curArg); + } + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].remove(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + checkValidity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'checkValidity' called on an object that is not a valid instance of HTMLSelectElement."); + } + + return esValue[implSymbol].checkValidity(); + } + + reportValidity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'reportValidity' called on an object that is not a valid instance of HTMLSelectElement."); + } + + return esValue[implSymbol].reportValidity(); + } + + setCustomValidity(error) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError( + "'setCustomValidity' called on an object that is not a valid instance of HTMLSelectElement." + ); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'setCustomValidity' on 'HTMLSelectElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setCustomValidity' on 'HTMLSelectElement': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].setCustomValidity(...args); + } + + get autofocus() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get autofocus' called on an object that is not a valid instance of HTMLSelectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "autofocus"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set autofocus(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set autofocus' called on an object that is not a valid instance of HTMLSelectElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'autofocus' property on 'HTMLSelectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "autofocus", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "autofocus"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get disabled() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get disabled' called on an object that is not a valid instance of HTMLSelectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "disabled"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set disabled(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set disabled' called on an object that is not a valid instance of HTMLSelectElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'disabled' property on 'HTMLSelectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "disabled", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "disabled"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get form() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get form' called on an object that is not a valid instance of HTMLSelectElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["form"]); + } + + get multiple() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get multiple' called on an object that is not a valid instance of HTMLSelectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "multiple"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set multiple(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set multiple' called on an object that is not a valid instance of HTMLSelectElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'multiple' property on 'HTMLSelectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "multiple", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "multiple"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of HTMLSelectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "name"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set name(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set name' called on an object that is not a valid instance of HTMLSelectElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'name' property on 'HTMLSelectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "name", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get required() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get required' called on an object that is not a valid instance of HTMLSelectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "required"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set required(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set required' called on an object that is not a valid instance of HTMLSelectElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'required' property on 'HTMLSelectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "required", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "required"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get size() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get size' called on an object that is not a valid instance of HTMLSelectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + let value = esValue[implSymbol].getAttributeNS(null, "size"); + if (value === null) { + return 0; + } + value = parseNonNegativeInteger_helpers_strings(value); + return value !== null && value >= 0 && value <= 2147483647 ? value : 0; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set size(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set size' called on an object that is not a valid instance of HTMLSelectElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'size' property on 'HTMLSelectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const n = V <= 2147483647 ? V : 0; + esValue[implSymbol].setAttributeNS(null, "size", String(n)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of HTMLSelectElement."); + } + + return esValue[implSymbol]["type"]; + } + + get options() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get options' called on an object that is not a valid instance of HTMLSelectElement."); + } + + return utils.getSameObject(this, "options", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["options"]); + }); + } + + get length() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get length' called on an object that is not a valid instance of HTMLSelectElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["length"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set length(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set length' called on an object that is not a valid instance of HTMLSelectElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'length' property on 'HTMLSelectElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["length"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get selectedOptions() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get selectedOptions' called on an object that is not a valid instance of HTMLSelectElement." + ); + } + + return utils.getSameObject(this, "selectedOptions", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["selectedOptions"]); + }); + } + + get selectedIndex() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get selectedIndex' called on an object that is not a valid instance of HTMLSelectElement." + ); + } + + return esValue[implSymbol]["selectedIndex"]; + } + + set selectedIndex(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set selectedIndex' called on an object that is not a valid instance of HTMLSelectElement." + ); + } + + V = conversions["long"](V, { + context: "Failed to set the 'selectedIndex' property on 'HTMLSelectElement': The provided value" + }); + + esValue[implSymbol]["selectedIndex"] = V; + } + + get value() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get value' called on an object that is not a valid instance of HTMLSelectElement."); + } + + return esValue[implSymbol]["value"]; + } + + set value(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set value' called on an object that is not a valid instance of HTMLSelectElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'value' property on 'HTMLSelectElement': The provided value" + }); + + esValue[implSymbol]["value"] = V; + } + + get willValidate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get willValidate' called on an object that is not a valid instance of HTMLSelectElement." + ); + } + + return esValue[implSymbol]["willValidate"]; + } + + get validity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get validity' called on an object that is not a valid instance of HTMLSelectElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["validity"]); + } + + get validationMessage() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get validationMessage' called on an object that is not a valid instance of HTMLSelectElement." + ); + } + + return esValue[implSymbol]["validationMessage"]; + } + + get labels() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get labels' called on an object that is not a valid instance of HTMLSelectElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["labels"]); + } + } + Object.defineProperties(HTMLSelectElement.prototype, { + item: { enumerable: true }, + namedItem: { enumerable: true }, + add: { enumerable: true }, + remove: { enumerable: true }, + checkValidity: { enumerable: true }, + reportValidity: { enumerable: true }, + setCustomValidity: { enumerable: true }, + autofocus: { enumerable: true }, + disabled: { enumerable: true }, + form: { enumerable: true }, + multiple: { enumerable: true }, + name: { enumerable: true }, + required: { enumerable: true }, + size: { enumerable: true }, + type: { enumerable: true }, + options: { enumerable: true }, + length: { enumerable: true }, + selectedOptions: { enumerable: true }, + selectedIndex: { enumerable: true }, + value: { enumerable: true }, + willValidate: { enumerable: true }, + validity: { enumerable: true }, + validationMessage: { enumerable: true }, + labels: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLSelectElement", configurable: true }, + [Symbol.iterator]: { value: Array.prototype[Symbol.iterator], configurable: true, writable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLSelectElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLSelectElement + }); +}; + +const proxyHandlerCache = new WeakMap(); +class ProxyHandler { + constructor(globalObject) { + this._globalObject = globalObject; + } + + get(target, P, receiver) { + if (typeof P === "symbol") { + return Reflect.get(target, P, receiver); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc === undefined) { + const parent = Object.getPrototypeOf(target); + if (parent === null) { + return undefined; + } + return Reflect.get(target, P, receiver); + } + if (!desc.get && !desc.set) { + return desc.value; + } + const getter = desc.get; + if (getter === undefined) { + return undefined; + } + return Reflect.apply(getter, receiver, []); + } + + has(target, P) { + if (typeof P === "symbol") { + return Reflect.has(target, P); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc !== undefined) { + return true; + } + const parent = Object.getPrototypeOf(target); + if (parent !== null) { + return Reflect.has(parent, P); + } + return false; + } + + ownKeys(target) { + const keys = new Set(); + + for (const key of target[implSymbol][utils.supportedPropertyIndices]) { + keys.add(`${key}`); + } + + for (const key of Reflect.ownKeys(target)) { + keys.add(key); + } + return [...keys]; + } + + getOwnPropertyDescriptor(target, P) { + if (typeof P === "symbol") { + return Reflect.getOwnPropertyDescriptor(target, P); + } + let ignoreNamedProps = false; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + return { + writable: true, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + ignoreNamedProps = true; + } + + return Reflect.getOwnPropertyDescriptor(target, P); + } + + set(target, P, V, receiver) { + if (typeof P === "symbol") { + return Reflect.set(target, P, V, receiver); + } + // The `receiver` argument refers to the Proxy exotic object or an object + // that inherits from it, whereas `target` refers to the Proxy target: + if (target[implSymbol][utils.wrapperSymbol] === receiver) { + const globalObject = this._globalObject; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + let indexedValue = V; + + if (indexedValue === null || indexedValue === undefined) { + indexedValue = null; + } else { + indexedValue = HTMLOptionElement.convert(indexedValue, { + context: "Failed to set the " + index + " property on 'HTMLSelectElement': The provided value" + }); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const creating = !(target[implSymbol].item(index) !== null); + if (creating) { + target[implSymbol][utils.indexedSetNew](index, indexedValue); + } else { + target[implSymbol][utils.indexedSetExisting](index, indexedValue); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + + return true; + } + } + let ownDesc; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + ownDesc = { + writable: true, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + } + + if (ownDesc === undefined) { + ownDesc = Reflect.getOwnPropertyDescriptor(target, P); + } + if (ownDesc === undefined) { + const parent = Reflect.getPrototypeOf(target); + if (parent !== null) { + return Reflect.set(parent, P, V, receiver); + } + ownDesc = { writable: true, enumerable: true, configurable: true, value: undefined }; + } + if (!ownDesc.writable) { + return false; + } + if (!utils.isObject(receiver)) { + return false; + } + const existingDesc = Reflect.getOwnPropertyDescriptor(receiver, P); + let valueDesc; + if (existingDesc !== undefined) { + if (existingDesc.get || existingDesc.set) { + return false; + } + if (!existingDesc.writable) { + return false; + } + valueDesc = { value: V }; + } else { + valueDesc = { writable: true, enumerable: true, configurable: true, value: V }; + } + return Reflect.defineProperty(receiver, P, valueDesc); + } + + defineProperty(target, P, desc) { + if (typeof P === "symbol") { + return Reflect.defineProperty(target, P, desc); + } + + const globalObject = this._globalObject; + + if (utils.isArrayIndexPropName(P)) { + if (desc.get || desc.set) { + return false; + } + + const index = P >>> 0; + let indexedValue = desc.value; + + if (indexedValue === null || indexedValue === undefined) { + indexedValue = null; + } else { + indexedValue = HTMLOptionElement.convert(indexedValue, { + context: "Failed to set the " + index + " property on 'HTMLSelectElement': The provided value" + }); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const creating = !(target[implSymbol].item(index) !== null); + if (creating) { + target[implSymbol][utils.indexedSetNew](index, indexedValue); + } else { + target[implSymbol][utils.indexedSetExisting](index, indexedValue); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + + return true; + } + + return Reflect.defineProperty(target, P, desc); + } + + deleteProperty(target, P) { + if (typeof P === "symbol") { + return Reflect.deleteProperty(target, P); + } + + const globalObject = this._globalObject; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + return !(target[implSymbol].item(index) !== null); + } + + return Reflect.deleteProperty(target, P); + } + + preventExtensions() { + return false; + } +} + +const Impl = require("../nodes/HTMLSelectElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLSlotElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLSlotElement.js new file mode 100644 index 000000000..7ab40632f --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLSlotElement.js @@ -0,0 +1,188 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const AssignedNodesOptions = require("./AssignedNodesOptions.js"); +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLSlotElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLSlotElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLSlotElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLSlotElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLSlotElement before HTMLElement"); + } + class HTMLSlotElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + assignedNodes() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'assignedNodes' called on an object that is not a valid instance of HTMLSlotElement."); + } + const args = []; + { + let curArg = arguments[0]; + curArg = AssignedNodesOptions.convert(curArg, { + context: "Failed to execute 'assignedNodes' on 'HTMLSlotElement': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].assignedNodes(...args)); + } + + assignedElements() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'assignedElements' called on an object that is not a valid instance of HTMLSlotElement."); + } + const args = []; + { + let curArg = arguments[0]; + curArg = AssignedNodesOptions.convert(curArg, { + context: "Failed to execute 'assignedElements' on 'HTMLSlotElement': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].assignedElements(...args)); + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of HTMLSlotElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "name"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set name(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set name' called on an object that is not a valid instance of HTMLSlotElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'name' property on 'HTMLSlotElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "name", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLSlotElement.prototype, { + assignedNodes: { enumerable: true }, + assignedElements: { enumerable: true }, + name: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLSlotElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLSlotElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLSlotElement + }); +}; + +const Impl = require("../nodes/HTMLSlotElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLSourceElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLSourceElement.js new file mode 100644 index 000000000..c8eb0265d --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLSourceElement.js @@ -0,0 +1,310 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const parseURLToResultingURLRecord_helpers_document_base_url = + require("../helpers/document-base-url.js").parseURLToResultingURLRecord; +const serializeURLwhatwg_url = require("whatwg-url").serializeURL; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLSourceElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLSourceElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLSourceElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLSourceElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLSourceElement before HTMLElement"); + } + class HTMLSourceElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get src() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get src' called on an object that is not a valid instance of HTMLSourceElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "src"); + if (value === null) { + return ""; + } + const urlRecord = parseURLToResultingURLRecord_helpers_document_base_url( + value, + esValue[implSymbol]._ownerDocument + ); + if (urlRecord !== null) { + return serializeURLwhatwg_url(urlRecord); + } + return conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set src(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set src' called on an object that is not a valid instance of HTMLSourceElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'src' property on 'HTMLSourceElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "src", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of HTMLSourceElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "type"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set type(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set type' called on an object that is not a valid instance of HTMLSourceElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'type' property on 'HTMLSourceElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "type", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get srcset() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get srcset' called on an object that is not a valid instance of HTMLSourceElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "srcset"); + return value === null ? "" : conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set srcset(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set srcset' called on an object that is not a valid instance of HTMLSourceElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'srcset' property on 'HTMLSourceElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "srcset", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get sizes() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get sizes' called on an object that is not a valid instance of HTMLSourceElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "sizes"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set sizes(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set sizes' called on an object that is not a valid instance of HTMLSourceElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'sizes' property on 'HTMLSourceElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "sizes", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get media() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get media' called on an object that is not a valid instance of HTMLSourceElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "media"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set media(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set media' called on an object that is not a valid instance of HTMLSourceElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'media' property on 'HTMLSourceElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "media", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLSourceElement.prototype, { + src: { enumerable: true }, + type: { enumerable: true }, + srcset: { enumerable: true }, + sizes: { enumerable: true }, + media: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLSourceElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLSourceElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLSourceElement + }); +}; + +const Impl = require("../nodes/HTMLSourceElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLSpanElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLSpanElement.js new file mode 100644 index 000000000..fd8028d2e --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLSpanElement.js @@ -0,0 +1,115 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLSpanElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLSpanElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLSpanElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLSpanElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLSpanElement before HTMLElement"); + } + class HTMLSpanElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + } + Object.defineProperties(HTMLSpanElement.prototype, { + [Symbol.toStringTag]: { value: "HTMLSpanElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLSpanElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLSpanElement + }); +}; + +const Impl = require("../nodes/HTMLSpanElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLStyleElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLStyleElement.js new file mode 100644 index 000000000..10f3d94d5 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLStyleElement.js @@ -0,0 +1,200 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLStyleElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLStyleElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLStyleElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLStyleElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLStyleElement before HTMLElement"); + } + class HTMLStyleElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get media() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get media' called on an object that is not a valid instance of HTMLStyleElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "media"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set media(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set media' called on an object that is not a valid instance of HTMLStyleElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'media' property on 'HTMLStyleElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "media", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of HTMLStyleElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "type"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set type(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set type' called on an object that is not a valid instance of HTMLStyleElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'type' property on 'HTMLStyleElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "type", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get sheet() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get sheet' called on an object that is not a valid instance of HTMLStyleElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["sheet"]); + } + } + Object.defineProperties(HTMLStyleElement.prototype, { + media: { enumerable: true }, + type: { enumerable: true }, + sheet: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLStyleElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLStyleElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLStyleElement + }); +}; + +const Impl = require("../nodes/HTMLStyleElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLTableCaptionElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTableCaptionElement.js new file mode 100644 index 000000000..39adfd5f8 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTableCaptionElement.js @@ -0,0 +1,153 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLTableCaptionElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLTableCaptionElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLTableCaptionElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLTableCaptionElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLTableCaptionElement before HTMLElement"); + } + class HTMLTableCaptionElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get align() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get align' called on an object that is not a valid instance of HTMLTableCaptionElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "align"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set align(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set align' called on an object that is not a valid instance of HTMLTableCaptionElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'align' property on 'HTMLTableCaptionElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "align", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLTableCaptionElement.prototype, { + align: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLTableCaptionElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLTableCaptionElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLTableCaptionElement + }); +}; + +const Impl = require("../nodes/HTMLTableCaptionElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLTableCellElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTableCellElement.js new file mode 100644 index 000000000..64e29fc74 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTableCellElement.js @@ -0,0 +1,635 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLTableCellElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLTableCellElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLTableCellElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLTableCellElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLTableCellElement before HTMLElement"); + } + class HTMLTableCellElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get colSpan() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get colSpan' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["colSpan"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set colSpan(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set colSpan' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'colSpan' property on 'HTMLTableCellElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["colSpan"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get rowSpan() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get rowSpan' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["rowSpan"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set rowSpan(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set rowSpan' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'rowSpan' property on 'HTMLTableCellElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["rowSpan"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get headers() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get headers' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "headers"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set headers(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set headers' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'headers' property on 'HTMLTableCellElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "headers", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get cellIndex() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get cellIndex' called on an object that is not a valid instance of HTMLTableCellElement." + ); + } + + return esValue[implSymbol]["cellIndex"]; + } + + get scope() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get scope' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["scope"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set scope(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set scope' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'scope' property on 'HTMLTableCellElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["scope"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get abbr() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get abbr' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "abbr"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set abbr(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set abbr' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'abbr' property on 'HTMLTableCellElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "abbr", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get align() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get align' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "align"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set align(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set align' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'align' property on 'HTMLTableCellElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "align", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get axis() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get axis' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "axis"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set axis(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set axis' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'axis' property on 'HTMLTableCellElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "axis", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get height() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get height' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "height"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set height(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set height' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'height' property on 'HTMLTableCellElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "height", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get width() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get width' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "width"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set width(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set width' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'width' property on 'HTMLTableCellElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "width", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get ch() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ch' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "char"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set ch(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ch' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'ch' property on 'HTMLTableCellElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "char", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get chOff() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get chOff' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "charoff"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set chOff(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set chOff' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'chOff' property on 'HTMLTableCellElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "charoff", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get noWrap() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get noWrap' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "nowrap"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set noWrap(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set noWrap' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'noWrap' property on 'HTMLTableCellElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "nowrap", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "nowrap"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get vAlign() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get vAlign' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "valign"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set vAlign(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set vAlign' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'vAlign' property on 'HTMLTableCellElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "valign", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get bgColor() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get bgColor' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "bgcolor"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set bgColor(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set bgColor' called on an object that is not a valid instance of HTMLTableCellElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'bgColor' property on 'HTMLTableCellElement': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "bgcolor", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLTableCellElement.prototype, { + colSpan: { enumerable: true }, + rowSpan: { enumerable: true }, + headers: { enumerable: true }, + cellIndex: { enumerable: true }, + scope: { enumerable: true }, + abbr: { enumerable: true }, + align: { enumerable: true }, + axis: { enumerable: true }, + height: { enumerable: true }, + width: { enumerable: true }, + ch: { enumerable: true }, + chOff: { enumerable: true }, + noWrap: { enumerable: true }, + vAlign: { enumerable: true }, + bgColor: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLTableCellElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLTableCellElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLTableCellElement + }); +}; + +const Impl = require("../nodes/HTMLTableCellElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLTableColElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTableColElement.js new file mode 100644 index 000000000..9287256b4 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTableColElement.js @@ -0,0 +1,339 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const parseNonNegativeInteger_helpers_strings = require("../helpers/strings.js").parseNonNegativeInteger; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLTableColElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLTableColElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLTableColElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLTableColElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLTableColElement before HTMLElement"); + } + class HTMLTableColElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get span() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get span' called on an object that is not a valid instance of HTMLTableColElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + let value = esValue[implSymbol].getAttributeNS(null, "span"); + if (value === null) { + return 0; + } + value = parseNonNegativeInteger_helpers_strings(value); + return value !== null && value >= 0 && value <= 2147483647 ? value : 0; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set span(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set span' called on an object that is not a valid instance of HTMLTableColElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'span' property on 'HTMLTableColElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const n = V <= 2147483647 ? V : 0; + esValue[implSymbol].setAttributeNS(null, "span", String(n)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get align() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get align' called on an object that is not a valid instance of HTMLTableColElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "align"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set align(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set align' called on an object that is not a valid instance of HTMLTableColElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'align' property on 'HTMLTableColElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "align", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get ch() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ch' called on an object that is not a valid instance of HTMLTableColElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "char"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set ch(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ch' called on an object that is not a valid instance of HTMLTableColElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'ch' property on 'HTMLTableColElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "char", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get chOff() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get chOff' called on an object that is not a valid instance of HTMLTableColElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "charoff"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set chOff(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set chOff' called on an object that is not a valid instance of HTMLTableColElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'chOff' property on 'HTMLTableColElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "charoff", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get vAlign() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get vAlign' called on an object that is not a valid instance of HTMLTableColElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "valign"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set vAlign(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set vAlign' called on an object that is not a valid instance of HTMLTableColElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'vAlign' property on 'HTMLTableColElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "valign", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get width() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get width' called on an object that is not a valid instance of HTMLTableColElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "width"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set width(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set width' called on an object that is not a valid instance of HTMLTableColElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'width' property on 'HTMLTableColElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "width", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLTableColElement.prototype, { + span: { enumerable: true }, + align: { enumerable: true }, + ch: { enumerable: true }, + chOff: { enumerable: true }, + vAlign: { enumerable: true }, + width: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLTableColElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLTableColElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLTableColElement + }); +}; + +const Impl = require("../nodes/HTMLTableColElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLTableElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTableElement.js new file mode 100644 index 000000000..daaa9af27 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTableElement.js @@ -0,0 +1,725 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const HTMLTableCaptionElement = require("./HTMLTableCaptionElement.js"); +const HTMLTableSectionElement = require("./HTMLTableSectionElement.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLTableElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLTableElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLTableElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLTableElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLTableElement before HTMLElement"); + } + class HTMLTableElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + createCaption() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'createCaption' called on an object that is not a valid instance of HTMLTableElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].createCaption()); + } + + deleteCaption() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'deleteCaption' called on an object that is not a valid instance of HTMLTableElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].deleteCaption(); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + createTHead() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'createTHead' called on an object that is not a valid instance of HTMLTableElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].createTHead()); + } + + deleteTHead() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'deleteTHead' called on an object that is not a valid instance of HTMLTableElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].deleteTHead(); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + createTFoot() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'createTFoot' called on an object that is not a valid instance of HTMLTableElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].createTFoot()); + } + + deleteTFoot() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'deleteTFoot' called on an object that is not a valid instance of HTMLTableElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].deleteTFoot(); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + createTBody() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'createTBody' called on an object that is not a valid instance of HTMLTableElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].createTBody()); + } + + insertRow() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'insertRow' called on an object that is not a valid instance of HTMLTableElement."); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + curArg = conversions["long"](curArg, { + context: "Failed to execute 'insertRow' on 'HTMLTableElement': parameter 1" + }); + } else { + curArg = -1; + } + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].insertRow(...args)); + } + + deleteRow(index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'deleteRow' called on an object that is not a valid instance of HTMLTableElement."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'deleteRow' on 'HTMLTableElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["long"](curArg, { + context: "Failed to execute 'deleteRow' on 'HTMLTableElement': parameter 1" + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].deleteRow(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get caption() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get caption' called on an object that is not a valid instance of HTMLTableElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol]["caption"]); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set caption(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set caption' called on an object that is not a valid instance of HTMLTableElement."); + } + + if (V === null || V === undefined) { + V = null; + } else { + V = HTMLTableCaptionElement.convert(V, { + context: "Failed to set the 'caption' property on 'HTMLTableElement': The provided value" + }); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["caption"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get tHead() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get tHead' called on an object that is not a valid instance of HTMLTableElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol]["tHead"]); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set tHead(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set tHead' called on an object that is not a valid instance of HTMLTableElement."); + } + + if (V === null || V === undefined) { + V = null; + } else { + V = HTMLTableSectionElement.convert(V, { + context: "Failed to set the 'tHead' property on 'HTMLTableElement': The provided value" + }); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["tHead"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get tFoot() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get tFoot' called on an object that is not a valid instance of HTMLTableElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol]["tFoot"]); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set tFoot(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set tFoot' called on an object that is not a valid instance of HTMLTableElement."); + } + + if (V === null || V === undefined) { + V = null; + } else { + V = HTMLTableSectionElement.convert(V, { + context: "Failed to set the 'tFoot' property on 'HTMLTableElement': The provided value" + }); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["tFoot"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get tBodies() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get tBodies' called on an object that is not a valid instance of HTMLTableElement."); + } + + return utils.getSameObject(this, "tBodies", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["tBodies"]); + }); + } + + get rows() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get rows' called on an object that is not a valid instance of HTMLTableElement."); + } + + return utils.getSameObject(this, "rows", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["rows"]); + }); + } + + get align() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get align' called on an object that is not a valid instance of HTMLTableElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "align"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set align(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set align' called on an object that is not a valid instance of HTMLTableElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'align' property on 'HTMLTableElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "align", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get border() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get border' called on an object that is not a valid instance of HTMLTableElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "border"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set border(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set border' called on an object that is not a valid instance of HTMLTableElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'border' property on 'HTMLTableElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "border", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get frame() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get frame' called on an object that is not a valid instance of HTMLTableElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "frame"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set frame(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set frame' called on an object that is not a valid instance of HTMLTableElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'frame' property on 'HTMLTableElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "frame", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get rules() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get rules' called on an object that is not a valid instance of HTMLTableElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "rules"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set rules(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set rules' called on an object that is not a valid instance of HTMLTableElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'rules' property on 'HTMLTableElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "rules", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get summary() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get summary' called on an object that is not a valid instance of HTMLTableElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "summary"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set summary(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set summary' called on an object that is not a valid instance of HTMLTableElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'summary' property on 'HTMLTableElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "summary", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get width() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get width' called on an object that is not a valid instance of HTMLTableElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "width"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set width(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set width' called on an object that is not a valid instance of HTMLTableElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'width' property on 'HTMLTableElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "width", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get bgColor() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get bgColor' called on an object that is not a valid instance of HTMLTableElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "bgcolor"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set bgColor(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set bgColor' called on an object that is not a valid instance of HTMLTableElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'bgColor' property on 'HTMLTableElement': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "bgcolor", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get cellPadding() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get cellPadding' called on an object that is not a valid instance of HTMLTableElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "cellpadding"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set cellPadding(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set cellPadding' called on an object that is not a valid instance of HTMLTableElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'cellPadding' property on 'HTMLTableElement': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "cellpadding", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get cellSpacing() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get cellSpacing' called on an object that is not a valid instance of HTMLTableElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "cellspacing"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set cellSpacing(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set cellSpacing' called on an object that is not a valid instance of HTMLTableElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'cellSpacing' property on 'HTMLTableElement': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "cellspacing", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLTableElement.prototype, { + createCaption: { enumerable: true }, + deleteCaption: { enumerable: true }, + createTHead: { enumerable: true }, + deleteTHead: { enumerable: true }, + createTFoot: { enumerable: true }, + deleteTFoot: { enumerable: true }, + createTBody: { enumerable: true }, + insertRow: { enumerable: true }, + deleteRow: { enumerable: true }, + caption: { enumerable: true }, + tHead: { enumerable: true }, + tFoot: { enumerable: true }, + tBodies: { enumerable: true }, + rows: { enumerable: true }, + align: { enumerable: true }, + border: { enumerable: true }, + frame: { enumerable: true }, + rules: { enumerable: true }, + summary: { enumerable: true }, + width: { enumerable: true }, + bgColor: { enumerable: true }, + cellPadding: { enumerable: true }, + cellSpacing: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLTableElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLTableElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLTableElement + }); +}; + +const Impl = require("../nodes/HTMLTableElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLTableRowElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTableRowElement.js new file mode 100644 index 000000000..f835d5f54 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTableRowElement.js @@ -0,0 +1,386 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLTableRowElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLTableRowElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLTableRowElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLTableRowElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLTableRowElement before HTMLElement"); + } + class HTMLTableRowElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + insertCell() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'insertCell' called on an object that is not a valid instance of HTMLTableRowElement."); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + curArg = conversions["long"](curArg, { + context: "Failed to execute 'insertCell' on 'HTMLTableRowElement': parameter 1" + }); + } else { + curArg = -1; + } + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].insertCell(...args)); + } + + deleteCell(index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'deleteCell' called on an object that is not a valid instance of HTMLTableRowElement."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'deleteCell' on 'HTMLTableRowElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["long"](curArg, { + context: "Failed to execute 'deleteCell' on 'HTMLTableRowElement': parameter 1" + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].deleteCell(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get rowIndex() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get rowIndex' called on an object that is not a valid instance of HTMLTableRowElement."); + } + + return esValue[implSymbol]["rowIndex"]; + } + + get sectionRowIndex() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get sectionRowIndex' called on an object that is not a valid instance of HTMLTableRowElement." + ); + } + + return esValue[implSymbol]["sectionRowIndex"]; + } + + get cells() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get cells' called on an object that is not a valid instance of HTMLTableRowElement."); + } + + return utils.getSameObject(this, "cells", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["cells"]); + }); + } + + get align() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get align' called on an object that is not a valid instance of HTMLTableRowElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "align"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set align(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set align' called on an object that is not a valid instance of HTMLTableRowElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'align' property on 'HTMLTableRowElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "align", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get ch() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ch' called on an object that is not a valid instance of HTMLTableRowElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "char"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set ch(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ch' called on an object that is not a valid instance of HTMLTableRowElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'ch' property on 'HTMLTableRowElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "char", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get chOff() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get chOff' called on an object that is not a valid instance of HTMLTableRowElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "charoff"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set chOff(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set chOff' called on an object that is not a valid instance of HTMLTableRowElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'chOff' property on 'HTMLTableRowElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "charoff", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get vAlign() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get vAlign' called on an object that is not a valid instance of HTMLTableRowElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "valign"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set vAlign(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set vAlign' called on an object that is not a valid instance of HTMLTableRowElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'vAlign' property on 'HTMLTableRowElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "valign", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get bgColor() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get bgColor' called on an object that is not a valid instance of HTMLTableRowElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "bgcolor"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set bgColor(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set bgColor' called on an object that is not a valid instance of HTMLTableRowElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'bgColor' property on 'HTMLTableRowElement': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "bgcolor", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLTableRowElement.prototype, { + insertCell: { enumerable: true }, + deleteCell: { enumerable: true }, + rowIndex: { enumerable: true }, + sectionRowIndex: { enumerable: true }, + cells: { enumerable: true }, + align: { enumerable: true }, + ch: { enumerable: true }, + chOff: { enumerable: true }, + vAlign: { enumerable: true }, + bgColor: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLTableRowElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLTableRowElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLTableRowElement + }); +}; + +const Impl = require("../nodes/HTMLTableRowElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLTableSectionElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTableSectionElement.js new file mode 100644 index 000000000..297876564 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTableSectionElement.js @@ -0,0 +1,329 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLTableSectionElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLTableSectionElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLTableSectionElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLTableSectionElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLTableSectionElement before HTMLElement"); + } + class HTMLTableSectionElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + insertRow() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'insertRow' called on an object that is not a valid instance of HTMLTableSectionElement."); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + curArg = conversions["long"](curArg, { + context: "Failed to execute 'insertRow' on 'HTMLTableSectionElement': parameter 1" + }); + } else { + curArg = -1; + } + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].insertRow(...args)); + } + + deleteRow(index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'deleteRow' called on an object that is not a valid instance of HTMLTableSectionElement."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'deleteRow' on 'HTMLTableSectionElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["long"](curArg, { + context: "Failed to execute 'deleteRow' on 'HTMLTableSectionElement': parameter 1" + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].deleteRow(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get rows() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get rows' called on an object that is not a valid instance of HTMLTableSectionElement."); + } + + return utils.getSameObject(this, "rows", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["rows"]); + }); + } + + get align() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get align' called on an object that is not a valid instance of HTMLTableSectionElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "align"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set align(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set align' called on an object that is not a valid instance of HTMLTableSectionElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'align' property on 'HTMLTableSectionElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "align", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get ch() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ch' called on an object that is not a valid instance of HTMLTableSectionElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "char"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set ch(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ch' called on an object that is not a valid instance of HTMLTableSectionElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'ch' property on 'HTMLTableSectionElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "char", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get chOff() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get chOff' called on an object that is not a valid instance of HTMLTableSectionElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "charoff"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set chOff(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set chOff' called on an object that is not a valid instance of HTMLTableSectionElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'chOff' property on 'HTMLTableSectionElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "charoff", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get vAlign() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get vAlign' called on an object that is not a valid instance of HTMLTableSectionElement." + ); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "valign"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set vAlign(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set vAlign' called on an object that is not a valid instance of HTMLTableSectionElement." + ); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'vAlign' property on 'HTMLTableSectionElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "valign", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLTableSectionElement.prototype, { + insertRow: { enumerable: true }, + deleteRow: { enumerable: true }, + rows: { enumerable: true }, + align: { enumerable: true }, + ch: { enumerable: true }, + chOff: { enumerable: true }, + vAlign: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLTableSectionElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLTableSectionElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLTableSectionElement + }); +}; + +const Impl = require("../nodes/HTMLTableSectionElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLTemplateElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTemplateElement.js new file mode 100644 index 000000000..397a0019f --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTemplateElement.js @@ -0,0 +1,126 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLTemplateElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLTemplateElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLTemplateElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLTemplateElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLTemplateElement before HTMLElement"); + } + class HTMLTemplateElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get content() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get content' called on an object that is not a valid instance of HTMLTemplateElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["content"]); + } + } + Object.defineProperties(HTMLTemplateElement.prototype, { + content: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLTemplateElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLTemplateElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLTemplateElement + }); +}; + +const Impl = require("../nodes/HTMLTemplateElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLTextAreaElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTextAreaElement.js new file mode 100644 index 000000000..0cd4adeb9 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTextAreaElement.js @@ -0,0 +1,1088 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const SelectionMode = require("./SelectionMode.js"); +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const parseInteger_helpers_strings = require("../helpers/strings.js").parseInteger; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLTextAreaElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLTextAreaElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLTextAreaElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLTextAreaElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLTextAreaElement before HTMLElement"); + } + class HTMLTextAreaElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + checkValidity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'checkValidity' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + return esValue[implSymbol].checkValidity(); + } + + reportValidity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError( + "'reportValidity' called on an object that is not a valid instance of HTMLTextAreaElement." + ); + } + + return esValue[implSymbol].reportValidity(); + } + + setCustomValidity(error) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError( + "'setCustomValidity' called on an object that is not a valid instance of HTMLTextAreaElement." + ); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'setCustomValidity' on 'HTMLTextAreaElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setCustomValidity' on 'HTMLTextAreaElement': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].setCustomValidity(...args); + } + + select() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'select' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + return esValue[implSymbol].select(); + } + + setRangeText(replacement) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'setRangeText' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'setRangeText' on 'HTMLTextAreaElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + switch (arguments.length) { + case 1: + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setRangeText' on 'HTMLTextAreaElement': parameter 1" + }); + args.push(curArg); + } + break; + case 2: + throw new TypeError( + "Failed to execute 'setRangeText' on 'HTMLTextAreaElement': only " + + arguments.length + + " arguments present." + ); + break; + case 3: + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setRangeText' on 'HTMLTextAreaElement': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'setRangeText' on 'HTMLTextAreaElement': parameter 2" + }); + args.push(curArg); + } + { + let curArg = arguments[2]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'setRangeText' on 'HTMLTextAreaElement': parameter 3" + }); + args.push(curArg); + } + break; + default: + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setRangeText' on 'HTMLTextAreaElement': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'setRangeText' on 'HTMLTextAreaElement': parameter 2" + }); + args.push(curArg); + } + { + let curArg = arguments[2]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'setRangeText' on 'HTMLTextAreaElement': parameter 3" + }); + args.push(curArg); + } + { + let curArg = arguments[3]; + if (curArg !== undefined) { + curArg = SelectionMode.convert(curArg, { + context: "Failed to execute 'setRangeText' on 'HTMLTextAreaElement': parameter 4" + }); + } else { + curArg = "preserve"; + } + args.push(curArg); + } + } + return esValue[implSymbol].setRangeText(...args); + } + + setSelectionRange(start, end) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError( + "'setSelectionRange' called on an object that is not a valid instance of HTMLTextAreaElement." + ); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'setSelectionRange' on 'HTMLTextAreaElement': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'setSelectionRange' on 'HTMLTextAreaElement': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'setSelectionRange' on 'HTMLTextAreaElement': parameter 2" + }); + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'setSelectionRange' on 'HTMLTextAreaElement': parameter 3" + }); + } + args.push(curArg); + } + return esValue[implSymbol].setSelectionRange(...args); + } + + get autocomplete() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get autocomplete' called on an object that is not a valid instance of HTMLTextAreaElement." + ); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "autocomplete"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set autocomplete(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set autocomplete' called on an object that is not a valid instance of HTMLTextAreaElement." + ); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'autocomplete' property on 'HTMLTextAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "autocomplete", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get autofocus() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get autofocus' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "autofocus"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set autofocus(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set autofocus' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'autofocus' property on 'HTMLTextAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "autofocus", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "autofocus"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get cols() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get cols' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["cols"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set cols(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set cols' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'cols' property on 'HTMLTextAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["cols"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get dirName() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get dirName' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "dirname"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set dirName(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set dirName' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'dirName' property on 'HTMLTextAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "dirname", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get disabled() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get disabled' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "disabled"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set disabled(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set disabled' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'disabled' property on 'HTMLTextAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "disabled", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "disabled"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get form() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get form' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["form"]); + } + + get inputMode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get inputMode' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "inputmode"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set inputMode(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set inputMode' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'inputMode' property on 'HTMLTextAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "inputmode", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get maxLength() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get maxLength' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + let value = esValue[implSymbol].getAttributeNS(null, "maxlength"); + if (value === null) { + return 0; + } + value = parseInteger_helpers_strings(value); + return value !== null && conversions.long(value) === value ? value : 0; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set maxLength(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set maxLength' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + V = conversions["long"](V, { + context: "Failed to set the 'maxLength' property on 'HTMLTextAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "maxlength", String(V)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get minLength() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get minLength' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + let value = esValue[implSymbol].getAttributeNS(null, "minlength"); + if (value === null) { + return 0; + } + value = parseInteger_helpers_strings(value); + return value !== null && conversions.long(value) === value ? value : 0; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set minLength(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set minLength' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + V = conversions["long"](V, { + context: "Failed to set the 'minLength' property on 'HTMLTextAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "minlength", String(V)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "name"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set name(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set name' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'name' property on 'HTMLTextAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "name", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get placeholder() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get placeholder' called on an object that is not a valid instance of HTMLTextAreaElement." + ); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "placeholder"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set placeholder(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set placeholder' called on an object that is not a valid instance of HTMLTextAreaElement." + ); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'placeholder' property on 'HTMLTextAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "placeholder", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get readOnly() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get readOnly' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "readonly"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set readOnly(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set readOnly' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'readOnly' property on 'HTMLTextAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "readonly", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "readonly"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get required() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get required' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "required"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set required(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set required' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'required' property on 'HTMLTextAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "required", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "required"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get rows() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get rows' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["rows"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set rows(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set rows' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'rows' property on 'HTMLTextAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["rows"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get wrap() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get wrap' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "wrap"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set wrap(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set wrap' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'wrap' property on 'HTMLTextAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "wrap", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + return esValue[implSymbol]["type"]; + } + + get defaultValue() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get defaultValue' called on an object that is not a valid instance of HTMLTextAreaElement." + ); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["defaultValue"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set defaultValue(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set defaultValue' called on an object that is not a valid instance of HTMLTextAreaElement." + ); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'defaultValue' property on 'HTMLTextAreaElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["defaultValue"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get value() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get value' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["value"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set value(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set value' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'value' property on 'HTMLTextAreaElement': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["value"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get textLength() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get textLength' called on an object that is not a valid instance of HTMLTextAreaElement." + ); + } + + return esValue[implSymbol]["textLength"]; + } + + get willValidate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get willValidate' called on an object that is not a valid instance of HTMLTextAreaElement." + ); + } + + return esValue[implSymbol]["willValidate"]; + } + + get validity() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get validity' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["validity"]); + } + + get validationMessage() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get validationMessage' called on an object that is not a valid instance of HTMLTextAreaElement." + ); + } + + return esValue[implSymbol]["validationMessage"]; + } + + get labels() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get labels' called on an object that is not a valid instance of HTMLTextAreaElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["labels"]); + } + + get selectionStart() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get selectionStart' called on an object that is not a valid instance of HTMLTextAreaElement." + ); + } + + return esValue[implSymbol]["selectionStart"]; + } + + set selectionStart(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set selectionStart' called on an object that is not a valid instance of HTMLTextAreaElement." + ); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'selectionStart' property on 'HTMLTextAreaElement': The provided value" + }); + + esValue[implSymbol]["selectionStart"] = V; + } + + get selectionEnd() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get selectionEnd' called on an object that is not a valid instance of HTMLTextAreaElement." + ); + } + + return esValue[implSymbol]["selectionEnd"]; + } + + set selectionEnd(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set selectionEnd' called on an object that is not a valid instance of HTMLTextAreaElement." + ); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'selectionEnd' property on 'HTMLTextAreaElement': The provided value" + }); + + esValue[implSymbol]["selectionEnd"] = V; + } + + get selectionDirection() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get selectionDirection' called on an object that is not a valid instance of HTMLTextAreaElement." + ); + } + + return esValue[implSymbol]["selectionDirection"]; + } + + set selectionDirection(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set selectionDirection' called on an object that is not a valid instance of HTMLTextAreaElement." + ); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'selectionDirection' property on 'HTMLTextAreaElement': The provided value" + }); + + esValue[implSymbol]["selectionDirection"] = V; + } + } + Object.defineProperties(HTMLTextAreaElement.prototype, { + checkValidity: { enumerable: true }, + reportValidity: { enumerable: true }, + setCustomValidity: { enumerable: true }, + select: { enumerable: true }, + setRangeText: { enumerable: true }, + setSelectionRange: { enumerable: true }, + autocomplete: { enumerable: true }, + autofocus: { enumerable: true }, + cols: { enumerable: true }, + dirName: { enumerable: true }, + disabled: { enumerable: true }, + form: { enumerable: true }, + inputMode: { enumerable: true }, + maxLength: { enumerable: true }, + minLength: { enumerable: true }, + name: { enumerable: true }, + placeholder: { enumerable: true }, + readOnly: { enumerable: true }, + required: { enumerable: true }, + rows: { enumerable: true }, + wrap: { enumerable: true }, + type: { enumerable: true }, + defaultValue: { enumerable: true }, + value: { enumerable: true }, + textLength: { enumerable: true }, + willValidate: { enumerable: true }, + validity: { enumerable: true }, + validationMessage: { enumerable: true }, + labels: { enumerable: true }, + selectionStart: { enumerable: true }, + selectionEnd: { enumerable: true }, + selectionDirection: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLTextAreaElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLTextAreaElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLTextAreaElement + }); +}; + +const Impl = require("../nodes/HTMLTextAreaElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLTimeElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTimeElement.js new file mode 100644 index 000000000..cddf2dde7 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTimeElement.js @@ -0,0 +1,153 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLTimeElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLTimeElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLTimeElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLTimeElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLTimeElement before HTMLElement"); + } + class HTMLTimeElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get dateTime() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get dateTime' called on an object that is not a valid instance of HTMLTimeElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "datetime"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set dateTime(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set dateTime' called on an object that is not a valid instance of HTMLTimeElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'dateTime' property on 'HTMLTimeElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "datetime", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLTimeElement.prototype, { + dateTime: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLTimeElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLTimeElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLTimeElement + }); +}; + +const Impl = require("../nodes/HTMLTimeElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLTitleElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTitleElement.js new file mode 100644 index 000000000..4350eb0c0 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTitleElement.js @@ -0,0 +1,152 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLTitleElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLTitleElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLTitleElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLTitleElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLTitleElement before HTMLElement"); + } + class HTMLTitleElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get text() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get text' called on an object that is not a valid instance of HTMLTitleElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["text"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set text(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set text' called on an object that is not a valid instance of HTMLTitleElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'text' property on 'HTMLTitleElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["text"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLTitleElement.prototype, { + text: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLTitleElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLTitleElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLTitleElement + }); +}; + +const Impl = require("../nodes/HTMLTitleElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLTrackElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTrackElement.js new file mode 100644 index 000000000..d7ed0fe6c --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLTrackElement.js @@ -0,0 +1,334 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const parseURLToResultingURLRecord_helpers_document_base_url = + require("../helpers/document-base-url.js").parseURLToResultingURLRecord; +const serializeURLwhatwg_url = require("whatwg-url").serializeURL; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLTrackElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLTrackElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLTrackElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLTrackElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLTrackElement before HTMLElement"); + } + class HTMLTrackElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get kind() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get kind' called on an object that is not a valid instance of HTMLTrackElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "kind"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set kind(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set kind' called on an object that is not a valid instance of HTMLTrackElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'kind' property on 'HTMLTrackElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "kind", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get src() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get src' called on an object that is not a valid instance of HTMLTrackElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "src"); + if (value === null) { + return ""; + } + const urlRecord = parseURLToResultingURLRecord_helpers_document_base_url( + value, + esValue[implSymbol]._ownerDocument + ); + if (urlRecord !== null) { + return serializeURLwhatwg_url(urlRecord); + } + return conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set src(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set src' called on an object that is not a valid instance of HTMLTrackElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'src' property on 'HTMLTrackElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "src", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get srclang() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get srclang' called on an object that is not a valid instance of HTMLTrackElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "srclang"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set srclang(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set srclang' called on an object that is not a valid instance of HTMLTrackElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'srclang' property on 'HTMLTrackElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "srclang", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get label() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get label' called on an object that is not a valid instance of HTMLTrackElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "label"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set label(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set label' called on an object that is not a valid instance of HTMLTrackElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'label' property on 'HTMLTrackElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "label", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get default() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get default' called on an object that is not a valid instance of HTMLTrackElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "default"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set default(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set default' called on an object that is not a valid instance of HTMLTrackElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'default' property on 'HTMLTrackElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "default", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "default"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get readyState() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get readyState' called on an object that is not a valid instance of HTMLTrackElement."); + } + + return esValue[implSymbol]["readyState"]; + } + } + Object.defineProperties(HTMLTrackElement.prototype, { + kind: { enumerable: true }, + src: { enumerable: true }, + srclang: { enumerable: true }, + label: { enumerable: true }, + default: { enumerable: true }, + readyState: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLTrackElement", configurable: true }, + NONE: { value: 0, enumerable: true }, + LOADING: { value: 1, enumerable: true }, + LOADED: { value: 2, enumerable: true }, + ERROR: { value: 3, enumerable: true } + }); + Object.defineProperties(HTMLTrackElement, { + NONE: { value: 0, enumerable: true }, + LOADING: { value: 1, enumerable: true }, + LOADED: { value: 2, enumerable: true }, + ERROR: { value: 3, enumerable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLTrackElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLTrackElement + }); +}; + +const Impl = require("../nodes/HTMLTrackElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLUListElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLUListElement.js new file mode 100644 index 000000000..50d3ead2a --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLUListElement.js @@ -0,0 +1,192 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLUListElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLUListElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLUListElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLUListElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLUListElement before HTMLElement"); + } + class HTMLUListElement extends globalObject.HTMLElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get compact() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get compact' called on an object that is not a valid instance of HTMLUListElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "compact"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set compact(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set compact' called on an object that is not a valid instance of HTMLUListElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'compact' property on 'HTMLUListElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "compact", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "compact"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of HTMLUListElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "type"); + return value === null ? "" : value; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set type(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set type' called on an object that is not a valid instance of HTMLUListElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'type' property on 'HTMLUListElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "type", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLUListElement.prototype, { + compact: { enumerable: true }, + type: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLUListElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLUListElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLUListElement + }); +}; + +const Impl = require("../nodes/HTMLUListElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLUnknownElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLUnknownElement.js new file mode 100644 index 000000000..9e5fea380 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLUnknownElement.js @@ -0,0 +1,114 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLElement = require("./HTMLElement.js"); + +const interfaceName = "HTMLUnknownElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLUnknownElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLUnknownElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLUnknownElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLUnknownElement before HTMLElement"); + } + class HTMLUnknownElement extends globalObject.HTMLElement { + constructor() { + throw new TypeError("Illegal constructor"); + } + } + Object.defineProperties(HTMLUnknownElement.prototype, { + [Symbol.toStringTag]: { value: "HTMLUnknownElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLUnknownElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLUnknownElement + }); +}; + +const Impl = require("../nodes/HTMLUnknownElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HTMLVideoElement.js b/node_modules/jsdom/lib/jsdom/living/generated/HTMLVideoElement.js new file mode 100644 index 000000000..f00794826 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HTMLVideoElement.js @@ -0,0 +1,310 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HTMLConstructor_helpers_html_constructor = require("../helpers/html-constructor.js").HTMLConstructor; +const parseNonNegativeInteger_helpers_strings = require("../helpers/strings.js").parseNonNegativeInteger; +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const parseURLToResultingURLRecord_helpers_document_base_url = + require("../helpers/document-base-url.js").parseURLToResultingURLRecord; +const serializeURLwhatwg_url = require("whatwg-url").serializeURL; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const HTMLMediaElement = require("./HTMLMediaElement.js"); + +const interfaceName = "HTMLVideoElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HTMLVideoElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HTMLVideoElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HTMLVideoElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + HTMLMediaElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.HTMLMediaElement === undefined) { + throw new Error("Internal error: attempting to evaluate HTMLVideoElement before HTMLMediaElement"); + } + class HTMLVideoElement extends globalObject.HTMLMediaElement { + constructor() { + return HTMLConstructor_helpers_html_constructor(globalObject, interfaceName, new.target); + } + + get width() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get width' called on an object that is not a valid instance of HTMLVideoElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + let value = esValue[implSymbol].getAttributeNS(null, "width"); + if (value === null) { + return 0; + } + value = parseNonNegativeInteger_helpers_strings(value); + return value !== null && value >= 0 && value <= 2147483647 ? value : 0; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set width(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set width' called on an object that is not a valid instance of HTMLVideoElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'width' property on 'HTMLVideoElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const n = V <= 2147483647 ? V : 0; + esValue[implSymbol].setAttributeNS(null, "width", String(n)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get height() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get height' called on an object that is not a valid instance of HTMLVideoElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + let value = esValue[implSymbol].getAttributeNS(null, "height"); + if (value === null) { + return 0; + } + value = parseNonNegativeInteger_helpers_strings(value); + return value !== null && value >= 0 && value <= 2147483647 ? value : 0; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set height(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set height' called on an object that is not a valid instance of HTMLVideoElement."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'height' property on 'HTMLVideoElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const n = V <= 2147483647 ? V : 0; + esValue[implSymbol].setAttributeNS(null, "height", String(n)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get videoWidth() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get videoWidth' called on an object that is not a valid instance of HTMLVideoElement."); + } + + return esValue[implSymbol]["videoWidth"]; + } + + get videoHeight() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get videoHeight' called on an object that is not a valid instance of HTMLVideoElement."); + } + + return esValue[implSymbol]["videoHeight"]; + } + + get poster() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get poster' called on an object that is not a valid instance of HTMLVideoElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + const value = esValue[implSymbol].getAttributeNS(null, "poster"); + if (value === null) { + return ""; + } + const urlRecord = parseURLToResultingURLRecord_helpers_document_base_url( + value, + esValue[implSymbol]._ownerDocument + ); + if (urlRecord !== null) { + return serializeURLwhatwg_url(urlRecord); + } + return conversions.USVString(value); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set poster(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set poster' called on an object that is not a valid instance of HTMLVideoElement."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'poster' property on 'HTMLVideoElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol].setAttributeNS(null, "poster", V); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get playsInline() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get playsInline' called on an object that is not a valid instance of HTMLVideoElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].hasAttributeNS(null, "playsinline"); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set playsInline(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set playsInline' called on an object that is not a valid instance of HTMLVideoElement."); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'playsInline' property on 'HTMLVideoElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + if (V) { + esValue[implSymbol].setAttributeNS(null, "playsinline", ""); + } else { + esValue[implSymbol].removeAttributeNS(null, "playsinline"); + } + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(HTMLVideoElement.prototype, { + width: { enumerable: true }, + height: { enumerable: true }, + videoWidth: { enumerable: true }, + videoHeight: { enumerable: true }, + poster: { enumerable: true }, + playsInline: { enumerable: true }, + [Symbol.toStringTag]: { value: "HTMLVideoElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HTMLVideoElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HTMLVideoElement + }); +}; + +const Impl = require("../nodes/HTMLVideoElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HashChangeEvent.js b/node_modules/jsdom/lib/jsdom/living/generated/HashChangeEvent.js new file mode 100644 index 000000000..63d051f97 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HashChangeEvent.js @@ -0,0 +1,153 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const HashChangeEventInit = require("./HashChangeEventInit.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const Event = require("./Event.js"); + +const interfaceName = "HashChangeEvent"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'HashChangeEvent'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["HashChangeEvent"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor HashChangeEvent is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Event._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Event === undefined) { + throw new Error("Internal error: attempting to evaluate HashChangeEvent before Event"); + } + class HashChangeEvent extends globalObject.Event { + constructor(type) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'HashChangeEvent': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'HashChangeEvent': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = HashChangeEventInit.convert(curArg, { context: "Failed to construct 'HashChangeEvent': parameter 2" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + get oldURL() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oldURL' called on an object that is not a valid instance of HashChangeEvent."); + } + + return esValue[implSymbol]["oldURL"]; + } + + get newURL() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get newURL' called on an object that is not a valid instance of HashChangeEvent."); + } + + return esValue[implSymbol]["newURL"]; + } + } + Object.defineProperties(HashChangeEvent.prototype, { + oldURL: { enumerable: true }, + newURL: { enumerable: true }, + [Symbol.toStringTag]: { value: "HashChangeEvent", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = HashChangeEvent; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: HashChangeEvent + }); +}; + +const Impl = require("../events/HashChangeEvent-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/HashChangeEventInit.js b/node_modules/jsdom/lib/jsdom/living/generated/HashChangeEventInit.js new file mode 100644 index 000000000..af8bf80b4 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/HashChangeEventInit.js @@ -0,0 +1,44 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventInit = require("./EventInit.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + EventInit._convertInherit(obj, ret, { context }); + + { + const key = "newURL"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["USVString"](value, { context: context + " has member 'newURL' that" }); + + ret[key] = value; + } else { + ret[key] = ""; + } + } + + { + const key = "oldURL"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["USVString"](value, { context: context + " has member 'oldURL' that" }); + + ret[key] = value; + } else { + ret[key] = ""; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/Headers.js b/node_modules/jsdom/lib/jsdom/living/generated/Headers.js new file mode 100644 index 000000000..a0265da36 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/Headers.js @@ -0,0 +1,379 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const Function = require("./Function.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "Headers"; + +const IteratorPrototype = Object.create(utils.IteratorPrototype, { + next: { + value: function next() { + const internal = this && this[utils.iterInternalSymbol]; + if (!internal) { + throw new TypeError("next() called on a value that is not an iterator prototype object"); + } + + const { target, kind, index } = internal; + const values = Array.from(target[implSymbol]); + const len = values.length; + if (index >= len) { + return { value: undefined, done: true }; + } + + const pair = values[index]; + internal.index = index + 1; + return utils.iteratorResult(pair.map(utils.tryWrapperForImpl), kind); + }, + writable: true, + enumerable: true, + configurable: true + }, + [Symbol.toStringTag]: { + value: "Headers Iterator", + configurable: true + } +}); + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'Headers'.`); +}; + +exports.createDefaultIterator = (target, kind) => { + const iterator = Object.create(IteratorPrototype); + Object.defineProperty(iterator, utils.iterInternalSymbol, { + value: { target, kind, index: 0 }, + configurable: true + }); + return iterator; +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["Headers"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor Headers is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "Worker"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class Headers { + constructor() { + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + if (utils.isObject(curArg)) { + if (curArg[Symbol.iterator] !== undefined) { + if (!utils.isObject(curArg)) { + throw new TypeError( + "Failed to construct 'Headers': parameter 1" + " sequence" + " is not an iterable object." + ); + } else { + const V = []; + const tmp = curArg; + for (let nextItem of tmp) { + if (!utils.isObject(nextItem)) { + throw new TypeError( + "Failed to construct 'Headers': parameter 1" + + " sequence" + + "'s element" + + " is not an iterable object." + ); + } else { + const V = []; + const tmp = nextItem; + for (let nextItem of tmp) { + nextItem = conversions["ByteString"](nextItem, { + context: + "Failed to construct 'Headers': parameter 1" + " sequence" + "'s element" + "'s element" + }); + + V.push(nextItem); + } + nextItem = V; + } + + V.push(nextItem); + } + curArg = V; + } + } else { + if (!utils.isObject(curArg)) { + throw new TypeError("Failed to construct 'Headers': parameter 1" + " record" + " is not an object."); + } else { + const result = Object.create(null); + for (const key of Reflect.ownKeys(curArg)) { + const desc = Object.getOwnPropertyDescriptor(curArg, key); + if (desc && desc.enumerable) { + let typedKey = key; + + typedKey = conversions["ByteString"](typedKey, { + context: "Failed to construct 'Headers': parameter 1" + " record" + "'s key" + }); + + let typedValue = curArg[key]; + + typedValue = conversions["ByteString"](typedValue, { + context: "Failed to construct 'Headers': parameter 1" + " record" + "'s value" + }); + + result[typedKey] = typedValue; + } + } + curArg = result; + } + } + } else { + throw new TypeError("Failed to construct 'Headers': parameter 1" + " is not of any supported type."); + } + } + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + append(name, value) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'append' called on an object that is not a valid instance of Headers."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'append' on 'Headers': 2 arguments required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["ByteString"](curArg, { context: "Failed to execute 'append' on 'Headers': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["ByteString"](curArg, { context: "Failed to execute 'append' on 'Headers': parameter 2" }); + args.push(curArg); + } + return esValue[implSymbol].append(...args); + } + + delete(name) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'delete' called on an object that is not a valid instance of Headers."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'delete' on 'Headers': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["ByteString"](curArg, { context: "Failed to execute 'delete' on 'Headers': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].delete(...args); + } + + get(name) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'get' called on an object that is not a valid instance of Headers."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'get' on 'Headers': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["ByteString"](curArg, { context: "Failed to execute 'get' on 'Headers': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].get(...args); + } + + has(name) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'has' called on an object that is not a valid instance of Headers."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'has' on 'Headers': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["ByteString"](curArg, { context: "Failed to execute 'has' on 'Headers': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].has(...args); + } + + set(name, value) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'set' called on an object that is not a valid instance of Headers."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'set' on 'Headers': 2 arguments required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["ByteString"](curArg, { context: "Failed to execute 'set' on 'Headers': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["ByteString"](curArg, { context: "Failed to execute 'set' on 'Headers': parameter 2" }); + args.push(curArg); + } + return esValue[implSymbol].set(...args); + } + + keys() { + if (!exports.is(this)) { + throw new TypeError("'keys' called on an object that is not a valid instance of Headers."); + } + return exports.createDefaultIterator(this, "key"); + } + + values() { + if (!exports.is(this)) { + throw new TypeError("'values' called on an object that is not a valid instance of Headers."); + } + return exports.createDefaultIterator(this, "value"); + } + + entries() { + if (!exports.is(this)) { + throw new TypeError("'entries' called on an object that is not a valid instance of Headers."); + } + return exports.createDefaultIterator(this, "key+value"); + } + + forEach(callback) { + if (!exports.is(this)) { + throw new TypeError("'forEach' called on an object that is not a valid instance of Headers."); + } + if (arguments.length < 1) { + throw new TypeError("Failed to execute 'forEach' on 'iterable': 1 argument required, " + "but only 0 present."); + } + callback = Function.convert(callback, { + context: "Failed to execute 'forEach' on 'iterable': The callback provided as parameter 1" + }); + const thisArg = arguments[1]; + let pairs = Array.from(this[implSymbol]); + let i = 0; + while (i < pairs.length) { + const [key, value] = pairs[i].map(utils.tryWrapperForImpl); + callback.call(thisArg, value, key, this); + pairs = Array.from(this[implSymbol]); + i++; + } + } + } + Object.defineProperties(Headers.prototype, { + append: { enumerable: true }, + delete: { enumerable: true }, + get: { enumerable: true }, + has: { enumerable: true }, + set: { enumerable: true }, + keys: { enumerable: true }, + values: { enumerable: true }, + entries: { enumerable: true }, + forEach: { enumerable: true }, + [Symbol.toStringTag]: { value: "Headers", configurable: true }, + [Symbol.iterator]: { value: Headers.prototype.entries, configurable: true, writable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = Headers; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: Headers + }); +}; + +const Impl = require("../fetch/Headers-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/History.js b/node_modules/jsdom/lib/jsdom/living/generated/History.js new file mode 100644 index 000000000..2ce438759 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/History.js @@ -0,0 +1,256 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "History"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'History'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["History"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor History is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class History { + constructor() { + throw new TypeError("Illegal constructor"); + } + + go() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'go' called on an object that is not a valid instance of History."); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + curArg = conversions["long"](curArg, { context: "Failed to execute 'go' on 'History': parameter 1" }); + } else { + curArg = 0; + } + args.push(curArg); + } + return esValue[implSymbol].go(...args); + } + + back() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'back' called on an object that is not a valid instance of History."); + } + + return esValue[implSymbol].back(); + } + + forward() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'forward' called on an object that is not a valid instance of History."); + } + + return esValue[implSymbol].forward(); + } + + pushState(data, title) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'pushState' called on an object that is not a valid instance of History."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'pushState' on 'History': 2 arguments required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["any"](curArg, { context: "Failed to execute 'pushState' on 'History': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'pushState' on 'History': parameter 2" + }); + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'pushState' on 'History': parameter 3" + }); + } + } else { + curArg = null; + } + args.push(curArg); + } + return esValue[implSymbol].pushState(...args); + } + + replaceState(data, title) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'replaceState' called on an object that is not a valid instance of History."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'replaceState' on 'History': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["any"](curArg, { context: "Failed to execute 'replaceState' on 'History': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'replaceState' on 'History': parameter 2" + }); + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'replaceState' on 'History': parameter 3" + }); + } + } else { + curArg = null; + } + args.push(curArg); + } + return esValue[implSymbol].replaceState(...args); + } + + get length() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get length' called on an object that is not a valid instance of History."); + } + + return esValue[implSymbol]["length"]; + } + + get state() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get state' called on an object that is not a valid instance of History."); + } + + return esValue[implSymbol]["state"]; + } + } + Object.defineProperties(History.prototype, { + go: { enumerable: true }, + back: { enumerable: true }, + forward: { enumerable: true }, + pushState: { enumerable: true }, + replaceState: { enumerable: true }, + length: { enumerable: true }, + state: { enumerable: true }, + [Symbol.toStringTag]: { value: "History", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = History; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: History + }); +}; + +const Impl = require("../window/History-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/InputEvent.js b/node_modules/jsdom/lib/jsdom/living/generated/InputEvent.js new file mode 100644 index 000000000..3dd61df1b --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/InputEvent.js @@ -0,0 +1,164 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const InputEventInit = require("./InputEventInit.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const UIEvent = require("./UIEvent.js"); + +const interfaceName = "InputEvent"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'InputEvent'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["InputEvent"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor InputEvent is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + UIEvent._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.UIEvent === undefined) { + throw new Error("Internal error: attempting to evaluate InputEvent before UIEvent"); + } + class InputEvent extends globalObject.UIEvent { + constructor(type) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'InputEvent': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'InputEvent': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = InputEventInit.convert(curArg, { context: "Failed to construct 'InputEvent': parameter 2" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + get data() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get data' called on an object that is not a valid instance of InputEvent."); + } + + return esValue[implSymbol]["data"]; + } + + get isComposing() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get isComposing' called on an object that is not a valid instance of InputEvent."); + } + + return esValue[implSymbol]["isComposing"]; + } + + get inputType() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get inputType' called on an object that is not a valid instance of InputEvent."); + } + + return esValue[implSymbol]["inputType"]; + } + } + Object.defineProperties(InputEvent.prototype, { + data: { enumerable: true }, + isComposing: { enumerable: true }, + inputType: { enumerable: true }, + [Symbol.toStringTag]: { value: "InputEvent", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = InputEvent; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: InputEvent + }); +}; + +const Impl = require("../events/InputEvent-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/InputEventInit.js b/node_modules/jsdom/lib/jsdom/living/generated/InputEventInit.js new file mode 100644 index 000000000..a41cfa2a6 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/InputEventInit.js @@ -0,0 +1,59 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const UIEventInit = require("./UIEventInit.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + UIEventInit._convertInherit(obj, ret, { context }); + + { + const key = "data"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + if (value === null || value === undefined) { + value = null; + } else { + value = conversions["DOMString"](value, { context: context + " has member 'data' that" }); + } + ret[key] = value; + } else { + ret[key] = null; + } + } + + { + const key = "inputType"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["DOMString"](value, { context: context + " has member 'inputType' that" }); + + ret[key] = value; + } else { + ret[key] = ""; + } + } + + { + const key = "isComposing"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'isComposing' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/KeyboardEvent.js b/node_modules/jsdom/lib/jsdom/living/generated/KeyboardEvent.js new file mode 100644 index 000000000..11916a2bf --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/KeyboardEvent.js @@ -0,0 +1,413 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const KeyboardEventInit = require("./KeyboardEventInit.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const UIEvent = require("./UIEvent.js"); + +const interfaceName = "KeyboardEvent"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'KeyboardEvent'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["KeyboardEvent"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor KeyboardEvent is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + UIEvent._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.UIEvent === undefined) { + throw new Error("Internal error: attempting to evaluate KeyboardEvent before UIEvent"); + } + class KeyboardEvent extends globalObject.UIEvent { + constructor(type) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'KeyboardEvent': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'KeyboardEvent': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = KeyboardEventInit.convert(curArg, { context: "Failed to construct 'KeyboardEvent': parameter 2" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + getModifierState(keyArg) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getModifierState' called on an object that is not a valid instance of KeyboardEvent."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'getModifierState' on 'KeyboardEvent': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getModifierState' on 'KeyboardEvent': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].getModifierState(...args); + } + + initKeyboardEvent(typeArg) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'initKeyboardEvent' called on an object that is not a valid instance of KeyboardEvent."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'initKeyboardEvent' on 'KeyboardEvent': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'initKeyboardEvent' on 'KeyboardEvent': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initKeyboardEvent' on 'KeyboardEvent': parameter 2" + }); + } else { + curArg = false; + } + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initKeyboardEvent' on 'KeyboardEvent': parameter 3" + }); + } else { + curArg = false; + } + args.push(curArg); + } + { + let curArg = arguments[3]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = utils.tryImplForWrapper(curArg); + } + } else { + curArg = null; + } + args.push(curArg); + } + { + let curArg = arguments[4]; + if (curArg !== undefined) { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'initKeyboardEvent' on 'KeyboardEvent': parameter 5" + }); + } else { + curArg = ""; + } + args.push(curArg); + } + { + let curArg = arguments[5]; + if (curArg !== undefined) { + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'initKeyboardEvent' on 'KeyboardEvent': parameter 6" + }); + } else { + curArg = 0; + } + args.push(curArg); + } + { + let curArg = arguments[6]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initKeyboardEvent' on 'KeyboardEvent': parameter 7" + }); + } else { + curArg = false; + } + args.push(curArg); + } + { + let curArg = arguments[7]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initKeyboardEvent' on 'KeyboardEvent': parameter 8" + }); + } else { + curArg = false; + } + args.push(curArg); + } + { + let curArg = arguments[8]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initKeyboardEvent' on 'KeyboardEvent': parameter 9" + }); + } else { + curArg = false; + } + args.push(curArg); + } + { + let curArg = arguments[9]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initKeyboardEvent' on 'KeyboardEvent': parameter 10" + }); + } else { + curArg = false; + } + args.push(curArg); + } + return esValue[implSymbol].initKeyboardEvent(...args); + } + + get key() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get key' called on an object that is not a valid instance of KeyboardEvent."); + } + + return esValue[implSymbol]["key"]; + } + + get code() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get code' called on an object that is not a valid instance of KeyboardEvent."); + } + + return esValue[implSymbol]["code"]; + } + + get location() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get location' called on an object that is not a valid instance of KeyboardEvent."); + } + + return esValue[implSymbol]["location"]; + } + + get ctrlKey() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ctrlKey' called on an object that is not a valid instance of KeyboardEvent."); + } + + return esValue[implSymbol]["ctrlKey"]; + } + + get shiftKey() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get shiftKey' called on an object that is not a valid instance of KeyboardEvent."); + } + + return esValue[implSymbol]["shiftKey"]; + } + + get altKey() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get altKey' called on an object that is not a valid instance of KeyboardEvent."); + } + + return esValue[implSymbol]["altKey"]; + } + + get metaKey() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get metaKey' called on an object that is not a valid instance of KeyboardEvent."); + } + + return esValue[implSymbol]["metaKey"]; + } + + get repeat() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get repeat' called on an object that is not a valid instance of KeyboardEvent."); + } + + return esValue[implSymbol]["repeat"]; + } + + get isComposing() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get isComposing' called on an object that is not a valid instance of KeyboardEvent."); + } + + return esValue[implSymbol]["isComposing"]; + } + + get charCode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get charCode' called on an object that is not a valid instance of KeyboardEvent."); + } + + return esValue[implSymbol]["charCode"]; + } + + get keyCode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get keyCode' called on an object that is not a valid instance of KeyboardEvent."); + } + + return esValue[implSymbol]["keyCode"]; + } + } + Object.defineProperties(KeyboardEvent.prototype, { + getModifierState: { enumerable: true }, + initKeyboardEvent: { enumerable: true }, + key: { enumerable: true }, + code: { enumerable: true }, + location: { enumerable: true }, + ctrlKey: { enumerable: true }, + shiftKey: { enumerable: true }, + altKey: { enumerable: true }, + metaKey: { enumerable: true }, + repeat: { enumerable: true }, + isComposing: { enumerable: true }, + charCode: { enumerable: true }, + keyCode: { enumerable: true }, + [Symbol.toStringTag]: { value: "KeyboardEvent", configurable: true }, + DOM_KEY_LOCATION_STANDARD: { value: 0x00, enumerable: true }, + DOM_KEY_LOCATION_LEFT: { value: 0x01, enumerable: true }, + DOM_KEY_LOCATION_RIGHT: { value: 0x02, enumerable: true }, + DOM_KEY_LOCATION_NUMPAD: { value: 0x03, enumerable: true } + }); + Object.defineProperties(KeyboardEvent, { + DOM_KEY_LOCATION_STANDARD: { value: 0x00, enumerable: true }, + DOM_KEY_LOCATION_LEFT: { value: 0x01, enumerable: true }, + DOM_KEY_LOCATION_RIGHT: { value: 0x02, enumerable: true }, + DOM_KEY_LOCATION_NUMPAD: { value: 0x03, enumerable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = KeyboardEvent; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: KeyboardEvent + }); +}; + +const Impl = require("../events/KeyboardEvent-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/KeyboardEventInit.js b/node_modules/jsdom/lib/jsdom/living/generated/KeyboardEventInit.js new file mode 100644 index 000000000..b6b38aa6c --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/KeyboardEventInit.js @@ -0,0 +1,104 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventModifierInit = require("./EventModifierInit.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + EventModifierInit._convertInherit(obj, ret, { context }); + + { + const key = "charCode"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["unsigned long"](value, { context: context + " has member 'charCode' that" }); + + ret[key] = value; + } else { + ret[key] = 0; + } + } + + { + const key = "code"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["DOMString"](value, { context: context + " has member 'code' that" }); + + ret[key] = value; + } else { + ret[key] = ""; + } + } + + { + const key = "isComposing"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'isComposing' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "key"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["DOMString"](value, { context: context + " has member 'key' that" }); + + ret[key] = value; + } else { + ret[key] = ""; + } + } + + { + const key = "keyCode"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["unsigned long"](value, { context: context + " has member 'keyCode' that" }); + + ret[key] = value; + } else { + ret[key] = 0; + } + } + + { + const key = "location"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["unsigned long"](value, { context: context + " has member 'location' that" }); + + ret[key] = value; + } else { + ret[key] = 0; + } + } + + { + const key = "repeat"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'repeat' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/Location.js b/node_modules/jsdom/lib/jsdom/living/generated/Location.js new file mode 100644 index 000000000..2767eaf07 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/Location.js @@ -0,0 +1,370 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "Location"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'Location'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["Location"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor Location is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Object.defineProperties( + wrapper, + Object.getOwnPropertyDescriptors({ + assign(url) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'assign' called on an object that is not a valid instance of Location."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'assign' on 'Location': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'assign' on 'Location': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].assign(...args); + }, + replace(url) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'replace' called on an object that is not a valid instance of Location."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'replace' on 'Location': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'replace' on 'Location': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].replace(...args); + }, + reload() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'reload' called on an object that is not a valid instance of Location."); + } + + return esValue[implSymbol].reload(); + }, + get href() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get href' called on an object that is not a valid instance of Location."); + } + + return esValue[implSymbol]["href"]; + }, + set href(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set href' called on an object that is not a valid instance of Location."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'href' property on 'Location': The provided value" + }); + + esValue[implSymbol]["href"] = V; + }, + toString() { + const esValue = this; + if (!exports.is(esValue)) { + throw new TypeError("'toString' called on an object that is not a valid instance of Location."); + } + + return esValue[implSymbol]["href"]; + }, + get origin() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get origin' called on an object that is not a valid instance of Location."); + } + + return esValue[implSymbol]["origin"]; + }, + get protocol() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get protocol' called on an object that is not a valid instance of Location."); + } + + return esValue[implSymbol]["protocol"]; + }, + set protocol(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set protocol' called on an object that is not a valid instance of Location."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'protocol' property on 'Location': The provided value" + }); + + esValue[implSymbol]["protocol"] = V; + }, + get host() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get host' called on an object that is not a valid instance of Location."); + } + + return esValue[implSymbol]["host"]; + }, + set host(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set host' called on an object that is not a valid instance of Location."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'host' property on 'Location': The provided value" + }); + + esValue[implSymbol]["host"] = V; + }, + get hostname() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get hostname' called on an object that is not a valid instance of Location."); + } + + return esValue[implSymbol]["hostname"]; + }, + set hostname(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set hostname' called on an object that is not a valid instance of Location."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'hostname' property on 'Location': The provided value" + }); + + esValue[implSymbol]["hostname"] = V; + }, + get port() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get port' called on an object that is not a valid instance of Location."); + } + + return esValue[implSymbol]["port"]; + }, + set port(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set port' called on an object that is not a valid instance of Location."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'port' property on 'Location': The provided value" + }); + + esValue[implSymbol]["port"] = V; + }, + get pathname() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get pathname' called on an object that is not a valid instance of Location."); + } + + return esValue[implSymbol]["pathname"]; + }, + set pathname(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set pathname' called on an object that is not a valid instance of Location."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'pathname' property on 'Location': The provided value" + }); + + esValue[implSymbol]["pathname"] = V; + }, + get search() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get search' called on an object that is not a valid instance of Location."); + } + + return esValue[implSymbol]["search"]; + }, + set search(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set search' called on an object that is not a valid instance of Location."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'search' property on 'Location': The provided value" + }); + + esValue[implSymbol]["search"] = V; + }, + get hash() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get hash' called on an object that is not a valid instance of Location."); + } + + return esValue[implSymbol]["hash"]; + }, + set hash(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set hash' called on an object that is not a valid instance of Location."); + } + + V = conversions["USVString"](V, { + context: "Failed to set the 'hash' property on 'Location': The provided value" + }); + + esValue[implSymbol]["hash"] = V; + } + }) + ); + + Object.defineProperties(wrapper, { + assign: { configurable: false, writable: false }, + replace: { configurable: false, writable: false }, + reload: { configurable: false, writable: false }, + href: { configurable: false }, + toString: { configurable: false, writable: false }, + origin: { configurable: false }, + protocol: { configurable: false }, + host: { configurable: false }, + hostname: { configurable: false }, + port: { configurable: false }, + pathname: { configurable: false }, + search: { configurable: false }, + hash: { configurable: false } + }); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class Location { + constructor() { + throw new TypeError("Illegal constructor"); + } + } + Object.defineProperties(Location.prototype, { [Symbol.toStringTag]: { value: "Location", configurable: true } }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = Location; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: Location + }); +}; + +const Impl = require("../window/Location-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/MessageEvent.js b/node_modules/jsdom/lib/jsdom/living/generated/MessageEvent.js new file mode 100644 index 000000000..a5b18b6c7 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/MessageEvent.js @@ -0,0 +1,301 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const MessageEventInit = require("./MessageEventInit.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const Event = require("./Event.js"); + +const interfaceName = "MessageEvent"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'MessageEvent'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["MessageEvent"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor MessageEvent is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Event._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "Worker", "AudioWorklet"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Event === undefined) { + throw new Error("Internal error: attempting to evaluate MessageEvent before Event"); + } + class MessageEvent extends globalObject.Event { + constructor(type) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'MessageEvent': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'MessageEvent': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = MessageEventInit.convert(curArg, { context: "Failed to construct 'MessageEvent': parameter 2" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + initMessageEvent(type) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'initMessageEvent' called on an object that is not a valid instance of MessageEvent."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'initMessageEvent' on 'MessageEvent': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'initMessageEvent' on 'MessageEvent': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initMessageEvent' on 'MessageEvent': parameter 2" + }); + } else { + curArg = false; + } + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initMessageEvent' on 'MessageEvent': parameter 3" + }); + } else { + curArg = false; + } + args.push(curArg); + } + { + let curArg = arguments[3]; + if (curArg !== undefined) { + curArg = conversions["any"](curArg, { + context: "Failed to execute 'initMessageEvent' on 'MessageEvent': parameter 4" + }); + } else { + curArg = null; + } + args.push(curArg); + } + { + let curArg = arguments[4]; + if (curArg !== undefined) { + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'initMessageEvent' on 'MessageEvent': parameter 5" + }); + } else { + curArg = ""; + } + args.push(curArg); + } + { + let curArg = arguments[5]; + if (curArg !== undefined) { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'initMessageEvent' on 'MessageEvent': parameter 6" + }); + } else { + curArg = ""; + } + args.push(curArg); + } + { + let curArg = arguments[6]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = utils.tryImplForWrapper(curArg); + } + } else { + curArg = null; + } + args.push(curArg); + } + { + let curArg = arguments[7]; + if (curArg !== undefined) { + if (!utils.isObject(curArg)) { + throw new TypeError( + "Failed to execute 'initMessageEvent' on 'MessageEvent': parameter 8" + " is not an iterable object." + ); + } else { + const V = []; + const tmp = curArg; + for (let nextItem of tmp) { + nextItem = utils.tryImplForWrapper(nextItem); + + V.push(nextItem); + } + curArg = V; + } + } else { + curArg = []; + } + args.push(curArg); + } + return esValue[implSymbol].initMessageEvent(...args); + } + + get data() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get data' called on an object that is not a valid instance of MessageEvent."); + } + + return esValue[implSymbol]["data"]; + } + + get origin() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get origin' called on an object that is not a valid instance of MessageEvent."); + } + + return esValue[implSymbol]["origin"]; + } + + get lastEventId() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get lastEventId' called on an object that is not a valid instance of MessageEvent."); + } + + return esValue[implSymbol]["lastEventId"]; + } + + get source() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get source' called on an object that is not a valid instance of MessageEvent."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["source"]); + } + + get ports() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ports' called on an object that is not a valid instance of MessageEvent."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ports"]); + } + } + Object.defineProperties(MessageEvent.prototype, { + initMessageEvent: { enumerable: true }, + data: { enumerable: true }, + origin: { enumerable: true }, + lastEventId: { enumerable: true }, + source: { enumerable: true }, + ports: { enumerable: true }, + [Symbol.toStringTag]: { value: "MessageEvent", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = MessageEvent; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: MessageEvent + }); +}; + +const Impl = require("../events/MessageEvent-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/MessageEventInit.js b/node_modules/jsdom/lib/jsdom/living/generated/MessageEventInit.js new file mode 100644 index 000000000..d3837fe92 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/MessageEventInit.js @@ -0,0 +1,94 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventInit = require("./EventInit.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + EventInit._convertInherit(obj, ret, { context }); + + { + const key = "data"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["any"](value, { context: context + " has member 'data' that" }); + + ret[key] = value; + } else { + ret[key] = null; + } + } + + { + const key = "lastEventId"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["DOMString"](value, { context: context + " has member 'lastEventId' that" }); + + ret[key] = value; + } else { + ret[key] = ""; + } + } + + { + const key = "origin"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["USVString"](value, { context: context + " has member 'origin' that" }); + + ret[key] = value; + } else { + ret[key] = ""; + } + } + + { + const key = "ports"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + if (!utils.isObject(value)) { + throw new TypeError(context + " has member 'ports' that" + " is not an iterable object."); + } else { + const V = []; + const tmp = value; + for (let nextItem of tmp) { + nextItem = utils.tryImplForWrapper(nextItem); + + V.push(nextItem); + } + value = V; + } + + ret[key] = value; + } else { + ret[key] = []; + } + } + + { + const key = "source"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + if (value === null || value === undefined) { + value = null; + } else { + value = utils.tryImplForWrapper(value); + } + ret[key] = value; + } else { + ret[key] = null; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/MimeType.js b/node_modules/jsdom/lib/jsdom/living/generated/MimeType.js new file mode 100644 index 000000000..5c55931fc --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/MimeType.js @@ -0,0 +1,151 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "MimeType"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'MimeType'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["MimeType"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor MimeType is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class MimeType { + constructor() { + throw new TypeError("Illegal constructor"); + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of MimeType."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["type"]); + } + + get description() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get description' called on an object that is not a valid instance of MimeType."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["description"]); + } + + get suffixes() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get suffixes' called on an object that is not a valid instance of MimeType."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["suffixes"]); + } + + get enabledPlugin() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get enabledPlugin' called on an object that is not a valid instance of MimeType."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["enabledPlugin"]); + } + } + Object.defineProperties(MimeType.prototype, { + type: { enumerable: true }, + description: { enumerable: true }, + suffixes: { enumerable: true }, + enabledPlugin: { enumerable: true }, + [Symbol.toStringTag]: { value: "MimeType", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = MimeType; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: MimeType + }); +}; + +const Impl = require("../navigator/MimeType-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/MimeTypeArray.js b/node_modules/jsdom/lib/jsdom/living/generated/MimeTypeArray.js new file mode 100644 index 000000000..9f686e505 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/MimeTypeArray.js @@ -0,0 +1,330 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "MimeTypeArray"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'MimeTypeArray'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["MimeTypeArray"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor MimeTypeArray is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + let wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class MimeTypeArray { + constructor() { + throw new TypeError("Illegal constructor"); + } + + item(index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'item' called on an object that is not a valid instance of MimeTypeArray."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'item' on 'MimeTypeArray': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'item' on 'MimeTypeArray': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].item(...args); + } + + namedItem(name) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'namedItem' called on an object that is not a valid instance of MimeTypeArray."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'namedItem' on 'MimeTypeArray': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'namedItem' on 'MimeTypeArray': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].namedItem(...args); + } + + get length() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get length' called on an object that is not a valid instance of MimeTypeArray."); + } + + return esValue[implSymbol]["length"]; + } + } + Object.defineProperties(MimeTypeArray.prototype, { + item: { enumerable: true }, + namedItem: { enumerable: true }, + length: { enumerable: true }, + [Symbol.toStringTag]: { value: "MimeTypeArray", configurable: true }, + [Symbol.iterator]: { value: Array.prototype[Symbol.iterator], configurable: true, writable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = MimeTypeArray; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: MimeTypeArray + }); +}; + +const proxyHandler = { + get(target, P, receiver) { + if (typeof P === "symbol") { + return Reflect.get(target, P, receiver); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc === undefined) { + const parent = Object.getPrototypeOf(target); + if (parent === null) { + return undefined; + } + return Reflect.get(target, P, receiver); + } + if (!desc.get && !desc.set) { + return desc.value; + } + const getter = desc.get; + if (getter === undefined) { + return undefined; + } + return Reflect.apply(getter, receiver, []); + }, + + has(target, P) { + if (typeof P === "symbol") { + return Reflect.has(target, P); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc !== undefined) { + return true; + } + const parent = Object.getPrototypeOf(target); + if (parent !== null) { + return Reflect.has(parent, P); + } + return false; + }, + + ownKeys(target) { + const keys = new Set(); + + for (const key of target[implSymbol][utils.supportedPropertyIndices]) { + keys.add(`${key}`); + } + + for (const key of Reflect.ownKeys(target)) { + keys.add(key); + } + return [...keys]; + }, + + getOwnPropertyDescriptor(target, P) { + if (typeof P === "symbol") { + return Reflect.getOwnPropertyDescriptor(target, P); + } + let ignoreNamedProps = false; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + return { + writable: false, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + ignoreNamedProps = true; + } + + return Reflect.getOwnPropertyDescriptor(target, P); + }, + + set(target, P, V, receiver) { + if (typeof P === "symbol") { + return Reflect.set(target, P, V, receiver); + } + // The `receiver` argument refers to the Proxy exotic object or an object + // that inherits from it, whereas `target` refers to the Proxy target: + if (target[implSymbol][utils.wrapperSymbol] === receiver) { + } + let ownDesc; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + ownDesc = { + writable: false, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + } + + if (ownDesc === undefined) { + ownDesc = Reflect.getOwnPropertyDescriptor(target, P); + } + if (ownDesc === undefined) { + const parent = Reflect.getPrototypeOf(target); + if (parent !== null) { + return Reflect.set(parent, P, V, receiver); + } + ownDesc = { writable: true, enumerable: true, configurable: true, value: undefined }; + } + if (!ownDesc.writable) { + return false; + } + if (!utils.isObject(receiver)) { + return false; + } + const existingDesc = Reflect.getOwnPropertyDescriptor(receiver, P); + let valueDesc; + if (existingDesc !== undefined) { + if (existingDesc.get || existingDesc.set) { + return false; + } + if (!existingDesc.writable) { + return false; + } + valueDesc = { value: V }; + } else { + valueDesc = { writable: true, enumerable: true, configurable: true, value: V }; + } + return Reflect.defineProperty(receiver, P, valueDesc); + }, + + defineProperty(target, P, desc) { + if (typeof P === "symbol") { + return Reflect.defineProperty(target, P, desc); + } + + if (utils.isArrayIndexPropName(P)) { + return false; + } + + return Reflect.defineProperty(target, P, desc); + }, + + deleteProperty(target, P) { + if (typeof P === "symbol") { + return Reflect.deleteProperty(target, P); + } + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + return !(target[implSymbol].item(index) !== null); + } + + return Reflect.deleteProperty(target, P); + }, + + preventExtensions() { + return false; + } +}; + +const Impl = require("../navigator/MimeTypeArray-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/MouseEvent.js b/node_modules/jsdom/lib/jsdom/living/generated/MouseEvent.js new file mode 100644 index 000000000..61d008d86 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/MouseEvent.js @@ -0,0 +1,463 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const MouseEventInit = require("./MouseEventInit.js"); +const EventTarget = require("./EventTarget.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const UIEvent = require("./UIEvent.js"); + +const interfaceName = "MouseEvent"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'MouseEvent'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["MouseEvent"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor MouseEvent is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + UIEvent._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.UIEvent === undefined) { + throw new Error("Internal error: attempting to evaluate MouseEvent before UIEvent"); + } + class MouseEvent extends globalObject.UIEvent { + constructor(type) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'MouseEvent': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'MouseEvent': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = MouseEventInit.convert(curArg, { context: "Failed to construct 'MouseEvent': parameter 2" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + getModifierState(keyArg) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getModifierState' called on an object that is not a valid instance of MouseEvent."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'getModifierState' on 'MouseEvent': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getModifierState' on 'MouseEvent': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].getModifierState(...args); + } + + initMouseEvent(typeArg) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'initMouseEvent' called on an object that is not a valid instance of MouseEvent."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'initMouseEvent' on 'MouseEvent': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'initMouseEvent' on 'MouseEvent': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initMouseEvent' on 'MouseEvent': parameter 2" + }); + } else { + curArg = false; + } + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initMouseEvent' on 'MouseEvent': parameter 3" + }); + } else { + curArg = false; + } + args.push(curArg); + } + { + let curArg = arguments[3]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = utils.tryImplForWrapper(curArg); + } + } else { + curArg = null; + } + args.push(curArg); + } + { + let curArg = arguments[4]; + if (curArg !== undefined) { + curArg = conversions["long"](curArg, { + context: "Failed to execute 'initMouseEvent' on 'MouseEvent': parameter 5" + }); + } else { + curArg = 0; + } + args.push(curArg); + } + { + let curArg = arguments[5]; + if (curArg !== undefined) { + curArg = conversions["long"](curArg, { + context: "Failed to execute 'initMouseEvent' on 'MouseEvent': parameter 6" + }); + } else { + curArg = 0; + } + args.push(curArg); + } + { + let curArg = arguments[6]; + if (curArg !== undefined) { + curArg = conversions["long"](curArg, { + context: "Failed to execute 'initMouseEvent' on 'MouseEvent': parameter 7" + }); + } else { + curArg = 0; + } + args.push(curArg); + } + { + let curArg = arguments[7]; + if (curArg !== undefined) { + curArg = conversions["long"](curArg, { + context: "Failed to execute 'initMouseEvent' on 'MouseEvent': parameter 8" + }); + } else { + curArg = 0; + } + args.push(curArg); + } + { + let curArg = arguments[8]; + if (curArg !== undefined) { + curArg = conversions["long"](curArg, { + context: "Failed to execute 'initMouseEvent' on 'MouseEvent': parameter 9" + }); + } else { + curArg = 0; + } + args.push(curArg); + } + { + let curArg = arguments[9]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initMouseEvent' on 'MouseEvent': parameter 10" + }); + } else { + curArg = 0; + } + args.push(curArg); + } + { + let curArg = arguments[10]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initMouseEvent' on 'MouseEvent': parameter 11" + }); + } else { + curArg = 0; + } + args.push(curArg); + } + { + let curArg = arguments[11]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initMouseEvent' on 'MouseEvent': parameter 12" + }); + } else { + curArg = 0; + } + args.push(curArg); + } + { + let curArg = arguments[12]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initMouseEvent' on 'MouseEvent': parameter 13" + }); + } else { + curArg = 0; + } + args.push(curArg); + } + { + let curArg = arguments[13]; + if (curArg !== undefined) { + curArg = conversions["short"](curArg, { + context: "Failed to execute 'initMouseEvent' on 'MouseEvent': parameter 14" + }); + } else { + curArg = 0; + } + args.push(curArg); + } + { + let curArg = arguments[14]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = EventTarget.convert(curArg, { + context: "Failed to execute 'initMouseEvent' on 'MouseEvent': parameter 15" + }); + } + } else { + curArg = null; + } + args.push(curArg); + } + return esValue[implSymbol].initMouseEvent(...args); + } + + get screenX() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get screenX' called on an object that is not a valid instance of MouseEvent."); + } + + return esValue[implSymbol]["screenX"]; + } + + get screenY() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get screenY' called on an object that is not a valid instance of MouseEvent."); + } + + return esValue[implSymbol]["screenY"]; + } + + get clientX() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get clientX' called on an object that is not a valid instance of MouseEvent."); + } + + return esValue[implSymbol]["clientX"]; + } + + get clientY() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get clientY' called on an object that is not a valid instance of MouseEvent."); + } + + return esValue[implSymbol]["clientY"]; + } + + get ctrlKey() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ctrlKey' called on an object that is not a valid instance of MouseEvent."); + } + + return esValue[implSymbol]["ctrlKey"]; + } + + get shiftKey() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get shiftKey' called on an object that is not a valid instance of MouseEvent."); + } + + return esValue[implSymbol]["shiftKey"]; + } + + get altKey() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get altKey' called on an object that is not a valid instance of MouseEvent."); + } + + return esValue[implSymbol]["altKey"]; + } + + get metaKey() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get metaKey' called on an object that is not a valid instance of MouseEvent."); + } + + return esValue[implSymbol]["metaKey"]; + } + + get button() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get button' called on an object that is not a valid instance of MouseEvent."); + } + + return esValue[implSymbol]["button"]; + } + + get buttons() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get buttons' called on an object that is not a valid instance of MouseEvent."); + } + + return esValue[implSymbol]["buttons"]; + } + + get relatedTarget() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get relatedTarget' called on an object that is not a valid instance of MouseEvent."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["relatedTarget"]); + } + } + Object.defineProperties(MouseEvent.prototype, { + getModifierState: { enumerable: true }, + initMouseEvent: { enumerable: true }, + screenX: { enumerable: true }, + screenY: { enumerable: true }, + clientX: { enumerable: true }, + clientY: { enumerable: true }, + ctrlKey: { enumerable: true }, + shiftKey: { enumerable: true }, + altKey: { enumerable: true }, + metaKey: { enumerable: true }, + button: { enumerable: true }, + buttons: { enumerable: true }, + relatedTarget: { enumerable: true }, + [Symbol.toStringTag]: { value: "MouseEvent", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = MouseEvent; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: MouseEvent + }); +}; + +const Impl = require("../events/MouseEvent-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/MouseEventInit.js b/node_modules/jsdom/lib/jsdom/living/generated/MouseEventInit.js new file mode 100644 index 000000000..f49c8a679 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/MouseEventInit.js @@ -0,0 +1,108 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventTarget = require("./EventTarget.js"); +const EventModifierInit = require("./EventModifierInit.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + EventModifierInit._convertInherit(obj, ret, { context }); + + { + const key = "button"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["short"](value, { context: context + " has member 'button' that" }); + + ret[key] = value; + } else { + ret[key] = 0; + } + } + + { + const key = "buttons"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["unsigned short"](value, { context: context + " has member 'buttons' that" }); + + ret[key] = value; + } else { + ret[key] = 0; + } + } + + { + const key = "clientX"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["long"](value, { context: context + " has member 'clientX' that" }); + + ret[key] = value; + } else { + ret[key] = 0; + } + } + + { + const key = "clientY"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["long"](value, { context: context + " has member 'clientY' that" }); + + ret[key] = value; + } else { + ret[key] = 0; + } + } + + { + const key = "relatedTarget"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + if (value === null || value === undefined) { + value = null; + } else { + value = EventTarget.convert(value, { context: context + " has member 'relatedTarget' that" }); + } + ret[key] = value; + } else { + ret[key] = null; + } + } + + { + const key = "screenX"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["long"](value, { context: context + " has member 'screenX' that" }); + + ret[key] = value; + } else { + ret[key] = 0; + } + } + + { + const key = "screenY"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["long"](value, { context: context + " has member 'screenY' that" }); + + ret[key] = value; + } else { + ret[key] = 0; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/MutationCallback.js b/node_modules/jsdom/lib/jsdom/living/generated/MutationCallback.js new file mode 100644 index 000000000..c3deb23e2 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/MutationCallback.js @@ -0,0 +1,38 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +exports.convert = (value, { context = "The provided value" } = {}) => { + if (typeof value !== "function") { + throw new TypeError(context + " is not a function"); + } + + function invokeTheCallbackFunction(mutations, observer) { + if (new.target !== undefined) { + throw new Error("Internal error: invokeTheCallbackFunction is not a constructor"); + } + + const thisArg = utils.tryWrapperForImpl(this); + let callResult; + + mutations = utils.tryWrapperForImpl(mutations); + + observer = utils.tryWrapperForImpl(observer); + + callResult = Reflect.apply(value, thisArg, [mutations, observer]); + } + + invokeTheCallbackFunction.construct = (mutations, observer) => { + mutations = utils.tryWrapperForImpl(mutations); + + observer = utils.tryWrapperForImpl(observer); + + let callResult = Reflect.construct(value, [mutations, observer]); + }; + + invokeTheCallbackFunction[utils.wrapperSymbol] = value; + invokeTheCallbackFunction.objectReference = value; + + return invokeTheCallbackFunction; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/MutationObserver.js b/node_modules/jsdom/lib/jsdom/living/generated/MutationObserver.js new file mode 100644 index 000000000..56c7a2b96 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/MutationObserver.js @@ -0,0 +1,171 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const MutationCallback = require("./MutationCallback.js"); +const Node = require("./Node.js"); +const MutationObserverInit = require("./MutationObserverInit.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "MutationObserver"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'MutationObserver'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["MutationObserver"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor MutationObserver is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class MutationObserver { + constructor(callback) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'MutationObserver': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = MutationCallback.convert(curArg, { context: "Failed to construct 'MutationObserver': parameter 1" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + observe(target) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'observe' called on an object that is not a valid instance of MutationObserver."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'observe' on 'MutationObserver': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'observe' on 'MutationObserver': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = MutationObserverInit.convert(curArg, { + context: "Failed to execute 'observe' on 'MutationObserver': parameter 2" + }); + args.push(curArg); + } + return esValue[implSymbol].observe(...args); + } + + disconnect() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'disconnect' called on an object that is not a valid instance of MutationObserver."); + } + + return esValue[implSymbol].disconnect(); + } + + takeRecords() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'takeRecords' called on an object that is not a valid instance of MutationObserver."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].takeRecords()); + } + } + Object.defineProperties(MutationObserver.prototype, { + observe: { enumerable: true }, + disconnect: { enumerable: true }, + takeRecords: { enumerable: true }, + [Symbol.toStringTag]: { value: "MutationObserver", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = MutationObserver; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: MutationObserver + }); +}; + +const Impl = require("../mutation-observer/MutationObserver-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/MutationObserverInit.js b/node_modules/jsdom/lib/jsdom/living/generated/MutationObserverInit.js new file mode 100644 index 000000000..424c8e06c --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/MutationObserverInit.js @@ -0,0 +1,103 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + { + const key = "attributeFilter"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + if (!utils.isObject(value)) { + throw new TypeError(context + " has member 'attributeFilter' that" + " is not an iterable object."); + } else { + const V = []; + const tmp = value; + for (let nextItem of tmp) { + nextItem = conversions["DOMString"](nextItem, { + context: context + " has member 'attributeFilter' that" + "'s element" + }); + + V.push(nextItem); + } + value = V; + } + + ret[key] = value; + } + } + + { + const key = "attributeOldValue"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'attributeOldValue' that" }); + + ret[key] = value; + } + } + + { + const key = "attributes"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'attributes' that" }); + + ret[key] = value; + } + } + + { + const key = "characterData"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'characterData' that" }); + + ret[key] = value; + } + } + + { + const key = "characterDataOldValue"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'characterDataOldValue' that" }); + + ret[key] = value; + } + } + + { + const key = "childList"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'childList' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "subtree"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'subtree' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/MutationRecord.js b/node_modules/jsdom/lib/jsdom/living/generated/MutationRecord.js new file mode 100644 index 000000000..8c28778e7 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/MutationRecord.js @@ -0,0 +1,216 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "MutationRecord"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'MutationRecord'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["MutationRecord"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor MutationRecord is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class MutationRecord { + constructor() { + throw new TypeError("Illegal constructor"); + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of MutationRecord."); + } + + return esValue[implSymbol]["type"]; + } + + get target() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get target' called on an object that is not a valid instance of MutationRecord."); + } + + return utils.getSameObject(this, "target", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["target"]); + }); + } + + get addedNodes() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get addedNodes' called on an object that is not a valid instance of MutationRecord."); + } + + return utils.getSameObject(this, "addedNodes", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["addedNodes"]); + }); + } + + get removedNodes() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get removedNodes' called on an object that is not a valid instance of MutationRecord."); + } + + return utils.getSameObject(this, "removedNodes", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["removedNodes"]); + }); + } + + get previousSibling() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get previousSibling' called on an object that is not a valid instance of MutationRecord." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["previousSibling"]); + } + + get nextSibling() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get nextSibling' called on an object that is not a valid instance of MutationRecord."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["nextSibling"]); + } + + get attributeName() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get attributeName' called on an object that is not a valid instance of MutationRecord."); + } + + return esValue[implSymbol]["attributeName"]; + } + + get attributeNamespace() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get attributeNamespace' called on an object that is not a valid instance of MutationRecord." + ); + } + + return esValue[implSymbol]["attributeNamespace"]; + } + + get oldValue() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oldValue' called on an object that is not a valid instance of MutationRecord."); + } + + return esValue[implSymbol]["oldValue"]; + } + } + Object.defineProperties(MutationRecord.prototype, { + type: { enumerable: true }, + target: { enumerable: true }, + addedNodes: { enumerable: true }, + removedNodes: { enumerable: true }, + previousSibling: { enumerable: true }, + nextSibling: { enumerable: true }, + attributeName: { enumerable: true }, + attributeNamespace: { enumerable: true }, + oldValue: { enumerable: true }, + [Symbol.toStringTag]: { value: "MutationRecord", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = MutationRecord; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: MutationRecord + }); +}; + +const Impl = require("../mutation-observer/MutationRecord-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/NamedNodeMap.js b/node_modules/jsdom/lib/jsdom/living/generated/NamedNodeMap.js new file mode 100644 index 000000000..4cb92d17d --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/NamedNodeMap.js @@ -0,0 +1,522 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const Attr = require("./Attr.js"); +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "NamedNodeMap"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'NamedNodeMap'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["NamedNodeMap"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor NamedNodeMap is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + let wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class NamedNodeMap { + constructor() { + throw new TypeError("Illegal constructor"); + } + + item(index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'item' called on an object that is not a valid instance of NamedNodeMap."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'item' on 'NamedNodeMap': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'item' on 'NamedNodeMap': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].item(...args)); + } + + getNamedItem(qualifiedName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getNamedItem' called on an object that is not a valid instance of NamedNodeMap."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'getNamedItem' on 'NamedNodeMap': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getNamedItem' on 'NamedNodeMap': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].getNamedItem(...args)); + } + + getNamedItemNS(namespace, localName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getNamedItemNS' called on an object that is not a valid instance of NamedNodeMap."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'getNamedItemNS' on 'NamedNodeMap': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getNamedItemNS' on 'NamedNodeMap': parameter 1" + }); + } + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getNamedItemNS' on 'NamedNodeMap': parameter 2" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].getNamedItemNS(...args)); + } + + setNamedItem(attr) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'setNamedItem' called on an object that is not a valid instance of NamedNodeMap."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'setNamedItem' on 'NamedNodeMap': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Attr.convert(curArg, { context: "Failed to execute 'setNamedItem' on 'NamedNodeMap': parameter 1" }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].setNamedItem(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + setNamedItemNS(attr) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'setNamedItemNS' called on an object that is not a valid instance of NamedNodeMap."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'setNamedItemNS' on 'NamedNodeMap': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Attr.convert(curArg, { context: "Failed to execute 'setNamedItemNS' on 'NamedNodeMap': parameter 1" }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].setNamedItemNS(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + removeNamedItem(qualifiedName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'removeNamedItem' called on an object that is not a valid instance of NamedNodeMap."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'removeNamedItem' on 'NamedNodeMap': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'removeNamedItem' on 'NamedNodeMap': parameter 1" + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].removeNamedItem(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + removeNamedItemNS(namespace, localName) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'removeNamedItemNS' called on an object that is not a valid instance of NamedNodeMap."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'removeNamedItemNS' on 'NamedNodeMap': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'removeNamedItemNS' on 'NamedNodeMap': parameter 1" + }); + } + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'removeNamedItemNS' on 'NamedNodeMap': parameter 2" + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].removeNamedItemNS(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get length() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get length' called on an object that is not a valid instance of NamedNodeMap."); + } + + return esValue[implSymbol]["length"]; + } + } + Object.defineProperties(NamedNodeMap.prototype, { + item: { enumerable: true }, + getNamedItem: { enumerable: true }, + getNamedItemNS: { enumerable: true }, + setNamedItem: { enumerable: true }, + setNamedItemNS: { enumerable: true }, + removeNamedItem: { enumerable: true }, + removeNamedItemNS: { enumerable: true }, + length: { enumerable: true }, + [Symbol.toStringTag]: { value: "NamedNodeMap", configurable: true }, + [Symbol.iterator]: { value: Array.prototype[Symbol.iterator], configurable: true, writable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = NamedNodeMap; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: NamedNodeMap + }); +}; + +const proxyHandler = { + get(target, P, receiver) { + if (typeof P === "symbol") { + return Reflect.get(target, P, receiver); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc === undefined) { + const parent = Object.getPrototypeOf(target); + if (parent === null) { + return undefined; + } + return Reflect.get(target, P, receiver); + } + if (!desc.get && !desc.set) { + return desc.value; + } + const getter = desc.get; + if (getter === undefined) { + return undefined; + } + return Reflect.apply(getter, receiver, []); + }, + + has(target, P) { + if (typeof P === "symbol") { + return Reflect.has(target, P); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc !== undefined) { + return true; + } + const parent = Object.getPrototypeOf(target); + if (parent !== null) { + return Reflect.has(parent, P); + } + return false; + }, + + ownKeys(target) { + const keys = new Set(); + + for (const key of target[implSymbol][utils.supportedPropertyIndices]) { + keys.add(`${key}`); + } + + for (const key of target[implSymbol][utils.supportedPropertyNames]) { + if (!(key in target)) { + keys.add(`${key}`); + } + } + + for (const key of Reflect.ownKeys(target)) { + keys.add(key); + } + return [...keys]; + }, + + getOwnPropertyDescriptor(target, P) { + if (typeof P === "symbol") { + return Reflect.getOwnPropertyDescriptor(target, P); + } + let ignoreNamedProps = false; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + return { + writable: false, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + ignoreNamedProps = true; + } + + const namedValue = target[implSymbol].getNamedItem(P); + + if (namedValue !== null && !(P in target) && !ignoreNamedProps) { + return { + writable: false, + enumerable: false, + configurable: true, + value: utils.tryWrapperForImpl(namedValue) + }; + } + + return Reflect.getOwnPropertyDescriptor(target, P); + }, + + set(target, P, V, receiver) { + if (typeof P === "symbol") { + return Reflect.set(target, P, V, receiver); + } + // The `receiver` argument refers to the Proxy exotic object or an object + // that inherits from it, whereas `target` refers to the Proxy target: + if (target[implSymbol][utils.wrapperSymbol] === receiver) { + } + let ownDesc; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + ownDesc = { + writable: false, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + } + + if (ownDesc === undefined) { + ownDesc = Reflect.getOwnPropertyDescriptor(target, P); + } + if (ownDesc === undefined) { + const parent = Reflect.getPrototypeOf(target); + if (parent !== null) { + return Reflect.set(parent, P, V, receiver); + } + ownDesc = { writable: true, enumerable: true, configurable: true, value: undefined }; + } + if (!ownDesc.writable) { + return false; + } + if (!utils.isObject(receiver)) { + return false; + } + const existingDesc = Reflect.getOwnPropertyDescriptor(receiver, P); + let valueDesc; + if (existingDesc !== undefined) { + if (existingDesc.get || existingDesc.set) { + return false; + } + if (!existingDesc.writable) { + return false; + } + valueDesc = { value: V }; + } else { + valueDesc = { writable: true, enumerable: true, configurable: true, value: V }; + } + return Reflect.defineProperty(receiver, P, valueDesc); + }, + + defineProperty(target, P, desc) { + if (typeof P === "symbol") { + return Reflect.defineProperty(target, P, desc); + } + + if (utils.isArrayIndexPropName(P)) { + return false; + } + if (!utils.hasOwn(target, P)) { + const creating = !(target[implSymbol].getNamedItem(P) !== null); + if (!creating) { + return false; + } + } + return Reflect.defineProperty(target, P, desc); + }, + + deleteProperty(target, P) { + if (typeof P === "symbol") { + return Reflect.deleteProperty(target, P); + } + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + return !(target[implSymbol].item(index) !== null); + } + + if (target[implSymbol].getNamedItem(P) !== null && !(P in target)) { + return false; + } + + return Reflect.deleteProperty(target, P); + }, + + preventExtensions() { + return false; + } +}; + +const Impl = require("../attributes/NamedNodeMap-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/Navigator.js b/node_modules/jsdom/lib/jsdom/living/generated/Navigator.js new file mode 100644 index 000000000..6ecc74bf0 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/Navigator.js @@ -0,0 +1,297 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "Navigator"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'Navigator'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["Navigator"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor Navigator is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class Navigator { + constructor() { + throw new TypeError("Illegal constructor"); + } + + javaEnabled() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'javaEnabled' called on an object that is not a valid instance of Navigator."); + } + + return esValue[implSymbol].javaEnabled(); + } + + get appCodeName() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get appCodeName' called on an object that is not a valid instance of Navigator."); + } + + return esValue[implSymbol]["appCodeName"]; + } + + get appName() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get appName' called on an object that is not a valid instance of Navigator."); + } + + return esValue[implSymbol]["appName"]; + } + + get appVersion() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get appVersion' called on an object that is not a valid instance of Navigator."); + } + + return esValue[implSymbol]["appVersion"]; + } + + get platform() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get platform' called on an object that is not a valid instance of Navigator."); + } + + return esValue[implSymbol]["platform"]; + } + + get product() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get product' called on an object that is not a valid instance of Navigator."); + } + + return esValue[implSymbol]["product"]; + } + + get productSub() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get productSub' called on an object that is not a valid instance of Navigator."); + } + + return esValue[implSymbol]["productSub"]; + } + + get userAgent() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get userAgent' called on an object that is not a valid instance of Navigator."); + } + + return esValue[implSymbol]["userAgent"]; + } + + get vendor() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get vendor' called on an object that is not a valid instance of Navigator."); + } + + return esValue[implSymbol]["vendor"]; + } + + get vendorSub() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get vendorSub' called on an object that is not a valid instance of Navigator."); + } + + return esValue[implSymbol]["vendorSub"]; + } + + get language() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get language' called on an object that is not a valid instance of Navigator."); + } + + return esValue[implSymbol]["language"]; + } + + get languages() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get languages' called on an object that is not a valid instance of Navigator."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["languages"]); + } + + get onLine() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onLine' called on an object that is not a valid instance of Navigator."); + } + + return esValue[implSymbol]["onLine"]; + } + + get cookieEnabled() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get cookieEnabled' called on an object that is not a valid instance of Navigator."); + } + + return esValue[implSymbol]["cookieEnabled"]; + } + + get plugins() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get plugins' called on an object that is not a valid instance of Navigator."); + } + + return utils.getSameObject(this, "plugins", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["plugins"]); + }); + } + + get mimeTypes() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get mimeTypes' called on an object that is not a valid instance of Navigator."); + } + + return utils.getSameObject(this, "mimeTypes", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["mimeTypes"]); + }); + } + + get hardwareConcurrency() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get hardwareConcurrency' called on an object that is not a valid instance of Navigator."); + } + + return esValue[implSymbol]["hardwareConcurrency"]; + } + } + Object.defineProperties(Navigator.prototype, { + javaEnabled: { enumerable: true }, + appCodeName: { enumerable: true }, + appName: { enumerable: true }, + appVersion: { enumerable: true }, + platform: { enumerable: true }, + product: { enumerable: true }, + productSub: { enumerable: true }, + userAgent: { enumerable: true }, + vendor: { enumerable: true }, + vendorSub: { enumerable: true }, + language: { enumerable: true }, + languages: { enumerable: true }, + onLine: { enumerable: true }, + cookieEnabled: { enumerable: true }, + plugins: { enumerable: true }, + mimeTypes: { enumerable: true }, + hardwareConcurrency: { enumerable: true }, + [Symbol.toStringTag]: { value: "Navigator", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = Navigator; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: Navigator + }); +}; + +const Impl = require("../navigator/Navigator-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/Node.js b/node_modules/jsdom/lib/jsdom/living/generated/Node.js new file mode 100644 index 000000000..3d211f21b --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/Node.js @@ -0,0 +1,736 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const GetRootNodeOptions = require("./GetRootNodeOptions.js"); +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const EventTarget = require("./EventTarget.js"); + +const interfaceName = "Node"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'Node'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["Node"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor Node is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + EventTarget._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.EventTarget === undefined) { + throw new Error("Internal error: attempting to evaluate Node before EventTarget"); + } + class Node extends globalObject.EventTarget { + constructor() { + throw new TypeError("Illegal constructor"); + } + + getRootNode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getRootNode' called on an object that is not a valid instance of Node."); + } + const args = []; + { + let curArg = arguments[0]; + curArg = GetRootNodeOptions.convert(curArg, { + context: "Failed to execute 'getRootNode' on 'Node': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].getRootNode(...args)); + } + + hasChildNodes() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'hasChildNodes' called on an object that is not a valid instance of Node."); + } + + return esValue[implSymbol].hasChildNodes(); + } + + normalize() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'normalize' called on an object that is not a valid instance of Node."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].normalize(); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + cloneNode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'cloneNode' called on an object that is not a valid instance of Node."); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { context: "Failed to execute 'cloneNode' on 'Node': parameter 1" }); + } else { + curArg = false; + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].cloneNode(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + isEqualNode(otherNode) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'isEqualNode' called on an object that is not a valid instance of Node."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'isEqualNode' on 'Node': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = exports.convert(curArg, { context: "Failed to execute 'isEqualNode' on 'Node': parameter 1" }); + } + args.push(curArg); + } + return esValue[implSymbol].isEqualNode(...args); + } + + isSameNode(otherNode) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'isSameNode' called on an object that is not a valid instance of Node."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'isSameNode' on 'Node': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = exports.convert(curArg, { context: "Failed to execute 'isSameNode' on 'Node': parameter 1" }); + } + args.push(curArg); + } + return esValue[implSymbol].isSameNode(...args); + } + + compareDocumentPosition(other) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'compareDocumentPosition' called on an object that is not a valid instance of Node."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'compareDocumentPosition' on 'Node': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = exports.convert(curArg, { + context: "Failed to execute 'compareDocumentPosition' on 'Node': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].compareDocumentPosition(...args); + } + + contains(other) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'contains' called on an object that is not a valid instance of Node."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'contains' on 'Node': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = exports.convert(curArg, { context: "Failed to execute 'contains' on 'Node': parameter 1" }); + } + args.push(curArg); + } + return esValue[implSymbol].contains(...args); + } + + lookupPrefix(namespace) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'lookupPrefix' called on an object that is not a valid instance of Node."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'lookupPrefix' on 'Node': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'lookupPrefix' on 'Node': parameter 1" + }); + } + args.push(curArg); + } + return esValue[implSymbol].lookupPrefix(...args); + } + + lookupNamespaceURI(prefix) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'lookupNamespaceURI' called on an object that is not a valid instance of Node."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'lookupNamespaceURI' on 'Node': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'lookupNamespaceURI' on 'Node': parameter 1" + }); + } + args.push(curArg); + } + return esValue[implSymbol].lookupNamespaceURI(...args); + } + + isDefaultNamespace(namespace) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'isDefaultNamespace' called on an object that is not a valid instance of Node."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'isDefaultNamespace' on 'Node': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'isDefaultNamespace' on 'Node': parameter 1" + }); + } + args.push(curArg); + } + return esValue[implSymbol].isDefaultNamespace(...args); + } + + insertBefore(node, child) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'insertBefore' called on an object that is not a valid instance of Node."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'insertBefore' on 'Node': 2 arguments required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = exports.convert(curArg, { context: "Failed to execute 'insertBefore' on 'Node': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = exports.convert(curArg, { context: "Failed to execute 'insertBefore' on 'Node': parameter 2" }); + } + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].insertBefore(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + appendChild(node) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'appendChild' called on an object that is not a valid instance of Node."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'appendChild' on 'Node': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = exports.convert(curArg, { context: "Failed to execute 'appendChild' on 'Node': parameter 1" }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].appendChild(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + replaceChild(node, child) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'replaceChild' called on an object that is not a valid instance of Node."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'replaceChild' on 'Node': 2 arguments required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = exports.convert(curArg, { context: "Failed to execute 'replaceChild' on 'Node': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = exports.convert(curArg, { context: "Failed to execute 'replaceChild' on 'Node': parameter 2" }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].replaceChild(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + removeChild(child) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'removeChild' called on an object that is not a valid instance of Node."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'removeChild' on 'Node': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = exports.convert(curArg, { context: "Failed to execute 'removeChild' on 'Node': parameter 1" }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].removeChild(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get nodeType() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get nodeType' called on an object that is not a valid instance of Node."); + } + + return esValue[implSymbol]["nodeType"]; + } + + get nodeName() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get nodeName' called on an object that is not a valid instance of Node."); + } + + return esValue[implSymbol]["nodeName"]; + } + + get baseURI() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get baseURI' called on an object that is not a valid instance of Node."); + } + + return esValue[implSymbol]["baseURI"]; + } + + get isConnected() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get isConnected' called on an object that is not a valid instance of Node."); + } + + return esValue[implSymbol]["isConnected"]; + } + + get ownerDocument() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ownerDocument' called on an object that is not a valid instance of Node."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ownerDocument"]); + } + + get parentNode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get parentNode' called on an object that is not a valid instance of Node."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["parentNode"]); + } + + get parentElement() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get parentElement' called on an object that is not a valid instance of Node."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["parentElement"]); + } + + get childNodes() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get childNodes' called on an object that is not a valid instance of Node."); + } + + return utils.getSameObject(this, "childNodes", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["childNodes"]); + }); + } + + get firstChild() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get firstChild' called on an object that is not a valid instance of Node."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["firstChild"]); + } + + get lastChild() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get lastChild' called on an object that is not a valid instance of Node."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["lastChild"]); + } + + get previousSibling() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get previousSibling' called on an object that is not a valid instance of Node."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["previousSibling"]); + } + + get nextSibling() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get nextSibling' called on an object that is not a valid instance of Node."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["nextSibling"]); + } + + get nodeValue() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get nodeValue' called on an object that is not a valid instance of Node."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["nodeValue"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set nodeValue(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set nodeValue' called on an object that is not a valid instance of Node."); + } + + if (V === null || V === undefined) { + V = null; + } else { + V = conversions["DOMString"](V, { + context: "Failed to set the 'nodeValue' property on 'Node': The provided value" + }); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["nodeValue"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get textContent() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get textContent' called on an object that is not a valid instance of Node."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["textContent"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set textContent(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set textContent' called on an object that is not a valid instance of Node."); + } + + if (V === null || V === undefined) { + V = null; + } else { + V = conversions["DOMString"](V, { + context: "Failed to set the 'textContent' property on 'Node': The provided value" + }); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["textContent"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(Node.prototype, { + getRootNode: { enumerable: true }, + hasChildNodes: { enumerable: true }, + normalize: { enumerable: true }, + cloneNode: { enumerable: true }, + isEqualNode: { enumerable: true }, + isSameNode: { enumerable: true }, + compareDocumentPosition: { enumerable: true }, + contains: { enumerable: true }, + lookupPrefix: { enumerable: true }, + lookupNamespaceURI: { enumerable: true }, + isDefaultNamespace: { enumerable: true }, + insertBefore: { enumerable: true }, + appendChild: { enumerable: true }, + replaceChild: { enumerable: true }, + removeChild: { enumerable: true }, + nodeType: { enumerable: true }, + nodeName: { enumerable: true }, + baseURI: { enumerable: true }, + isConnected: { enumerable: true }, + ownerDocument: { enumerable: true }, + parentNode: { enumerable: true }, + parentElement: { enumerable: true }, + childNodes: { enumerable: true }, + firstChild: { enumerable: true }, + lastChild: { enumerable: true }, + previousSibling: { enumerable: true }, + nextSibling: { enumerable: true }, + nodeValue: { enumerable: true }, + textContent: { enumerable: true }, + [Symbol.toStringTag]: { value: "Node", configurable: true }, + ELEMENT_NODE: { value: 1, enumerable: true }, + ATTRIBUTE_NODE: { value: 2, enumerable: true }, + TEXT_NODE: { value: 3, enumerable: true }, + CDATA_SECTION_NODE: { value: 4, enumerable: true }, + ENTITY_REFERENCE_NODE: { value: 5, enumerable: true }, + ENTITY_NODE: { value: 6, enumerable: true }, + PROCESSING_INSTRUCTION_NODE: { value: 7, enumerable: true }, + COMMENT_NODE: { value: 8, enumerable: true }, + DOCUMENT_NODE: { value: 9, enumerable: true }, + DOCUMENT_TYPE_NODE: { value: 10, enumerable: true }, + DOCUMENT_FRAGMENT_NODE: { value: 11, enumerable: true }, + NOTATION_NODE: { value: 12, enumerable: true }, + DOCUMENT_POSITION_DISCONNECTED: { value: 0x01, enumerable: true }, + DOCUMENT_POSITION_PRECEDING: { value: 0x02, enumerable: true }, + DOCUMENT_POSITION_FOLLOWING: { value: 0x04, enumerable: true }, + DOCUMENT_POSITION_CONTAINS: { value: 0x08, enumerable: true }, + DOCUMENT_POSITION_CONTAINED_BY: { value: 0x10, enumerable: true }, + DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC: { value: 0x20, enumerable: true } + }); + Object.defineProperties(Node, { + ELEMENT_NODE: { value: 1, enumerable: true }, + ATTRIBUTE_NODE: { value: 2, enumerable: true }, + TEXT_NODE: { value: 3, enumerable: true }, + CDATA_SECTION_NODE: { value: 4, enumerable: true }, + ENTITY_REFERENCE_NODE: { value: 5, enumerable: true }, + ENTITY_NODE: { value: 6, enumerable: true }, + PROCESSING_INSTRUCTION_NODE: { value: 7, enumerable: true }, + COMMENT_NODE: { value: 8, enumerable: true }, + DOCUMENT_NODE: { value: 9, enumerable: true }, + DOCUMENT_TYPE_NODE: { value: 10, enumerable: true }, + DOCUMENT_FRAGMENT_NODE: { value: 11, enumerable: true }, + NOTATION_NODE: { value: 12, enumerable: true }, + DOCUMENT_POSITION_DISCONNECTED: { value: 0x01, enumerable: true }, + DOCUMENT_POSITION_PRECEDING: { value: 0x02, enumerable: true }, + DOCUMENT_POSITION_FOLLOWING: { value: 0x04, enumerable: true }, + DOCUMENT_POSITION_CONTAINS: { value: 0x08, enumerable: true }, + DOCUMENT_POSITION_CONTAINED_BY: { value: 0x10, enumerable: true }, + DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC: { value: 0x20, enumerable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = Node; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: Node + }); +}; + +const Impl = require("../nodes/Node-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/NodeFilter.js b/node_modules/jsdom/lib/jsdom/living/generated/NodeFilter.js new file mode 100644 index 000000000..7c53d3349 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/NodeFilter.js @@ -0,0 +1,74 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +exports.convert = function convert(value, { context = "The provided value" } = {}) { + if (!utils.isObject(value)) { + throw new TypeError(`${context} is not an object.`); + } + + function callTheUserObjectsOperation(node) { + let thisArg = utils.tryWrapperForImpl(this); + let O = value; + let X = O; + + if (typeof O !== "function") { + X = O["acceptNode"]; + if (typeof X !== "function") { + throw new TypeError(`${context} does not correctly implement NodeFilter.`); + } + thisArg = O; + } + + node = utils.tryWrapperForImpl(node); + + let callResult = Reflect.apply(X, thisArg, [node]); + + callResult = conversions["unsigned short"](callResult, { context: context }); + + return callResult; + } + + callTheUserObjectsOperation[utils.wrapperSymbol] = value; + callTheUserObjectsOperation.objectReference = value; + + return callTheUserObjectsOperation; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + const NodeFilter = () => { + throw new TypeError("Illegal invocation"); + }; + + Object.defineProperties(NodeFilter, { + FILTER_ACCEPT: { value: 1, enumerable: true }, + FILTER_REJECT: { value: 2, enumerable: true }, + FILTER_SKIP: { value: 3, enumerable: true }, + SHOW_ALL: { value: 0xffffffff, enumerable: true }, + SHOW_ELEMENT: { value: 0x1, enumerable: true }, + SHOW_ATTRIBUTE: { value: 0x2, enumerable: true }, + SHOW_TEXT: { value: 0x4, enumerable: true }, + SHOW_CDATA_SECTION: { value: 0x8, enumerable: true }, + SHOW_ENTITY_REFERENCE: { value: 0x10, enumerable: true }, + SHOW_ENTITY: { value: 0x20, enumerable: true }, + SHOW_PROCESSING_INSTRUCTION: { value: 0x40, enumerable: true }, + SHOW_COMMENT: { value: 0x80, enumerable: true }, + SHOW_DOCUMENT: { value: 0x100, enumerable: true }, + SHOW_DOCUMENT_TYPE: { value: 0x200, enumerable: true }, + SHOW_DOCUMENT_FRAGMENT: { value: 0x400, enumerable: true }, + SHOW_NOTATION: { value: 0x800, enumerable: true } + }); + + Object.defineProperty(globalObject, "NodeFilter", { + configurable: true, + writable: true, + value: NodeFilter + }); +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/NodeIterator.js b/node_modules/jsdom/lib/jsdom/living/generated/NodeIterator.js new file mode 100644 index 000000000..724d41470 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/NodeIterator.js @@ -0,0 +1,196 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "NodeIterator"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'NodeIterator'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["NodeIterator"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor NodeIterator is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class NodeIterator { + constructor() { + throw new TypeError("Illegal constructor"); + } + + nextNode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'nextNode' called on an object that is not a valid instance of NodeIterator."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].nextNode()); + } + + previousNode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'previousNode' called on an object that is not a valid instance of NodeIterator."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].previousNode()); + } + + detach() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'detach' called on an object that is not a valid instance of NodeIterator."); + } + + return esValue[implSymbol].detach(); + } + + get root() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get root' called on an object that is not a valid instance of NodeIterator."); + } + + return utils.getSameObject(this, "root", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["root"]); + }); + } + + get referenceNode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get referenceNode' called on an object that is not a valid instance of NodeIterator."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["referenceNode"]); + } + + get pointerBeforeReferenceNode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get pointerBeforeReferenceNode' called on an object that is not a valid instance of NodeIterator." + ); + } + + return esValue[implSymbol]["pointerBeforeReferenceNode"]; + } + + get whatToShow() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get whatToShow' called on an object that is not a valid instance of NodeIterator."); + } + + return esValue[implSymbol]["whatToShow"]; + } + + get filter() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get filter' called on an object that is not a valid instance of NodeIterator."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["filter"]); + } + } + Object.defineProperties(NodeIterator.prototype, { + nextNode: { enumerable: true }, + previousNode: { enumerable: true }, + detach: { enumerable: true }, + root: { enumerable: true }, + referenceNode: { enumerable: true }, + pointerBeforeReferenceNode: { enumerable: true }, + whatToShow: { enumerable: true }, + filter: { enumerable: true }, + [Symbol.toStringTag]: { value: "NodeIterator", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = NodeIterator; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: NodeIterator + }); +}; + +const Impl = require("../traversal/NodeIterator-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/NodeList.js b/node_modules/jsdom/lib/jsdom/living/generated/NodeList.js new file mode 100644 index 000000000..f71041954 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/NodeList.js @@ -0,0 +1,309 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "NodeList"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'NodeList'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["NodeList"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor NodeList is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + let wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class NodeList { + constructor() { + throw new TypeError("Illegal constructor"); + } + + item(index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'item' called on an object that is not a valid instance of NodeList."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'item' on 'NodeList': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'item' on 'NodeList': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].item(...args)); + } + + get length() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get length' called on an object that is not a valid instance of NodeList."); + } + + return esValue[implSymbol]["length"]; + } + } + Object.defineProperties(NodeList.prototype, { + item: { enumerable: true }, + length: { enumerable: true }, + [Symbol.toStringTag]: { value: "NodeList", configurable: true }, + [Symbol.iterator]: { value: Array.prototype[Symbol.iterator], configurable: true, writable: true }, + keys: { value: Array.prototype.keys, configurable: true, enumerable: true, writable: true }, + values: { value: Array.prototype[Symbol.iterator], configurable: true, enumerable: true, writable: true }, + entries: { value: Array.prototype.entries, configurable: true, enumerable: true, writable: true }, + forEach: { value: Array.prototype.forEach, configurable: true, enumerable: true, writable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = NodeList; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: NodeList + }); +}; + +const proxyHandler = { + get(target, P, receiver) { + if (typeof P === "symbol") { + return Reflect.get(target, P, receiver); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc === undefined) { + const parent = Object.getPrototypeOf(target); + if (parent === null) { + return undefined; + } + return Reflect.get(target, P, receiver); + } + if (!desc.get && !desc.set) { + return desc.value; + } + const getter = desc.get; + if (getter === undefined) { + return undefined; + } + return Reflect.apply(getter, receiver, []); + }, + + has(target, P) { + if (typeof P === "symbol") { + return Reflect.has(target, P); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc !== undefined) { + return true; + } + const parent = Object.getPrototypeOf(target); + if (parent !== null) { + return Reflect.has(parent, P); + } + return false; + }, + + ownKeys(target) { + const keys = new Set(); + + for (const key of target[implSymbol][utils.supportedPropertyIndices]) { + keys.add(`${key}`); + } + + for (const key of Reflect.ownKeys(target)) { + keys.add(key); + } + return [...keys]; + }, + + getOwnPropertyDescriptor(target, P) { + if (typeof P === "symbol") { + return Reflect.getOwnPropertyDescriptor(target, P); + } + let ignoreNamedProps = false; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + return { + writable: false, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + ignoreNamedProps = true; + } + + return Reflect.getOwnPropertyDescriptor(target, P); + }, + + set(target, P, V, receiver) { + if (typeof P === "symbol") { + return Reflect.set(target, P, V, receiver); + } + // The `receiver` argument refers to the Proxy exotic object or an object + // that inherits from it, whereas `target` refers to the Proxy target: + if (target[implSymbol][utils.wrapperSymbol] === receiver) { + } + let ownDesc; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + ownDesc = { + writable: false, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + } + + if (ownDesc === undefined) { + ownDesc = Reflect.getOwnPropertyDescriptor(target, P); + } + if (ownDesc === undefined) { + const parent = Reflect.getPrototypeOf(target); + if (parent !== null) { + return Reflect.set(parent, P, V, receiver); + } + ownDesc = { writable: true, enumerable: true, configurable: true, value: undefined }; + } + if (!ownDesc.writable) { + return false; + } + if (!utils.isObject(receiver)) { + return false; + } + const existingDesc = Reflect.getOwnPropertyDescriptor(receiver, P); + let valueDesc; + if (existingDesc !== undefined) { + if (existingDesc.get || existingDesc.set) { + return false; + } + if (!existingDesc.writable) { + return false; + } + valueDesc = { value: V }; + } else { + valueDesc = { writable: true, enumerable: true, configurable: true, value: V }; + } + return Reflect.defineProperty(receiver, P, valueDesc); + }, + + defineProperty(target, P, desc) { + if (typeof P === "symbol") { + return Reflect.defineProperty(target, P, desc); + } + + if (utils.isArrayIndexPropName(P)) { + return false; + } + + return Reflect.defineProperty(target, P, desc); + }, + + deleteProperty(target, P) { + if (typeof P === "symbol") { + return Reflect.deleteProperty(target, P); + } + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + return !(target[implSymbol].item(index) !== null); + } + + return Reflect.deleteProperty(target, P); + }, + + preventExtensions() { + return false; + } +}; + +const Impl = require("../nodes/NodeList-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/OnBeforeUnloadEventHandlerNonNull.js b/node_modules/jsdom/lib/jsdom/living/generated/OnBeforeUnloadEventHandlerNonNull.js new file mode 100644 index 000000000..f1815e080 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/OnBeforeUnloadEventHandlerNonNull.js @@ -0,0 +1,46 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +exports.convert = (value, { context = "The provided value" } = {}) => { + function invokeTheCallbackFunction(event) { + if (new.target !== undefined) { + throw new Error("Internal error: invokeTheCallbackFunction is not a constructor"); + } + + const thisArg = utils.tryWrapperForImpl(this); + let callResult; + + if (typeof value === "function") { + event = utils.tryWrapperForImpl(event); + + callResult = Reflect.apply(value, thisArg, [event]); + } + + if (callResult === null || callResult === undefined) { + callResult = null; + } else { + callResult = conversions["DOMString"](callResult, { context: context }); + } + return callResult; + } + + invokeTheCallbackFunction.construct = event => { + event = utils.tryWrapperForImpl(event); + + let callResult = Reflect.construct(value, [event]); + + if (callResult === null || callResult === undefined) { + callResult = null; + } else { + callResult = conversions["DOMString"](callResult, { context: context }); + } + return callResult; + }; + + invokeTheCallbackFunction[utils.wrapperSymbol] = value; + invokeTheCallbackFunction.objectReference = value; + + return invokeTheCallbackFunction; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/OnErrorEventHandlerNonNull.js b/node_modules/jsdom/lib/jsdom/living/generated/OnErrorEventHandlerNonNull.js new file mode 100644 index 000000000..176fe1482 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/OnErrorEventHandlerNonNull.js @@ -0,0 +1,60 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +exports.convert = (value, { context = "The provided value" } = {}) => { + function invokeTheCallbackFunction(...args) { + if (new.target !== undefined) { + throw new Error("Internal error: invokeTheCallbackFunction is not a constructor"); + } + + const thisArg = utils.tryWrapperForImpl(this); + let callResult; + + if (typeof value === "function") { + for (let i = 0; i < Math.min(args.length, 5); i++) { + args[i] = utils.tryWrapperForImpl(args[i]); + } + + if (args.length < 1) { + for (let i = args.length; i < 1; i++) { + args[i] = undefined; + } + } else if (args.length > 5) { + args.length = 5; + } + + callResult = Reflect.apply(value, thisArg, args); + } + + callResult = conversions["any"](callResult, { context: context }); + + return callResult; + } + + invokeTheCallbackFunction.construct = (...args) => { + for (let i = 0; i < Math.min(args.length, 5); i++) { + args[i] = utils.tryWrapperForImpl(args[i]); + } + + if (args.length < 1) { + for (let i = args.length; i < 1; i++) { + args[i] = undefined; + } + } else if (args.length > 5) { + args.length = 5; + } + + let callResult = Reflect.construct(value, args); + + callResult = conversions["any"](callResult, { context: context }); + + return callResult; + }; + + invokeTheCallbackFunction[utils.wrapperSymbol] = value; + invokeTheCallbackFunction.objectReference = value; + + return invokeTheCallbackFunction; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/PageTransitionEvent.js b/node_modules/jsdom/lib/jsdom/living/generated/PageTransitionEvent.js new file mode 100644 index 000000000..0adc13072 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/PageTransitionEvent.js @@ -0,0 +1,146 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const PageTransitionEventInit = require("./PageTransitionEventInit.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const Event = require("./Event.js"); + +const interfaceName = "PageTransitionEvent"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'PageTransitionEvent'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["PageTransitionEvent"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor PageTransitionEvent is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Event._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Event === undefined) { + throw new Error("Internal error: attempting to evaluate PageTransitionEvent before Event"); + } + class PageTransitionEvent extends globalObject.Event { + constructor(type) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'PageTransitionEvent': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to construct 'PageTransitionEvent': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = PageTransitionEventInit.convert(curArg, { + context: "Failed to construct 'PageTransitionEvent': parameter 2" + }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + get persisted() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get persisted' called on an object that is not a valid instance of PageTransitionEvent."); + } + + return esValue[implSymbol]["persisted"]; + } + } + Object.defineProperties(PageTransitionEvent.prototype, { + persisted: { enumerable: true }, + [Symbol.toStringTag]: { value: "PageTransitionEvent", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = PageTransitionEvent; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: PageTransitionEvent + }); +}; + +const Impl = require("../events/PageTransitionEvent-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/PageTransitionEventInit.js b/node_modules/jsdom/lib/jsdom/living/generated/PageTransitionEventInit.js new file mode 100644 index 000000000..1eeffb8e7 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/PageTransitionEventInit.js @@ -0,0 +1,32 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventInit = require("./EventInit.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + EventInit._convertInherit(obj, ret, { context }); + + { + const key = "persisted"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'persisted' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/Performance.js b/node_modules/jsdom/lib/jsdom/living/generated/Performance.js new file mode 100644 index 000000000..96a5dbb66 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/Performance.js @@ -0,0 +1,145 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const EventTarget = require("./EventTarget.js"); + +const interfaceName = "Performance"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'Performance'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["Performance"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor Performance is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + EventTarget._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "Worker"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.EventTarget === undefined) { + throw new Error("Internal error: attempting to evaluate Performance before EventTarget"); + } + class Performance extends globalObject.EventTarget { + constructor() { + throw new TypeError("Illegal constructor"); + } + + now() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'now' called on an object that is not a valid instance of Performance."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].now()); + } + + toJSON() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'toJSON' called on an object that is not a valid instance of Performance."); + } + + return esValue[implSymbol].toJSON(); + } + + get timeOrigin() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get timeOrigin' called on an object that is not a valid instance of Performance."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["timeOrigin"]); + } + } + Object.defineProperties(Performance.prototype, { + now: { enumerable: true }, + toJSON: { enumerable: true }, + timeOrigin: { enumerable: true }, + [Symbol.toStringTag]: { value: "Performance", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = Performance; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: Performance + }); +}; + +const Impl = require("../hr-time/Performance-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/Plugin.js b/node_modules/jsdom/lib/jsdom/living/generated/Plugin.js new file mode 100644 index 000000000..a3eba56ce --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/Plugin.js @@ -0,0 +1,361 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "Plugin"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'Plugin'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["Plugin"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor Plugin is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + let wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class Plugin { + constructor() { + throw new TypeError("Illegal constructor"); + } + + item(index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'item' called on an object that is not a valid instance of Plugin."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'item' on 'Plugin': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { context: "Failed to execute 'item' on 'Plugin': parameter 1" }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].item(...args)); + } + + namedItem(name) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'namedItem' called on an object that is not a valid instance of Plugin."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'namedItem' on 'Plugin': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'namedItem' on 'Plugin': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].namedItem(...args)); + } + + get name() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get name' called on an object that is not a valid instance of Plugin."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["name"]); + } + + get description() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get description' called on an object that is not a valid instance of Plugin."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["description"]); + } + + get filename() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get filename' called on an object that is not a valid instance of Plugin."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["filename"]); + } + + get length() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get length' called on an object that is not a valid instance of Plugin."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["length"]); + } + } + Object.defineProperties(Plugin.prototype, { + item: { enumerable: true }, + namedItem: { enumerable: true }, + name: { enumerable: true }, + description: { enumerable: true }, + filename: { enumerable: true }, + length: { enumerable: true }, + [Symbol.toStringTag]: { value: "Plugin", configurable: true }, + [Symbol.iterator]: { value: Array.prototype[Symbol.iterator], configurable: true, writable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = Plugin; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: Plugin + }); +}; + +const proxyHandler = { + get(target, P, receiver) { + if (typeof P === "symbol") { + return Reflect.get(target, P, receiver); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc === undefined) { + const parent = Object.getPrototypeOf(target); + if (parent === null) { + return undefined; + } + return Reflect.get(target, P, receiver); + } + if (!desc.get && !desc.set) { + return desc.value; + } + const getter = desc.get; + if (getter === undefined) { + return undefined; + } + return Reflect.apply(getter, receiver, []); + }, + + has(target, P) { + if (typeof P === "symbol") { + return Reflect.has(target, P); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc !== undefined) { + return true; + } + const parent = Object.getPrototypeOf(target); + if (parent !== null) { + return Reflect.has(parent, P); + } + return false; + }, + + ownKeys(target) { + const keys = new Set(); + + for (const key of target[implSymbol][utils.supportedPropertyIndices]) { + keys.add(`${key}`); + } + + for (const key of Reflect.ownKeys(target)) { + keys.add(key); + } + return [...keys]; + }, + + getOwnPropertyDescriptor(target, P) { + if (typeof P === "symbol") { + return Reflect.getOwnPropertyDescriptor(target, P); + } + let ignoreNamedProps = false; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + + if (target[implSymbol][utils.supportsPropertyIndex](index)) { + const indexedValue = target[implSymbol].item(index); + return { + writable: false, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + ignoreNamedProps = true; + } + + return Reflect.getOwnPropertyDescriptor(target, P); + }, + + set(target, P, V, receiver) { + if (typeof P === "symbol") { + return Reflect.set(target, P, V, receiver); + } + // The `receiver` argument refers to the Proxy exotic object or an object + // that inherits from it, whereas `target` refers to the Proxy target: + if (target[implSymbol][utils.wrapperSymbol] === receiver) { + } + let ownDesc; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + + if (target[implSymbol][utils.supportsPropertyIndex](index)) { + const indexedValue = target[implSymbol].item(index); + ownDesc = { + writable: false, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + } + + if (ownDesc === undefined) { + ownDesc = Reflect.getOwnPropertyDescriptor(target, P); + } + if (ownDesc === undefined) { + const parent = Reflect.getPrototypeOf(target); + if (parent !== null) { + return Reflect.set(parent, P, V, receiver); + } + ownDesc = { writable: true, enumerable: true, configurable: true, value: undefined }; + } + if (!ownDesc.writable) { + return false; + } + if (!utils.isObject(receiver)) { + return false; + } + const existingDesc = Reflect.getOwnPropertyDescriptor(receiver, P); + let valueDesc; + if (existingDesc !== undefined) { + if (existingDesc.get || existingDesc.set) { + return false; + } + if (!existingDesc.writable) { + return false; + } + valueDesc = { value: V }; + } else { + valueDesc = { writable: true, enumerable: true, configurable: true, value: V }; + } + return Reflect.defineProperty(receiver, P, valueDesc); + }, + + defineProperty(target, P, desc) { + if (typeof P === "symbol") { + return Reflect.defineProperty(target, P, desc); + } + + if (utils.isArrayIndexPropName(P)) { + return false; + } + + return Reflect.defineProperty(target, P, desc); + }, + + deleteProperty(target, P) { + if (typeof P === "symbol") { + return Reflect.deleteProperty(target, P); + } + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + return !target[implSymbol][utils.supportsPropertyIndex](index); + } + + return Reflect.deleteProperty(target, P); + }, + + preventExtensions() { + return false; + } +}; + +const Impl = require("../navigator/Plugin-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/PluginArray.js b/node_modules/jsdom/lib/jsdom/living/generated/PluginArray.js new file mode 100644 index 000000000..48d1bf398 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/PluginArray.js @@ -0,0 +1,340 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "PluginArray"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'PluginArray'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["PluginArray"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor PluginArray is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + let wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class PluginArray { + constructor() { + throw new TypeError("Illegal constructor"); + } + + refresh() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'refresh' called on an object that is not a valid instance of PluginArray."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].refresh()); + } + + item(index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'item' called on an object that is not a valid instance of PluginArray."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'item' on 'PluginArray': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'item' on 'PluginArray': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].item(...args); + } + + namedItem(name) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'namedItem' called on an object that is not a valid instance of PluginArray."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'namedItem' on 'PluginArray': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'namedItem' on 'PluginArray': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].namedItem(...args); + } + + get length() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get length' called on an object that is not a valid instance of PluginArray."); + } + + return esValue[implSymbol]["length"]; + } + } + Object.defineProperties(PluginArray.prototype, { + refresh: { enumerable: true }, + item: { enumerable: true }, + namedItem: { enumerable: true }, + length: { enumerable: true }, + [Symbol.toStringTag]: { value: "PluginArray", configurable: true }, + [Symbol.iterator]: { value: Array.prototype[Symbol.iterator], configurable: true, writable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = PluginArray; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: PluginArray + }); +}; + +const proxyHandler = { + get(target, P, receiver) { + if (typeof P === "symbol") { + return Reflect.get(target, P, receiver); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc === undefined) { + const parent = Object.getPrototypeOf(target); + if (parent === null) { + return undefined; + } + return Reflect.get(target, P, receiver); + } + if (!desc.get && !desc.set) { + return desc.value; + } + const getter = desc.get; + if (getter === undefined) { + return undefined; + } + return Reflect.apply(getter, receiver, []); + }, + + has(target, P) { + if (typeof P === "symbol") { + return Reflect.has(target, P); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc !== undefined) { + return true; + } + const parent = Object.getPrototypeOf(target); + if (parent !== null) { + return Reflect.has(parent, P); + } + return false; + }, + + ownKeys(target) { + const keys = new Set(); + + for (const key of target[implSymbol][utils.supportedPropertyIndices]) { + keys.add(`${key}`); + } + + for (const key of Reflect.ownKeys(target)) { + keys.add(key); + } + return [...keys]; + }, + + getOwnPropertyDescriptor(target, P) { + if (typeof P === "symbol") { + return Reflect.getOwnPropertyDescriptor(target, P); + } + let ignoreNamedProps = false; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + return { + writable: false, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + ignoreNamedProps = true; + } + + return Reflect.getOwnPropertyDescriptor(target, P); + }, + + set(target, P, V, receiver) { + if (typeof P === "symbol") { + return Reflect.set(target, P, V, receiver); + } + // The `receiver` argument refers to the Proxy exotic object or an object + // that inherits from it, whereas `target` refers to the Proxy target: + if (target[implSymbol][utils.wrapperSymbol] === receiver) { + } + let ownDesc; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + ownDesc = { + writable: false, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + } + + if (ownDesc === undefined) { + ownDesc = Reflect.getOwnPropertyDescriptor(target, P); + } + if (ownDesc === undefined) { + const parent = Reflect.getPrototypeOf(target); + if (parent !== null) { + return Reflect.set(parent, P, V, receiver); + } + ownDesc = { writable: true, enumerable: true, configurable: true, value: undefined }; + } + if (!ownDesc.writable) { + return false; + } + if (!utils.isObject(receiver)) { + return false; + } + const existingDesc = Reflect.getOwnPropertyDescriptor(receiver, P); + let valueDesc; + if (existingDesc !== undefined) { + if (existingDesc.get || existingDesc.set) { + return false; + } + if (!existingDesc.writable) { + return false; + } + valueDesc = { value: V }; + } else { + valueDesc = { writable: true, enumerable: true, configurable: true, value: V }; + } + return Reflect.defineProperty(receiver, P, valueDesc); + }, + + defineProperty(target, P, desc) { + if (typeof P === "symbol") { + return Reflect.defineProperty(target, P, desc); + } + + if (utils.isArrayIndexPropName(P)) { + return false; + } + + return Reflect.defineProperty(target, P, desc); + }, + + deleteProperty(target, P) { + if (typeof P === "symbol") { + return Reflect.deleteProperty(target, P); + } + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + return !(target[implSymbol].item(index) !== null); + } + + return Reflect.deleteProperty(target, P); + }, + + preventExtensions() { + return false; + } +}; + +const Impl = require("../navigator/PluginArray-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/PopStateEvent.js b/node_modules/jsdom/lib/jsdom/living/generated/PopStateEvent.js new file mode 100644 index 000000000..ee13d364f --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/PopStateEvent.js @@ -0,0 +1,142 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const PopStateEventInit = require("./PopStateEventInit.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const Event = require("./Event.js"); + +const interfaceName = "PopStateEvent"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'PopStateEvent'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["PopStateEvent"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor PopStateEvent is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Event._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Event === undefined) { + throw new Error("Internal error: attempting to evaluate PopStateEvent before Event"); + } + class PopStateEvent extends globalObject.Event { + constructor(type) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'PopStateEvent': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'PopStateEvent': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = PopStateEventInit.convert(curArg, { context: "Failed to construct 'PopStateEvent': parameter 2" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + get state() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get state' called on an object that is not a valid instance of PopStateEvent."); + } + + return esValue[implSymbol]["state"]; + } + } + Object.defineProperties(PopStateEvent.prototype, { + state: { enumerable: true }, + [Symbol.toStringTag]: { value: "PopStateEvent", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = PopStateEvent; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: PopStateEvent + }); +}; + +const Impl = require("../events/PopStateEvent-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/PopStateEventInit.js b/node_modules/jsdom/lib/jsdom/living/generated/PopStateEventInit.js new file mode 100644 index 000000000..6f9c674f7 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/PopStateEventInit.js @@ -0,0 +1,32 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventInit = require("./EventInit.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + EventInit._convertInherit(obj, ret, { context }); + + { + const key = "state"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["any"](value, { context: context + " has member 'state' that" }); + + ret[key] = value; + } else { + ret[key] = null; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/ProcessingInstruction.js b/node_modules/jsdom/lib/jsdom/living/generated/ProcessingInstruction.js new file mode 100644 index 000000000..84153904e --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/ProcessingInstruction.js @@ -0,0 +1,125 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const CharacterData = require("./CharacterData.js"); + +const interfaceName = "ProcessingInstruction"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'ProcessingInstruction'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["ProcessingInstruction"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor ProcessingInstruction is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + CharacterData._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.CharacterData === undefined) { + throw new Error("Internal error: attempting to evaluate ProcessingInstruction before CharacterData"); + } + class ProcessingInstruction extends globalObject.CharacterData { + constructor() { + throw new TypeError("Illegal constructor"); + } + + get target() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get target' called on an object that is not a valid instance of ProcessingInstruction."); + } + + return esValue[implSymbol]["target"]; + } + } + Object.defineProperties(ProcessingInstruction.prototype, { + target: { enumerable: true }, + [Symbol.toStringTag]: { value: "ProcessingInstruction", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = ProcessingInstruction; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: ProcessingInstruction + }); +}; + +const Impl = require("../nodes/ProcessingInstruction-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/ProgressEvent.js b/node_modules/jsdom/lib/jsdom/living/generated/ProgressEvent.js new file mode 100644 index 000000000..3aeca2df7 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/ProgressEvent.js @@ -0,0 +1,166 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const ProgressEventInit = require("./ProgressEventInit.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const Event = require("./Event.js"); + +const interfaceName = "ProgressEvent"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'ProgressEvent'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["ProgressEvent"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor ProgressEvent is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Event._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "DedicatedWorker", "SharedWorker"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Event === undefined) { + throw new Error("Internal error: attempting to evaluate ProgressEvent before Event"); + } + class ProgressEvent extends globalObject.Event { + constructor(type) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'ProgressEvent': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'ProgressEvent': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = ProgressEventInit.convert(curArg, { context: "Failed to construct 'ProgressEvent': parameter 2" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + get lengthComputable() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get lengthComputable' called on an object that is not a valid instance of ProgressEvent." + ); + } + + return esValue[implSymbol]["lengthComputable"]; + } + + get loaded() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get loaded' called on an object that is not a valid instance of ProgressEvent."); + } + + return esValue[implSymbol]["loaded"]; + } + + get total() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get total' called on an object that is not a valid instance of ProgressEvent."); + } + + return esValue[implSymbol]["total"]; + } + } + Object.defineProperties(ProgressEvent.prototype, { + lengthComputable: { enumerable: true }, + loaded: { enumerable: true }, + total: { enumerable: true }, + [Symbol.toStringTag]: { value: "ProgressEvent", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = ProgressEvent; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: ProgressEvent + }); +}; + +const Impl = require("../events/ProgressEvent-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/ProgressEventInit.js b/node_modules/jsdom/lib/jsdom/living/generated/ProgressEventInit.js new file mode 100644 index 000000000..7dd3dee31 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/ProgressEventInit.js @@ -0,0 +1,56 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventInit = require("./EventInit.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + EventInit._convertInherit(obj, ret, { context }); + + { + const key = "lengthComputable"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'lengthComputable' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "loaded"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["unsigned long long"](value, { context: context + " has member 'loaded' that" }); + + ret[key] = value; + } else { + ret[key] = 0; + } + } + + { + const key = "total"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["unsigned long long"](value, { context: context + " has member 'total' that" }); + + ret[key] = value; + } else { + ret[key] = 0; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/Range.js b/node_modules/jsdom/lib/jsdom/living/generated/Range.js new file mode 100644 index 000000000..e8f6dbdc9 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/Range.js @@ -0,0 +1,619 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const Node = require("./Node.js"); +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const AbstractRange = require("./AbstractRange.js"); + +const interfaceName = "Range"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'Range'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["Range"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor Range is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + AbstractRange._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.AbstractRange === undefined) { + throw new Error("Internal error: attempting to evaluate Range before AbstractRange"); + } + class Range extends globalObject.AbstractRange { + constructor() { + return exports.setup(Object.create(new.target.prototype), globalObject, undefined); + } + + setStart(node, offset) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'setStart' called on an object that is not a valid instance of Range."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'setStart' on 'Range': 2 arguments required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'setStart' on 'Range': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'setStart' on 'Range': parameter 2" + }); + args.push(curArg); + } + return esValue[implSymbol].setStart(...args); + } + + setEnd(node, offset) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'setEnd' called on an object that is not a valid instance of Range."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'setEnd' on 'Range': 2 arguments required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'setEnd' on 'Range': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'setEnd' on 'Range': parameter 2" + }); + args.push(curArg); + } + return esValue[implSymbol].setEnd(...args); + } + + setStartBefore(node) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'setStartBefore' called on an object that is not a valid instance of Range."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'setStartBefore' on 'Range': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'setStartBefore' on 'Range': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].setStartBefore(...args); + } + + setStartAfter(node) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'setStartAfter' called on an object that is not a valid instance of Range."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'setStartAfter' on 'Range': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'setStartAfter' on 'Range': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].setStartAfter(...args); + } + + setEndBefore(node) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'setEndBefore' called on an object that is not a valid instance of Range."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'setEndBefore' on 'Range': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'setEndBefore' on 'Range': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].setEndBefore(...args); + } + + setEndAfter(node) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'setEndAfter' called on an object that is not a valid instance of Range."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'setEndAfter' on 'Range': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'setEndAfter' on 'Range': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].setEndAfter(...args); + } + + collapse() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'collapse' called on an object that is not a valid instance of Range."); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { context: "Failed to execute 'collapse' on 'Range': parameter 1" }); + } else { + curArg = false; + } + args.push(curArg); + } + return esValue[implSymbol].collapse(...args); + } + + selectNode(node) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'selectNode' called on an object that is not a valid instance of Range."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'selectNode' on 'Range': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'selectNode' on 'Range': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].selectNode(...args); + } + + selectNodeContents(node) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'selectNodeContents' called on an object that is not a valid instance of Range."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'selectNodeContents' on 'Range': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'selectNodeContents' on 'Range': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].selectNodeContents(...args); + } + + compareBoundaryPoints(how, sourceRange) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'compareBoundaryPoints' called on an object that is not a valid instance of Range."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'compareBoundaryPoints' on 'Range': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned short"](curArg, { + context: "Failed to execute 'compareBoundaryPoints' on 'Range': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = exports.convert(curArg, { + context: "Failed to execute 'compareBoundaryPoints' on 'Range': parameter 2" + }); + args.push(curArg); + } + return esValue[implSymbol].compareBoundaryPoints(...args); + } + + deleteContents() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'deleteContents' called on an object that is not a valid instance of Range."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].deleteContents(); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + extractContents() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'extractContents' called on an object that is not a valid instance of Range."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].extractContents()); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + cloneContents() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'cloneContents' called on an object that is not a valid instance of Range."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].cloneContents()); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + insertNode(node) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'insertNode' called on an object that is not a valid instance of Range."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'insertNode' on 'Range': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'insertNode' on 'Range': parameter 1" }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].insertNode(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + surroundContents(newParent) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'surroundContents' called on an object that is not a valid instance of Range."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'surroundContents' on 'Range': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'surroundContents' on 'Range': parameter 1" }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].surroundContents(...args); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + cloneRange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'cloneRange' called on an object that is not a valid instance of Range."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].cloneRange()); + } + + detach() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'detach' called on an object that is not a valid instance of Range."); + } + + return esValue[implSymbol].detach(); + } + + isPointInRange(node, offset) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'isPointInRange' called on an object that is not a valid instance of Range."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'isPointInRange' on 'Range': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'isPointInRange' on 'Range': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'isPointInRange' on 'Range': parameter 2" + }); + args.push(curArg); + } + return esValue[implSymbol].isPointInRange(...args); + } + + comparePoint(node, offset) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'comparePoint' called on an object that is not a valid instance of Range."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'comparePoint' on 'Range': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'comparePoint' on 'Range': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'comparePoint' on 'Range': parameter 2" + }); + args.push(curArg); + } + return esValue[implSymbol].comparePoint(...args); + } + + intersectsNode(node) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'intersectsNode' called on an object that is not a valid instance of Range."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'intersectsNode' on 'Range': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'intersectsNode' on 'Range': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].intersectsNode(...args); + } + + toString() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'toString' called on an object that is not a valid instance of Range."); + } + + return esValue[implSymbol].toString(); + } + + createContextualFragment(fragment) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'createContextualFragment' called on an object that is not a valid instance of Range."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'createContextualFragment' on 'Range': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'createContextualFragment' on 'Range': parameter 1" + }); + args.push(curArg); + } + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return utils.tryWrapperForImpl(esValue[implSymbol].createContextualFragment(...args)); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get commonAncestorContainer() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get commonAncestorContainer' called on an object that is not a valid instance of Range."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["commonAncestorContainer"]); + } + } + Object.defineProperties(Range.prototype, { + setStart: { enumerable: true }, + setEnd: { enumerable: true }, + setStartBefore: { enumerable: true }, + setStartAfter: { enumerable: true }, + setEndBefore: { enumerable: true }, + setEndAfter: { enumerable: true }, + collapse: { enumerable: true }, + selectNode: { enumerable: true }, + selectNodeContents: { enumerable: true }, + compareBoundaryPoints: { enumerable: true }, + deleteContents: { enumerable: true }, + extractContents: { enumerable: true }, + cloneContents: { enumerable: true }, + insertNode: { enumerable: true }, + surroundContents: { enumerable: true }, + cloneRange: { enumerable: true }, + detach: { enumerable: true }, + isPointInRange: { enumerable: true }, + comparePoint: { enumerable: true }, + intersectsNode: { enumerable: true }, + toString: { enumerable: true }, + createContextualFragment: { enumerable: true }, + commonAncestorContainer: { enumerable: true }, + [Symbol.toStringTag]: { value: "Range", configurable: true }, + START_TO_START: { value: 0, enumerable: true }, + START_TO_END: { value: 1, enumerable: true }, + END_TO_END: { value: 2, enumerable: true }, + END_TO_START: { value: 3, enumerable: true } + }); + Object.defineProperties(Range, { + START_TO_START: { value: 0, enumerable: true }, + START_TO_END: { value: 1, enumerable: true }, + END_TO_END: { value: 2, enumerable: true }, + END_TO_START: { value: 3, enumerable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = Range; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: Range + }); +}; + +const Impl = require("../range/Range-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/SVGAnimatedString.js b/node_modules/jsdom/lib/jsdom/living/generated/SVGAnimatedString.js new file mode 100644 index 000000000..46806ca2b --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/SVGAnimatedString.js @@ -0,0 +1,143 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "SVGAnimatedString"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'SVGAnimatedString'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["SVGAnimatedString"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor SVGAnimatedString is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class SVGAnimatedString { + constructor() { + throw new TypeError("Illegal constructor"); + } + + get baseVal() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get baseVal' called on an object that is not a valid instance of SVGAnimatedString."); + } + + return esValue[implSymbol]["baseVal"]; + } + + set baseVal(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set baseVal' called on an object that is not a valid instance of SVGAnimatedString."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'baseVal' property on 'SVGAnimatedString': The provided value" + }); + + esValue[implSymbol]["baseVal"] = V; + } + + get animVal() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get animVal' called on an object that is not a valid instance of SVGAnimatedString."); + } + + return esValue[implSymbol]["animVal"]; + } + } + Object.defineProperties(SVGAnimatedString.prototype, { + baseVal: { enumerable: true }, + animVal: { enumerable: true }, + [Symbol.toStringTag]: { value: "SVGAnimatedString", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = SVGAnimatedString; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: SVGAnimatedString + }); +}; + +const Impl = require("../svg/SVGAnimatedString-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/SVGBoundingBoxOptions.js b/node_modules/jsdom/lib/jsdom/living/generated/SVGBoundingBoxOptions.js new file mode 100644 index 000000000..67fa2fbf1 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/SVGBoundingBoxOptions.js @@ -0,0 +1,64 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + { + const key = "clipped"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'clipped' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "fill"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'fill' that" }); + + ret[key] = value; + } else { + ret[key] = true; + } + } + + { + const key = "markers"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'markers' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } + + { + const key = "stroke"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["boolean"](value, { context: context + " has member 'stroke' that" }); + + ret[key] = value; + } else { + ret[key] = false; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/SVGElement.js b/node_modules/jsdom/lib/jsdom/living/generated/SVGElement.js new file mode 100644 index 000000000..a1d55c7f8 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/SVGElement.js @@ -0,0 +1,1986 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventHandlerNonNull = require("./EventHandlerNonNull.js"); +const OnErrorEventHandlerNonNull = require("./OnErrorEventHandlerNonNull.js"); +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const Element = require("./Element.js"); + +const interfaceName = "SVGElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'SVGElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["SVGElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor SVGElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Element._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Element === undefined) { + throw new Error("Internal error: attempting to evaluate SVGElement before Element"); + } + class SVGElement extends globalObject.Element { + constructor() { + throw new TypeError("Illegal constructor"); + } + + focus() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'focus' called on an object that is not a valid instance of SVGElement."); + } + + return esValue[implSymbol].focus(); + } + + blur() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'blur' called on an object that is not a valid instance of SVGElement."); + } + + return esValue[implSymbol].blur(); + } + + get className() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get className' called on an object that is not a valid instance of SVGElement."); + } + + return utils.getSameObject(this, "className", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["className"]); + }); + } + + get ownerSVGElement() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ownerSVGElement' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ownerSVGElement"]); + } + + get viewportElement() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get viewportElement' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["viewportElement"]); + } + + get style() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get style' called on an object that is not a valid instance of SVGElement."); + } + + return utils.getSameObject(this, "style", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["style"]); + }); + } + + set style(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set style' called on an object that is not a valid instance of SVGElement."); + } + + const Q = esValue["style"]; + if (!utils.isObject(Q)) { + throw new TypeError("Property 'style' is not an object"); + } + Reflect.set(Q, "cssText", V); + } + + get onabort() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onabort' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onabort"]); + } + + set onabort(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onabort' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onabort' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onabort"] = V; + } + + get onauxclick() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onauxclick' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onauxclick"]); + } + + set onauxclick(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onauxclick' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onauxclick' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onauxclick"] = V; + } + + get onblur() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onblur' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onblur"]); + } + + set onblur(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onblur' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onblur' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onblur"] = V; + } + + get oncancel() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oncancel' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oncancel"]); + } + + set oncancel(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oncancel' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oncancel' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["oncancel"] = V; + } + + get oncanplay() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oncanplay' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oncanplay"]); + } + + set oncanplay(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oncanplay' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oncanplay' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["oncanplay"] = V; + } + + get oncanplaythrough() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oncanplaythrough' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oncanplaythrough"]); + } + + set oncanplaythrough(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oncanplaythrough' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oncanplaythrough' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["oncanplaythrough"] = V; + } + + get onchange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onchange' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onchange"]); + } + + set onchange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onchange' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onchange' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onchange"] = V; + } + + get onclick() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onclick' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onclick"]); + } + + set onclick(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onclick' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onclick' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onclick"] = V; + } + + get onclose() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onclose' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onclose"]); + } + + set onclose(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onclose' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onclose' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onclose"] = V; + } + + get oncontextmenu() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oncontextmenu' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oncontextmenu"]); + } + + set oncontextmenu(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oncontextmenu' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oncontextmenu' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["oncontextmenu"] = V; + } + + get oncuechange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oncuechange' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oncuechange"]); + } + + set oncuechange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oncuechange' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oncuechange' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["oncuechange"] = V; + } + + get ondblclick() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondblclick' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondblclick"]); + } + + set ondblclick(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondblclick' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondblclick' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["ondblclick"] = V; + } + + get ondrag() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondrag' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondrag"]); + } + + set ondrag(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondrag' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondrag' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["ondrag"] = V; + } + + get ondragend() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondragend' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondragend"]); + } + + set ondragend(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondragend' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondragend' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["ondragend"] = V; + } + + get ondragenter() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondragenter' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondragenter"]); + } + + set ondragenter(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondragenter' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondragenter' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["ondragenter"] = V; + } + + get ondragleave() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondragleave' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondragleave"]); + } + + set ondragleave(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondragleave' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondragleave' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["ondragleave"] = V; + } + + get ondragover() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondragover' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondragover"]); + } + + set ondragover(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondragover' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondragover' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["ondragover"] = V; + } + + get ondragstart() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondragstart' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondragstart"]); + } + + set ondragstart(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondragstart' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondragstart' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["ondragstart"] = V; + } + + get ondrop() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondrop' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondrop"]); + } + + set ondrop(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondrop' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondrop' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["ondrop"] = V; + } + + get ondurationchange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ondurationchange' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ondurationchange"]); + } + + set ondurationchange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ondurationchange' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ondurationchange' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["ondurationchange"] = V; + } + + get onemptied() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onemptied' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onemptied"]); + } + + set onemptied(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onemptied' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onemptied' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onemptied"] = V; + } + + get onended() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onended' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onended"]); + } + + set onended(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onended' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onended' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onended"] = V; + } + + get onerror() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onerror' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onerror"]); + } + + set onerror(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onerror' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = OnErrorEventHandlerNonNull.convert(V, { + context: "Failed to set the 'onerror' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onerror"] = V; + } + + get onfocus() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onfocus' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onfocus"]); + } + + set onfocus(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onfocus' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onfocus' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onfocus"] = V; + } + + get oninput() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oninput' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oninput"]); + } + + set oninput(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oninput' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oninput' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["oninput"] = V; + } + + get oninvalid() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oninvalid' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["oninvalid"]); + } + + set oninvalid(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set oninvalid' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'oninvalid' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["oninvalid"] = V; + } + + get onkeydown() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onkeydown' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onkeydown"]); + } + + set onkeydown(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onkeydown' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onkeydown' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onkeydown"] = V; + } + + get onkeypress() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onkeypress' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onkeypress"]); + } + + set onkeypress(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onkeypress' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onkeypress' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onkeypress"] = V; + } + + get onkeyup() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onkeyup' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onkeyup"]); + } + + set onkeyup(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onkeyup' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onkeyup' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onkeyup"] = V; + } + + get onload() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onload' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onload"]); + } + + set onload(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onload' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onload' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onload"] = V; + } + + get onloadeddata() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onloadeddata' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onloadeddata"]); + } + + set onloadeddata(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onloadeddata' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onloadeddata' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onloadeddata"] = V; + } + + get onloadedmetadata() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onloadedmetadata' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onloadedmetadata"]); + } + + set onloadedmetadata(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onloadedmetadata' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onloadedmetadata' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onloadedmetadata"] = V; + } + + get onloadend() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onloadend' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onloadend"]); + } + + set onloadend(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onloadend' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onloadend' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onloadend"] = V; + } + + get onloadstart() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onloadstart' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onloadstart"]); + } + + set onloadstart(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onloadstart' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onloadstart' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onloadstart"] = V; + } + + get onmousedown() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmousedown' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmousedown"]); + } + + set onmousedown(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmousedown' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmousedown' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onmousedown"] = V; + } + + get onmouseenter() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + return; + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmouseenter"]); + } + + set onmouseenter(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + return; + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmouseenter' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onmouseenter"] = V; + } + + get onmouseleave() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + return; + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmouseleave"]); + } + + set onmouseleave(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + return; + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmouseleave' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onmouseleave"] = V; + } + + get onmousemove() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmousemove' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmousemove"]); + } + + set onmousemove(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmousemove' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmousemove' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onmousemove"] = V; + } + + get onmouseout() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmouseout' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmouseout"]); + } + + set onmouseout(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmouseout' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmouseout' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onmouseout"] = V; + } + + get onmouseover() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmouseover' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmouseover"]); + } + + set onmouseover(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmouseover' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmouseover' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onmouseover"] = V; + } + + get onmouseup() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmouseup' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmouseup"]); + } + + set onmouseup(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmouseup' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmouseup' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onmouseup"] = V; + } + + get onwheel() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onwheel' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onwheel"]); + } + + set onwheel(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onwheel' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onwheel' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onwheel"] = V; + } + + get onpause() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onpause' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onpause"]); + } + + set onpause(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onpause' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onpause' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onpause"] = V; + } + + get onplay() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onplay' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onplay"]); + } + + set onplay(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onplay' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onplay' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onplay"] = V; + } + + get onplaying() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onplaying' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onplaying"]); + } + + set onplaying(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onplaying' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onplaying' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onplaying"] = V; + } + + get onprogress() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onprogress' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onprogress"]); + } + + set onprogress(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onprogress' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onprogress' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onprogress"] = V; + } + + get onratechange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onratechange' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onratechange"]); + } + + set onratechange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onratechange' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onratechange' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onratechange"] = V; + } + + get onreset() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onreset' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onreset"]); + } + + set onreset(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onreset' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onreset' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onreset"] = V; + } + + get onresize() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onresize' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onresize"]); + } + + set onresize(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onresize' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onresize' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onresize"] = V; + } + + get onscroll() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onscroll' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onscroll"]); + } + + set onscroll(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onscroll' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onscroll' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onscroll"] = V; + } + + get onsecuritypolicyviolation() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onsecuritypolicyviolation' called on an object that is not a valid instance of SVGElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onsecuritypolicyviolation"]); + } + + set onsecuritypolicyviolation(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onsecuritypolicyviolation' called on an object that is not a valid instance of SVGElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onsecuritypolicyviolation' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onsecuritypolicyviolation"] = V; + } + + get onseeked() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onseeked' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onseeked"]); + } + + set onseeked(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onseeked' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onseeked' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onseeked"] = V; + } + + get onseeking() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onseeking' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onseeking"]); + } + + set onseeking(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onseeking' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onseeking' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onseeking"] = V; + } + + get onselect() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onselect' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onselect"]); + } + + set onselect(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onselect' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onselect' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onselect"] = V; + } + + get onstalled() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onstalled' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onstalled"]); + } + + set onstalled(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onstalled' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onstalled' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onstalled"] = V; + } + + get onsubmit() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onsubmit' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onsubmit"]); + } + + set onsubmit(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onsubmit' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onsubmit' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onsubmit"] = V; + } + + get onsuspend() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onsuspend' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onsuspend"]); + } + + set onsuspend(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onsuspend' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onsuspend' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onsuspend"] = V; + } + + get ontimeupdate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ontimeupdate' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ontimeupdate"]); + } + + set ontimeupdate(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ontimeupdate' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ontimeupdate' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["ontimeupdate"] = V; + } + + get ontoggle() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ontoggle' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ontoggle"]); + } + + set ontoggle(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ontoggle' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ontoggle' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["ontoggle"] = V; + } + + get onvolumechange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onvolumechange' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onvolumechange"]); + } + + set onvolumechange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onvolumechange' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onvolumechange' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onvolumechange"] = V; + } + + get onwaiting() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onwaiting' called on an object that is not a valid instance of SVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onwaiting"]); + } + + set onwaiting(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onwaiting' called on an object that is not a valid instance of SVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onwaiting' property on 'SVGElement': The provided value" + }); + } + esValue[implSymbol]["onwaiting"] = V; + } + + get dataset() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get dataset' called on an object that is not a valid instance of SVGElement."); + } + + return utils.getSameObject(this, "dataset", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["dataset"]); + }); + } + + get nonce() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get nonce' called on an object that is not a valid instance of SVGElement."); + } + + const value = esValue[implSymbol].getAttributeNS(null, "nonce"); + return value === null ? "" : value; + } + + set nonce(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set nonce' called on an object that is not a valid instance of SVGElement."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'nonce' property on 'SVGElement': The provided value" + }); + + esValue[implSymbol].setAttributeNS(null, "nonce", V); + } + + get tabIndex() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get tabIndex' called on an object that is not a valid instance of SVGElement."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["tabIndex"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set tabIndex(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set tabIndex' called on an object that is not a valid instance of SVGElement."); + } + + V = conversions["long"](V, { + context: "Failed to set the 'tabIndex' property on 'SVGElement': The provided value" + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["tabIndex"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + } + Object.defineProperties(SVGElement.prototype, { + focus: { enumerable: true }, + blur: { enumerable: true }, + className: { enumerable: true }, + ownerSVGElement: { enumerable: true }, + viewportElement: { enumerable: true }, + style: { enumerable: true }, + onabort: { enumerable: true }, + onauxclick: { enumerable: true }, + onblur: { enumerable: true }, + oncancel: { enumerable: true }, + oncanplay: { enumerable: true }, + oncanplaythrough: { enumerable: true }, + onchange: { enumerable: true }, + onclick: { enumerable: true }, + onclose: { enumerable: true }, + oncontextmenu: { enumerable: true }, + oncuechange: { enumerable: true }, + ondblclick: { enumerable: true }, + ondrag: { enumerable: true }, + ondragend: { enumerable: true }, + ondragenter: { enumerable: true }, + ondragleave: { enumerable: true }, + ondragover: { enumerable: true }, + ondragstart: { enumerable: true }, + ondrop: { enumerable: true }, + ondurationchange: { enumerable: true }, + onemptied: { enumerable: true }, + onended: { enumerable: true }, + onerror: { enumerable: true }, + onfocus: { enumerable: true }, + oninput: { enumerable: true }, + oninvalid: { enumerable: true }, + onkeydown: { enumerable: true }, + onkeypress: { enumerable: true }, + onkeyup: { enumerable: true }, + onload: { enumerable: true }, + onloadeddata: { enumerable: true }, + onloadedmetadata: { enumerable: true }, + onloadend: { enumerable: true }, + onloadstart: { enumerable: true }, + onmousedown: { enumerable: true }, + onmouseenter: { enumerable: true }, + onmouseleave: { enumerable: true }, + onmousemove: { enumerable: true }, + onmouseout: { enumerable: true }, + onmouseover: { enumerable: true }, + onmouseup: { enumerable: true }, + onwheel: { enumerable: true }, + onpause: { enumerable: true }, + onplay: { enumerable: true }, + onplaying: { enumerable: true }, + onprogress: { enumerable: true }, + onratechange: { enumerable: true }, + onreset: { enumerable: true }, + onresize: { enumerable: true }, + onscroll: { enumerable: true }, + onsecuritypolicyviolation: { enumerable: true }, + onseeked: { enumerable: true }, + onseeking: { enumerable: true }, + onselect: { enumerable: true }, + onstalled: { enumerable: true }, + onsubmit: { enumerable: true }, + onsuspend: { enumerable: true }, + ontimeupdate: { enumerable: true }, + ontoggle: { enumerable: true }, + onvolumechange: { enumerable: true }, + onwaiting: { enumerable: true }, + dataset: { enumerable: true }, + nonce: { enumerable: true }, + tabIndex: { enumerable: true }, + [Symbol.toStringTag]: { value: "SVGElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = SVGElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: SVGElement + }); +}; + +const Impl = require("../nodes/SVGElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/SVGGraphicsElement.js b/node_modules/jsdom/lib/jsdom/living/generated/SVGGraphicsElement.js new file mode 100644 index 000000000..301cb14e0 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/SVGGraphicsElement.js @@ -0,0 +1,144 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const SVGElement = require("./SVGElement.js"); + +const interfaceName = "SVGGraphicsElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'SVGGraphicsElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["SVGGraphicsElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor SVGGraphicsElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + SVGElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.SVGElement === undefined) { + throw new Error("Internal error: attempting to evaluate SVGGraphicsElement before SVGElement"); + } + class SVGGraphicsElement extends globalObject.SVGElement { + constructor() { + throw new TypeError("Illegal constructor"); + } + + get requiredExtensions() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get requiredExtensions' called on an object that is not a valid instance of SVGGraphicsElement." + ); + } + + return utils.getSameObject(this, "requiredExtensions", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["requiredExtensions"]); + }); + } + + get systemLanguage() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get systemLanguage' called on an object that is not a valid instance of SVGGraphicsElement." + ); + } + + return utils.getSameObject(this, "systemLanguage", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["systemLanguage"]); + }); + } + } + Object.defineProperties(SVGGraphicsElement.prototype, { + requiredExtensions: { enumerable: true }, + systemLanguage: { enumerable: true }, + [Symbol.toStringTag]: { value: "SVGGraphicsElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = SVGGraphicsElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: SVGGraphicsElement + }); +}; + +const Impl = require("../nodes/SVGGraphicsElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/SVGNumber.js b/node_modules/jsdom/lib/jsdom/living/generated/SVGNumber.js new file mode 100644 index 000000000..373b54e19 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/SVGNumber.js @@ -0,0 +1,130 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "SVGNumber"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'SVGNumber'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["SVGNumber"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor SVGNumber is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class SVGNumber { + constructor() { + throw new TypeError("Illegal constructor"); + } + + get value() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get value' called on an object that is not a valid instance of SVGNumber."); + } + + return esValue[implSymbol]["value"]; + } + + set value(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set value' called on an object that is not a valid instance of SVGNumber."); + } + + V = conversions["float"](V, { context: "Failed to set the 'value' property on 'SVGNumber': The provided value" }); + + esValue[implSymbol]["value"] = V; + } + } + Object.defineProperties(SVGNumber.prototype, { + value: { enumerable: true }, + [Symbol.toStringTag]: { value: "SVGNumber", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = SVGNumber; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: SVGNumber + }); +}; + +const Impl = require("../svg/SVGNumber-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/SVGSVGElement.js b/node_modules/jsdom/lib/jsdom/living/generated/SVGSVGElement.js new file mode 100644 index 000000000..2f55ebc06 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/SVGSVGElement.js @@ -0,0 +1,681 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventHandlerNonNull = require("./EventHandlerNonNull.js"); +const OnBeforeUnloadEventHandlerNonNull = require("./OnBeforeUnloadEventHandlerNonNull.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const SVGGraphicsElement = require("./SVGGraphicsElement.js"); + +const interfaceName = "SVGSVGElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'SVGSVGElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["SVGSVGElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor SVGSVGElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + SVGGraphicsElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.SVGGraphicsElement === undefined) { + throw new Error("Internal error: attempting to evaluate SVGSVGElement before SVGGraphicsElement"); + } + class SVGSVGElement extends globalObject.SVGGraphicsElement { + constructor() { + throw new TypeError("Illegal constructor"); + } + + createSVGNumber() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'createSVGNumber' called on an object that is not a valid instance of SVGSVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].createSVGNumber()); + } + + getElementById(elementId) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getElementById' called on an object that is not a valid instance of SVGSVGElement."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'getElementById' on 'SVGSVGElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'getElementById' on 'SVGSVGElement': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].getElementById(...args)); + } + + suspendRedraw(maxWaitMilliseconds) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'suspendRedraw' called on an object that is not a valid instance of SVGSVGElement."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'suspendRedraw' on 'SVGSVGElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'suspendRedraw' on 'SVGSVGElement': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].suspendRedraw(...args); + } + + unsuspendRedraw(suspendHandleID) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'unsuspendRedraw' called on an object that is not a valid instance of SVGSVGElement."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'unsuspendRedraw' on 'SVGSVGElement': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'unsuspendRedraw' on 'SVGSVGElement': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].unsuspendRedraw(...args); + } + + unsuspendRedrawAll() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'unsuspendRedrawAll' called on an object that is not a valid instance of SVGSVGElement."); + } + + return esValue[implSymbol].unsuspendRedrawAll(); + } + + forceRedraw() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'forceRedraw' called on an object that is not a valid instance of SVGSVGElement."); + } + + return esValue[implSymbol].forceRedraw(); + } + + get onafterprint() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onafterprint' called on an object that is not a valid instance of SVGSVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onafterprint"]); + } + + set onafterprint(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onafterprint' called on an object that is not a valid instance of SVGSVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onafterprint' property on 'SVGSVGElement': The provided value" + }); + } + esValue[implSymbol]["onafterprint"] = V; + } + + get onbeforeprint() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onbeforeprint' called on an object that is not a valid instance of SVGSVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onbeforeprint"]); + } + + set onbeforeprint(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onbeforeprint' called on an object that is not a valid instance of SVGSVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onbeforeprint' property on 'SVGSVGElement': The provided value" + }); + } + esValue[implSymbol]["onbeforeprint"] = V; + } + + get onbeforeunload() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onbeforeunload' called on an object that is not a valid instance of SVGSVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onbeforeunload"]); + } + + set onbeforeunload(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onbeforeunload' called on an object that is not a valid instance of SVGSVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = OnBeforeUnloadEventHandlerNonNull.convert(V, { + context: "Failed to set the 'onbeforeunload' property on 'SVGSVGElement': The provided value" + }); + } + esValue[implSymbol]["onbeforeunload"] = V; + } + + get onhashchange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onhashchange' called on an object that is not a valid instance of SVGSVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onhashchange"]); + } + + set onhashchange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onhashchange' called on an object that is not a valid instance of SVGSVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onhashchange' property on 'SVGSVGElement': The provided value" + }); + } + esValue[implSymbol]["onhashchange"] = V; + } + + get onlanguagechange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onlanguagechange' called on an object that is not a valid instance of SVGSVGElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onlanguagechange"]); + } + + set onlanguagechange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onlanguagechange' called on an object that is not a valid instance of SVGSVGElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onlanguagechange' property on 'SVGSVGElement': The provided value" + }); + } + esValue[implSymbol]["onlanguagechange"] = V; + } + + get onmessage() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmessage' called on an object that is not a valid instance of SVGSVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmessage"]); + } + + set onmessage(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmessage' called on an object that is not a valid instance of SVGSVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmessage' property on 'SVGSVGElement': The provided value" + }); + } + esValue[implSymbol]["onmessage"] = V; + } + + get onmessageerror() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmessageerror' called on an object that is not a valid instance of SVGSVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmessageerror"]); + } + + set onmessageerror(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmessageerror' called on an object that is not a valid instance of SVGSVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmessageerror' property on 'SVGSVGElement': The provided value" + }); + } + esValue[implSymbol]["onmessageerror"] = V; + } + + get onoffline() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onoffline' called on an object that is not a valid instance of SVGSVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onoffline"]); + } + + set onoffline(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onoffline' called on an object that is not a valid instance of SVGSVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onoffline' property on 'SVGSVGElement': The provided value" + }); + } + esValue[implSymbol]["onoffline"] = V; + } + + get ononline() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ononline' called on an object that is not a valid instance of SVGSVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ononline"]); + } + + set ononline(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set ononline' called on an object that is not a valid instance of SVGSVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ononline' property on 'SVGSVGElement': The provided value" + }); + } + esValue[implSymbol]["ononline"] = V; + } + + get onpagehide() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onpagehide' called on an object that is not a valid instance of SVGSVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onpagehide"]); + } + + set onpagehide(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onpagehide' called on an object that is not a valid instance of SVGSVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onpagehide' property on 'SVGSVGElement': The provided value" + }); + } + esValue[implSymbol]["onpagehide"] = V; + } + + get onpageshow() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onpageshow' called on an object that is not a valid instance of SVGSVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onpageshow"]); + } + + set onpageshow(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onpageshow' called on an object that is not a valid instance of SVGSVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onpageshow' property on 'SVGSVGElement': The provided value" + }); + } + esValue[implSymbol]["onpageshow"] = V; + } + + get onpopstate() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onpopstate' called on an object that is not a valid instance of SVGSVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onpopstate"]); + } + + set onpopstate(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onpopstate' called on an object that is not a valid instance of SVGSVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onpopstate' property on 'SVGSVGElement': The provided value" + }); + } + esValue[implSymbol]["onpopstate"] = V; + } + + get onrejectionhandled() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onrejectionhandled' called on an object that is not a valid instance of SVGSVGElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onrejectionhandled"]); + } + + set onrejectionhandled(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onrejectionhandled' called on an object that is not a valid instance of SVGSVGElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onrejectionhandled' property on 'SVGSVGElement': The provided value" + }); + } + esValue[implSymbol]["onrejectionhandled"] = V; + } + + get onstorage() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onstorage' called on an object that is not a valid instance of SVGSVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onstorage"]); + } + + set onstorage(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onstorage' called on an object that is not a valid instance of SVGSVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onstorage' property on 'SVGSVGElement': The provided value" + }); + } + esValue[implSymbol]["onstorage"] = V; + } + + get onunhandledrejection() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onunhandledrejection' called on an object that is not a valid instance of SVGSVGElement." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onunhandledrejection"]); + } + + set onunhandledrejection(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onunhandledrejection' called on an object that is not a valid instance of SVGSVGElement." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onunhandledrejection' property on 'SVGSVGElement': The provided value" + }); + } + esValue[implSymbol]["onunhandledrejection"] = V; + } + + get onunload() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onunload' called on an object that is not a valid instance of SVGSVGElement."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onunload"]); + } + + set onunload(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onunload' called on an object that is not a valid instance of SVGSVGElement."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onunload' property on 'SVGSVGElement': The provided value" + }); + } + esValue[implSymbol]["onunload"] = V; + } + } + Object.defineProperties(SVGSVGElement.prototype, { + createSVGNumber: { enumerable: true }, + getElementById: { enumerable: true }, + suspendRedraw: { enumerable: true }, + unsuspendRedraw: { enumerable: true }, + unsuspendRedrawAll: { enumerable: true }, + forceRedraw: { enumerable: true }, + onafterprint: { enumerable: true }, + onbeforeprint: { enumerable: true }, + onbeforeunload: { enumerable: true }, + onhashchange: { enumerable: true }, + onlanguagechange: { enumerable: true }, + onmessage: { enumerable: true }, + onmessageerror: { enumerable: true }, + onoffline: { enumerable: true }, + ononline: { enumerable: true }, + onpagehide: { enumerable: true }, + onpageshow: { enumerable: true }, + onpopstate: { enumerable: true }, + onrejectionhandled: { enumerable: true }, + onstorage: { enumerable: true }, + onunhandledrejection: { enumerable: true }, + onunload: { enumerable: true }, + [Symbol.toStringTag]: { value: "SVGSVGElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = SVGSVGElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: SVGSVGElement + }); +}; + +const Impl = require("../nodes/SVGSVGElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/SVGStringList.js b/node_modules/jsdom/lib/jsdom/living/generated/SVGStringList.js new file mode 100644 index 000000000..1d14e0ec1 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/SVGStringList.js @@ -0,0 +1,504 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "SVGStringList"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'SVGStringList'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["SVGStringList"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor SVGStringList is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + let wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class SVGStringList { + constructor() { + throw new TypeError("Illegal constructor"); + } + + clear() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'clear' called on an object that is not a valid instance of SVGStringList."); + } + + return esValue[implSymbol].clear(); + } + + initialize(newItem) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'initialize' called on an object that is not a valid instance of SVGStringList."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'initialize' on 'SVGStringList': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'initialize' on 'SVGStringList': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].initialize(...args); + } + + getItem(index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getItem' called on an object that is not a valid instance of SVGStringList."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'getItem' on 'SVGStringList': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'getItem' on 'SVGStringList': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].getItem(...args); + } + + insertItemBefore(newItem, index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'insertItemBefore' called on an object that is not a valid instance of SVGStringList."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'insertItemBefore' on 'SVGStringList': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'insertItemBefore' on 'SVGStringList': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'insertItemBefore' on 'SVGStringList': parameter 2" + }); + args.push(curArg); + } + return esValue[implSymbol].insertItemBefore(...args); + } + + replaceItem(newItem, index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'replaceItem' called on an object that is not a valid instance of SVGStringList."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'replaceItem' on 'SVGStringList': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'replaceItem' on 'SVGStringList': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'replaceItem' on 'SVGStringList': parameter 2" + }); + args.push(curArg); + } + return esValue[implSymbol].replaceItem(...args); + } + + removeItem(index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'removeItem' called on an object that is not a valid instance of SVGStringList."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'removeItem' on 'SVGStringList': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'removeItem' on 'SVGStringList': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].removeItem(...args); + } + + appendItem(newItem) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'appendItem' called on an object that is not a valid instance of SVGStringList."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'appendItem' on 'SVGStringList': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'appendItem' on 'SVGStringList': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].appendItem(...args); + } + + get length() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get length' called on an object that is not a valid instance of SVGStringList."); + } + + return esValue[implSymbol]["length"]; + } + + get numberOfItems() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get numberOfItems' called on an object that is not a valid instance of SVGStringList."); + } + + return esValue[implSymbol]["numberOfItems"]; + } + } + Object.defineProperties(SVGStringList.prototype, { + clear: { enumerable: true }, + initialize: { enumerable: true }, + getItem: { enumerable: true }, + insertItemBefore: { enumerable: true }, + replaceItem: { enumerable: true }, + removeItem: { enumerable: true }, + appendItem: { enumerable: true }, + length: { enumerable: true }, + numberOfItems: { enumerable: true }, + [Symbol.toStringTag]: { value: "SVGStringList", configurable: true }, + [Symbol.iterator]: { value: Array.prototype[Symbol.iterator], configurable: true, writable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = SVGStringList; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: SVGStringList + }); +}; + +const proxyHandler = { + get(target, P, receiver) { + if (typeof P === "symbol") { + return Reflect.get(target, P, receiver); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc === undefined) { + const parent = Object.getPrototypeOf(target); + if (parent === null) { + return undefined; + } + return Reflect.get(target, P, receiver); + } + if (!desc.get && !desc.set) { + return desc.value; + } + const getter = desc.get; + if (getter === undefined) { + return undefined; + } + return Reflect.apply(getter, receiver, []); + }, + + has(target, P) { + if (typeof P === "symbol") { + return Reflect.has(target, P); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc !== undefined) { + return true; + } + const parent = Object.getPrototypeOf(target); + if (parent !== null) { + return Reflect.has(parent, P); + } + return false; + }, + + ownKeys(target) { + const keys = new Set(); + + for (const key of target[implSymbol][utils.supportedPropertyIndices]) { + keys.add(`${key}`); + } + + for (const key of Reflect.ownKeys(target)) { + keys.add(key); + } + return [...keys]; + }, + + getOwnPropertyDescriptor(target, P) { + if (typeof P === "symbol") { + return Reflect.getOwnPropertyDescriptor(target, P); + } + let ignoreNamedProps = false; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + + if (target[implSymbol][utils.supportsPropertyIndex](index)) { + const indexedValue = target[implSymbol].getItem(index); + return { + writable: true, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + ignoreNamedProps = true; + } + + return Reflect.getOwnPropertyDescriptor(target, P); + }, + + set(target, P, V, receiver) { + if (typeof P === "symbol") { + return Reflect.set(target, P, V, receiver); + } + // The `receiver` argument refers to the Proxy exotic object or an object + // that inherits from it, whereas `target` refers to the Proxy target: + if (target[implSymbol][utils.wrapperSymbol] === receiver) { + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + let indexedValue = V; + + indexedValue = conversions["DOMString"](indexedValue, { + context: "Failed to set the " + index + " property on 'SVGStringList': The provided value" + }); + + const creating = !target[implSymbol][utils.supportsPropertyIndex](index); + if (creating) { + target[implSymbol][utils.indexedSetNew](index, indexedValue); + } else { + target[implSymbol][utils.indexedSetExisting](index, indexedValue); + } + + return true; + } + } + let ownDesc; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + + if (target[implSymbol][utils.supportsPropertyIndex](index)) { + const indexedValue = target[implSymbol].getItem(index); + ownDesc = { + writable: true, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + } + + if (ownDesc === undefined) { + ownDesc = Reflect.getOwnPropertyDescriptor(target, P); + } + if (ownDesc === undefined) { + const parent = Reflect.getPrototypeOf(target); + if (parent !== null) { + return Reflect.set(parent, P, V, receiver); + } + ownDesc = { writable: true, enumerable: true, configurable: true, value: undefined }; + } + if (!ownDesc.writable) { + return false; + } + if (!utils.isObject(receiver)) { + return false; + } + const existingDesc = Reflect.getOwnPropertyDescriptor(receiver, P); + let valueDesc; + if (existingDesc !== undefined) { + if (existingDesc.get || existingDesc.set) { + return false; + } + if (!existingDesc.writable) { + return false; + } + valueDesc = { value: V }; + } else { + valueDesc = { writable: true, enumerable: true, configurable: true, value: V }; + } + return Reflect.defineProperty(receiver, P, valueDesc); + }, + + defineProperty(target, P, desc) { + if (typeof P === "symbol") { + return Reflect.defineProperty(target, P, desc); + } + + if (utils.isArrayIndexPropName(P)) { + if (desc.get || desc.set) { + return false; + } + + const index = P >>> 0; + let indexedValue = desc.value; + + indexedValue = conversions["DOMString"](indexedValue, { + context: "Failed to set the " + index + " property on 'SVGStringList': The provided value" + }); + + const creating = !target[implSymbol][utils.supportsPropertyIndex](index); + if (creating) { + target[implSymbol][utils.indexedSetNew](index, indexedValue); + } else { + target[implSymbol][utils.indexedSetExisting](index, indexedValue); + } + + return true; + } + + return Reflect.defineProperty(target, P, desc); + }, + + deleteProperty(target, P) { + if (typeof P === "symbol") { + return Reflect.deleteProperty(target, P); + } + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + return !target[implSymbol][utils.supportsPropertyIndex](index); + } + + return Reflect.deleteProperty(target, P); + }, + + preventExtensions() { + return false; + } +}; + +const Impl = require("../svg/SVGStringList-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/SVGTitleElement.js b/node_modules/jsdom/lib/jsdom/living/generated/SVGTitleElement.js new file mode 100644 index 000000000..be60fb616 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/SVGTitleElement.js @@ -0,0 +1,114 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const SVGElement = require("./SVGElement.js"); + +const interfaceName = "SVGTitleElement"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'SVGTitleElement'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["SVGTitleElement"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor SVGTitleElement is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + SVGElement._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.SVGElement === undefined) { + throw new Error("Internal error: attempting to evaluate SVGTitleElement before SVGElement"); + } + class SVGTitleElement extends globalObject.SVGElement { + constructor() { + throw new TypeError("Illegal constructor"); + } + } + Object.defineProperties(SVGTitleElement.prototype, { + [Symbol.toStringTag]: { value: "SVGTitleElement", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = SVGTitleElement; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: SVGTitleElement + }); +}; + +const Impl = require("../nodes/SVGTitleElement-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/Screen.js b/node_modules/jsdom/lib/jsdom/living/generated/Screen.js new file mode 100644 index 000000000..3b13a9308 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/Screen.js @@ -0,0 +1,173 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "Screen"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'Screen'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["Screen"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor Screen is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class Screen { + constructor() { + throw new TypeError("Illegal constructor"); + } + + get availWidth() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get availWidth' called on an object that is not a valid instance of Screen."); + } + + return esValue[implSymbol]["availWidth"]; + } + + get availHeight() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get availHeight' called on an object that is not a valid instance of Screen."); + } + + return esValue[implSymbol]["availHeight"]; + } + + get width() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get width' called on an object that is not a valid instance of Screen."); + } + + return esValue[implSymbol]["width"]; + } + + get height() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get height' called on an object that is not a valid instance of Screen."); + } + + return esValue[implSymbol]["height"]; + } + + get colorDepth() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get colorDepth' called on an object that is not a valid instance of Screen."); + } + + return esValue[implSymbol]["colorDepth"]; + } + + get pixelDepth() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get pixelDepth' called on an object that is not a valid instance of Screen."); + } + + return esValue[implSymbol]["pixelDepth"]; + } + } + Object.defineProperties(Screen.prototype, { + availWidth: { enumerable: true }, + availHeight: { enumerable: true }, + width: { enumerable: true }, + height: { enumerable: true }, + colorDepth: { enumerable: true }, + pixelDepth: { enumerable: true }, + [Symbol.toStringTag]: { value: "Screen", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = Screen; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: Screen + }); +}; + +const Impl = require("../window/Screen-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/ScrollBehavior.js b/node_modules/jsdom/lib/jsdom/living/generated/ScrollBehavior.js new file mode 100644 index 000000000..40ff17c57 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/ScrollBehavior.js @@ -0,0 +1,12 @@ +"use strict"; + +const enumerationValues = new Set(["auto", "instant", "smooth"]); +exports.enumerationValues = enumerationValues; + +exports.convert = function convert(value, { context = "The provided value" } = {}) { + const string = `${value}`; + if (!enumerationValues.has(string)) { + throw new TypeError(`${context} '${string}' is not a valid enumeration value for ScrollBehavior`); + } + return string; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/ScrollIntoViewOptions.js b/node_modules/jsdom/lib/jsdom/living/generated/ScrollIntoViewOptions.js new file mode 100644 index 000000000..6294eaf65 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/ScrollIntoViewOptions.js @@ -0,0 +1,45 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const ScrollLogicalPosition = require("./ScrollLogicalPosition.js"); +const ScrollOptions = require("./ScrollOptions.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + ScrollOptions._convertInherit(obj, ret, { context }); + + { + const key = "block"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = ScrollLogicalPosition.convert(value, { context: context + " has member 'block' that" }); + + ret[key] = value; + } else { + ret[key] = "start"; + } + } + + { + const key = "inline"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = ScrollLogicalPosition.convert(value, { context: context + " has member 'inline' that" }); + + ret[key] = value; + } else { + ret[key] = "nearest"; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/ScrollLogicalPosition.js b/node_modules/jsdom/lib/jsdom/living/generated/ScrollLogicalPosition.js new file mode 100644 index 000000000..4cd4a69be --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/ScrollLogicalPosition.js @@ -0,0 +1,12 @@ +"use strict"; + +const enumerationValues = new Set(["start", "center", "end", "nearest"]); +exports.enumerationValues = enumerationValues; + +exports.convert = function convert(value, { context = "The provided value" } = {}) { + const string = `${value}`; + if (!enumerationValues.has(string)) { + throw new TypeError(`${context} '${string}' is not a valid enumeration value for ScrollLogicalPosition`); + } + return string; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/ScrollOptions.js b/node_modules/jsdom/lib/jsdom/living/generated/ScrollOptions.js new file mode 100644 index 000000000..fc5a346e4 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/ScrollOptions.js @@ -0,0 +1,30 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const ScrollBehavior = require("./ScrollBehavior.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + { + const key = "behavior"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = ScrollBehavior.convert(value, { context: context + " has member 'behavior' that" }); + + ret[key] = value; + } else { + ret[key] = "auto"; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/ScrollRestoration.js b/node_modules/jsdom/lib/jsdom/living/generated/ScrollRestoration.js new file mode 100644 index 000000000..9c55989b8 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/ScrollRestoration.js @@ -0,0 +1,12 @@ +"use strict"; + +const enumerationValues = new Set(["auto", "manual"]); +exports.enumerationValues = enumerationValues; + +exports.convert = function convert(value, { context = "The provided value" } = {}) { + const string = `${value}`; + if (!enumerationValues.has(string)) { + throw new TypeError(`${context} '${string}' is not a valid enumeration value for ScrollRestoration`); + } + return string; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/Selection.js b/node_modules/jsdom/lib/jsdom/living/generated/Selection.js new file mode 100644 index 000000000..ff7dc733c --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/Selection.js @@ -0,0 +1,527 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const Range = require("./Range.js"); +const Node = require("./Node.js"); +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "Selection"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'Selection'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["Selection"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor Selection is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class Selection { + constructor() { + throw new TypeError("Illegal constructor"); + } + + getRangeAt(index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getRangeAt' called on an object that is not a valid instance of Selection."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'getRangeAt' on 'Selection': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'getRangeAt' on 'Selection': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].getRangeAt(...args)); + } + + addRange(range) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'addRange' called on an object that is not a valid instance of Selection."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'addRange' on 'Selection': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Range.convert(curArg, { context: "Failed to execute 'addRange' on 'Selection': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].addRange(...args); + } + + removeRange(range) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'removeRange' called on an object that is not a valid instance of Selection."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'removeRange' on 'Selection': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Range.convert(curArg, { context: "Failed to execute 'removeRange' on 'Selection': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].removeRange(...args); + } + + removeAllRanges() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'removeAllRanges' called on an object that is not a valid instance of Selection."); + } + + return esValue[implSymbol].removeAllRanges(); + } + + empty() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'empty' called on an object that is not a valid instance of Selection."); + } + + return esValue[implSymbol].empty(); + } + + collapse(node) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'collapse' called on an object that is not a valid instance of Selection."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'collapse' on 'Selection': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = Node.convert(curArg, { context: "Failed to execute 'collapse' on 'Selection': parameter 1" }); + } + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'collapse' on 'Selection': parameter 2" + }); + } else { + curArg = 0; + } + args.push(curArg); + } + return esValue[implSymbol].collapse(...args); + } + + setPosition(node) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'setPosition' called on an object that is not a valid instance of Selection."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'setPosition' on 'Selection': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = Node.convert(curArg, { context: "Failed to execute 'setPosition' on 'Selection': parameter 1" }); + } + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'setPosition' on 'Selection': parameter 2" + }); + } else { + curArg = 0; + } + args.push(curArg); + } + return esValue[implSymbol].setPosition(...args); + } + + collapseToStart() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'collapseToStart' called on an object that is not a valid instance of Selection."); + } + + return esValue[implSymbol].collapseToStart(); + } + + collapseToEnd() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'collapseToEnd' called on an object that is not a valid instance of Selection."); + } + + return esValue[implSymbol].collapseToEnd(); + } + + extend(node) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'extend' called on an object that is not a valid instance of Selection."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'extend' on 'Selection': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'extend' on 'Selection': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'extend' on 'Selection': parameter 2" + }); + } else { + curArg = 0; + } + args.push(curArg); + } + return esValue[implSymbol].extend(...args); + } + + setBaseAndExtent(anchorNode, anchorOffset, focusNode, focusOffset) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'setBaseAndExtent' called on an object that is not a valid instance of Selection."); + } + + if (arguments.length < 4) { + throw new TypeError( + "Failed to execute 'setBaseAndExtent' on 'Selection': 4 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'setBaseAndExtent' on 'Selection': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'setBaseAndExtent' on 'Selection': parameter 2" + }); + args.push(curArg); + } + { + let curArg = arguments[2]; + curArg = Node.convert(curArg, { context: "Failed to execute 'setBaseAndExtent' on 'Selection': parameter 3" }); + args.push(curArg); + } + { + let curArg = arguments[3]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'setBaseAndExtent' on 'Selection': parameter 4" + }); + args.push(curArg); + } + return esValue[implSymbol].setBaseAndExtent(...args); + } + + selectAllChildren(node) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'selectAllChildren' called on an object that is not a valid instance of Selection."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'selectAllChildren' on 'Selection': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'selectAllChildren' on 'Selection': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].selectAllChildren(...args); + } + + deleteFromDocument() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'deleteFromDocument' called on an object that is not a valid instance of Selection."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol].deleteFromDocument(); + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + containsNode(node) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'containsNode' called on an object that is not a valid instance of Selection."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'containsNode' on 'Selection': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { context: "Failed to execute 'containsNode' on 'Selection': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'containsNode' on 'Selection': parameter 2" + }); + } else { + curArg = false; + } + args.push(curArg); + } + return esValue[implSymbol].containsNode(...args); + } + + toString() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'toString' called on an object that is not a valid instance of Selection."); + } + + return esValue[implSymbol].toString(); + } + + get anchorNode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get anchorNode' called on an object that is not a valid instance of Selection."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["anchorNode"]); + } + + get anchorOffset() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get anchorOffset' called on an object that is not a valid instance of Selection."); + } + + return esValue[implSymbol]["anchorOffset"]; + } + + get focusNode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get focusNode' called on an object that is not a valid instance of Selection."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["focusNode"]); + } + + get focusOffset() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get focusOffset' called on an object that is not a valid instance of Selection."); + } + + return esValue[implSymbol]["focusOffset"]; + } + + get isCollapsed() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get isCollapsed' called on an object that is not a valid instance of Selection."); + } + + return esValue[implSymbol]["isCollapsed"]; + } + + get rangeCount() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get rangeCount' called on an object that is not a valid instance of Selection."); + } + + return esValue[implSymbol]["rangeCount"]; + } + + get type() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get type' called on an object that is not a valid instance of Selection."); + } + + return esValue[implSymbol]["type"]; + } + } + Object.defineProperties(Selection.prototype, { + getRangeAt: { enumerable: true }, + addRange: { enumerable: true }, + removeRange: { enumerable: true }, + removeAllRanges: { enumerable: true }, + empty: { enumerable: true }, + collapse: { enumerable: true }, + setPosition: { enumerable: true }, + collapseToStart: { enumerable: true }, + collapseToEnd: { enumerable: true }, + extend: { enumerable: true }, + setBaseAndExtent: { enumerable: true }, + selectAllChildren: { enumerable: true }, + deleteFromDocument: { enumerable: true }, + containsNode: { enumerable: true }, + toString: { enumerable: true }, + anchorNode: { enumerable: true }, + anchorOffset: { enumerable: true }, + focusNode: { enumerable: true }, + focusOffset: { enumerable: true }, + isCollapsed: { enumerable: true }, + rangeCount: { enumerable: true }, + type: { enumerable: true }, + [Symbol.toStringTag]: { value: "Selection", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = Selection; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: Selection + }); +}; + +const Impl = require("../selection/Selection-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/SelectionMode.js b/node_modules/jsdom/lib/jsdom/living/generated/SelectionMode.js new file mode 100644 index 000000000..3ee6afbfb --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/SelectionMode.js @@ -0,0 +1,12 @@ +"use strict"; + +const enumerationValues = new Set(["select", "start", "end", "preserve"]); +exports.enumerationValues = enumerationValues; + +exports.convert = function convert(value, { context = "The provided value" } = {}) { + const string = `${value}`; + if (!enumerationValues.has(string)) { + throw new TypeError(`${context} '${string}' is not a valid enumeration value for SelectionMode`); + } + return string; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/ShadowRoot.js b/node_modules/jsdom/lib/jsdom/living/generated/ShadowRoot.js new file mode 100644 index 000000000..4f68041c4 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/ShadowRoot.js @@ -0,0 +1,185 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const ceReactionsPreSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPreSteps; +const ceReactionsPostSteps_helpers_custom_elements = require("../helpers/custom-elements.js").ceReactionsPostSteps; +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const DocumentFragment = require("./DocumentFragment.js"); + +const interfaceName = "ShadowRoot"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'ShadowRoot'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["ShadowRoot"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor ShadowRoot is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + DocumentFragment._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.DocumentFragment === undefined) { + throw new Error("Internal error: attempting to evaluate ShadowRoot before DocumentFragment"); + } + class ShadowRoot extends globalObject.DocumentFragment { + constructor() { + throw new TypeError("Illegal constructor"); + } + + get mode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get mode' called on an object that is not a valid instance of ShadowRoot."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["mode"]); + } + + get host() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get host' called on an object that is not a valid instance of ShadowRoot."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["host"]); + } + + get innerHTML() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get innerHTML' called on an object that is not a valid instance of ShadowRoot."); + } + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + return esValue[implSymbol]["innerHTML"]; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + set innerHTML(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set innerHTML' called on an object that is not a valid instance of ShadowRoot."); + } + + V = conversions["DOMString"](V, { + context: "Failed to set the 'innerHTML' property on 'ShadowRoot': The provided value", + treatNullAsEmptyString: true + }); + + ceReactionsPreSteps_helpers_custom_elements(globalObject); + try { + esValue[implSymbol]["innerHTML"] = V; + } finally { + ceReactionsPostSteps_helpers_custom_elements(globalObject); + } + } + + get activeElement() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get activeElement' called on an object that is not a valid instance of ShadowRoot."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["activeElement"]); + } + } + Object.defineProperties(ShadowRoot.prototype, { + mode: { enumerable: true }, + host: { enumerable: true }, + innerHTML: { enumerable: true }, + activeElement: { enumerable: true }, + [Symbol.toStringTag]: { value: "ShadowRoot", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = ShadowRoot; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: ShadowRoot + }); +}; + +const Impl = require("../nodes/ShadowRoot-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/ShadowRootInit.js b/node_modules/jsdom/lib/jsdom/living/generated/ShadowRootInit.js new file mode 100644 index 000000000..3023fdbc9 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/ShadowRootInit.js @@ -0,0 +1,30 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const ShadowRootMode = require("./ShadowRootMode.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + { + const key = "mode"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = ShadowRootMode.convert(value, { context: context + " has member 'mode' that" }); + + ret[key] = value; + } else { + throw new TypeError("mode is required in 'ShadowRootInit'"); + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/ShadowRootMode.js b/node_modules/jsdom/lib/jsdom/living/generated/ShadowRootMode.js new file mode 100644 index 000000000..3a15717d7 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/ShadowRootMode.js @@ -0,0 +1,12 @@ +"use strict"; + +const enumerationValues = new Set(["open", "closed"]); +exports.enumerationValues = enumerationValues; + +exports.convert = function convert(value, { context = "The provided value" } = {}) { + const string = `${value}`; + if (!enumerationValues.has(string)) { + throw new TypeError(`${context} '${string}' is not a valid enumeration value for ShadowRootMode`); + } + return string; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/StaticRange.js b/node_modules/jsdom/lib/jsdom/living/generated/StaticRange.js new file mode 100644 index 000000000..bbd163996 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/StaticRange.js @@ -0,0 +1,126 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const StaticRangeInit = require("./StaticRangeInit.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const AbstractRange = require("./AbstractRange.js"); + +const interfaceName = "StaticRange"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'StaticRange'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["StaticRange"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor StaticRange is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + AbstractRange._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.AbstractRange === undefined) { + throw new Error("Internal error: attempting to evaluate StaticRange before AbstractRange"); + } + class StaticRange extends globalObject.AbstractRange { + constructor(init) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'StaticRange': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = StaticRangeInit.convert(curArg, { context: "Failed to construct 'StaticRange': parameter 1" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + } + Object.defineProperties(StaticRange.prototype, { + [Symbol.toStringTag]: { value: "StaticRange", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = StaticRange; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: StaticRange + }); +}; + +const Impl = require("../range/StaticRange-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/StaticRangeInit.js b/node_modules/jsdom/lib/jsdom/living/generated/StaticRangeInit.js new file mode 100644 index 000000000..3df433994 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/StaticRangeInit.js @@ -0,0 +1,66 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const Node = require("./Node.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + { + const key = "endContainer"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = Node.convert(value, { context: context + " has member 'endContainer' that" }); + + ret[key] = value; + } else { + throw new TypeError("endContainer is required in 'StaticRangeInit'"); + } + } + + { + const key = "endOffset"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["unsigned long"](value, { context: context + " has member 'endOffset' that" }); + + ret[key] = value; + } else { + throw new TypeError("endOffset is required in 'StaticRangeInit'"); + } + } + + { + const key = "startContainer"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = Node.convert(value, { context: context + " has member 'startContainer' that" }); + + ret[key] = value; + } else { + throw new TypeError("startContainer is required in 'StaticRangeInit'"); + } + } + + { + const key = "startOffset"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["unsigned long"](value, { context: context + " has member 'startOffset' that" }); + + ret[key] = value; + } else { + throw new TypeError("startOffset is required in 'StaticRangeInit'"); + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/Storage.js b/node_modules/jsdom/lib/jsdom/living/generated/Storage.js new file mode 100644 index 000000000..b253d8641 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/Storage.js @@ -0,0 +1,389 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "Storage"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'Storage'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["Storage"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor Storage is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + let wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class Storage { + constructor() { + throw new TypeError("Illegal constructor"); + } + + key(index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'key' called on an object that is not a valid instance of Storage."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'key' on 'Storage': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { context: "Failed to execute 'key' on 'Storage': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].key(...args); + } + + getItem(key) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getItem' called on an object that is not a valid instance of Storage."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'getItem' on 'Storage': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to execute 'getItem' on 'Storage': parameter 1" }); + args.push(curArg); + } + return esValue[implSymbol].getItem(...args); + } + + setItem(key, value) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'setItem' called on an object that is not a valid instance of Storage."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'setItem' on 'Storage': 2 arguments required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to execute 'setItem' on 'Storage': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["DOMString"](curArg, { context: "Failed to execute 'setItem' on 'Storage': parameter 2" }); + args.push(curArg); + } + return esValue[implSymbol].setItem(...args); + } + + removeItem(key) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'removeItem' called on an object that is not a valid instance of Storage."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'removeItem' on 'Storage': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'removeItem' on 'Storage': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].removeItem(...args); + } + + clear() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'clear' called on an object that is not a valid instance of Storage."); + } + + return esValue[implSymbol].clear(); + } + + get length() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get length' called on an object that is not a valid instance of Storage."); + } + + return esValue[implSymbol]["length"]; + } + } + Object.defineProperties(Storage.prototype, { + key: { enumerable: true }, + getItem: { enumerable: true }, + setItem: { enumerable: true }, + removeItem: { enumerable: true }, + clear: { enumerable: true }, + length: { enumerable: true }, + [Symbol.toStringTag]: { value: "Storage", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = Storage; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: Storage + }); +}; + +const proxyHandler = { + get(target, P, receiver) { + if (typeof P === "symbol") { + return Reflect.get(target, P, receiver); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc === undefined) { + const parent = Object.getPrototypeOf(target); + if (parent === null) { + return undefined; + } + return Reflect.get(target, P, receiver); + } + if (!desc.get && !desc.set) { + return desc.value; + } + const getter = desc.get; + if (getter === undefined) { + return undefined; + } + return Reflect.apply(getter, receiver, []); + }, + + has(target, P) { + if (typeof P === "symbol") { + return Reflect.has(target, P); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc !== undefined) { + return true; + } + const parent = Object.getPrototypeOf(target); + if (parent !== null) { + return Reflect.has(parent, P); + } + return false; + }, + + ownKeys(target) { + const keys = new Set(); + + for (const key of target[implSymbol][utils.supportedPropertyNames]) { + if (!(key in target)) { + keys.add(`${key}`); + } + } + + for (const key of Reflect.ownKeys(target)) { + keys.add(key); + } + return [...keys]; + }, + + getOwnPropertyDescriptor(target, P) { + if (typeof P === "symbol") { + return Reflect.getOwnPropertyDescriptor(target, P); + } + let ignoreNamedProps = false; + + const namedValue = target[implSymbol].getItem(P); + + if (namedValue !== null && !(P in target) && !ignoreNamedProps) { + return { + writable: true, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(namedValue) + }; + } + + return Reflect.getOwnPropertyDescriptor(target, P); + }, + + set(target, P, V, receiver) { + if (typeof P === "symbol") { + return Reflect.set(target, P, V, receiver); + } + // The `receiver` argument refers to the Proxy exotic object or an object + // that inherits from it, whereas `target` refers to the Proxy target: + if (target[implSymbol][utils.wrapperSymbol] === receiver) { + if (typeof P === "string") { + let namedValue = V; + + namedValue = conversions["DOMString"](namedValue, { + context: "Failed to set the '" + P + "' property on 'Storage': The provided value" + }); + + target[implSymbol].setItem(P, namedValue); + + return true; + } + } + let ownDesc; + + if (ownDesc === undefined) { + ownDesc = Reflect.getOwnPropertyDescriptor(target, P); + } + if (ownDesc === undefined) { + const parent = Reflect.getPrototypeOf(target); + if (parent !== null) { + return Reflect.set(parent, P, V, receiver); + } + ownDesc = { writable: true, enumerable: true, configurable: true, value: undefined }; + } + if (!ownDesc.writable) { + return false; + } + if (!utils.isObject(receiver)) { + return false; + } + const existingDesc = Reflect.getOwnPropertyDescriptor(receiver, P); + let valueDesc; + if (existingDesc !== undefined) { + if (existingDesc.get || existingDesc.set) { + return false; + } + if (!existingDesc.writable) { + return false; + } + valueDesc = { value: V }; + } else { + valueDesc = { writable: true, enumerable: true, configurable: true, value: V }; + } + return Reflect.defineProperty(receiver, P, valueDesc); + }, + + defineProperty(target, P, desc) { + if (typeof P === "symbol") { + return Reflect.defineProperty(target, P, desc); + } + if (!utils.hasOwn(target, P)) { + if (desc.get || desc.set) { + return false; + } + + let namedValue = desc.value; + + namedValue = conversions["DOMString"](namedValue, { + context: "Failed to set the '" + P + "' property on 'Storage': The provided value" + }); + + target[implSymbol].setItem(P, namedValue); + + return true; + } + return Reflect.defineProperty(target, P, desc); + }, + + deleteProperty(target, P) { + if (typeof P === "symbol") { + return Reflect.deleteProperty(target, P); + } + + if (target[implSymbol].getItem(P) !== null && !(P in target)) { + target[implSymbol].removeItem(P); + return true; + } + + return Reflect.deleteProperty(target, P); + }, + + preventExtensions() { + return false; + } +}; + +const Impl = require("../webstorage/Storage-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/StorageEvent.js b/node_modules/jsdom/lib/jsdom/living/generated/StorageEvent.js new file mode 100644 index 000000000..d40f6e8ea --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/StorageEvent.js @@ -0,0 +1,305 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const StorageEventInit = require("./StorageEventInit.js"); +const Storage = require("./Storage.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const Event = require("./Event.js"); + +const interfaceName = "StorageEvent"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'StorageEvent'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["StorageEvent"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor StorageEvent is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Event._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Event === undefined) { + throw new Error("Internal error: attempting to evaluate StorageEvent before Event"); + } + class StorageEvent extends globalObject.Event { + constructor(type) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'StorageEvent': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'StorageEvent': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = StorageEventInit.convert(curArg, { context: "Failed to construct 'StorageEvent': parameter 2" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + initStorageEvent(type) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'initStorageEvent' called on an object that is not a valid instance of StorageEvent."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'initStorageEvent' on 'StorageEvent': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'initStorageEvent' on 'StorageEvent': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initStorageEvent' on 'StorageEvent': parameter 2" + }); + } else { + curArg = false; + } + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initStorageEvent' on 'StorageEvent': parameter 3" + }); + } else { + curArg = false; + } + args.push(curArg); + } + { + let curArg = arguments[3]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'initStorageEvent' on 'StorageEvent': parameter 4" + }); + } + } else { + curArg = null; + } + args.push(curArg); + } + { + let curArg = arguments[4]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'initStorageEvent' on 'StorageEvent': parameter 5" + }); + } + } else { + curArg = null; + } + args.push(curArg); + } + { + let curArg = arguments[5]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'initStorageEvent' on 'StorageEvent': parameter 6" + }); + } + } else { + curArg = null; + } + args.push(curArg); + } + { + let curArg = arguments[6]; + if (curArg !== undefined) { + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'initStorageEvent' on 'StorageEvent': parameter 7" + }); + } else { + curArg = ""; + } + args.push(curArg); + } + { + let curArg = arguments[7]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = Storage.convert(curArg, { + context: "Failed to execute 'initStorageEvent' on 'StorageEvent': parameter 8" + }); + } + } else { + curArg = null; + } + args.push(curArg); + } + return esValue[implSymbol].initStorageEvent(...args); + } + + get key() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get key' called on an object that is not a valid instance of StorageEvent."); + } + + return esValue[implSymbol]["key"]; + } + + get oldValue() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get oldValue' called on an object that is not a valid instance of StorageEvent."); + } + + return esValue[implSymbol]["oldValue"]; + } + + get newValue() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get newValue' called on an object that is not a valid instance of StorageEvent."); + } + + return esValue[implSymbol]["newValue"]; + } + + get url() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get url' called on an object that is not a valid instance of StorageEvent."); + } + + return esValue[implSymbol]["url"]; + } + + get storageArea() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get storageArea' called on an object that is not a valid instance of StorageEvent."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["storageArea"]); + } + } + Object.defineProperties(StorageEvent.prototype, { + initStorageEvent: { enumerable: true }, + key: { enumerable: true }, + oldValue: { enumerable: true }, + newValue: { enumerable: true }, + url: { enumerable: true }, + storageArea: { enumerable: true }, + [Symbol.toStringTag]: { value: "StorageEvent", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = StorageEvent; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: StorageEvent + }); +}; + +const Impl = require("../events/StorageEvent-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/StorageEventInit.js b/node_modules/jsdom/lib/jsdom/living/generated/StorageEventInit.js new file mode 100644 index 000000000..9c28e148a --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/StorageEventInit.js @@ -0,0 +1,93 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const Storage = require("./Storage.js"); +const EventInit = require("./EventInit.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + EventInit._convertInherit(obj, ret, { context }); + + { + const key = "key"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + if (value === null || value === undefined) { + value = null; + } else { + value = conversions["DOMString"](value, { context: context + " has member 'key' that" }); + } + ret[key] = value; + } else { + ret[key] = null; + } + } + + { + const key = "newValue"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + if (value === null || value === undefined) { + value = null; + } else { + value = conversions["DOMString"](value, { context: context + " has member 'newValue' that" }); + } + ret[key] = value; + } else { + ret[key] = null; + } + } + + { + const key = "oldValue"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + if (value === null || value === undefined) { + value = null; + } else { + value = conversions["DOMString"](value, { context: context + " has member 'oldValue' that" }); + } + ret[key] = value; + } else { + ret[key] = null; + } + } + + { + const key = "storageArea"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + if (value === null || value === undefined) { + value = null; + } else { + value = Storage.convert(value, { context: context + " has member 'storageArea' that" }); + } + ret[key] = value; + } else { + ret[key] = null; + } + } + + { + const key = "url"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["USVString"](value, { context: context + " has member 'url' that" }); + + ret[key] = value; + } else { + ret[key] = ""; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/StyleSheetList.js b/node_modules/jsdom/lib/jsdom/living/generated/StyleSheetList.js new file mode 100644 index 000000000..6fa090ccd --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/StyleSheetList.js @@ -0,0 +1,307 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "StyleSheetList"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'StyleSheetList'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["StyleSheetList"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor StyleSheetList is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + let wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper = new Proxy(wrapper, proxyHandler); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class StyleSheetList { + constructor() { + throw new TypeError("Illegal constructor"); + } + + item(index) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'item' called on an object that is not a valid instance of StyleSheetList."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'item' on 'StyleSheetList': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'item' on 'StyleSheetList': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].item(...args)); + } + + get length() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get length' called on an object that is not a valid instance of StyleSheetList."); + } + + return esValue[implSymbol]["length"]; + } + } + Object.defineProperties(StyleSheetList.prototype, { + item: { enumerable: true }, + length: { enumerable: true }, + [Symbol.toStringTag]: { value: "StyleSheetList", configurable: true }, + [Symbol.iterator]: { value: Array.prototype[Symbol.iterator], configurable: true, writable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = StyleSheetList; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: StyleSheetList + }); +}; + +const proxyHandler = { + get(target, P, receiver) { + if (typeof P === "symbol") { + return Reflect.get(target, P, receiver); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc === undefined) { + const parent = Object.getPrototypeOf(target); + if (parent === null) { + return undefined; + } + return Reflect.get(target, P, receiver); + } + if (!desc.get && !desc.set) { + return desc.value; + } + const getter = desc.get; + if (getter === undefined) { + return undefined; + } + return Reflect.apply(getter, receiver, []); + }, + + has(target, P) { + if (typeof P === "symbol") { + return Reflect.has(target, P); + } + const desc = this.getOwnPropertyDescriptor(target, P); + if (desc !== undefined) { + return true; + } + const parent = Object.getPrototypeOf(target); + if (parent !== null) { + return Reflect.has(parent, P); + } + return false; + }, + + ownKeys(target) { + const keys = new Set(); + + for (const key of target[implSymbol][utils.supportedPropertyIndices]) { + keys.add(`${key}`); + } + + for (const key of Reflect.ownKeys(target)) { + keys.add(key); + } + return [...keys]; + }, + + getOwnPropertyDescriptor(target, P) { + if (typeof P === "symbol") { + return Reflect.getOwnPropertyDescriptor(target, P); + } + let ignoreNamedProps = false; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + return { + writable: false, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + ignoreNamedProps = true; + } + + return Reflect.getOwnPropertyDescriptor(target, P); + }, + + set(target, P, V, receiver) { + if (typeof P === "symbol") { + return Reflect.set(target, P, V, receiver); + } + // The `receiver` argument refers to the Proxy exotic object or an object + // that inherits from it, whereas `target` refers to the Proxy target: + if (target[implSymbol][utils.wrapperSymbol] === receiver) { + } + let ownDesc; + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + const indexedValue = target[implSymbol].item(index); + if (indexedValue !== null) { + ownDesc = { + writable: false, + enumerable: true, + configurable: true, + value: utils.tryWrapperForImpl(indexedValue) + }; + } + } + + if (ownDesc === undefined) { + ownDesc = Reflect.getOwnPropertyDescriptor(target, P); + } + if (ownDesc === undefined) { + const parent = Reflect.getPrototypeOf(target); + if (parent !== null) { + return Reflect.set(parent, P, V, receiver); + } + ownDesc = { writable: true, enumerable: true, configurable: true, value: undefined }; + } + if (!ownDesc.writable) { + return false; + } + if (!utils.isObject(receiver)) { + return false; + } + const existingDesc = Reflect.getOwnPropertyDescriptor(receiver, P); + let valueDesc; + if (existingDesc !== undefined) { + if (existingDesc.get || existingDesc.set) { + return false; + } + if (!existingDesc.writable) { + return false; + } + valueDesc = { value: V }; + } else { + valueDesc = { writable: true, enumerable: true, configurable: true, value: V }; + } + return Reflect.defineProperty(receiver, P, valueDesc); + }, + + defineProperty(target, P, desc) { + if (typeof P === "symbol") { + return Reflect.defineProperty(target, P, desc); + } + + if (utils.isArrayIndexPropName(P)) { + return false; + } + + return Reflect.defineProperty(target, P, desc); + }, + + deleteProperty(target, P) { + if (typeof P === "symbol") { + return Reflect.deleteProperty(target, P); + } + + if (utils.isArrayIndexPropName(P)) { + const index = P >>> 0; + return !(target[implSymbol].item(index) !== null); + } + + return Reflect.deleteProperty(target, P); + }, + + preventExtensions() { + return false; + } +}; + +const Impl = require("../cssom/StyleSheetList-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/SupportedType.js b/node_modules/jsdom/lib/jsdom/living/generated/SupportedType.js new file mode 100644 index 000000000..3260bac44 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/SupportedType.js @@ -0,0 +1,18 @@ +"use strict"; + +const enumerationValues = new Set([ + "text/html", + "text/xml", + "application/xml", + "application/xhtml+xml", + "image/svg+xml" +]); +exports.enumerationValues = enumerationValues; + +exports.convert = function convert(value, { context = "The provided value" } = {}) { + const string = `${value}`; + if (!enumerationValues.has(string)) { + throw new TypeError(`${context} '${string}' is not a valid enumeration value for SupportedType`); + } + return string; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/Text.js b/node_modules/jsdom/lib/jsdom/living/generated/Text.js new file mode 100644 index 000000000..8ed58cb05 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/Text.js @@ -0,0 +1,169 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const CharacterData = require("./CharacterData.js"); + +const interfaceName = "Text"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'Text'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["Text"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor Text is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + CharacterData._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.CharacterData === undefined) { + throw new Error("Internal error: attempting to evaluate Text before CharacterData"); + } + class Text extends globalObject.CharacterData { + constructor() { + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'Text': parameter 1" }); + } else { + curArg = ""; + } + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + splitText(offset) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'splitText' called on an object that is not a valid instance of Text."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'splitText' on 'Text': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["unsigned long"](curArg, { + context: "Failed to execute 'splitText' on 'Text': parameter 1" + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].splitText(...args)); + } + + get wholeText() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get wholeText' called on an object that is not a valid instance of Text."); + } + + return esValue[implSymbol]["wholeText"]; + } + + get assignedSlot() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get assignedSlot' called on an object that is not a valid instance of Text."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["assignedSlot"]); + } + } + Object.defineProperties(Text.prototype, { + splitText: { enumerable: true }, + wholeText: { enumerable: true }, + assignedSlot: { enumerable: true }, + [Symbol.toStringTag]: { value: "Text", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = Text; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: Text + }); +}; + +const Impl = require("../nodes/Text-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/TextTrackKind.js b/node_modules/jsdom/lib/jsdom/living/generated/TextTrackKind.js new file mode 100644 index 000000000..977b60720 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/TextTrackKind.js @@ -0,0 +1,12 @@ +"use strict"; + +const enumerationValues = new Set(["subtitles", "captions", "descriptions", "chapters", "metadata"]); +exports.enumerationValues = enumerationValues; + +exports.convert = function convert(value, { context = "The provided value" } = {}) { + const string = `${value}`; + if (!enumerationValues.has(string)) { + throw new TypeError(`${context} '${string}' is not a valid enumeration value for TextTrackKind`); + } + return string; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/TouchEvent.js b/node_modules/jsdom/lib/jsdom/living/generated/TouchEvent.js new file mode 100644 index 000000000..0b1932703 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/TouchEvent.js @@ -0,0 +1,208 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const TouchEventInit = require("./TouchEventInit.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const UIEvent = require("./UIEvent.js"); + +const interfaceName = "TouchEvent"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'TouchEvent'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["TouchEvent"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor TouchEvent is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + UIEvent._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.UIEvent === undefined) { + throw new Error("Internal error: attempting to evaluate TouchEvent before UIEvent"); + } + class TouchEvent extends globalObject.UIEvent { + constructor(type) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'TouchEvent': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'TouchEvent': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = TouchEventInit.convert(curArg, { context: "Failed to construct 'TouchEvent': parameter 2" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + get touches() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get touches' called on an object that is not a valid instance of TouchEvent."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["touches"]); + } + + get targetTouches() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get targetTouches' called on an object that is not a valid instance of TouchEvent."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["targetTouches"]); + } + + get changedTouches() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get changedTouches' called on an object that is not a valid instance of TouchEvent."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["changedTouches"]); + } + + get altKey() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get altKey' called on an object that is not a valid instance of TouchEvent."); + } + + return esValue[implSymbol]["altKey"]; + } + + get metaKey() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get metaKey' called on an object that is not a valid instance of TouchEvent."); + } + + return esValue[implSymbol]["metaKey"]; + } + + get ctrlKey() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get ctrlKey' called on an object that is not a valid instance of TouchEvent."); + } + + return esValue[implSymbol]["ctrlKey"]; + } + + get shiftKey() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get shiftKey' called on an object that is not a valid instance of TouchEvent."); + } + + return esValue[implSymbol]["shiftKey"]; + } + } + Object.defineProperties(TouchEvent.prototype, { + touches: { enumerable: true }, + targetTouches: { enumerable: true }, + changedTouches: { enumerable: true }, + altKey: { enumerable: true }, + metaKey: { enumerable: true }, + ctrlKey: { enumerable: true }, + shiftKey: { enumerable: true }, + [Symbol.toStringTag]: { value: "TouchEvent", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = TouchEvent; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: TouchEvent + }); +}; + +const Impl = require("../events/TouchEvent-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/TouchEventInit.js b/node_modules/jsdom/lib/jsdom/living/generated/TouchEventInit.js new file mode 100644 index 000000000..670568e5b --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/TouchEventInit.js @@ -0,0 +1,89 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventModifierInit = require("./EventModifierInit.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + EventModifierInit._convertInherit(obj, ret, { context }); + + { + const key = "changedTouches"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + if (!utils.isObject(value)) { + throw new TypeError(context + " has member 'changedTouches' that" + " is not an iterable object."); + } else { + const V = []; + const tmp = value; + for (let nextItem of tmp) { + nextItem = utils.tryImplForWrapper(nextItem); + + V.push(nextItem); + } + value = V; + } + + ret[key] = value; + } else { + ret[key] = []; + } + } + + { + const key = "targetTouches"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + if (!utils.isObject(value)) { + throw new TypeError(context + " has member 'targetTouches' that" + " is not an iterable object."); + } else { + const V = []; + const tmp = value; + for (let nextItem of tmp) { + nextItem = utils.tryImplForWrapper(nextItem); + + V.push(nextItem); + } + value = V; + } + + ret[key] = value; + } else { + ret[key] = []; + } + } + + { + const key = "touches"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + if (!utils.isObject(value)) { + throw new TypeError(context + " has member 'touches' that" + " is not an iterable object."); + } else { + const V = []; + const tmp = value; + for (let nextItem of tmp) { + nextItem = utils.tryImplForWrapper(nextItem); + + V.push(nextItem); + } + value = V; + } + + ret[key] = value; + } else { + ret[key] = []; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/TreeWalker.js b/node_modules/jsdom/lib/jsdom/living/generated/TreeWalker.js new file mode 100644 index 000000000..ed187705e --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/TreeWalker.js @@ -0,0 +1,236 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const Node = require("./Node.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "TreeWalker"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'TreeWalker'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["TreeWalker"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor TreeWalker is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class TreeWalker { + constructor() { + throw new TypeError("Illegal constructor"); + } + + parentNode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'parentNode' called on an object that is not a valid instance of TreeWalker."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].parentNode()); + } + + firstChild() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'firstChild' called on an object that is not a valid instance of TreeWalker."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].firstChild()); + } + + lastChild() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'lastChild' called on an object that is not a valid instance of TreeWalker."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].lastChild()); + } + + previousSibling() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'previousSibling' called on an object that is not a valid instance of TreeWalker."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].previousSibling()); + } + + nextSibling() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'nextSibling' called on an object that is not a valid instance of TreeWalker."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].nextSibling()); + } + + previousNode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'previousNode' called on an object that is not a valid instance of TreeWalker."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].previousNode()); + } + + nextNode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'nextNode' called on an object that is not a valid instance of TreeWalker."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol].nextNode()); + } + + get root() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get root' called on an object that is not a valid instance of TreeWalker."); + } + + return utils.getSameObject(this, "root", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["root"]); + }); + } + + get whatToShow() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get whatToShow' called on an object that is not a valid instance of TreeWalker."); + } + + return esValue[implSymbol]["whatToShow"]; + } + + get filter() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get filter' called on an object that is not a valid instance of TreeWalker."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["filter"]); + } + + get currentNode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get currentNode' called on an object that is not a valid instance of TreeWalker."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["currentNode"]); + } + + set currentNode(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set currentNode' called on an object that is not a valid instance of TreeWalker."); + } + + V = Node.convert(V, { context: "Failed to set the 'currentNode' property on 'TreeWalker': The provided value" }); + + esValue[implSymbol]["currentNode"] = V; + } + } + Object.defineProperties(TreeWalker.prototype, { + parentNode: { enumerable: true }, + firstChild: { enumerable: true }, + lastChild: { enumerable: true }, + previousSibling: { enumerable: true }, + nextSibling: { enumerable: true }, + previousNode: { enumerable: true }, + nextNode: { enumerable: true }, + root: { enumerable: true }, + whatToShow: { enumerable: true }, + filter: { enumerable: true }, + currentNode: { enumerable: true }, + [Symbol.toStringTag]: { value: "TreeWalker", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = TreeWalker; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: TreeWalker + }); +}; + +const Impl = require("../traversal/TreeWalker-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/UIEvent.js b/node_modules/jsdom/lib/jsdom/living/generated/UIEvent.js new file mode 100644 index 000000000..1b43d1c9c --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/UIEvent.js @@ -0,0 +1,235 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const UIEventInit = require("./UIEventInit.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const Event = require("./Event.js"); + +const interfaceName = "UIEvent"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'UIEvent'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["UIEvent"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor UIEvent is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Event._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Event === undefined) { + throw new Error("Internal error: attempting to evaluate UIEvent before Event"); + } + class UIEvent extends globalObject.Event { + constructor(type) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'UIEvent': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'UIEvent': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = UIEventInit.convert(curArg, { context: "Failed to construct 'UIEvent': parameter 2" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + initUIEvent(typeArg) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'initUIEvent' called on an object that is not a valid instance of UIEvent."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'initUIEvent' on 'UIEvent': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'initUIEvent' on 'UIEvent': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initUIEvent' on 'UIEvent': parameter 2" + }); + } else { + curArg = false; + } + args.push(curArg); + } + { + let curArg = arguments[2]; + if (curArg !== undefined) { + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'initUIEvent' on 'UIEvent': parameter 3" + }); + } else { + curArg = false; + } + args.push(curArg); + } + { + let curArg = arguments[3]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = utils.tryImplForWrapper(curArg); + } + } else { + curArg = null; + } + args.push(curArg); + } + { + let curArg = arguments[4]; + if (curArg !== undefined) { + curArg = conversions["long"](curArg, { + context: "Failed to execute 'initUIEvent' on 'UIEvent': parameter 5" + }); + } else { + curArg = 0; + } + args.push(curArg); + } + return esValue[implSymbol].initUIEvent(...args); + } + + get view() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get view' called on an object that is not a valid instance of UIEvent."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["view"]); + } + + get detail() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get detail' called on an object that is not a valid instance of UIEvent."); + } + + return esValue[implSymbol]["detail"]; + } + + get which() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get which' called on an object that is not a valid instance of UIEvent."); + } + + return esValue[implSymbol]["which"]; + } + } + Object.defineProperties(UIEvent.prototype, { + initUIEvent: { enumerable: true }, + view: { enumerable: true }, + detail: { enumerable: true }, + which: { enumerable: true }, + [Symbol.toStringTag]: { value: "UIEvent", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = UIEvent; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: UIEvent + }); +}; + +const Impl = require("../events/UIEvent-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/UIEventInit.js b/node_modules/jsdom/lib/jsdom/living/generated/UIEventInit.js new file mode 100644 index 000000000..9f4ceba96 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/UIEventInit.js @@ -0,0 +1,59 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventInit = require("./EventInit.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + EventInit._convertInherit(obj, ret, { context }); + + { + const key = "detail"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["long"](value, { context: context + " has member 'detail' that" }); + + ret[key] = value; + } else { + ret[key] = 0; + } + } + + { + const key = "view"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + if (value === null || value === undefined) { + value = null; + } else { + value = utils.tryImplForWrapper(value); + } + ret[key] = value; + } else { + ret[key] = null; + } + } + + { + const key = "which"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["unsigned long"](value, { context: context + " has member 'which' that" }); + + ret[key] = value; + } else { + ret[key] = 0; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/ValidityState.js b/node_modules/jsdom/lib/jsdom/living/generated/ValidityState.js new file mode 100644 index 000000000..c91f166fa --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/ValidityState.js @@ -0,0 +1,228 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "ValidityState"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'ValidityState'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["ValidityState"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor ValidityState is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class ValidityState { + constructor() { + throw new TypeError("Illegal constructor"); + } + + get valueMissing() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get valueMissing' called on an object that is not a valid instance of ValidityState."); + } + + return esValue[implSymbol]["valueMissing"]; + } + + get typeMismatch() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get typeMismatch' called on an object that is not a valid instance of ValidityState."); + } + + return esValue[implSymbol]["typeMismatch"]; + } + + get patternMismatch() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get patternMismatch' called on an object that is not a valid instance of ValidityState."); + } + + return esValue[implSymbol]["patternMismatch"]; + } + + get tooLong() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get tooLong' called on an object that is not a valid instance of ValidityState."); + } + + return esValue[implSymbol]["tooLong"]; + } + + get tooShort() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get tooShort' called on an object that is not a valid instance of ValidityState."); + } + + return esValue[implSymbol]["tooShort"]; + } + + get rangeUnderflow() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get rangeUnderflow' called on an object that is not a valid instance of ValidityState."); + } + + return esValue[implSymbol]["rangeUnderflow"]; + } + + get rangeOverflow() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get rangeOverflow' called on an object that is not a valid instance of ValidityState."); + } + + return esValue[implSymbol]["rangeOverflow"]; + } + + get stepMismatch() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get stepMismatch' called on an object that is not a valid instance of ValidityState."); + } + + return esValue[implSymbol]["stepMismatch"]; + } + + get badInput() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get badInput' called on an object that is not a valid instance of ValidityState."); + } + + return esValue[implSymbol]["badInput"]; + } + + get customError() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get customError' called on an object that is not a valid instance of ValidityState."); + } + + return esValue[implSymbol]["customError"]; + } + + get valid() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get valid' called on an object that is not a valid instance of ValidityState."); + } + + return esValue[implSymbol]["valid"]; + } + } + Object.defineProperties(ValidityState.prototype, { + valueMissing: { enumerable: true }, + typeMismatch: { enumerable: true }, + patternMismatch: { enumerable: true }, + tooLong: { enumerable: true }, + tooShort: { enumerable: true }, + rangeUnderflow: { enumerable: true }, + rangeOverflow: { enumerable: true }, + stepMismatch: { enumerable: true }, + badInput: { enumerable: true }, + customError: { enumerable: true }, + valid: { enumerable: true }, + [Symbol.toStringTag]: { value: "ValidityState", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = ValidityState; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: ValidityState + }); +}; + +const Impl = require("../constraint-validation/ValidityState-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/VisibilityState.js b/node_modules/jsdom/lib/jsdom/living/generated/VisibilityState.js new file mode 100644 index 000000000..bc198c1cf --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/VisibilityState.js @@ -0,0 +1,12 @@ +"use strict"; + +const enumerationValues = new Set(["hidden", "visible", "prerender"]); +exports.enumerationValues = enumerationValues; + +exports.convert = function convert(value, { context = "The provided value" } = {}) { + const string = `${value}`; + if (!enumerationValues.has(string)) { + throw new TypeError(`${context} '${string}' is not a valid enumeration value for VisibilityState`); + } + return string; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/VoidFunction.js b/node_modules/jsdom/lib/jsdom/living/generated/VoidFunction.js new file mode 100644 index 000000000..43b00518b --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/VoidFunction.js @@ -0,0 +1,30 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +exports.convert = (value, { context = "The provided value" } = {}) => { + if (typeof value !== "function") { + throw new TypeError(context + " is not a function"); + } + + function invokeTheCallbackFunction() { + if (new.target !== undefined) { + throw new Error("Internal error: invokeTheCallbackFunction is not a constructor"); + } + + const thisArg = utils.tryWrapperForImpl(this); + let callResult; + + callResult = Reflect.apply(value, thisArg, []); + } + + invokeTheCallbackFunction.construct = () => { + let callResult = Reflect.construct(value, []); + }; + + invokeTheCallbackFunction[utils.wrapperSymbol] = value; + invokeTheCallbackFunction.objectReference = value; + + return invokeTheCallbackFunction; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/WebSocket.js b/node_modules/jsdom/lib/jsdom/living/generated/WebSocket.js new file mode 100644 index 000000000..ade3bb5fb --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/WebSocket.js @@ -0,0 +1,444 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const Blob = require("./Blob.js"); +const EventHandlerNonNull = require("./EventHandlerNonNull.js"); +const BinaryType = require("./BinaryType.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const EventTarget = require("./EventTarget.js"); + +const interfaceName = "WebSocket"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'WebSocket'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["WebSocket"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor WebSocket is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + EventTarget._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "Worker"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.EventTarget === undefined) { + throw new Error("Internal error: attempting to evaluate WebSocket before EventTarget"); + } + class WebSocket extends globalObject.EventTarget { + constructor(url) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'WebSocket': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { context: "Failed to construct 'WebSocket': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + if (utils.isObject(curArg)) { + if (curArg[Symbol.iterator] !== undefined) { + if (!utils.isObject(curArg)) { + throw new TypeError( + "Failed to construct 'WebSocket': parameter 2" + " sequence" + " is not an iterable object." + ); + } else { + const V = []; + const tmp = curArg; + for (let nextItem of tmp) { + nextItem = conversions["DOMString"](nextItem, { + context: "Failed to construct 'WebSocket': parameter 2" + " sequence" + "'s element" + }); + + V.push(nextItem); + } + curArg = V; + } + } else { + } + } else { + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'WebSocket': parameter 2" }); + } + } else { + curArg = []; + } + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + close() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'close' called on an object that is not a valid instance of WebSocket."); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + curArg = conversions["unsigned short"](curArg, { + context: "Failed to execute 'close' on 'WebSocket': parameter 1", + clamp: true + }); + } + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== undefined) { + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'close' on 'WebSocket': parameter 2" + }); + } + args.push(curArg); + } + return esValue[implSymbol].close(...args); + } + + send(data) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'send' called on an object that is not a valid instance of WebSocket."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'send' on 'WebSocket': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + if (Blob.is(curArg)) { + { + let curArg = arguments[0]; + curArg = Blob.convert(curArg, { context: "Failed to execute 'send' on 'WebSocket': parameter 1" }); + args.push(curArg); + } + } else if (utils.isArrayBuffer(curArg)) { + { + let curArg = arguments[0]; + curArg = conversions["ArrayBuffer"](curArg, { + context: "Failed to execute 'send' on 'WebSocket': parameter 1" + }); + args.push(curArg); + } + } else if (ArrayBuffer.isView(curArg)) { + { + let curArg = arguments[0]; + if (ArrayBuffer.isView(curArg)) { + } else { + throw new TypeError( + "Failed to execute 'send' on 'WebSocket': parameter 1" + " is not of any supported type." + ); + } + args.push(curArg); + } + } else { + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'send' on 'WebSocket': parameter 1" + }); + args.push(curArg); + } + } + } + return esValue[implSymbol].send(...args); + } + + get url() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get url' called on an object that is not a valid instance of WebSocket."); + } + + return esValue[implSymbol]["url"]; + } + + get readyState() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get readyState' called on an object that is not a valid instance of WebSocket."); + } + + return esValue[implSymbol]["readyState"]; + } + + get bufferedAmount() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get bufferedAmount' called on an object that is not a valid instance of WebSocket."); + } + + return esValue[implSymbol]["bufferedAmount"]; + } + + get onopen() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onopen' called on an object that is not a valid instance of WebSocket."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onopen"]); + } + + set onopen(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onopen' called on an object that is not a valid instance of WebSocket."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onopen' property on 'WebSocket': The provided value" + }); + } + esValue[implSymbol]["onopen"] = V; + } + + get onerror() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onerror' called on an object that is not a valid instance of WebSocket."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onerror"]); + } + + set onerror(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onerror' called on an object that is not a valid instance of WebSocket."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onerror' property on 'WebSocket': The provided value" + }); + } + esValue[implSymbol]["onerror"] = V; + } + + get onclose() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onclose' called on an object that is not a valid instance of WebSocket."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onclose"]); + } + + set onclose(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onclose' called on an object that is not a valid instance of WebSocket."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onclose' property on 'WebSocket': The provided value" + }); + } + esValue[implSymbol]["onclose"] = V; + } + + get extensions() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get extensions' called on an object that is not a valid instance of WebSocket."); + } + + return esValue[implSymbol]["extensions"]; + } + + get protocol() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get protocol' called on an object that is not a valid instance of WebSocket."); + } + + return esValue[implSymbol]["protocol"]; + } + + get onmessage() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get onmessage' called on an object that is not a valid instance of WebSocket."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onmessage"]); + } + + set onmessage(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set onmessage' called on an object that is not a valid instance of WebSocket."); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onmessage' property on 'WebSocket': The provided value" + }); + } + esValue[implSymbol]["onmessage"] = V; + } + + get binaryType() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get binaryType' called on an object that is not a valid instance of WebSocket."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["binaryType"]); + } + + set binaryType(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set binaryType' called on an object that is not a valid instance of WebSocket."); + } + + V = `${V}`; + if (!BinaryType.enumerationValues.has(V)) { + return; + } + + esValue[implSymbol]["binaryType"] = V; + } + } + Object.defineProperties(WebSocket.prototype, { + close: { enumerable: true }, + send: { enumerable: true }, + url: { enumerable: true }, + readyState: { enumerable: true }, + bufferedAmount: { enumerable: true }, + onopen: { enumerable: true }, + onerror: { enumerable: true }, + onclose: { enumerable: true }, + extensions: { enumerable: true }, + protocol: { enumerable: true }, + onmessage: { enumerable: true }, + binaryType: { enumerable: true }, + [Symbol.toStringTag]: { value: "WebSocket", configurable: true }, + CONNECTING: { value: 0, enumerable: true }, + OPEN: { value: 1, enumerable: true }, + CLOSING: { value: 2, enumerable: true }, + CLOSED: { value: 3, enumerable: true } + }); + Object.defineProperties(WebSocket, { + CONNECTING: { value: 0, enumerable: true }, + OPEN: { value: 1, enumerable: true }, + CLOSING: { value: 2, enumerable: true }, + CLOSED: { value: 3, enumerable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = WebSocket; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: WebSocket + }); +}; + +const Impl = require("../websockets/WebSocket-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/WheelEvent.js b/node_modules/jsdom/lib/jsdom/living/generated/WheelEvent.js new file mode 100644 index 000000000..bbd623ece --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/WheelEvent.js @@ -0,0 +1,183 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const WheelEventInit = require("./WheelEventInit.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const MouseEvent = require("./MouseEvent.js"); + +const interfaceName = "WheelEvent"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'WheelEvent'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["WheelEvent"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor WheelEvent is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + MouseEvent._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.MouseEvent === undefined) { + throw new Error("Internal error: attempting to evaluate WheelEvent before MouseEvent"); + } + class WheelEvent extends globalObject.MouseEvent { + constructor(type) { + if (arguments.length < 1) { + throw new TypeError( + "Failed to construct 'WheelEvent': 1 argument required, but only " + arguments.length + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { context: "Failed to construct 'WheelEvent': parameter 1" }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = WheelEventInit.convert(curArg, { context: "Failed to construct 'WheelEvent': parameter 2" }); + args.push(curArg); + } + return exports.setup(Object.create(new.target.prototype), globalObject, args); + } + + get deltaX() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get deltaX' called on an object that is not a valid instance of WheelEvent."); + } + + return esValue[implSymbol]["deltaX"]; + } + + get deltaY() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get deltaY' called on an object that is not a valid instance of WheelEvent."); + } + + return esValue[implSymbol]["deltaY"]; + } + + get deltaZ() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get deltaZ' called on an object that is not a valid instance of WheelEvent."); + } + + return esValue[implSymbol]["deltaZ"]; + } + + get deltaMode() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get deltaMode' called on an object that is not a valid instance of WheelEvent."); + } + + return esValue[implSymbol]["deltaMode"]; + } + } + Object.defineProperties(WheelEvent.prototype, { + deltaX: { enumerable: true }, + deltaY: { enumerable: true }, + deltaZ: { enumerable: true }, + deltaMode: { enumerable: true }, + [Symbol.toStringTag]: { value: "WheelEvent", configurable: true }, + DOM_DELTA_PIXEL: { value: 0x00, enumerable: true }, + DOM_DELTA_LINE: { value: 0x01, enumerable: true }, + DOM_DELTA_PAGE: { value: 0x02, enumerable: true } + }); + Object.defineProperties(WheelEvent, { + DOM_DELTA_PIXEL: { value: 0x00, enumerable: true }, + DOM_DELTA_LINE: { value: 0x01, enumerable: true }, + DOM_DELTA_PAGE: { value: 0x02, enumerable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = WheelEvent; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: WheelEvent + }); +}; + +const Impl = require("../events/WheelEvent-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/WheelEventInit.js b/node_modules/jsdom/lib/jsdom/living/generated/WheelEventInit.js new file mode 100644 index 000000000..f5bc1d376 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/WheelEventInit.js @@ -0,0 +1,68 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const MouseEventInit = require("./MouseEventInit.js"); + +exports._convertInherit = (obj, ret, { context = "The provided value" } = {}) => { + MouseEventInit._convertInherit(obj, ret, { context }); + + { + const key = "deltaMode"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["unsigned long"](value, { context: context + " has member 'deltaMode' that" }); + + ret[key] = value; + } else { + ret[key] = 0; + } + } + + { + const key = "deltaX"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["double"](value, { context: context + " has member 'deltaX' that" }); + + ret[key] = value; + } else { + ret[key] = 0.0; + } + } + + { + const key = "deltaY"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["double"](value, { context: context + " has member 'deltaY' that" }); + + ret[key] = value; + } else { + ret[key] = 0.0; + } + } + + { + const key = "deltaZ"; + let value = obj === undefined || obj === null ? undefined : obj[key]; + if (value !== undefined) { + value = conversions["double"](value, { context: context + " has member 'deltaZ' that" }); + + ret[key] = value; + } else { + ret[key] = 0.0; + } + } +}; + +exports.convert = function convert(obj, { context = "The provided value" } = {}) { + if (obj !== undefined && typeof obj !== "object" && typeof obj !== "function") { + throw new TypeError(`${context} is not an object.`); + } + + const ret = Object.create(null); + exports._convertInherit(obj, ret, { context }); + return ret; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/XMLDocument.js b/node_modules/jsdom/lib/jsdom/living/generated/XMLDocument.js new file mode 100644 index 000000000..3f76007b1 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/XMLDocument.js @@ -0,0 +1,114 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const Document = require("./Document.js"); + +const interfaceName = "XMLDocument"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'XMLDocument'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["XMLDocument"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor XMLDocument is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + Document._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.Document === undefined) { + throw new Error("Internal error: attempting to evaluate XMLDocument before Document"); + } + class XMLDocument extends globalObject.Document { + constructor() { + throw new TypeError("Illegal constructor"); + } + } + Object.defineProperties(XMLDocument.prototype, { + [Symbol.toStringTag]: { value: "XMLDocument", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = XMLDocument; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: XMLDocument + }); +}; + +const Impl = require("../nodes/XMLDocument-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/XMLHttpRequest.js b/node_modules/jsdom/lib/jsdom/living/generated/XMLHttpRequest.js new file mode 100644 index 000000000..62c83094a --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/XMLHttpRequest.js @@ -0,0 +1,617 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const Document = require("./Document.js"); +const Blob = require("./Blob.js"); +const FormData = require("./FormData.js"); +const EventHandlerNonNull = require("./EventHandlerNonNull.js"); +const XMLHttpRequestResponseType = require("./XMLHttpRequestResponseType.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const XMLHttpRequestEventTarget = require("./XMLHttpRequestEventTarget.js"); + +const interfaceName = "XMLHttpRequest"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'XMLHttpRequest'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["XMLHttpRequest"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor XMLHttpRequest is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + XMLHttpRequestEventTarget._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "DedicatedWorker", "SharedWorker"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.XMLHttpRequestEventTarget === undefined) { + throw new Error("Internal error: attempting to evaluate XMLHttpRequest before XMLHttpRequestEventTarget"); + } + class XMLHttpRequest extends globalObject.XMLHttpRequestEventTarget { + constructor() { + return exports.setup(Object.create(new.target.prototype), globalObject, undefined); + } + + open(method, url) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'open' called on an object that is not a valid instance of XMLHttpRequest."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'open' on 'XMLHttpRequest': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + switch (arguments.length) { + case 2: + { + let curArg = arguments[0]; + curArg = conversions["ByteString"](curArg, { + context: "Failed to execute 'open' on 'XMLHttpRequest': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'open' on 'XMLHttpRequest': parameter 2" + }); + args.push(curArg); + } + break; + case 3: + { + let curArg = arguments[0]; + curArg = conversions["ByteString"](curArg, { + context: "Failed to execute 'open' on 'XMLHttpRequest': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'open' on 'XMLHttpRequest': parameter 2" + }); + args.push(curArg); + } + { + let curArg = arguments[2]; + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'open' on 'XMLHttpRequest': parameter 3" + }); + args.push(curArg); + } + break; + case 4: + { + let curArg = arguments[0]; + curArg = conversions["ByteString"](curArg, { + context: "Failed to execute 'open' on 'XMLHttpRequest': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'open' on 'XMLHttpRequest': parameter 2" + }); + args.push(curArg); + } + { + let curArg = arguments[2]; + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'open' on 'XMLHttpRequest': parameter 3" + }); + args.push(curArg); + } + { + let curArg = arguments[3]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'open' on 'XMLHttpRequest': parameter 4" + }); + } + } else { + curArg = null; + } + args.push(curArg); + } + break; + default: + { + let curArg = arguments[0]; + curArg = conversions["ByteString"](curArg, { + context: "Failed to execute 'open' on 'XMLHttpRequest': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'open' on 'XMLHttpRequest': parameter 2" + }); + args.push(curArg); + } + { + let curArg = arguments[2]; + curArg = conversions["boolean"](curArg, { + context: "Failed to execute 'open' on 'XMLHttpRequest': parameter 3" + }); + args.push(curArg); + } + { + let curArg = arguments[3]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'open' on 'XMLHttpRequest': parameter 4" + }); + } + } else { + curArg = null; + } + args.push(curArg); + } + { + let curArg = arguments[4]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'open' on 'XMLHttpRequest': parameter 5" + }); + } + } else { + curArg = null; + } + args.push(curArg); + } + } + return esValue[implSymbol].open(...args); + } + + setRequestHeader(name, value) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'setRequestHeader' called on an object that is not a valid instance of XMLHttpRequest."); + } + + if (arguments.length < 2) { + throw new TypeError( + "Failed to execute 'setRequestHeader' on 'XMLHttpRequest': 2 arguments required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["ByteString"](curArg, { + context: "Failed to execute 'setRequestHeader' on 'XMLHttpRequest': parameter 1" + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["ByteString"](curArg, { + context: "Failed to execute 'setRequestHeader' on 'XMLHttpRequest': parameter 2" + }); + args.push(curArg); + } + return esValue[implSymbol].setRequestHeader(...args); + } + + send() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'send' called on an object that is not a valid instance of XMLHttpRequest."); + } + const args = []; + { + let curArg = arguments[0]; + if (curArg !== undefined) { + if (curArg === null || curArg === undefined) { + curArg = null; + } else { + if (Document.is(curArg) || Blob.is(curArg) || FormData.is(curArg)) { + curArg = utils.implForWrapper(curArg); + } else if (utils.isArrayBuffer(curArg)) { + } else if (ArrayBuffer.isView(curArg)) { + } else { + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'send' on 'XMLHttpRequest': parameter 1" + }); + } + } + } else { + curArg = null; + } + args.push(curArg); + } + return esValue[implSymbol].send(...args); + } + + abort() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'abort' called on an object that is not a valid instance of XMLHttpRequest."); + } + + return esValue[implSymbol].abort(); + } + + getResponseHeader(name) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'getResponseHeader' called on an object that is not a valid instance of XMLHttpRequest."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'getResponseHeader' on 'XMLHttpRequest': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["ByteString"](curArg, { + context: "Failed to execute 'getResponseHeader' on 'XMLHttpRequest': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].getResponseHeader(...args); + } + + getAllResponseHeaders() { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError( + "'getAllResponseHeaders' called on an object that is not a valid instance of XMLHttpRequest." + ); + } + + return esValue[implSymbol].getAllResponseHeaders(); + } + + overrideMimeType(mime) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'overrideMimeType' called on an object that is not a valid instance of XMLHttpRequest."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'overrideMimeType' on 'XMLHttpRequest': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["DOMString"](curArg, { + context: "Failed to execute 'overrideMimeType' on 'XMLHttpRequest': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].overrideMimeType(...args); + } + + get onreadystatechange() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onreadystatechange' called on an object that is not a valid instance of XMLHttpRequest." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onreadystatechange"]); + } + + set onreadystatechange(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onreadystatechange' called on an object that is not a valid instance of XMLHttpRequest." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onreadystatechange' property on 'XMLHttpRequest': The provided value" + }); + } + esValue[implSymbol]["onreadystatechange"] = V; + } + + get readyState() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get readyState' called on an object that is not a valid instance of XMLHttpRequest."); + } + + return esValue[implSymbol]["readyState"]; + } + + get timeout() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get timeout' called on an object that is not a valid instance of XMLHttpRequest."); + } + + return esValue[implSymbol]["timeout"]; + } + + set timeout(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set timeout' called on an object that is not a valid instance of XMLHttpRequest."); + } + + V = conversions["unsigned long"](V, { + context: "Failed to set the 'timeout' property on 'XMLHttpRequest': The provided value" + }); + + esValue[implSymbol]["timeout"] = V; + } + + get withCredentials() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get withCredentials' called on an object that is not a valid instance of XMLHttpRequest." + ); + } + + return esValue[implSymbol]["withCredentials"]; + } + + set withCredentials(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set withCredentials' called on an object that is not a valid instance of XMLHttpRequest." + ); + } + + V = conversions["boolean"](V, { + context: "Failed to set the 'withCredentials' property on 'XMLHttpRequest': The provided value" + }); + + esValue[implSymbol]["withCredentials"] = V; + } + + get upload() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get upload' called on an object that is not a valid instance of XMLHttpRequest."); + } + + return utils.getSameObject(this, "upload", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["upload"]); + }); + } + + get responseURL() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get responseURL' called on an object that is not a valid instance of XMLHttpRequest."); + } + + return esValue[implSymbol]["responseURL"]; + } + + get status() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get status' called on an object that is not a valid instance of XMLHttpRequest."); + } + + return esValue[implSymbol]["status"]; + } + + get statusText() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get statusText' called on an object that is not a valid instance of XMLHttpRequest."); + } + + return esValue[implSymbol]["statusText"]; + } + + get responseType() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get responseType' called on an object that is not a valid instance of XMLHttpRequest."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["responseType"]); + } + + set responseType(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'set responseType' called on an object that is not a valid instance of XMLHttpRequest."); + } + + V = `${V}`; + if (!XMLHttpRequestResponseType.enumerationValues.has(V)) { + return; + } + + esValue[implSymbol]["responseType"] = V; + } + + get response() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get response' called on an object that is not a valid instance of XMLHttpRequest."); + } + + return esValue[implSymbol]["response"]; + } + + get responseText() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get responseText' called on an object that is not a valid instance of XMLHttpRequest."); + } + + return esValue[implSymbol]["responseText"]; + } + + get responseXML() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError("'get responseXML' called on an object that is not a valid instance of XMLHttpRequest."); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["responseXML"]); + } + } + Object.defineProperties(XMLHttpRequest.prototype, { + open: { enumerable: true }, + setRequestHeader: { enumerable: true }, + send: { enumerable: true }, + abort: { enumerable: true }, + getResponseHeader: { enumerable: true }, + getAllResponseHeaders: { enumerable: true }, + overrideMimeType: { enumerable: true }, + onreadystatechange: { enumerable: true }, + readyState: { enumerable: true }, + timeout: { enumerable: true }, + withCredentials: { enumerable: true }, + upload: { enumerable: true }, + responseURL: { enumerable: true }, + status: { enumerable: true }, + statusText: { enumerable: true }, + responseType: { enumerable: true }, + response: { enumerable: true }, + responseText: { enumerable: true }, + responseXML: { enumerable: true }, + [Symbol.toStringTag]: { value: "XMLHttpRequest", configurable: true }, + UNSENT: { value: 0, enumerable: true }, + OPENED: { value: 1, enumerable: true }, + HEADERS_RECEIVED: { value: 2, enumerable: true }, + LOADING: { value: 3, enumerable: true }, + DONE: { value: 4, enumerable: true } + }); + Object.defineProperties(XMLHttpRequest, { + UNSENT: { value: 0, enumerable: true }, + OPENED: { value: 1, enumerable: true }, + HEADERS_RECEIVED: { value: 2, enumerable: true }, + LOADING: { value: 3, enumerable: true }, + DONE: { value: 4, enumerable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = XMLHttpRequest; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: XMLHttpRequest + }); +}; + +const Impl = require("../xhr/XMLHttpRequest-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/XMLHttpRequestEventTarget.js b/node_modules/jsdom/lib/jsdom/living/generated/XMLHttpRequestEventTarget.js new file mode 100644 index 000000000..ecdc79714 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/XMLHttpRequestEventTarget.js @@ -0,0 +1,341 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const EventHandlerNonNull = require("./EventHandlerNonNull.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const EventTarget = require("./EventTarget.js"); + +const interfaceName = "XMLHttpRequestEventTarget"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'XMLHttpRequestEventTarget'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["XMLHttpRequestEventTarget"]; + if (ctor === undefined) { + throw new Error( + "Internal error: constructor XMLHttpRequestEventTarget is not installed on the passed global object" + ); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + EventTarget._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "DedicatedWorker", "SharedWorker"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.EventTarget === undefined) { + throw new Error("Internal error: attempting to evaluate XMLHttpRequestEventTarget before EventTarget"); + } + class XMLHttpRequestEventTarget extends globalObject.EventTarget { + constructor() { + throw new TypeError("Illegal constructor"); + } + + get onloadstart() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onloadstart' called on an object that is not a valid instance of XMLHttpRequestEventTarget." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onloadstart"]); + } + + set onloadstart(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onloadstart' called on an object that is not a valid instance of XMLHttpRequestEventTarget." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onloadstart' property on 'XMLHttpRequestEventTarget': The provided value" + }); + } + esValue[implSymbol]["onloadstart"] = V; + } + + get onprogress() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onprogress' called on an object that is not a valid instance of XMLHttpRequestEventTarget." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onprogress"]); + } + + set onprogress(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onprogress' called on an object that is not a valid instance of XMLHttpRequestEventTarget." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onprogress' property on 'XMLHttpRequestEventTarget': The provided value" + }); + } + esValue[implSymbol]["onprogress"] = V; + } + + get onabort() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onabort' called on an object that is not a valid instance of XMLHttpRequestEventTarget." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onabort"]); + } + + set onabort(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onabort' called on an object that is not a valid instance of XMLHttpRequestEventTarget." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onabort' property on 'XMLHttpRequestEventTarget': The provided value" + }); + } + esValue[implSymbol]["onabort"] = V; + } + + get onerror() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onerror' called on an object that is not a valid instance of XMLHttpRequestEventTarget." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onerror"]); + } + + set onerror(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onerror' called on an object that is not a valid instance of XMLHttpRequestEventTarget." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onerror' property on 'XMLHttpRequestEventTarget': The provided value" + }); + } + esValue[implSymbol]["onerror"] = V; + } + + get onload() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onload' called on an object that is not a valid instance of XMLHttpRequestEventTarget." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onload"]); + } + + set onload(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onload' called on an object that is not a valid instance of XMLHttpRequestEventTarget." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onload' property on 'XMLHttpRequestEventTarget': The provided value" + }); + } + esValue[implSymbol]["onload"] = V; + } + + get ontimeout() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get ontimeout' called on an object that is not a valid instance of XMLHttpRequestEventTarget." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["ontimeout"]); + } + + set ontimeout(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set ontimeout' called on an object that is not a valid instance of XMLHttpRequestEventTarget." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'ontimeout' property on 'XMLHttpRequestEventTarget': The provided value" + }); + } + esValue[implSymbol]["ontimeout"] = V; + } + + get onloadend() { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'get onloadend' called on an object that is not a valid instance of XMLHttpRequestEventTarget." + ); + } + + return utils.tryWrapperForImpl(esValue[implSymbol]["onloadend"]); + } + + set onloadend(V) { + const esValue = this !== null && this !== undefined ? this : globalObject; + + if (!exports.is(esValue)) { + throw new TypeError( + "'set onloadend' called on an object that is not a valid instance of XMLHttpRequestEventTarget." + ); + } + + if (!utils.isObject(V)) { + V = null; + } else { + V = EventHandlerNonNull.convert(V, { + context: "Failed to set the 'onloadend' property on 'XMLHttpRequestEventTarget': The provided value" + }); + } + esValue[implSymbol]["onloadend"] = V; + } + } + Object.defineProperties(XMLHttpRequestEventTarget.prototype, { + onloadstart: { enumerable: true }, + onprogress: { enumerable: true }, + onabort: { enumerable: true }, + onerror: { enumerable: true }, + onload: { enumerable: true }, + ontimeout: { enumerable: true }, + onloadend: { enumerable: true }, + [Symbol.toStringTag]: { value: "XMLHttpRequestEventTarget", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = XMLHttpRequestEventTarget; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: XMLHttpRequestEventTarget + }); +}; + +const Impl = require("../xhr/XMLHttpRequestEventTarget-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/XMLHttpRequestResponseType.js b/node_modules/jsdom/lib/jsdom/living/generated/XMLHttpRequestResponseType.js new file mode 100644 index 000000000..56696c8b0 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/XMLHttpRequestResponseType.js @@ -0,0 +1,12 @@ +"use strict"; + +const enumerationValues = new Set(["", "arraybuffer", "blob", "document", "json", "text"]); +exports.enumerationValues = enumerationValues; + +exports.convert = function convert(value, { context = "The provided value" } = {}) { + const string = `${value}`; + if (!enumerationValues.has(string)) { + throw new TypeError(`${context} '${string}' is not a valid enumeration value for XMLHttpRequestResponseType`); + } + return string; +}; diff --git a/node_modules/jsdom/lib/jsdom/living/generated/XMLHttpRequestUpload.js b/node_modules/jsdom/lib/jsdom/living/generated/XMLHttpRequestUpload.js new file mode 100644 index 000000000..3e34ade60 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/XMLHttpRequestUpload.js @@ -0,0 +1,114 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; +const XMLHttpRequestEventTarget = require("./XMLHttpRequestEventTarget.js"); + +const interfaceName = "XMLHttpRequestUpload"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'XMLHttpRequestUpload'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["XMLHttpRequestUpload"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor XMLHttpRequestUpload is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => { + XMLHttpRequestEventTarget._internalSetup(wrapper, globalObject); +}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window", "DedicatedWorker", "SharedWorker"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + + if (globalObject.XMLHttpRequestEventTarget === undefined) { + throw new Error("Internal error: attempting to evaluate XMLHttpRequestUpload before XMLHttpRequestEventTarget"); + } + class XMLHttpRequestUpload extends globalObject.XMLHttpRequestEventTarget { + constructor() { + throw new TypeError("Illegal constructor"); + } + } + Object.defineProperties(XMLHttpRequestUpload.prototype, { + [Symbol.toStringTag]: { value: "XMLHttpRequestUpload", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = XMLHttpRequestUpload; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: XMLHttpRequestUpload + }); +}; + +const Impl = require("../xhr/XMLHttpRequestUpload-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/XMLSerializer.js b/node_modules/jsdom/lib/jsdom/living/generated/XMLSerializer.js new file mode 100644 index 000000000..7cefd6b21 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/XMLSerializer.js @@ -0,0 +1,133 @@ +"use strict"; + +const conversions = require("webidl-conversions"); +const utils = require("./utils.js"); + +const Node = require("./Node.js"); +const implSymbol = utils.implSymbol; +const ctorRegistrySymbol = utils.ctorRegistrySymbol; + +const interfaceName = "XMLSerializer"; + +exports.is = value => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; +}; +exports.isImpl = value => { + return utils.isObject(value) && value instanceof Impl.implementation; +}; +exports.convert = (value, { context = "The provided value" } = {}) => { + if (exports.is(value)) { + return utils.implForWrapper(value); + } + throw new TypeError(`${context} is not of type 'XMLSerializer'.`); +}; + +function makeWrapper(globalObject) { + if (globalObject[ctorRegistrySymbol] === undefined) { + throw new Error("Internal error: invalid global object"); + } + + const ctor = globalObject[ctorRegistrySymbol]["XMLSerializer"]; + if (ctor === undefined) { + throw new Error("Internal error: constructor XMLSerializer is not installed on the passed global object"); + } + + return Object.create(ctor.prototype); +} + +exports.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports.setup(wrapper, globalObject, constructorArgs, privateData); +}; + +exports.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); +}; + +exports._internalSetup = (wrapper, globalObject) => {}; + +exports.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; +}; + +exports.new = globalObject => { + const wrapper = makeWrapper(globalObject); + + exports._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; +}; + +const exposed = new Set(["Window"]); + +exports.install = (globalObject, globalNames) => { + if (!globalNames.some(globalName => exposed.has(globalName))) { + return; + } + class XMLSerializer { + constructor() { + return exports.setup(Object.create(new.target.prototype), globalObject, undefined); + } + + serializeToString(root) { + const esValue = this !== null && this !== undefined ? this : globalObject; + if (!exports.is(esValue)) { + throw new TypeError("'serializeToString' called on an object that is not a valid instance of XMLSerializer."); + } + + if (arguments.length < 1) { + throw new TypeError( + "Failed to execute 'serializeToString' on 'XMLSerializer': 1 argument required, but only " + + arguments.length + + " present." + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = Node.convert(curArg, { + context: "Failed to execute 'serializeToString' on 'XMLSerializer': parameter 1" + }); + args.push(curArg); + } + return esValue[implSymbol].serializeToString(...args); + } + } + Object.defineProperties(XMLSerializer.prototype, { + serializeToString: { enumerable: true }, + [Symbol.toStringTag]: { value: "XMLSerializer", configurable: true } + }); + if (globalObject[ctorRegistrySymbol] === undefined) { + globalObject[ctorRegistrySymbol] = Object.create(null); + } + globalObject[ctorRegistrySymbol][interfaceName] = XMLSerializer; + + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: XMLSerializer + }); +}; + +const Impl = require("../domparsing/XMLSerializer-impl.js"); diff --git a/node_modules/jsdom/lib/jsdom/living/generated/utils.js b/node_modules/jsdom/lib/jsdom/living/generated/utils.js new file mode 100644 index 000000000..cf6d232b0 --- /dev/null +++ b/node_modules/jsdom/lib/jsdom/living/generated/utils.js @@ -0,0 +1,141 @@ +"use strict"; + +// Returns "Type(value) is Object" in ES terminology. +function isObject(value) { + return typeof value === "object" && value !== null || typeof value === "function"; +} + +const hasOwn = Function.prototype.call.bind(Object.prototype.hasOwnProperty); + +const wrapperSymbol = Symbol("wrapper"); +const implSymbol = Symbol("impl"); +const sameObjectCaches = Symbol("SameObject caches"); +const ctorRegistrySymbol = Symbol.for("[webidl2js] constructor registry"); + +function getSameObject(wrapper, prop, creator) { + if (!wrapper[sameObjectCaches]) { + wrapper[sameObjectCaches] = Object.create(null); + } + + if (prop in wrapper[sameObjectCaches]) { + return wrapper[sameObjectCaches][prop]; + } + + wrapper[sameObjectCaches][prop] = creator(); + return wrapper[sameObjectCaches][prop]; +} + +function wrapperForImpl(impl) { + return impl ? impl[wrapperSymbol] : null; +} + +function implForWrapper(wrapper) { + return wrapper ? wrapper[implSymbol] : null; +} + +function tryWrapperForImpl(impl) { + const wrapper = wrapperForImpl(impl); + return wrapper ? wrapper : impl; +} + +function tryImplForWrapper(wrapper) { + const impl = implForWrapper(wrapper); + return impl ? impl : wrapper; +} + +const iterInternalSymbol = Symbol("internal"); +const IteratorPrototype = Object.getPrototypeOf(Object.getPrototypeOf([][Symbol.iterator]())); +const AsyncIteratorPrototype = Object.getPrototypeOf(Object.getPrototypeOf(async function* () {}).prototype); + +function isArrayIndexPropName(P) { + if (typeof P !== "string") { + return false; + } + const i = P >>> 0; + if (i === Math.pow(2, 32) - 1) { + return false; + } + const s = `${i}`; + if (P !== s) { + return false; + } + return true; +} + +const byteLengthGetter = + Object.getOwnPropertyDescriptor(ArrayBuffer.prototype, "byteLength").get; +function isArrayBuffer(value) { + try { + byteLengthGetter.call(value); + return true; + } catch (e) { + return false; + } +} + +function iteratorResult([key, value], kind) { + let result; + switch (kind) { + case "key": + result = key; + break; + case "value": + result = value; + break; + case "key+value": + result = [key, value]; + break; + } + return { value: result, done: false }; +} + +const supportsPropertyIndex = Symbol("supports property index"); +const supportedPropertyIndices = Symbol("supported property indices"); +const supportsPropertyName = Symbol("supports property name"); +const supportedPropertyNames = Symbol("supported property names"); +const indexedGet = Symbol("indexed property get"); +const indexedSetNew = Symbol("indexed property set new"); +const indexedSetExisting = Symbol("indexed property set existing"); +const namedGet = Symbol("named property get"); +const namedSetNew = Symbol("named property set new"); +const namedSetExisting = Symbol("named property set existing"); +const namedDelete = Symbol("named property delete"); + +const asyncIteratorNext = Symbol("async iterator get the next iteration result"); +const asyncIteratorReturn = Symbol("async iterator return steps"); +const asyncIteratorInit = Symbol("async iterator initialization steps"); +const asyncIteratorEOI = Symbol("async iterator end of iteration"); + +module.exports = exports = { + isObject, + hasOwn, + wrapperSymbol, + implSymbol, + getSameObject, + ctorRegistrySymbol, + wrapperForImpl, + implForWrapper, + tryWrapperForImpl, + tryImplForWrapper, + iterInternalSymbol, + IteratorPrototype, + AsyncIteratorPrototype, + isArrayBuffer, + isArrayIndexPropName, + supportsPropertyIndex, + supportedPropertyIndices, + supportsPropertyName, + supportedPropertyNames, + indexedGet, + indexedSetNew, + indexedSetExisting, + namedGet, + namedSetNew, + namedSetExisting, + namedDelete, + asyncIteratorNext, + asyncIteratorReturn, + asyncIteratorInit, + asyncIteratorEOI, + iteratorResult +}; diff --git a/node_modules/nyc/node_modules/@babel/traverse/lib/path/generated/asserts.js b/node_modules/nyc/node_modules/@babel/traverse/lib/path/generated/asserts.js new file mode 100644 index 000000000..bee8a438e --- /dev/null +++ b/node_modules/nyc/node_modules/@babel/traverse/lib/path/generated/asserts.js @@ -0,0 +1,5 @@ +"use strict"; + +var t = require("@babel/types"); + +var _index = require("../index"); \ No newline at end of file diff --git a/node_modules/nyc/node_modules/@babel/traverse/lib/path/generated/validators.js b/node_modules/nyc/node_modules/@babel/traverse/lib/path/generated/validators.js new file mode 100644 index 000000000..bee8a438e --- /dev/null +++ b/node_modules/nyc/node_modules/@babel/traverse/lib/path/generated/validators.js @@ -0,0 +1,5 @@ +"use strict"; + +var t = require("@babel/types"); + +var _index = require("../index"); \ No newline at end of file diff --git a/node_modules/nyc/node_modules/@babel/traverse/lib/path/generated/virtual-types.js b/node_modules/nyc/node_modules/@babel/traverse/lib/path/generated/virtual-types.js new file mode 100644 index 000000000..bf37ed937 --- /dev/null +++ b/node_modules/nyc/node_modules/@babel/traverse/lib/path/generated/virtual-types.js @@ -0,0 +1,3 @@ +"use strict"; + +var t = require("@babel/types"); \ No newline at end of file diff --git a/node_modules/nyc/node_modules/@babel/types/lib/asserts/generated/index.js b/node_modules/nyc/node_modules/@babel/types/lib/asserts/generated/index.js new file mode 100644 index 000000000..b75a4e936 --- /dev/null +++ b/node_modules/nyc/node_modules/@babel/types/lib/asserts/generated/index.js @@ -0,0 +1,1522 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.assertAccessor = assertAccessor; +exports.assertAnyTypeAnnotation = assertAnyTypeAnnotation; +exports.assertArgumentPlaceholder = assertArgumentPlaceholder; +exports.assertArrayExpression = assertArrayExpression; +exports.assertArrayPattern = assertArrayPattern; +exports.assertArrayTypeAnnotation = assertArrayTypeAnnotation; +exports.assertArrowFunctionExpression = assertArrowFunctionExpression; +exports.assertAssignmentExpression = assertAssignmentExpression; +exports.assertAssignmentPattern = assertAssignmentPattern; +exports.assertAwaitExpression = assertAwaitExpression; +exports.assertBigIntLiteral = assertBigIntLiteral; +exports.assertBinary = assertBinary; +exports.assertBinaryExpression = assertBinaryExpression; +exports.assertBindExpression = assertBindExpression; +exports.assertBlock = assertBlock; +exports.assertBlockParent = assertBlockParent; +exports.assertBlockStatement = assertBlockStatement; +exports.assertBooleanLiteral = assertBooleanLiteral; +exports.assertBooleanLiteralTypeAnnotation = assertBooleanLiteralTypeAnnotation; +exports.assertBooleanTypeAnnotation = assertBooleanTypeAnnotation; +exports.assertBreakStatement = assertBreakStatement; +exports.assertCallExpression = assertCallExpression; +exports.assertCatchClause = assertCatchClause; +exports.assertClass = assertClass; +exports.assertClassAccessorProperty = assertClassAccessorProperty; +exports.assertClassBody = assertClassBody; +exports.assertClassDeclaration = assertClassDeclaration; +exports.assertClassExpression = assertClassExpression; +exports.assertClassImplements = assertClassImplements; +exports.assertClassMethod = assertClassMethod; +exports.assertClassPrivateMethod = assertClassPrivateMethod; +exports.assertClassPrivateProperty = assertClassPrivateProperty; +exports.assertClassProperty = assertClassProperty; +exports.assertCompletionStatement = assertCompletionStatement; +exports.assertConditional = assertConditional; +exports.assertConditionalExpression = assertConditionalExpression; +exports.assertContinueStatement = assertContinueStatement; +exports.assertDebuggerStatement = assertDebuggerStatement; +exports.assertDecimalLiteral = assertDecimalLiteral; +exports.assertDeclaration = assertDeclaration; +exports.assertDeclareClass = assertDeclareClass; +exports.assertDeclareExportAllDeclaration = assertDeclareExportAllDeclaration; +exports.assertDeclareExportDeclaration = assertDeclareExportDeclaration; +exports.assertDeclareFunction = assertDeclareFunction; +exports.assertDeclareInterface = assertDeclareInterface; +exports.assertDeclareModule = assertDeclareModule; +exports.assertDeclareModuleExports = assertDeclareModuleExports; +exports.assertDeclareOpaqueType = assertDeclareOpaqueType; +exports.assertDeclareTypeAlias = assertDeclareTypeAlias; +exports.assertDeclareVariable = assertDeclareVariable; +exports.assertDeclaredPredicate = assertDeclaredPredicate; +exports.assertDecorator = assertDecorator; +exports.assertDirective = assertDirective; +exports.assertDirectiveLiteral = assertDirectiveLiteral; +exports.assertDoExpression = assertDoExpression; +exports.assertDoWhileStatement = assertDoWhileStatement; +exports.assertEmptyStatement = assertEmptyStatement; +exports.assertEmptyTypeAnnotation = assertEmptyTypeAnnotation; +exports.assertEnumBody = assertEnumBody; +exports.assertEnumBooleanBody = assertEnumBooleanBody; +exports.assertEnumBooleanMember = assertEnumBooleanMember; +exports.assertEnumDeclaration = assertEnumDeclaration; +exports.assertEnumDefaultedMember = assertEnumDefaultedMember; +exports.assertEnumMember = assertEnumMember; +exports.assertEnumNumberBody = assertEnumNumberBody; +exports.assertEnumNumberMember = assertEnumNumberMember; +exports.assertEnumStringBody = assertEnumStringBody; +exports.assertEnumStringMember = assertEnumStringMember; +exports.assertEnumSymbolBody = assertEnumSymbolBody; +exports.assertExistsTypeAnnotation = assertExistsTypeAnnotation; +exports.assertExportAllDeclaration = assertExportAllDeclaration; +exports.assertExportDeclaration = assertExportDeclaration; +exports.assertExportDefaultDeclaration = assertExportDefaultDeclaration; +exports.assertExportDefaultSpecifier = assertExportDefaultSpecifier; +exports.assertExportNamedDeclaration = assertExportNamedDeclaration; +exports.assertExportNamespaceSpecifier = assertExportNamespaceSpecifier; +exports.assertExportSpecifier = assertExportSpecifier; +exports.assertExpression = assertExpression; +exports.assertExpressionStatement = assertExpressionStatement; +exports.assertExpressionWrapper = assertExpressionWrapper; +exports.assertFile = assertFile; +exports.assertFlow = assertFlow; +exports.assertFlowBaseAnnotation = assertFlowBaseAnnotation; +exports.assertFlowDeclaration = assertFlowDeclaration; +exports.assertFlowPredicate = assertFlowPredicate; +exports.assertFlowType = assertFlowType; +exports.assertFor = assertFor; +exports.assertForInStatement = assertForInStatement; +exports.assertForOfStatement = assertForOfStatement; +exports.assertForStatement = assertForStatement; +exports.assertForXStatement = assertForXStatement; +exports.assertFunction = assertFunction; +exports.assertFunctionDeclaration = assertFunctionDeclaration; +exports.assertFunctionExpression = assertFunctionExpression; +exports.assertFunctionParent = assertFunctionParent; +exports.assertFunctionTypeAnnotation = assertFunctionTypeAnnotation; +exports.assertFunctionTypeParam = assertFunctionTypeParam; +exports.assertGenericTypeAnnotation = assertGenericTypeAnnotation; +exports.assertIdentifier = assertIdentifier; +exports.assertIfStatement = assertIfStatement; +exports.assertImmutable = assertImmutable; +exports.assertImport = assertImport; +exports.assertImportAttribute = assertImportAttribute; +exports.assertImportDeclaration = assertImportDeclaration; +exports.assertImportDefaultSpecifier = assertImportDefaultSpecifier; +exports.assertImportNamespaceSpecifier = assertImportNamespaceSpecifier; +exports.assertImportSpecifier = assertImportSpecifier; +exports.assertIndexedAccessType = assertIndexedAccessType; +exports.assertInferredPredicate = assertInferredPredicate; +exports.assertInterfaceDeclaration = assertInterfaceDeclaration; +exports.assertInterfaceExtends = assertInterfaceExtends; +exports.assertInterfaceTypeAnnotation = assertInterfaceTypeAnnotation; +exports.assertInterpreterDirective = assertInterpreterDirective; +exports.assertIntersectionTypeAnnotation = assertIntersectionTypeAnnotation; +exports.assertJSX = assertJSX; +exports.assertJSXAttribute = assertJSXAttribute; +exports.assertJSXClosingElement = assertJSXClosingElement; +exports.assertJSXClosingFragment = assertJSXClosingFragment; +exports.assertJSXElement = assertJSXElement; +exports.assertJSXEmptyExpression = assertJSXEmptyExpression; +exports.assertJSXExpressionContainer = assertJSXExpressionContainer; +exports.assertJSXFragment = assertJSXFragment; +exports.assertJSXIdentifier = assertJSXIdentifier; +exports.assertJSXMemberExpression = assertJSXMemberExpression; +exports.assertJSXNamespacedName = assertJSXNamespacedName; +exports.assertJSXOpeningElement = assertJSXOpeningElement; +exports.assertJSXOpeningFragment = assertJSXOpeningFragment; +exports.assertJSXSpreadAttribute = assertJSXSpreadAttribute; +exports.assertJSXSpreadChild = assertJSXSpreadChild; +exports.assertJSXText = assertJSXText; +exports.assertLVal = assertLVal; +exports.assertLabeledStatement = assertLabeledStatement; +exports.assertLiteral = assertLiteral; +exports.assertLogicalExpression = assertLogicalExpression; +exports.assertLoop = assertLoop; +exports.assertMemberExpression = assertMemberExpression; +exports.assertMetaProperty = assertMetaProperty; +exports.assertMethod = assertMethod; +exports.assertMiscellaneous = assertMiscellaneous; +exports.assertMixedTypeAnnotation = assertMixedTypeAnnotation; +exports.assertModuleDeclaration = assertModuleDeclaration; +exports.assertModuleExpression = assertModuleExpression; +exports.assertModuleSpecifier = assertModuleSpecifier; +exports.assertNewExpression = assertNewExpression; +exports.assertNoop = assertNoop; +exports.assertNullLiteral = assertNullLiteral; +exports.assertNullLiteralTypeAnnotation = assertNullLiteralTypeAnnotation; +exports.assertNullableTypeAnnotation = assertNullableTypeAnnotation; +exports.assertNumberLiteral = assertNumberLiteral; +exports.assertNumberLiteralTypeAnnotation = assertNumberLiteralTypeAnnotation; +exports.assertNumberTypeAnnotation = assertNumberTypeAnnotation; +exports.assertNumericLiteral = assertNumericLiteral; +exports.assertObjectExpression = assertObjectExpression; +exports.assertObjectMember = assertObjectMember; +exports.assertObjectMethod = assertObjectMethod; +exports.assertObjectPattern = assertObjectPattern; +exports.assertObjectProperty = assertObjectProperty; +exports.assertObjectTypeAnnotation = assertObjectTypeAnnotation; +exports.assertObjectTypeCallProperty = assertObjectTypeCallProperty; +exports.assertObjectTypeIndexer = assertObjectTypeIndexer; +exports.assertObjectTypeInternalSlot = assertObjectTypeInternalSlot; +exports.assertObjectTypeProperty = assertObjectTypeProperty; +exports.assertObjectTypeSpreadProperty = assertObjectTypeSpreadProperty; +exports.assertOpaqueType = assertOpaqueType; +exports.assertOptionalCallExpression = assertOptionalCallExpression; +exports.assertOptionalIndexedAccessType = assertOptionalIndexedAccessType; +exports.assertOptionalMemberExpression = assertOptionalMemberExpression; +exports.assertParenthesizedExpression = assertParenthesizedExpression; +exports.assertPattern = assertPattern; +exports.assertPatternLike = assertPatternLike; +exports.assertPipelineBareFunction = assertPipelineBareFunction; +exports.assertPipelinePrimaryTopicReference = assertPipelinePrimaryTopicReference; +exports.assertPipelineTopicExpression = assertPipelineTopicExpression; +exports.assertPlaceholder = assertPlaceholder; +exports.assertPrivate = assertPrivate; +exports.assertPrivateName = assertPrivateName; +exports.assertProgram = assertProgram; +exports.assertProperty = assertProperty; +exports.assertPureish = assertPureish; +exports.assertQualifiedTypeIdentifier = assertQualifiedTypeIdentifier; +exports.assertRecordExpression = assertRecordExpression; +exports.assertRegExpLiteral = assertRegExpLiteral; +exports.assertRegexLiteral = assertRegexLiteral; +exports.assertRestElement = assertRestElement; +exports.assertRestProperty = assertRestProperty; +exports.assertReturnStatement = assertReturnStatement; +exports.assertScopable = assertScopable; +exports.assertSequenceExpression = assertSequenceExpression; +exports.assertSpreadElement = assertSpreadElement; +exports.assertSpreadProperty = assertSpreadProperty; +exports.assertStandardized = assertStandardized; +exports.assertStatement = assertStatement; +exports.assertStaticBlock = assertStaticBlock; +exports.assertStringLiteral = assertStringLiteral; +exports.assertStringLiteralTypeAnnotation = assertStringLiteralTypeAnnotation; +exports.assertStringTypeAnnotation = assertStringTypeAnnotation; +exports.assertSuper = assertSuper; +exports.assertSwitchCase = assertSwitchCase; +exports.assertSwitchStatement = assertSwitchStatement; +exports.assertSymbolTypeAnnotation = assertSymbolTypeAnnotation; +exports.assertTSAnyKeyword = assertTSAnyKeyword; +exports.assertTSArrayType = assertTSArrayType; +exports.assertTSAsExpression = assertTSAsExpression; +exports.assertTSBaseType = assertTSBaseType; +exports.assertTSBigIntKeyword = assertTSBigIntKeyword; +exports.assertTSBooleanKeyword = assertTSBooleanKeyword; +exports.assertTSCallSignatureDeclaration = assertTSCallSignatureDeclaration; +exports.assertTSConditionalType = assertTSConditionalType; +exports.assertTSConstructSignatureDeclaration = assertTSConstructSignatureDeclaration; +exports.assertTSConstructorType = assertTSConstructorType; +exports.assertTSDeclareFunction = assertTSDeclareFunction; +exports.assertTSDeclareMethod = assertTSDeclareMethod; +exports.assertTSEntityName = assertTSEntityName; +exports.assertTSEnumDeclaration = assertTSEnumDeclaration; +exports.assertTSEnumMember = assertTSEnumMember; +exports.assertTSExportAssignment = assertTSExportAssignment; +exports.assertTSExpressionWithTypeArguments = assertTSExpressionWithTypeArguments; +exports.assertTSExternalModuleReference = assertTSExternalModuleReference; +exports.assertTSFunctionType = assertTSFunctionType; +exports.assertTSImportEqualsDeclaration = assertTSImportEqualsDeclaration; +exports.assertTSImportType = assertTSImportType; +exports.assertTSIndexSignature = assertTSIndexSignature; +exports.assertTSIndexedAccessType = assertTSIndexedAccessType; +exports.assertTSInferType = assertTSInferType; +exports.assertTSInstantiationExpression = assertTSInstantiationExpression; +exports.assertTSInterfaceBody = assertTSInterfaceBody; +exports.assertTSInterfaceDeclaration = assertTSInterfaceDeclaration; +exports.assertTSIntersectionType = assertTSIntersectionType; +exports.assertTSIntrinsicKeyword = assertTSIntrinsicKeyword; +exports.assertTSLiteralType = assertTSLiteralType; +exports.assertTSMappedType = assertTSMappedType; +exports.assertTSMethodSignature = assertTSMethodSignature; +exports.assertTSModuleBlock = assertTSModuleBlock; +exports.assertTSModuleDeclaration = assertTSModuleDeclaration; +exports.assertTSNamedTupleMember = assertTSNamedTupleMember; +exports.assertTSNamespaceExportDeclaration = assertTSNamespaceExportDeclaration; +exports.assertTSNeverKeyword = assertTSNeverKeyword; +exports.assertTSNonNullExpression = assertTSNonNullExpression; +exports.assertTSNullKeyword = assertTSNullKeyword; +exports.assertTSNumberKeyword = assertTSNumberKeyword; +exports.assertTSObjectKeyword = assertTSObjectKeyword; +exports.assertTSOptionalType = assertTSOptionalType; +exports.assertTSParameterProperty = assertTSParameterProperty; +exports.assertTSParenthesizedType = assertTSParenthesizedType; +exports.assertTSPropertySignature = assertTSPropertySignature; +exports.assertTSQualifiedName = assertTSQualifiedName; +exports.assertTSRestType = assertTSRestType; +exports.assertTSStringKeyword = assertTSStringKeyword; +exports.assertTSSymbolKeyword = assertTSSymbolKeyword; +exports.assertTSThisType = assertTSThisType; +exports.assertTSTupleType = assertTSTupleType; +exports.assertTSType = assertTSType; +exports.assertTSTypeAliasDeclaration = assertTSTypeAliasDeclaration; +exports.assertTSTypeAnnotation = assertTSTypeAnnotation; +exports.assertTSTypeAssertion = assertTSTypeAssertion; +exports.assertTSTypeElement = assertTSTypeElement; +exports.assertTSTypeLiteral = assertTSTypeLiteral; +exports.assertTSTypeOperator = assertTSTypeOperator; +exports.assertTSTypeParameter = assertTSTypeParameter; +exports.assertTSTypeParameterDeclaration = assertTSTypeParameterDeclaration; +exports.assertTSTypeParameterInstantiation = assertTSTypeParameterInstantiation; +exports.assertTSTypePredicate = assertTSTypePredicate; +exports.assertTSTypeQuery = assertTSTypeQuery; +exports.assertTSTypeReference = assertTSTypeReference; +exports.assertTSUndefinedKeyword = assertTSUndefinedKeyword; +exports.assertTSUnionType = assertTSUnionType; +exports.assertTSUnknownKeyword = assertTSUnknownKeyword; +exports.assertTSVoidKeyword = assertTSVoidKeyword; +exports.assertTaggedTemplateExpression = assertTaggedTemplateExpression; +exports.assertTemplateElement = assertTemplateElement; +exports.assertTemplateLiteral = assertTemplateLiteral; +exports.assertTerminatorless = assertTerminatorless; +exports.assertThisExpression = assertThisExpression; +exports.assertThisTypeAnnotation = assertThisTypeAnnotation; +exports.assertThrowStatement = assertThrowStatement; +exports.assertTopicReference = assertTopicReference; +exports.assertTryStatement = assertTryStatement; +exports.assertTupleExpression = assertTupleExpression; +exports.assertTupleTypeAnnotation = assertTupleTypeAnnotation; +exports.assertTypeAlias = assertTypeAlias; +exports.assertTypeAnnotation = assertTypeAnnotation; +exports.assertTypeCastExpression = assertTypeCastExpression; +exports.assertTypeParameter = assertTypeParameter; +exports.assertTypeParameterDeclaration = assertTypeParameterDeclaration; +exports.assertTypeParameterInstantiation = assertTypeParameterInstantiation; +exports.assertTypeScript = assertTypeScript; +exports.assertTypeofTypeAnnotation = assertTypeofTypeAnnotation; +exports.assertUnaryExpression = assertUnaryExpression; +exports.assertUnaryLike = assertUnaryLike; +exports.assertUnionTypeAnnotation = assertUnionTypeAnnotation; +exports.assertUpdateExpression = assertUpdateExpression; +exports.assertUserWhitespacable = assertUserWhitespacable; +exports.assertV8IntrinsicIdentifier = assertV8IntrinsicIdentifier; +exports.assertVariableDeclaration = assertVariableDeclaration; +exports.assertVariableDeclarator = assertVariableDeclarator; +exports.assertVariance = assertVariance; +exports.assertVoidTypeAnnotation = assertVoidTypeAnnotation; +exports.assertWhile = assertWhile; +exports.assertWhileStatement = assertWhileStatement; +exports.assertWithStatement = assertWithStatement; +exports.assertYieldExpression = assertYieldExpression; + +var _is = require("../../validators/is"); + +function assert(type, node, opts) { + if (!(0, _is.default)(type, node, opts)) { + throw new Error(`Expected type "${type}" with option ${JSON.stringify(opts)}, ` + `but instead got "${node.type}".`); + } +} + +function assertArrayExpression(node, opts) { + assert("ArrayExpression", node, opts); +} + +function assertAssignmentExpression(node, opts) { + assert("AssignmentExpression", node, opts); +} + +function assertBinaryExpression(node, opts) { + assert("BinaryExpression", node, opts); +} + +function assertInterpreterDirective(node, opts) { + assert("InterpreterDirective", node, opts); +} + +function assertDirective(node, opts) { + assert("Directive", node, opts); +} + +function assertDirectiveLiteral(node, opts) { + assert("DirectiveLiteral", node, opts); +} + +function assertBlockStatement(node, opts) { + assert("BlockStatement", node, opts); +} + +function assertBreakStatement(node, opts) { + assert("BreakStatement", node, opts); +} + +function assertCallExpression(node, opts) { + assert("CallExpression", node, opts); +} + +function assertCatchClause(node, opts) { + assert("CatchClause", node, opts); +} + +function assertConditionalExpression(node, opts) { + assert("ConditionalExpression", node, opts); +} + +function assertContinueStatement(node, opts) { + assert("ContinueStatement", node, opts); +} + +function assertDebuggerStatement(node, opts) { + assert("DebuggerStatement", node, opts); +} + +function assertDoWhileStatement(node, opts) { + assert("DoWhileStatement", node, opts); +} + +function assertEmptyStatement(node, opts) { + assert("EmptyStatement", node, opts); +} + +function assertExpressionStatement(node, opts) { + assert("ExpressionStatement", node, opts); +} + +function assertFile(node, opts) { + assert("File", node, opts); +} + +function assertForInStatement(node, opts) { + assert("ForInStatement", node, opts); +} + +function assertForStatement(node, opts) { + assert("ForStatement", node, opts); +} + +function assertFunctionDeclaration(node, opts) { + assert("FunctionDeclaration", node, opts); +} + +function assertFunctionExpression(node, opts) { + assert("FunctionExpression", node, opts); +} + +function assertIdentifier(node, opts) { + assert("Identifier", node, opts); +} + +function assertIfStatement(node, opts) { + assert("IfStatement", node, opts); +} + +function assertLabeledStatement(node, opts) { + assert("LabeledStatement", node, opts); +} + +function assertStringLiteral(node, opts) { + assert("StringLiteral", node, opts); +} + +function assertNumericLiteral(node, opts) { + assert("NumericLiteral", node, opts); +} + +function assertNullLiteral(node, opts) { + assert("NullLiteral", node, opts); +} + +function assertBooleanLiteral(node, opts) { + assert("BooleanLiteral", node, opts); +} + +function assertRegExpLiteral(node, opts) { + assert("RegExpLiteral", node, opts); +} + +function assertLogicalExpression(node, opts) { + assert("LogicalExpression", node, opts); +} + +function assertMemberExpression(node, opts) { + assert("MemberExpression", node, opts); +} + +function assertNewExpression(node, opts) { + assert("NewExpression", node, opts); +} + +function assertProgram(node, opts) { + assert("Program", node, opts); +} + +function assertObjectExpression(node, opts) { + assert("ObjectExpression", node, opts); +} + +function assertObjectMethod(node, opts) { + assert("ObjectMethod", node, opts); +} + +function assertObjectProperty(node, opts) { + assert("ObjectProperty", node, opts); +} + +function assertRestElement(node, opts) { + assert("RestElement", node, opts); +} + +function assertReturnStatement(node, opts) { + assert("ReturnStatement", node, opts); +} + +function assertSequenceExpression(node, opts) { + assert("SequenceExpression", node, opts); +} + +function assertParenthesizedExpression(node, opts) { + assert("ParenthesizedExpression", node, opts); +} + +function assertSwitchCase(node, opts) { + assert("SwitchCase", node, opts); +} + +function assertSwitchStatement(node, opts) { + assert("SwitchStatement", node, opts); +} + +function assertThisExpression(node, opts) { + assert("ThisExpression", node, opts); +} + +function assertThrowStatement(node, opts) { + assert("ThrowStatement", node, opts); +} + +function assertTryStatement(node, opts) { + assert("TryStatement", node, opts); +} + +function assertUnaryExpression(node, opts) { + assert("UnaryExpression", node, opts); +} + +function assertUpdateExpression(node, opts) { + assert("UpdateExpression", node, opts); +} + +function assertVariableDeclaration(node, opts) { + assert("VariableDeclaration", node, opts); +} + +function assertVariableDeclarator(node, opts) { + assert("VariableDeclarator", node, opts); +} + +function assertWhileStatement(node, opts) { + assert("WhileStatement", node, opts); +} + +function assertWithStatement(node, opts) { + assert("WithStatement", node, opts); +} + +function assertAssignmentPattern(node, opts) { + assert("AssignmentPattern", node, opts); +} + +function assertArrayPattern(node, opts) { + assert("ArrayPattern", node, opts); +} + +function assertArrowFunctionExpression(node, opts) { + assert("ArrowFunctionExpression", node, opts); +} + +function assertClassBody(node, opts) { + assert("ClassBody", node, opts); +} + +function assertClassExpression(node, opts) { + assert("ClassExpression", node, opts); +} + +function assertClassDeclaration(node, opts) { + assert("ClassDeclaration", node, opts); +} + +function assertExportAllDeclaration(node, opts) { + assert("ExportAllDeclaration", node, opts); +} + +function assertExportDefaultDeclaration(node, opts) { + assert("ExportDefaultDeclaration", node, opts); +} + +function assertExportNamedDeclaration(node, opts) { + assert("ExportNamedDeclaration", node, opts); +} + +function assertExportSpecifier(node, opts) { + assert("ExportSpecifier", node, opts); +} + +function assertForOfStatement(node, opts) { + assert("ForOfStatement", node, opts); +} + +function assertImportDeclaration(node, opts) { + assert("ImportDeclaration", node, opts); +} + +function assertImportDefaultSpecifier(node, opts) { + assert("ImportDefaultSpecifier", node, opts); +} + +function assertImportNamespaceSpecifier(node, opts) { + assert("ImportNamespaceSpecifier", node, opts); +} + +function assertImportSpecifier(node, opts) { + assert("ImportSpecifier", node, opts); +} + +function assertMetaProperty(node, opts) { + assert("MetaProperty", node, opts); +} + +function assertClassMethod(node, opts) { + assert("ClassMethod", node, opts); +} + +function assertObjectPattern(node, opts) { + assert("ObjectPattern", node, opts); +} + +function assertSpreadElement(node, opts) { + assert("SpreadElement", node, opts); +} + +function assertSuper(node, opts) { + assert("Super", node, opts); +} + +function assertTaggedTemplateExpression(node, opts) { + assert("TaggedTemplateExpression", node, opts); +} + +function assertTemplateElement(node, opts) { + assert("TemplateElement", node, opts); +} + +function assertTemplateLiteral(node, opts) { + assert("TemplateLiteral", node, opts); +} + +function assertYieldExpression(node, opts) { + assert("YieldExpression", node, opts); +} + +function assertAwaitExpression(node, opts) { + assert("AwaitExpression", node, opts); +} + +function assertImport(node, opts) { + assert("Import", node, opts); +} + +function assertBigIntLiteral(node, opts) { + assert("BigIntLiteral", node, opts); +} + +function assertExportNamespaceSpecifier(node, opts) { + assert("ExportNamespaceSpecifier", node, opts); +} + +function assertOptionalMemberExpression(node, opts) { + assert("OptionalMemberExpression", node, opts); +} + +function assertOptionalCallExpression(node, opts) { + assert("OptionalCallExpression", node, opts); +} + +function assertClassProperty(node, opts) { + assert("ClassProperty", node, opts); +} + +function assertClassAccessorProperty(node, opts) { + assert("ClassAccessorProperty", node, opts); +} + +function assertClassPrivateProperty(node, opts) { + assert("ClassPrivateProperty", node, opts); +} + +function assertClassPrivateMethod(node, opts) { + assert("ClassPrivateMethod", node, opts); +} + +function assertPrivateName(node, opts) { + assert("PrivateName", node, opts); +} + +function assertStaticBlock(node, opts) { + assert("StaticBlock", node, opts); +} + +function assertAnyTypeAnnotation(node, opts) { + assert("AnyTypeAnnotation", node, opts); +} + +function assertArrayTypeAnnotation(node, opts) { + assert("ArrayTypeAnnotation", node, opts); +} + +function assertBooleanTypeAnnotation(node, opts) { + assert("BooleanTypeAnnotation", node, opts); +} + +function assertBooleanLiteralTypeAnnotation(node, opts) { + assert("BooleanLiteralTypeAnnotation", node, opts); +} + +function assertNullLiteralTypeAnnotation(node, opts) { + assert("NullLiteralTypeAnnotation", node, opts); +} + +function assertClassImplements(node, opts) { + assert("ClassImplements", node, opts); +} + +function assertDeclareClass(node, opts) { + assert("DeclareClass", node, opts); +} + +function assertDeclareFunction(node, opts) { + assert("DeclareFunction", node, opts); +} + +function assertDeclareInterface(node, opts) { + assert("DeclareInterface", node, opts); +} + +function assertDeclareModule(node, opts) { + assert("DeclareModule", node, opts); +} + +function assertDeclareModuleExports(node, opts) { + assert("DeclareModuleExports", node, opts); +} + +function assertDeclareTypeAlias(node, opts) { + assert("DeclareTypeAlias", node, opts); +} + +function assertDeclareOpaqueType(node, opts) { + assert("DeclareOpaqueType", node, opts); +} + +function assertDeclareVariable(node, opts) { + assert("DeclareVariable", node, opts); +} + +function assertDeclareExportDeclaration(node, opts) { + assert("DeclareExportDeclaration", node, opts); +} + +function assertDeclareExportAllDeclaration(node, opts) { + assert("DeclareExportAllDeclaration", node, opts); +} + +function assertDeclaredPredicate(node, opts) { + assert("DeclaredPredicate", node, opts); +} + +function assertExistsTypeAnnotation(node, opts) { + assert("ExistsTypeAnnotation", node, opts); +} + +function assertFunctionTypeAnnotation(node, opts) { + assert("FunctionTypeAnnotation", node, opts); +} + +function assertFunctionTypeParam(node, opts) { + assert("FunctionTypeParam", node, opts); +} + +function assertGenericTypeAnnotation(node, opts) { + assert("GenericTypeAnnotation", node, opts); +} + +function assertInferredPredicate(node, opts) { + assert("InferredPredicate", node, opts); +} + +function assertInterfaceExtends(node, opts) { + assert("InterfaceExtends", node, opts); +} + +function assertInterfaceDeclaration(node, opts) { + assert("InterfaceDeclaration", node, opts); +} + +function assertInterfaceTypeAnnotation(node, opts) { + assert("InterfaceTypeAnnotation", node, opts); +} + +function assertIntersectionTypeAnnotation(node, opts) { + assert("IntersectionTypeAnnotation", node, opts); +} + +function assertMixedTypeAnnotation(node, opts) { + assert("MixedTypeAnnotation", node, opts); +} + +function assertEmptyTypeAnnotation(node, opts) { + assert("EmptyTypeAnnotation", node, opts); +} + +function assertNullableTypeAnnotation(node, opts) { + assert("NullableTypeAnnotation", node, opts); +} + +function assertNumberLiteralTypeAnnotation(node, opts) { + assert("NumberLiteralTypeAnnotation", node, opts); +} + +function assertNumberTypeAnnotation(node, opts) { + assert("NumberTypeAnnotation", node, opts); +} + +function assertObjectTypeAnnotation(node, opts) { + assert("ObjectTypeAnnotation", node, opts); +} + +function assertObjectTypeInternalSlot(node, opts) { + assert("ObjectTypeInternalSlot", node, opts); +} + +function assertObjectTypeCallProperty(node, opts) { + assert("ObjectTypeCallProperty", node, opts); +} + +function assertObjectTypeIndexer(node, opts) { + assert("ObjectTypeIndexer", node, opts); +} + +function assertObjectTypeProperty(node, opts) { + assert("ObjectTypeProperty", node, opts); +} + +function assertObjectTypeSpreadProperty(node, opts) { + assert("ObjectTypeSpreadProperty", node, opts); +} + +function assertOpaqueType(node, opts) { + assert("OpaqueType", node, opts); +} + +function assertQualifiedTypeIdentifier(node, opts) { + assert("QualifiedTypeIdentifier", node, opts); +} + +function assertStringLiteralTypeAnnotation(node, opts) { + assert("StringLiteralTypeAnnotation", node, opts); +} + +function assertStringTypeAnnotation(node, opts) { + assert("StringTypeAnnotation", node, opts); +} + +function assertSymbolTypeAnnotation(node, opts) { + assert("SymbolTypeAnnotation", node, opts); +} + +function assertThisTypeAnnotation(node, opts) { + assert("ThisTypeAnnotation", node, opts); +} + +function assertTupleTypeAnnotation(node, opts) { + assert("TupleTypeAnnotation", node, opts); +} + +function assertTypeofTypeAnnotation(node, opts) { + assert("TypeofTypeAnnotation", node, opts); +} + +function assertTypeAlias(node, opts) { + assert("TypeAlias", node, opts); +} + +function assertTypeAnnotation(node, opts) { + assert("TypeAnnotation", node, opts); +} + +function assertTypeCastExpression(node, opts) { + assert("TypeCastExpression", node, opts); +} + +function assertTypeParameter(node, opts) { + assert("TypeParameter", node, opts); +} + +function assertTypeParameterDeclaration(node, opts) { + assert("TypeParameterDeclaration", node, opts); +} + +function assertTypeParameterInstantiation(node, opts) { + assert("TypeParameterInstantiation", node, opts); +} + +function assertUnionTypeAnnotation(node, opts) { + assert("UnionTypeAnnotation", node, opts); +} + +function assertVariance(node, opts) { + assert("Variance", node, opts); +} + +function assertVoidTypeAnnotation(node, opts) { + assert("VoidTypeAnnotation", node, opts); +} + +function assertEnumDeclaration(node, opts) { + assert("EnumDeclaration", node, opts); +} + +function assertEnumBooleanBody(node, opts) { + assert("EnumBooleanBody", node, opts); +} + +function assertEnumNumberBody(node, opts) { + assert("EnumNumberBody", node, opts); +} + +function assertEnumStringBody(node, opts) { + assert("EnumStringBody", node, opts); +} + +function assertEnumSymbolBody(node, opts) { + assert("EnumSymbolBody", node, opts); +} + +function assertEnumBooleanMember(node, opts) { + assert("EnumBooleanMember", node, opts); +} + +function assertEnumNumberMember(node, opts) { + assert("EnumNumberMember", node, opts); +} + +function assertEnumStringMember(node, opts) { + assert("EnumStringMember", node, opts); +} + +function assertEnumDefaultedMember(node, opts) { + assert("EnumDefaultedMember", node, opts); +} + +function assertIndexedAccessType(node, opts) { + assert("IndexedAccessType", node, opts); +} + +function assertOptionalIndexedAccessType(node, opts) { + assert("OptionalIndexedAccessType", node, opts); +} + +function assertJSXAttribute(node, opts) { + assert("JSXAttribute", node, opts); +} + +function assertJSXClosingElement(node, opts) { + assert("JSXClosingElement", node, opts); +} + +function assertJSXElement(node, opts) { + assert("JSXElement", node, opts); +} + +function assertJSXEmptyExpression(node, opts) { + assert("JSXEmptyExpression", node, opts); +} + +function assertJSXExpressionContainer(node, opts) { + assert("JSXExpressionContainer", node, opts); +} + +function assertJSXSpreadChild(node, opts) { + assert("JSXSpreadChild", node, opts); +} + +function assertJSXIdentifier(node, opts) { + assert("JSXIdentifier", node, opts); +} + +function assertJSXMemberExpression(node, opts) { + assert("JSXMemberExpression", node, opts); +} + +function assertJSXNamespacedName(node, opts) { + assert("JSXNamespacedName", node, opts); +} + +function assertJSXOpeningElement(node, opts) { + assert("JSXOpeningElement", node, opts); +} + +function assertJSXSpreadAttribute(node, opts) { + assert("JSXSpreadAttribute", node, opts); +} + +function assertJSXText(node, opts) { + assert("JSXText", node, opts); +} + +function assertJSXFragment(node, opts) { + assert("JSXFragment", node, opts); +} + +function assertJSXOpeningFragment(node, opts) { + assert("JSXOpeningFragment", node, opts); +} + +function assertJSXClosingFragment(node, opts) { + assert("JSXClosingFragment", node, opts); +} + +function assertNoop(node, opts) { + assert("Noop", node, opts); +} + +function assertPlaceholder(node, opts) { + assert("Placeholder", node, opts); +} + +function assertV8IntrinsicIdentifier(node, opts) { + assert("V8IntrinsicIdentifier", node, opts); +} + +function assertArgumentPlaceholder(node, opts) { + assert("ArgumentPlaceholder", node, opts); +} + +function assertBindExpression(node, opts) { + assert("BindExpression", node, opts); +} + +function assertImportAttribute(node, opts) { + assert("ImportAttribute", node, opts); +} + +function assertDecorator(node, opts) { + assert("Decorator", node, opts); +} + +function assertDoExpression(node, opts) { + assert("DoExpression", node, opts); +} + +function assertExportDefaultSpecifier(node, opts) { + assert("ExportDefaultSpecifier", node, opts); +} + +function assertRecordExpression(node, opts) { + assert("RecordExpression", node, opts); +} + +function assertTupleExpression(node, opts) { + assert("TupleExpression", node, opts); +} + +function assertDecimalLiteral(node, opts) { + assert("DecimalLiteral", node, opts); +} + +function assertModuleExpression(node, opts) { + assert("ModuleExpression", node, opts); +} + +function assertTopicReference(node, opts) { + assert("TopicReference", node, opts); +} + +function assertPipelineTopicExpression(node, opts) { + assert("PipelineTopicExpression", node, opts); +} + +function assertPipelineBareFunction(node, opts) { + assert("PipelineBareFunction", node, opts); +} + +function assertPipelinePrimaryTopicReference(node, opts) { + assert("PipelinePrimaryTopicReference", node, opts); +} + +function assertTSParameterProperty(node, opts) { + assert("TSParameterProperty", node, opts); +} + +function assertTSDeclareFunction(node, opts) { + assert("TSDeclareFunction", node, opts); +} + +function assertTSDeclareMethod(node, opts) { + assert("TSDeclareMethod", node, opts); +} + +function assertTSQualifiedName(node, opts) { + assert("TSQualifiedName", node, opts); +} + +function assertTSCallSignatureDeclaration(node, opts) { + assert("TSCallSignatureDeclaration", node, opts); +} + +function assertTSConstructSignatureDeclaration(node, opts) { + assert("TSConstructSignatureDeclaration", node, opts); +} + +function assertTSPropertySignature(node, opts) { + assert("TSPropertySignature", node, opts); +} + +function assertTSMethodSignature(node, opts) { + assert("TSMethodSignature", node, opts); +} + +function assertTSIndexSignature(node, opts) { + assert("TSIndexSignature", node, opts); +} + +function assertTSAnyKeyword(node, opts) { + assert("TSAnyKeyword", node, opts); +} + +function assertTSBooleanKeyword(node, opts) { + assert("TSBooleanKeyword", node, opts); +} + +function assertTSBigIntKeyword(node, opts) { + assert("TSBigIntKeyword", node, opts); +} + +function assertTSIntrinsicKeyword(node, opts) { + assert("TSIntrinsicKeyword", node, opts); +} + +function assertTSNeverKeyword(node, opts) { + assert("TSNeverKeyword", node, opts); +} + +function assertTSNullKeyword(node, opts) { + assert("TSNullKeyword", node, opts); +} + +function assertTSNumberKeyword(node, opts) { + assert("TSNumberKeyword", node, opts); +} + +function assertTSObjectKeyword(node, opts) { + assert("TSObjectKeyword", node, opts); +} + +function assertTSStringKeyword(node, opts) { + assert("TSStringKeyword", node, opts); +} + +function assertTSSymbolKeyword(node, opts) { + assert("TSSymbolKeyword", node, opts); +} + +function assertTSUndefinedKeyword(node, opts) { + assert("TSUndefinedKeyword", node, opts); +} + +function assertTSUnknownKeyword(node, opts) { + assert("TSUnknownKeyword", node, opts); +} + +function assertTSVoidKeyword(node, opts) { + assert("TSVoidKeyword", node, opts); +} + +function assertTSThisType(node, opts) { + assert("TSThisType", node, opts); +} + +function assertTSFunctionType(node, opts) { + assert("TSFunctionType", node, opts); +} + +function assertTSConstructorType(node, opts) { + assert("TSConstructorType", node, opts); +} + +function assertTSTypeReference(node, opts) { + assert("TSTypeReference", node, opts); +} + +function assertTSTypePredicate(node, opts) { + assert("TSTypePredicate", node, opts); +} + +function assertTSTypeQuery(node, opts) { + assert("TSTypeQuery", node, opts); +} + +function assertTSTypeLiteral(node, opts) { + assert("TSTypeLiteral", node, opts); +} + +function assertTSArrayType(node, opts) { + assert("TSArrayType", node, opts); +} + +function assertTSTupleType(node, opts) { + assert("TSTupleType", node, opts); +} + +function assertTSOptionalType(node, opts) { + assert("TSOptionalType", node, opts); +} + +function assertTSRestType(node, opts) { + assert("TSRestType", node, opts); +} + +function assertTSNamedTupleMember(node, opts) { + assert("TSNamedTupleMember", node, opts); +} + +function assertTSUnionType(node, opts) { + assert("TSUnionType", node, opts); +} + +function assertTSIntersectionType(node, opts) { + assert("TSIntersectionType", node, opts); +} + +function assertTSConditionalType(node, opts) { + assert("TSConditionalType", node, opts); +} + +function assertTSInferType(node, opts) { + assert("TSInferType", node, opts); +} + +function assertTSParenthesizedType(node, opts) { + assert("TSParenthesizedType", node, opts); +} + +function assertTSTypeOperator(node, opts) { + assert("TSTypeOperator", node, opts); +} + +function assertTSIndexedAccessType(node, opts) { + assert("TSIndexedAccessType", node, opts); +} + +function assertTSMappedType(node, opts) { + assert("TSMappedType", node, opts); +} + +function assertTSLiteralType(node, opts) { + assert("TSLiteralType", node, opts); +} + +function assertTSExpressionWithTypeArguments(node, opts) { + assert("TSExpressionWithTypeArguments", node, opts); +} + +function assertTSInterfaceDeclaration(node, opts) { + assert("TSInterfaceDeclaration", node, opts); +} + +function assertTSInterfaceBody(node, opts) { + assert("TSInterfaceBody", node, opts); +} + +function assertTSTypeAliasDeclaration(node, opts) { + assert("TSTypeAliasDeclaration", node, opts); +} + +function assertTSInstantiationExpression(node, opts) { + assert("TSInstantiationExpression", node, opts); +} + +function assertTSAsExpression(node, opts) { + assert("TSAsExpression", node, opts); +} + +function assertTSTypeAssertion(node, opts) { + assert("TSTypeAssertion", node, opts); +} + +function assertTSEnumDeclaration(node, opts) { + assert("TSEnumDeclaration", node, opts); +} + +function assertTSEnumMember(node, opts) { + assert("TSEnumMember", node, opts); +} + +function assertTSModuleDeclaration(node, opts) { + assert("TSModuleDeclaration", node, opts); +} + +function assertTSModuleBlock(node, opts) { + assert("TSModuleBlock", node, opts); +} + +function assertTSImportType(node, opts) { + assert("TSImportType", node, opts); +} + +function assertTSImportEqualsDeclaration(node, opts) { + assert("TSImportEqualsDeclaration", node, opts); +} + +function assertTSExternalModuleReference(node, opts) { + assert("TSExternalModuleReference", node, opts); +} + +function assertTSNonNullExpression(node, opts) { + assert("TSNonNullExpression", node, opts); +} + +function assertTSExportAssignment(node, opts) { + assert("TSExportAssignment", node, opts); +} + +function assertTSNamespaceExportDeclaration(node, opts) { + assert("TSNamespaceExportDeclaration", node, opts); +} + +function assertTSTypeAnnotation(node, opts) { + assert("TSTypeAnnotation", node, opts); +} + +function assertTSTypeParameterInstantiation(node, opts) { + assert("TSTypeParameterInstantiation", node, opts); +} + +function assertTSTypeParameterDeclaration(node, opts) { + assert("TSTypeParameterDeclaration", node, opts); +} + +function assertTSTypeParameter(node, opts) { + assert("TSTypeParameter", node, opts); +} + +function assertStandardized(node, opts) { + assert("Standardized", node, opts); +} + +function assertExpression(node, opts) { + assert("Expression", node, opts); +} + +function assertBinary(node, opts) { + assert("Binary", node, opts); +} + +function assertScopable(node, opts) { + assert("Scopable", node, opts); +} + +function assertBlockParent(node, opts) { + assert("BlockParent", node, opts); +} + +function assertBlock(node, opts) { + assert("Block", node, opts); +} + +function assertStatement(node, opts) { + assert("Statement", node, opts); +} + +function assertTerminatorless(node, opts) { + assert("Terminatorless", node, opts); +} + +function assertCompletionStatement(node, opts) { + assert("CompletionStatement", node, opts); +} + +function assertConditional(node, opts) { + assert("Conditional", node, opts); +} + +function assertLoop(node, opts) { + assert("Loop", node, opts); +} + +function assertWhile(node, opts) { + assert("While", node, opts); +} + +function assertExpressionWrapper(node, opts) { + assert("ExpressionWrapper", node, opts); +} + +function assertFor(node, opts) { + assert("For", node, opts); +} + +function assertForXStatement(node, opts) { + assert("ForXStatement", node, opts); +} + +function assertFunction(node, opts) { + assert("Function", node, opts); +} + +function assertFunctionParent(node, opts) { + assert("FunctionParent", node, opts); +} + +function assertPureish(node, opts) { + assert("Pureish", node, opts); +} + +function assertDeclaration(node, opts) { + assert("Declaration", node, opts); +} + +function assertPatternLike(node, opts) { + assert("PatternLike", node, opts); +} + +function assertLVal(node, opts) { + assert("LVal", node, opts); +} + +function assertTSEntityName(node, opts) { + assert("TSEntityName", node, opts); +} + +function assertLiteral(node, opts) { + assert("Literal", node, opts); +} + +function assertImmutable(node, opts) { + assert("Immutable", node, opts); +} + +function assertUserWhitespacable(node, opts) { + assert("UserWhitespacable", node, opts); +} + +function assertMethod(node, opts) { + assert("Method", node, opts); +} + +function assertObjectMember(node, opts) { + assert("ObjectMember", node, opts); +} + +function assertProperty(node, opts) { + assert("Property", node, opts); +} + +function assertUnaryLike(node, opts) { + assert("UnaryLike", node, opts); +} + +function assertPattern(node, opts) { + assert("Pattern", node, opts); +} + +function assertClass(node, opts) { + assert("Class", node, opts); +} + +function assertModuleDeclaration(node, opts) { + assert("ModuleDeclaration", node, opts); +} + +function assertExportDeclaration(node, opts) { + assert("ExportDeclaration", node, opts); +} + +function assertModuleSpecifier(node, opts) { + assert("ModuleSpecifier", node, opts); +} + +function assertAccessor(node, opts) { + assert("Accessor", node, opts); +} + +function assertPrivate(node, opts) { + assert("Private", node, opts); +} + +function assertFlow(node, opts) { + assert("Flow", node, opts); +} + +function assertFlowType(node, opts) { + assert("FlowType", node, opts); +} + +function assertFlowBaseAnnotation(node, opts) { + assert("FlowBaseAnnotation", node, opts); +} + +function assertFlowDeclaration(node, opts) { + assert("FlowDeclaration", node, opts); +} + +function assertFlowPredicate(node, opts) { + assert("FlowPredicate", node, opts); +} + +function assertEnumBody(node, opts) { + assert("EnumBody", node, opts); +} + +function assertEnumMember(node, opts) { + assert("EnumMember", node, opts); +} + +function assertJSX(node, opts) { + assert("JSX", node, opts); +} + +function assertMiscellaneous(node, opts) { + assert("Miscellaneous", node, opts); +} + +function assertTypeScript(node, opts) { + assert("TypeScript", node, opts); +} + +function assertTSTypeElement(node, opts) { + assert("TSTypeElement", node, opts); +} + +function assertTSType(node, opts) { + assert("TSType", node, opts); +} + +function assertTSBaseType(node, opts) { + assert("TSBaseType", node, opts); +} + +function assertNumberLiteral(node, opts) { + console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); + assert("NumberLiteral", node, opts); +} + +function assertRegexLiteral(node, opts) { + console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); + assert("RegexLiteral", node, opts); +} + +function assertRestProperty(node, opts) { + console.trace("The node type RestProperty has been renamed to RestElement"); + assert("RestProperty", node, opts); +} + +function assertSpreadProperty(node, opts) { + console.trace("The node type SpreadProperty has been renamed to SpreadElement"); + assert("SpreadProperty", node, opts); +} \ No newline at end of file diff --git a/node_modules/nyc/node_modules/@babel/types/lib/ast-types/generated/index.js b/node_modules/nyc/node_modules/@babel/types/lib/ast-types/generated/index.js new file mode 100644 index 000000000..e69de29bb diff --git a/node_modules/nyc/node_modules/@babel/types/lib/builders/generated/index.js b/node_modules/nyc/node_modules/@babel/types/lib/builders/generated/index.js new file mode 100644 index 000000000..35a8e143b --- /dev/null +++ b/node_modules/nyc/node_modules/@babel/types/lib/builders/generated/index.js @@ -0,0 +1,2227 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.anyTypeAnnotation = anyTypeAnnotation; +exports.argumentPlaceholder = argumentPlaceholder; +exports.arrayExpression = arrayExpression; +exports.arrayPattern = arrayPattern; +exports.arrayTypeAnnotation = arrayTypeAnnotation; +exports.arrowFunctionExpression = arrowFunctionExpression; +exports.assignmentExpression = assignmentExpression; +exports.assignmentPattern = assignmentPattern; +exports.awaitExpression = awaitExpression; +exports.bigIntLiteral = bigIntLiteral; +exports.binaryExpression = binaryExpression; +exports.bindExpression = bindExpression; +exports.blockStatement = blockStatement; +exports.booleanLiteral = booleanLiteral; +exports.booleanLiteralTypeAnnotation = booleanLiteralTypeAnnotation; +exports.booleanTypeAnnotation = booleanTypeAnnotation; +exports.breakStatement = breakStatement; +exports.callExpression = callExpression; +exports.catchClause = catchClause; +exports.classAccessorProperty = classAccessorProperty; +exports.classBody = classBody; +exports.classDeclaration = classDeclaration; +exports.classExpression = classExpression; +exports.classImplements = classImplements; +exports.classMethod = classMethod; +exports.classPrivateMethod = classPrivateMethod; +exports.classPrivateProperty = classPrivateProperty; +exports.classProperty = classProperty; +exports.conditionalExpression = conditionalExpression; +exports.continueStatement = continueStatement; +exports.debuggerStatement = debuggerStatement; +exports.decimalLiteral = decimalLiteral; +exports.declareClass = declareClass; +exports.declareExportAllDeclaration = declareExportAllDeclaration; +exports.declareExportDeclaration = declareExportDeclaration; +exports.declareFunction = declareFunction; +exports.declareInterface = declareInterface; +exports.declareModule = declareModule; +exports.declareModuleExports = declareModuleExports; +exports.declareOpaqueType = declareOpaqueType; +exports.declareTypeAlias = declareTypeAlias; +exports.declareVariable = declareVariable; +exports.declaredPredicate = declaredPredicate; +exports.decorator = decorator; +exports.directive = directive; +exports.directiveLiteral = directiveLiteral; +exports.doExpression = doExpression; +exports.doWhileStatement = doWhileStatement; +exports.emptyStatement = emptyStatement; +exports.emptyTypeAnnotation = emptyTypeAnnotation; +exports.enumBooleanBody = enumBooleanBody; +exports.enumBooleanMember = enumBooleanMember; +exports.enumDeclaration = enumDeclaration; +exports.enumDefaultedMember = enumDefaultedMember; +exports.enumNumberBody = enumNumberBody; +exports.enumNumberMember = enumNumberMember; +exports.enumStringBody = enumStringBody; +exports.enumStringMember = enumStringMember; +exports.enumSymbolBody = enumSymbolBody; +exports.existsTypeAnnotation = existsTypeAnnotation; +exports.exportAllDeclaration = exportAllDeclaration; +exports.exportDefaultDeclaration = exportDefaultDeclaration; +exports.exportDefaultSpecifier = exportDefaultSpecifier; +exports.exportNamedDeclaration = exportNamedDeclaration; +exports.exportNamespaceSpecifier = exportNamespaceSpecifier; +exports.exportSpecifier = exportSpecifier; +exports.expressionStatement = expressionStatement; +exports.file = file; +exports.forInStatement = forInStatement; +exports.forOfStatement = forOfStatement; +exports.forStatement = forStatement; +exports.functionDeclaration = functionDeclaration; +exports.functionExpression = functionExpression; +exports.functionTypeAnnotation = functionTypeAnnotation; +exports.functionTypeParam = functionTypeParam; +exports.genericTypeAnnotation = genericTypeAnnotation; +exports.identifier = identifier; +exports.ifStatement = ifStatement; +exports.import = _import; +exports.importAttribute = importAttribute; +exports.importDeclaration = importDeclaration; +exports.importDefaultSpecifier = importDefaultSpecifier; +exports.importNamespaceSpecifier = importNamespaceSpecifier; +exports.importSpecifier = importSpecifier; +exports.indexedAccessType = indexedAccessType; +exports.inferredPredicate = inferredPredicate; +exports.interfaceDeclaration = interfaceDeclaration; +exports.interfaceExtends = interfaceExtends; +exports.interfaceTypeAnnotation = interfaceTypeAnnotation; +exports.interpreterDirective = interpreterDirective; +exports.intersectionTypeAnnotation = intersectionTypeAnnotation; +exports.jSXAttribute = exports.jsxAttribute = jsxAttribute; +exports.jSXClosingElement = exports.jsxClosingElement = jsxClosingElement; +exports.jSXClosingFragment = exports.jsxClosingFragment = jsxClosingFragment; +exports.jSXElement = exports.jsxElement = jsxElement; +exports.jSXEmptyExpression = exports.jsxEmptyExpression = jsxEmptyExpression; +exports.jSXExpressionContainer = exports.jsxExpressionContainer = jsxExpressionContainer; +exports.jSXFragment = exports.jsxFragment = jsxFragment; +exports.jSXIdentifier = exports.jsxIdentifier = jsxIdentifier; +exports.jSXMemberExpression = exports.jsxMemberExpression = jsxMemberExpression; +exports.jSXNamespacedName = exports.jsxNamespacedName = jsxNamespacedName; +exports.jSXOpeningElement = exports.jsxOpeningElement = jsxOpeningElement; +exports.jSXOpeningFragment = exports.jsxOpeningFragment = jsxOpeningFragment; +exports.jSXSpreadAttribute = exports.jsxSpreadAttribute = jsxSpreadAttribute; +exports.jSXSpreadChild = exports.jsxSpreadChild = jsxSpreadChild; +exports.jSXText = exports.jsxText = jsxText; +exports.labeledStatement = labeledStatement; +exports.logicalExpression = logicalExpression; +exports.memberExpression = memberExpression; +exports.metaProperty = metaProperty; +exports.mixedTypeAnnotation = mixedTypeAnnotation; +exports.moduleExpression = moduleExpression; +exports.newExpression = newExpression; +exports.noop = noop; +exports.nullLiteral = nullLiteral; +exports.nullLiteralTypeAnnotation = nullLiteralTypeAnnotation; +exports.nullableTypeAnnotation = nullableTypeAnnotation; +exports.numberLiteral = NumberLiteral; +exports.numberLiteralTypeAnnotation = numberLiteralTypeAnnotation; +exports.numberTypeAnnotation = numberTypeAnnotation; +exports.numericLiteral = numericLiteral; +exports.objectExpression = objectExpression; +exports.objectMethod = objectMethod; +exports.objectPattern = objectPattern; +exports.objectProperty = objectProperty; +exports.objectTypeAnnotation = objectTypeAnnotation; +exports.objectTypeCallProperty = objectTypeCallProperty; +exports.objectTypeIndexer = objectTypeIndexer; +exports.objectTypeInternalSlot = objectTypeInternalSlot; +exports.objectTypeProperty = objectTypeProperty; +exports.objectTypeSpreadProperty = objectTypeSpreadProperty; +exports.opaqueType = opaqueType; +exports.optionalCallExpression = optionalCallExpression; +exports.optionalIndexedAccessType = optionalIndexedAccessType; +exports.optionalMemberExpression = optionalMemberExpression; +exports.parenthesizedExpression = parenthesizedExpression; +exports.pipelineBareFunction = pipelineBareFunction; +exports.pipelinePrimaryTopicReference = pipelinePrimaryTopicReference; +exports.pipelineTopicExpression = pipelineTopicExpression; +exports.placeholder = placeholder; +exports.privateName = privateName; +exports.program = program; +exports.qualifiedTypeIdentifier = qualifiedTypeIdentifier; +exports.recordExpression = recordExpression; +exports.regExpLiteral = regExpLiteral; +exports.regexLiteral = RegexLiteral; +exports.restElement = restElement; +exports.restProperty = RestProperty; +exports.returnStatement = returnStatement; +exports.sequenceExpression = sequenceExpression; +exports.spreadElement = spreadElement; +exports.spreadProperty = SpreadProperty; +exports.staticBlock = staticBlock; +exports.stringLiteral = stringLiteral; +exports.stringLiteralTypeAnnotation = stringLiteralTypeAnnotation; +exports.stringTypeAnnotation = stringTypeAnnotation; +exports.super = _super; +exports.switchCase = switchCase; +exports.switchStatement = switchStatement; +exports.symbolTypeAnnotation = symbolTypeAnnotation; +exports.taggedTemplateExpression = taggedTemplateExpression; +exports.templateElement = templateElement; +exports.templateLiteral = templateLiteral; +exports.thisExpression = thisExpression; +exports.thisTypeAnnotation = thisTypeAnnotation; +exports.throwStatement = throwStatement; +exports.topicReference = topicReference; +exports.tryStatement = tryStatement; +exports.tSAnyKeyword = exports.tsAnyKeyword = tsAnyKeyword; +exports.tSArrayType = exports.tsArrayType = tsArrayType; +exports.tSAsExpression = exports.tsAsExpression = tsAsExpression; +exports.tSBigIntKeyword = exports.tsBigIntKeyword = tsBigIntKeyword; +exports.tSBooleanKeyword = exports.tsBooleanKeyword = tsBooleanKeyword; +exports.tSCallSignatureDeclaration = exports.tsCallSignatureDeclaration = tsCallSignatureDeclaration; +exports.tSConditionalType = exports.tsConditionalType = tsConditionalType; +exports.tSConstructSignatureDeclaration = exports.tsConstructSignatureDeclaration = tsConstructSignatureDeclaration; +exports.tSConstructorType = exports.tsConstructorType = tsConstructorType; +exports.tSDeclareFunction = exports.tsDeclareFunction = tsDeclareFunction; +exports.tSDeclareMethod = exports.tsDeclareMethod = tsDeclareMethod; +exports.tSEnumDeclaration = exports.tsEnumDeclaration = tsEnumDeclaration; +exports.tSEnumMember = exports.tsEnumMember = tsEnumMember; +exports.tSExportAssignment = exports.tsExportAssignment = tsExportAssignment; +exports.tSExpressionWithTypeArguments = exports.tsExpressionWithTypeArguments = tsExpressionWithTypeArguments; +exports.tSExternalModuleReference = exports.tsExternalModuleReference = tsExternalModuleReference; +exports.tSFunctionType = exports.tsFunctionType = tsFunctionType; +exports.tSImportEqualsDeclaration = exports.tsImportEqualsDeclaration = tsImportEqualsDeclaration; +exports.tSImportType = exports.tsImportType = tsImportType; +exports.tSIndexSignature = exports.tsIndexSignature = tsIndexSignature; +exports.tSIndexedAccessType = exports.tsIndexedAccessType = tsIndexedAccessType; +exports.tSInferType = exports.tsInferType = tsInferType; +exports.tSInstantiationExpression = exports.tsInstantiationExpression = tsInstantiationExpression; +exports.tSInterfaceBody = exports.tsInterfaceBody = tsInterfaceBody; +exports.tSInterfaceDeclaration = exports.tsInterfaceDeclaration = tsInterfaceDeclaration; +exports.tSIntersectionType = exports.tsIntersectionType = tsIntersectionType; +exports.tSIntrinsicKeyword = exports.tsIntrinsicKeyword = tsIntrinsicKeyword; +exports.tSLiteralType = exports.tsLiteralType = tsLiteralType; +exports.tSMappedType = exports.tsMappedType = tsMappedType; +exports.tSMethodSignature = exports.tsMethodSignature = tsMethodSignature; +exports.tSModuleBlock = exports.tsModuleBlock = tsModuleBlock; +exports.tSModuleDeclaration = exports.tsModuleDeclaration = tsModuleDeclaration; +exports.tSNamedTupleMember = exports.tsNamedTupleMember = tsNamedTupleMember; +exports.tSNamespaceExportDeclaration = exports.tsNamespaceExportDeclaration = tsNamespaceExportDeclaration; +exports.tSNeverKeyword = exports.tsNeverKeyword = tsNeverKeyword; +exports.tSNonNullExpression = exports.tsNonNullExpression = tsNonNullExpression; +exports.tSNullKeyword = exports.tsNullKeyword = tsNullKeyword; +exports.tSNumberKeyword = exports.tsNumberKeyword = tsNumberKeyword; +exports.tSObjectKeyword = exports.tsObjectKeyword = tsObjectKeyword; +exports.tSOptionalType = exports.tsOptionalType = tsOptionalType; +exports.tSParameterProperty = exports.tsParameterProperty = tsParameterProperty; +exports.tSParenthesizedType = exports.tsParenthesizedType = tsParenthesizedType; +exports.tSPropertySignature = exports.tsPropertySignature = tsPropertySignature; +exports.tSQualifiedName = exports.tsQualifiedName = tsQualifiedName; +exports.tSRestType = exports.tsRestType = tsRestType; +exports.tSStringKeyword = exports.tsStringKeyword = tsStringKeyword; +exports.tSSymbolKeyword = exports.tsSymbolKeyword = tsSymbolKeyword; +exports.tSThisType = exports.tsThisType = tsThisType; +exports.tSTupleType = exports.tsTupleType = tsTupleType; +exports.tSTypeAliasDeclaration = exports.tsTypeAliasDeclaration = tsTypeAliasDeclaration; +exports.tSTypeAnnotation = exports.tsTypeAnnotation = tsTypeAnnotation; +exports.tSTypeAssertion = exports.tsTypeAssertion = tsTypeAssertion; +exports.tSTypeLiteral = exports.tsTypeLiteral = tsTypeLiteral; +exports.tSTypeOperator = exports.tsTypeOperator = tsTypeOperator; +exports.tSTypeParameter = exports.tsTypeParameter = tsTypeParameter; +exports.tSTypeParameterDeclaration = exports.tsTypeParameterDeclaration = tsTypeParameterDeclaration; +exports.tSTypeParameterInstantiation = exports.tsTypeParameterInstantiation = tsTypeParameterInstantiation; +exports.tSTypePredicate = exports.tsTypePredicate = tsTypePredicate; +exports.tSTypeQuery = exports.tsTypeQuery = tsTypeQuery; +exports.tSTypeReference = exports.tsTypeReference = tsTypeReference; +exports.tSUndefinedKeyword = exports.tsUndefinedKeyword = tsUndefinedKeyword; +exports.tSUnionType = exports.tsUnionType = tsUnionType; +exports.tSUnknownKeyword = exports.tsUnknownKeyword = tsUnknownKeyword; +exports.tSVoidKeyword = exports.tsVoidKeyword = tsVoidKeyword; +exports.tupleExpression = tupleExpression; +exports.tupleTypeAnnotation = tupleTypeAnnotation; +exports.typeAlias = typeAlias; +exports.typeAnnotation = typeAnnotation; +exports.typeCastExpression = typeCastExpression; +exports.typeParameter = typeParameter; +exports.typeParameterDeclaration = typeParameterDeclaration; +exports.typeParameterInstantiation = typeParameterInstantiation; +exports.typeofTypeAnnotation = typeofTypeAnnotation; +exports.unaryExpression = unaryExpression; +exports.unionTypeAnnotation = unionTypeAnnotation; +exports.updateExpression = updateExpression; +exports.v8IntrinsicIdentifier = v8IntrinsicIdentifier; +exports.variableDeclaration = variableDeclaration; +exports.variableDeclarator = variableDeclarator; +exports.variance = variance; +exports.voidTypeAnnotation = voidTypeAnnotation; +exports.whileStatement = whileStatement; +exports.withStatement = withStatement; +exports.yieldExpression = yieldExpression; + +var _validateNode = require("../validateNode"); + +function arrayExpression(elements = []) { + return (0, _validateNode.default)({ + type: "ArrayExpression", + elements + }); +} + +function assignmentExpression(operator, left, right) { + return (0, _validateNode.default)({ + type: "AssignmentExpression", + operator, + left, + right + }); +} + +function binaryExpression(operator, left, right) { + return (0, _validateNode.default)({ + type: "BinaryExpression", + operator, + left, + right + }); +} + +function interpreterDirective(value) { + return (0, _validateNode.default)({ + type: "InterpreterDirective", + value + }); +} + +function directive(value) { + return (0, _validateNode.default)({ + type: "Directive", + value + }); +} + +function directiveLiteral(value) { + return (0, _validateNode.default)({ + type: "DirectiveLiteral", + value + }); +} + +function blockStatement(body, directives = []) { + return (0, _validateNode.default)({ + type: "BlockStatement", + body, + directives + }); +} + +function breakStatement(label = null) { + return (0, _validateNode.default)({ + type: "BreakStatement", + label + }); +} + +function callExpression(callee, _arguments) { + return (0, _validateNode.default)({ + type: "CallExpression", + callee, + arguments: _arguments + }); +} + +function catchClause(param = null, body) { + return (0, _validateNode.default)({ + type: "CatchClause", + param, + body + }); +} + +function conditionalExpression(test, consequent, alternate) { + return (0, _validateNode.default)({ + type: "ConditionalExpression", + test, + consequent, + alternate + }); +} + +function continueStatement(label = null) { + return (0, _validateNode.default)({ + type: "ContinueStatement", + label + }); +} + +function debuggerStatement() { + return { + type: "DebuggerStatement" + }; +} + +function doWhileStatement(test, body) { + return (0, _validateNode.default)({ + type: "DoWhileStatement", + test, + body + }); +} + +function emptyStatement() { + return { + type: "EmptyStatement" + }; +} + +function expressionStatement(expression) { + return (0, _validateNode.default)({ + type: "ExpressionStatement", + expression + }); +} + +function file(program, comments = null, tokens = null) { + return (0, _validateNode.default)({ + type: "File", + program, + comments, + tokens + }); +} + +function forInStatement(left, right, body) { + return (0, _validateNode.default)({ + type: "ForInStatement", + left, + right, + body + }); +} + +function forStatement(init = null, test = null, update = null, body) { + return (0, _validateNode.default)({ + type: "ForStatement", + init, + test, + update, + body + }); +} + +function functionDeclaration(id = null, params, body, generator = false, async = false) { + return (0, _validateNode.default)({ + type: "FunctionDeclaration", + id, + params, + body, + generator, + async + }); +} + +function functionExpression(id = null, params, body, generator = false, async = false) { + return (0, _validateNode.default)({ + type: "FunctionExpression", + id, + params, + body, + generator, + async + }); +} + +function identifier(name) { + return (0, _validateNode.default)({ + type: "Identifier", + name + }); +} + +function ifStatement(test, consequent, alternate = null) { + return (0, _validateNode.default)({ + type: "IfStatement", + test, + consequent, + alternate + }); +} + +function labeledStatement(label, body) { + return (0, _validateNode.default)({ + type: "LabeledStatement", + label, + body + }); +} + +function stringLiteral(value) { + return (0, _validateNode.default)({ + type: "StringLiteral", + value + }); +} + +function numericLiteral(value) { + return (0, _validateNode.default)({ + type: "NumericLiteral", + value + }); +} + +function nullLiteral() { + return { + type: "NullLiteral" + }; +} + +function booleanLiteral(value) { + return (0, _validateNode.default)({ + type: "BooleanLiteral", + value + }); +} + +function regExpLiteral(pattern, flags = "") { + return (0, _validateNode.default)({ + type: "RegExpLiteral", + pattern, + flags + }); +} + +function logicalExpression(operator, left, right) { + return (0, _validateNode.default)({ + type: "LogicalExpression", + operator, + left, + right + }); +} + +function memberExpression(object, property, computed = false, optional = null) { + return (0, _validateNode.default)({ + type: "MemberExpression", + object, + property, + computed, + optional + }); +} + +function newExpression(callee, _arguments) { + return (0, _validateNode.default)({ + type: "NewExpression", + callee, + arguments: _arguments + }); +} + +function program(body, directives = [], sourceType = "script", interpreter = null) { + return (0, _validateNode.default)({ + type: "Program", + body, + directives, + sourceType, + interpreter, + sourceFile: null + }); +} + +function objectExpression(properties) { + return (0, _validateNode.default)({ + type: "ObjectExpression", + properties + }); +} + +function objectMethod(kind = "method", key, params, body, computed = false, generator = false, async = false) { + return (0, _validateNode.default)({ + type: "ObjectMethod", + kind, + key, + params, + body, + computed, + generator, + async + }); +} + +function objectProperty(key, value, computed = false, shorthand = false, decorators = null) { + return (0, _validateNode.default)({ + type: "ObjectProperty", + key, + value, + computed, + shorthand, + decorators + }); +} + +function restElement(argument) { + return (0, _validateNode.default)({ + type: "RestElement", + argument + }); +} + +function returnStatement(argument = null) { + return (0, _validateNode.default)({ + type: "ReturnStatement", + argument + }); +} + +function sequenceExpression(expressions) { + return (0, _validateNode.default)({ + type: "SequenceExpression", + expressions + }); +} + +function parenthesizedExpression(expression) { + return (0, _validateNode.default)({ + type: "ParenthesizedExpression", + expression + }); +} + +function switchCase(test = null, consequent) { + return (0, _validateNode.default)({ + type: "SwitchCase", + test, + consequent + }); +} + +function switchStatement(discriminant, cases) { + return (0, _validateNode.default)({ + type: "SwitchStatement", + discriminant, + cases + }); +} + +function thisExpression() { + return { + type: "ThisExpression" + }; +} + +function throwStatement(argument) { + return (0, _validateNode.default)({ + type: "ThrowStatement", + argument + }); +} + +function tryStatement(block, handler = null, finalizer = null) { + return (0, _validateNode.default)({ + type: "TryStatement", + block, + handler, + finalizer + }); +} + +function unaryExpression(operator, argument, prefix = true) { + return (0, _validateNode.default)({ + type: "UnaryExpression", + operator, + argument, + prefix + }); +} + +function updateExpression(operator, argument, prefix = false) { + return (0, _validateNode.default)({ + type: "UpdateExpression", + operator, + argument, + prefix + }); +} + +function variableDeclaration(kind, declarations) { + return (0, _validateNode.default)({ + type: "VariableDeclaration", + kind, + declarations + }); +} + +function variableDeclarator(id, init = null) { + return (0, _validateNode.default)({ + type: "VariableDeclarator", + id, + init + }); +} + +function whileStatement(test, body) { + return (0, _validateNode.default)({ + type: "WhileStatement", + test, + body + }); +} + +function withStatement(object, body) { + return (0, _validateNode.default)({ + type: "WithStatement", + object, + body + }); +} + +function assignmentPattern(left, right) { + return (0, _validateNode.default)({ + type: "AssignmentPattern", + left, + right + }); +} + +function arrayPattern(elements) { + return (0, _validateNode.default)({ + type: "ArrayPattern", + elements + }); +} + +function arrowFunctionExpression(params, body, async = false) { + return (0, _validateNode.default)({ + type: "ArrowFunctionExpression", + params, + body, + async, + expression: null + }); +} + +function classBody(body) { + return (0, _validateNode.default)({ + type: "ClassBody", + body + }); +} + +function classExpression(id = null, superClass = null, body, decorators = null) { + return (0, _validateNode.default)({ + type: "ClassExpression", + id, + superClass, + body, + decorators + }); +} + +function classDeclaration(id, superClass = null, body, decorators = null) { + return (0, _validateNode.default)({ + type: "ClassDeclaration", + id, + superClass, + body, + decorators + }); +} + +function exportAllDeclaration(source) { + return (0, _validateNode.default)({ + type: "ExportAllDeclaration", + source + }); +} + +function exportDefaultDeclaration(declaration) { + return (0, _validateNode.default)({ + type: "ExportDefaultDeclaration", + declaration + }); +} + +function exportNamedDeclaration(declaration = null, specifiers = [], source = null) { + return (0, _validateNode.default)({ + type: "ExportNamedDeclaration", + declaration, + specifiers, + source + }); +} + +function exportSpecifier(local, exported) { + return (0, _validateNode.default)({ + type: "ExportSpecifier", + local, + exported + }); +} + +function forOfStatement(left, right, body, _await = false) { + return (0, _validateNode.default)({ + type: "ForOfStatement", + left, + right, + body, + await: _await + }); +} + +function importDeclaration(specifiers, source) { + return (0, _validateNode.default)({ + type: "ImportDeclaration", + specifiers, + source + }); +} + +function importDefaultSpecifier(local) { + return (0, _validateNode.default)({ + type: "ImportDefaultSpecifier", + local + }); +} + +function importNamespaceSpecifier(local) { + return (0, _validateNode.default)({ + type: "ImportNamespaceSpecifier", + local + }); +} + +function importSpecifier(local, imported) { + return (0, _validateNode.default)({ + type: "ImportSpecifier", + local, + imported + }); +} + +function metaProperty(meta, property) { + return (0, _validateNode.default)({ + type: "MetaProperty", + meta, + property + }); +} + +function classMethod(kind = "method", key, params, body, computed = false, _static = false, generator = false, async = false) { + return (0, _validateNode.default)({ + type: "ClassMethod", + kind, + key, + params, + body, + computed, + static: _static, + generator, + async + }); +} + +function objectPattern(properties) { + return (0, _validateNode.default)({ + type: "ObjectPattern", + properties + }); +} + +function spreadElement(argument) { + return (0, _validateNode.default)({ + type: "SpreadElement", + argument + }); +} + +function _super() { + return { + type: "Super" + }; +} + +function taggedTemplateExpression(tag, quasi) { + return (0, _validateNode.default)({ + type: "TaggedTemplateExpression", + tag, + quasi + }); +} + +function templateElement(value, tail = false) { + return (0, _validateNode.default)({ + type: "TemplateElement", + value, + tail + }); +} + +function templateLiteral(quasis, expressions) { + return (0, _validateNode.default)({ + type: "TemplateLiteral", + quasis, + expressions + }); +} + +function yieldExpression(argument = null, delegate = false) { + return (0, _validateNode.default)({ + type: "YieldExpression", + argument, + delegate + }); +} + +function awaitExpression(argument) { + return (0, _validateNode.default)({ + type: "AwaitExpression", + argument + }); +} + +function _import() { + return { + type: "Import" + }; +} + +function bigIntLiteral(value) { + return (0, _validateNode.default)({ + type: "BigIntLiteral", + value + }); +} + +function exportNamespaceSpecifier(exported) { + return (0, _validateNode.default)({ + type: "ExportNamespaceSpecifier", + exported + }); +} + +function optionalMemberExpression(object, property, computed = false, optional) { + return (0, _validateNode.default)({ + type: "OptionalMemberExpression", + object, + property, + computed, + optional + }); +} + +function optionalCallExpression(callee, _arguments, optional) { + return (0, _validateNode.default)({ + type: "OptionalCallExpression", + callee, + arguments: _arguments, + optional + }); +} + +function classProperty(key, value = null, typeAnnotation = null, decorators = null, computed = false, _static = false) { + return (0, _validateNode.default)({ + type: "ClassProperty", + key, + value, + typeAnnotation, + decorators, + computed, + static: _static + }); +} + +function classAccessorProperty(key, value = null, typeAnnotation = null, decorators = null, computed = false, _static = false) { + return (0, _validateNode.default)({ + type: "ClassAccessorProperty", + key, + value, + typeAnnotation, + decorators, + computed, + static: _static + }); +} + +function classPrivateProperty(key, value = null, decorators = null, _static) { + return (0, _validateNode.default)({ + type: "ClassPrivateProperty", + key, + value, + decorators, + static: _static + }); +} + +function classPrivateMethod(kind = "method", key, params, body, _static = false) { + return (0, _validateNode.default)({ + type: "ClassPrivateMethod", + kind, + key, + params, + body, + static: _static + }); +} + +function privateName(id) { + return (0, _validateNode.default)({ + type: "PrivateName", + id + }); +} + +function staticBlock(body) { + return (0, _validateNode.default)({ + type: "StaticBlock", + body + }); +} + +function anyTypeAnnotation() { + return { + type: "AnyTypeAnnotation" + }; +} + +function arrayTypeAnnotation(elementType) { + return (0, _validateNode.default)({ + type: "ArrayTypeAnnotation", + elementType + }); +} + +function booleanTypeAnnotation() { + return { + type: "BooleanTypeAnnotation" + }; +} + +function booleanLiteralTypeAnnotation(value) { + return (0, _validateNode.default)({ + type: "BooleanLiteralTypeAnnotation", + value + }); +} + +function nullLiteralTypeAnnotation() { + return { + type: "NullLiteralTypeAnnotation" + }; +} + +function classImplements(id, typeParameters = null) { + return (0, _validateNode.default)({ + type: "ClassImplements", + id, + typeParameters + }); +} + +function declareClass(id, typeParameters = null, _extends = null, body) { + return (0, _validateNode.default)({ + type: "DeclareClass", + id, + typeParameters, + extends: _extends, + body + }); +} + +function declareFunction(id) { + return (0, _validateNode.default)({ + type: "DeclareFunction", + id + }); +} + +function declareInterface(id, typeParameters = null, _extends = null, body) { + return (0, _validateNode.default)({ + type: "DeclareInterface", + id, + typeParameters, + extends: _extends, + body + }); +} + +function declareModule(id, body, kind = null) { + return (0, _validateNode.default)({ + type: "DeclareModule", + id, + body, + kind + }); +} + +function declareModuleExports(typeAnnotation) { + return (0, _validateNode.default)({ + type: "DeclareModuleExports", + typeAnnotation + }); +} + +function declareTypeAlias(id, typeParameters = null, right) { + return (0, _validateNode.default)({ + type: "DeclareTypeAlias", + id, + typeParameters, + right + }); +} + +function declareOpaqueType(id, typeParameters = null, supertype = null) { + return (0, _validateNode.default)({ + type: "DeclareOpaqueType", + id, + typeParameters, + supertype + }); +} + +function declareVariable(id) { + return (0, _validateNode.default)({ + type: "DeclareVariable", + id + }); +} + +function declareExportDeclaration(declaration = null, specifiers = null, source = null) { + return (0, _validateNode.default)({ + type: "DeclareExportDeclaration", + declaration, + specifiers, + source + }); +} + +function declareExportAllDeclaration(source) { + return (0, _validateNode.default)({ + type: "DeclareExportAllDeclaration", + source + }); +} + +function declaredPredicate(value) { + return (0, _validateNode.default)({ + type: "DeclaredPredicate", + value + }); +} + +function existsTypeAnnotation() { + return { + type: "ExistsTypeAnnotation" + }; +} + +function functionTypeAnnotation(typeParameters = null, params, rest = null, returnType) { + return (0, _validateNode.default)({ + type: "FunctionTypeAnnotation", + typeParameters, + params, + rest, + returnType + }); +} + +function functionTypeParam(name = null, typeAnnotation) { + return (0, _validateNode.default)({ + type: "FunctionTypeParam", + name, + typeAnnotation + }); +} + +function genericTypeAnnotation(id, typeParameters = null) { + return (0, _validateNode.default)({ + type: "GenericTypeAnnotation", + id, + typeParameters + }); +} + +function inferredPredicate() { + return { + type: "InferredPredicate" + }; +} + +function interfaceExtends(id, typeParameters = null) { + return (0, _validateNode.default)({ + type: "InterfaceExtends", + id, + typeParameters + }); +} + +function interfaceDeclaration(id, typeParameters = null, _extends = null, body) { + return (0, _validateNode.default)({ + type: "InterfaceDeclaration", + id, + typeParameters, + extends: _extends, + body + }); +} + +function interfaceTypeAnnotation(_extends = null, body) { + return (0, _validateNode.default)({ + type: "InterfaceTypeAnnotation", + extends: _extends, + body + }); +} + +function intersectionTypeAnnotation(types) { + return (0, _validateNode.default)({ + type: "IntersectionTypeAnnotation", + types + }); +} + +function mixedTypeAnnotation() { + return { + type: "MixedTypeAnnotation" + }; +} + +function emptyTypeAnnotation() { + return { + type: "EmptyTypeAnnotation" + }; +} + +function nullableTypeAnnotation(typeAnnotation) { + return (0, _validateNode.default)({ + type: "NullableTypeAnnotation", + typeAnnotation + }); +} + +function numberLiteralTypeAnnotation(value) { + return (0, _validateNode.default)({ + type: "NumberLiteralTypeAnnotation", + value + }); +} + +function numberTypeAnnotation() { + return { + type: "NumberTypeAnnotation" + }; +} + +function objectTypeAnnotation(properties, indexers = [], callProperties = [], internalSlots = [], exact = false) { + return (0, _validateNode.default)({ + type: "ObjectTypeAnnotation", + properties, + indexers, + callProperties, + internalSlots, + exact + }); +} + +function objectTypeInternalSlot(id, value, optional, _static, method) { + return (0, _validateNode.default)({ + type: "ObjectTypeInternalSlot", + id, + value, + optional, + static: _static, + method + }); +} + +function objectTypeCallProperty(value) { + return (0, _validateNode.default)({ + type: "ObjectTypeCallProperty", + value, + static: null + }); +} + +function objectTypeIndexer(id = null, key, value, variance = null) { + return (0, _validateNode.default)({ + type: "ObjectTypeIndexer", + id, + key, + value, + variance, + static: null + }); +} + +function objectTypeProperty(key, value, variance = null) { + return (0, _validateNode.default)({ + type: "ObjectTypeProperty", + key, + value, + variance, + kind: null, + method: null, + optional: null, + proto: null, + static: null + }); +} + +function objectTypeSpreadProperty(argument) { + return (0, _validateNode.default)({ + type: "ObjectTypeSpreadProperty", + argument + }); +} + +function opaqueType(id, typeParameters = null, supertype = null, impltype) { + return (0, _validateNode.default)({ + type: "OpaqueType", + id, + typeParameters, + supertype, + impltype + }); +} + +function qualifiedTypeIdentifier(id, qualification) { + return (0, _validateNode.default)({ + type: "QualifiedTypeIdentifier", + id, + qualification + }); +} + +function stringLiteralTypeAnnotation(value) { + return (0, _validateNode.default)({ + type: "StringLiteralTypeAnnotation", + value + }); +} + +function stringTypeAnnotation() { + return { + type: "StringTypeAnnotation" + }; +} + +function symbolTypeAnnotation() { + return { + type: "SymbolTypeAnnotation" + }; +} + +function thisTypeAnnotation() { + return { + type: "ThisTypeAnnotation" + }; +} + +function tupleTypeAnnotation(types) { + return (0, _validateNode.default)({ + type: "TupleTypeAnnotation", + types + }); +} + +function typeofTypeAnnotation(argument) { + return (0, _validateNode.default)({ + type: "TypeofTypeAnnotation", + argument + }); +} + +function typeAlias(id, typeParameters = null, right) { + return (0, _validateNode.default)({ + type: "TypeAlias", + id, + typeParameters, + right + }); +} + +function typeAnnotation(typeAnnotation) { + return (0, _validateNode.default)({ + type: "TypeAnnotation", + typeAnnotation + }); +} + +function typeCastExpression(expression, typeAnnotation) { + return (0, _validateNode.default)({ + type: "TypeCastExpression", + expression, + typeAnnotation + }); +} + +function typeParameter(bound = null, _default = null, variance = null) { + return (0, _validateNode.default)({ + type: "TypeParameter", + bound, + default: _default, + variance, + name: null + }); +} + +function typeParameterDeclaration(params) { + return (0, _validateNode.default)({ + type: "TypeParameterDeclaration", + params + }); +} + +function typeParameterInstantiation(params) { + return (0, _validateNode.default)({ + type: "TypeParameterInstantiation", + params + }); +} + +function unionTypeAnnotation(types) { + return (0, _validateNode.default)({ + type: "UnionTypeAnnotation", + types + }); +} + +function variance(kind) { + return (0, _validateNode.default)({ + type: "Variance", + kind + }); +} + +function voidTypeAnnotation() { + return { + type: "VoidTypeAnnotation" + }; +} + +function enumDeclaration(id, body) { + return (0, _validateNode.default)({ + type: "EnumDeclaration", + id, + body + }); +} + +function enumBooleanBody(members) { + return (0, _validateNode.default)({ + type: "EnumBooleanBody", + members, + explicitType: null, + hasUnknownMembers: null + }); +} + +function enumNumberBody(members) { + return (0, _validateNode.default)({ + type: "EnumNumberBody", + members, + explicitType: null, + hasUnknownMembers: null + }); +} + +function enumStringBody(members) { + return (0, _validateNode.default)({ + type: "EnumStringBody", + members, + explicitType: null, + hasUnknownMembers: null + }); +} + +function enumSymbolBody(members) { + return (0, _validateNode.default)({ + type: "EnumSymbolBody", + members, + hasUnknownMembers: null + }); +} + +function enumBooleanMember(id) { + return (0, _validateNode.default)({ + type: "EnumBooleanMember", + id, + init: null + }); +} + +function enumNumberMember(id, init) { + return (0, _validateNode.default)({ + type: "EnumNumberMember", + id, + init + }); +} + +function enumStringMember(id, init) { + return (0, _validateNode.default)({ + type: "EnumStringMember", + id, + init + }); +} + +function enumDefaultedMember(id) { + return (0, _validateNode.default)({ + type: "EnumDefaultedMember", + id + }); +} + +function indexedAccessType(objectType, indexType) { + return (0, _validateNode.default)({ + type: "IndexedAccessType", + objectType, + indexType + }); +} + +function optionalIndexedAccessType(objectType, indexType) { + return (0, _validateNode.default)({ + type: "OptionalIndexedAccessType", + objectType, + indexType, + optional: null + }); +} + +function jsxAttribute(name, value = null) { + return (0, _validateNode.default)({ + type: "JSXAttribute", + name, + value + }); +} + +function jsxClosingElement(name) { + return (0, _validateNode.default)({ + type: "JSXClosingElement", + name + }); +} + +function jsxElement(openingElement, closingElement = null, children, selfClosing = null) { + return (0, _validateNode.default)({ + type: "JSXElement", + openingElement, + closingElement, + children, + selfClosing + }); +} + +function jsxEmptyExpression() { + return { + type: "JSXEmptyExpression" + }; +} + +function jsxExpressionContainer(expression) { + return (0, _validateNode.default)({ + type: "JSXExpressionContainer", + expression + }); +} + +function jsxSpreadChild(expression) { + return (0, _validateNode.default)({ + type: "JSXSpreadChild", + expression + }); +} + +function jsxIdentifier(name) { + return (0, _validateNode.default)({ + type: "JSXIdentifier", + name + }); +} + +function jsxMemberExpression(object, property) { + return (0, _validateNode.default)({ + type: "JSXMemberExpression", + object, + property + }); +} + +function jsxNamespacedName(namespace, name) { + return (0, _validateNode.default)({ + type: "JSXNamespacedName", + namespace, + name + }); +} + +function jsxOpeningElement(name, attributes, selfClosing = false) { + return (0, _validateNode.default)({ + type: "JSXOpeningElement", + name, + attributes, + selfClosing + }); +} + +function jsxSpreadAttribute(argument) { + return (0, _validateNode.default)({ + type: "JSXSpreadAttribute", + argument + }); +} + +function jsxText(value) { + return (0, _validateNode.default)({ + type: "JSXText", + value + }); +} + +function jsxFragment(openingFragment, closingFragment, children) { + return (0, _validateNode.default)({ + type: "JSXFragment", + openingFragment, + closingFragment, + children + }); +} + +function jsxOpeningFragment() { + return { + type: "JSXOpeningFragment" + }; +} + +function jsxClosingFragment() { + return { + type: "JSXClosingFragment" + }; +} + +function noop() { + return { + type: "Noop" + }; +} + +function placeholder(expectedNode, name) { + return (0, _validateNode.default)({ + type: "Placeholder", + expectedNode, + name + }); +} + +function v8IntrinsicIdentifier(name) { + return (0, _validateNode.default)({ + type: "V8IntrinsicIdentifier", + name + }); +} + +function argumentPlaceholder() { + return { + type: "ArgumentPlaceholder" + }; +} + +function bindExpression(object, callee) { + return (0, _validateNode.default)({ + type: "BindExpression", + object, + callee + }); +} + +function importAttribute(key, value) { + return (0, _validateNode.default)({ + type: "ImportAttribute", + key, + value + }); +} + +function decorator(expression) { + return (0, _validateNode.default)({ + type: "Decorator", + expression + }); +} + +function doExpression(body, async = false) { + return (0, _validateNode.default)({ + type: "DoExpression", + body, + async + }); +} + +function exportDefaultSpecifier(exported) { + return (0, _validateNode.default)({ + type: "ExportDefaultSpecifier", + exported + }); +} + +function recordExpression(properties) { + return (0, _validateNode.default)({ + type: "RecordExpression", + properties + }); +} + +function tupleExpression(elements = []) { + return (0, _validateNode.default)({ + type: "TupleExpression", + elements + }); +} + +function decimalLiteral(value) { + return (0, _validateNode.default)({ + type: "DecimalLiteral", + value + }); +} + +function moduleExpression(body) { + return (0, _validateNode.default)({ + type: "ModuleExpression", + body + }); +} + +function topicReference() { + return { + type: "TopicReference" + }; +} + +function pipelineTopicExpression(expression) { + return (0, _validateNode.default)({ + type: "PipelineTopicExpression", + expression + }); +} + +function pipelineBareFunction(callee) { + return (0, _validateNode.default)({ + type: "PipelineBareFunction", + callee + }); +} + +function pipelinePrimaryTopicReference() { + return { + type: "PipelinePrimaryTopicReference" + }; +} + +function tsParameterProperty(parameter) { + return (0, _validateNode.default)({ + type: "TSParameterProperty", + parameter + }); +} + +function tsDeclareFunction(id = null, typeParameters = null, params, returnType = null) { + return (0, _validateNode.default)({ + type: "TSDeclareFunction", + id, + typeParameters, + params, + returnType + }); +} + +function tsDeclareMethod(decorators = null, key, typeParameters = null, params, returnType = null) { + return (0, _validateNode.default)({ + type: "TSDeclareMethod", + decorators, + key, + typeParameters, + params, + returnType + }); +} + +function tsQualifiedName(left, right) { + return (0, _validateNode.default)({ + type: "TSQualifiedName", + left, + right + }); +} + +function tsCallSignatureDeclaration(typeParameters = null, parameters, typeAnnotation = null) { + return (0, _validateNode.default)({ + type: "TSCallSignatureDeclaration", + typeParameters, + parameters, + typeAnnotation + }); +} + +function tsConstructSignatureDeclaration(typeParameters = null, parameters, typeAnnotation = null) { + return (0, _validateNode.default)({ + type: "TSConstructSignatureDeclaration", + typeParameters, + parameters, + typeAnnotation + }); +} + +function tsPropertySignature(key, typeAnnotation = null, initializer = null) { + return (0, _validateNode.default)({ + type: "TSPropertySignature", + key, + typeAnnotation, + initializer, + kind: null + }); +} + +function tsMethodSignature(key, typeParameters = null, parameters, typeAnnotation = null) { + return (0, _validateNode.default)({ + type: "TSMethodSignature", + key, + typeParameters, + parameters, + typeAnnotation, + kind: null + }); +} + +function tsIndexSignature(parameters, typeAnnotation = null) { + return (0, _validateNode.default)({ + type: "TSIndexSignature", + parameters, + typeAnnotation + }); +} + +function tsAnyKeyword() { + return { + type: "TSAnyKeyword" + }; +} + +function tsBooleanKeyword() { + return { + type: "TSBooleanKeyword" + }; +} + +function tsBigIntKeyword() { + return { + type: "TSBigIntKeyword" + }; +} + +function tsIntrinsicKeyword() { + return { + type: "TSIntrinsicKeyword" + }; +} + +function tsNeverKeyword() { + return { + type: "TSNeverKeyword" + }; +} + +function tsNullKeyword() { + return { + type: "TSNullKeyword" + }; +} + +function tsNumberKeyword() { + return { + type: "TSNumberKeyword" + }; +} + +function tsObjectKeyword() { + return { + type: "TSObjectKeyword" + }; +} + +function tsStringKeyword() { + return { + type: "TSStringKeyword" + }; +} + +function tsSymbolKeyword() { + return { + type: "TSSymbolKeyword" + }; +} + +function tsUndefinedKeyword() { + return { + type: "TSUndefinedKeyword" + }; +} + +function tsUnknownKeyword() { + return { + type: "TSUnknownKeyword" + }; +} + +function tsVoidKeyword() { + return { + type: "TSVoidKeyword" + }; +} + +function tsThisType() { + return { + type: "TSThisType" + }; +} + +function tsFunctionType(typeParameters = null, parameters, typeAnnotation = null) { + return (0, _validateNode.default)({ + type: "TSFunctionType", + typeParameters, + parameters, + typeAnnotation + }); +} + +function tsConstructorType(typeParameters = null, parameters, typeAnnotation = null) { + return (0, _validateNode.default)({ + type: "TSConstructorType", + typeParameters, + parameters, + typeAnnotation + }); +} + +function tsTypeReference(typeName, typeParameters = null) { + return (0, _validateNode.default)({ + type: "TSTypeReference", + typeName, + typeParameters + }); +} + +function tsTypePredicate(parameterName, typeAnnotation = null, asserts = null) { + return (0, _validateNode.default)({ + type: "TSTypePredicate", + parameterName, + typeAnnotation, + asserts + }); +} + +function tsTypeQuery(exprName, typeParameters = null) { + return (0, _validateNode.default)({ + type: "TSTypeQuery", + exprName, + typeParameters + }); +} + +function tsTypeLiteral(members) { + return (0, _validateNode.default)({ + type: "TSTypeLiteral", + members + }); +} + +function tsArrayType(elementType) { + return (0, _validateNode.default)({ + type: "TSArrayType", + elementType + }); +} + +function tsTupleType(elementTypes) { + return (0, _validateNode.default)({ + type: "TSTupleType", + elementTypes + }); +} + +function tsOptionalType(typeAnnotation) { + return (0, _validateNode.default)({ + type: "TSOptionalType", + typeAnnotation + }); +} + +function tsRestType(typeAnnotation) { + return (0, _validateNode.default)({ + type: "TSRestType", + typeAnnotation + }); +} + +function tsNamedTupleMember(label, elementType, optional = false) { + return (0, _validateNode.default)({ + type: "TSNamedTupleMember", + label, + elementType, + optional + }); +} + +function tsUnionType(types) { + return (0, _validateNode.default)({ + type: "TSUnionType", + types + }); +} + +function tsIntersectionType(types) { + return (0, _validateNode.default)({ + type: "TSIntersectionType", + types + }); +} + +function tsConditionalType(checkType, extendsType, trueType, falseType) { + return (0, _validateNode.default)({ + type: "TSConditionalType", + checkType, + extendsType, + trueType, + falseType + }); +} + +function tsInferType(typeParameter) { + return (0, _validateNode.default)({ + type: "TSInferType", + typeParameter + }); +} + +function tsParenthesizedType(typeAnnotation) { + return (0, _validateNode.default)({ + type: "TSParenthesizedType", + typeAnnotation + }); +} + +function tsTypeOperator(typeAnnotation) { + return (0, _validateNode.default)({ + type: "TSTypeOperator", + typeAnnotation, + operator: null + }); +} + +function tsIndexedAccessType(objectType, indexType) { + return (0, _validateNode.default)({ + type: "TSIndexedAccessType", + objectType, + indexType + }); +} + +function tsMappedType(typeParameter, typeAnnotation = null, nameType = null) { + return (0, _validateNode.default)({ + type: "TSMappedType", + typeParameter, + typeAnnotation, + nameType + }); +} + +function tsLiteralType(literal) { + return (0, _validateNode.default)({ + type: "TSLiteralType", + literal + }); +} + +function tsExpressionWithTypeArguments(expression, typeParameters = null) { + return (0, _validateNode.default)({ + type: "TSExpressionWithTypeArguments", + expression, + typeParameters + }); +} + +function tsInterfaceDeclaration(id, typeParameters = null, _extends = null, body) { + return (0, _validateNode.default)({ + type: "TSInterfaceDeclaration", + id, + typeParameters, + extends: _extends, + body + }); +} + +function tsInterfaceBody(body) { + return (0, _validateNode.default)({ + type: "TSInterfaceBody", + body + }); +} + +function tsTypeAliasDeclaration(id, typeParameters = null, typeAnnotation) { + return (0, _validateNode.default)({ + type: "TSTypeAliasDeclaration", + id, + typeParameters, + typeAnnotation + }); +} + +function tsInstantiationExpression(expression, typeParameters = null) { + return (0, _validateNode.default)({ + type: "TSInstantiationExpression", + expression, + typeParameters + }); +} + +function tsAsExpression(expression, typeAnnotation) { + return (0, _validateNode.default)({ + type: "TSAsExpression", + expression, + typeAnnotation + }); +} + +function tsTypeAssertion(typeAnnotation, expression) { + return (0, _validateNode.default)({ + type: "TSTypeAssertion", + typeAnnotation, + expression + }); +} + +function tsEnumDeclaration(id, members) { + return (0, _validateNode.default)({ + type: "TSEnumDeclaration", + id, + members + }); +} + +function tsEnumMember(id, initializer = null) { + return (0, _validateNode.default)({ + type: "TSEnumMember", + id, + initializer + }); +} + +function tsModuleDeclaration(id, body) { + return (0, _validateNode.default)({ + type: "TSModuleDeclaration", + id, + body + }); +} + +function tsModuleBlock(body) { + return (0, _validateNode.default)({ + type: "TSModuleBlock", + body + }); +} + +function tsImportType(argument, qualifier = null, typeParameters = null) { + return (0, _validateNode.default)({ + type: "TSImportType", + argument, + qualifier, + typeParameters + }); +} + +function tsImportEqualsDeclaration(id, moduleReference) { + return (0, _validateNode.default)({ + type: "TSImportEqualsDeclaration", + id, + moduleReference, + isExport: null + }); +} + +function tsExternalModuleReference(expression) { + return (0, _validateNode.default)({ + type: "TSExternalModuleReference", + expression + }); +} + +function tsNonNullExpression(expression) { + return (0, _validateNode.default)({ + type: "TSNonNullExpression", + expression + }); +} + +function tsExportAssignment(expression) { + return (0, _validateNode.default)({ + type: "TSExportAssignment", + expression + }); +} + +function tsNamespaceExportDeclaration(id) { + return (0, _validateNode.default)({ + type: "TSNamespaceExportDeclaration", + id + }); +} + +function tsTypeAnnotation(typeAnnotation) { + return (0, _validateNode.default)({ + type: "TSTypeAnnotation", + typeAnnotation + }); +} + +function tsTypeParameterInstantiation(params) { + return (0, _validateNode.default)({ + type: "TSTypeParameterInstantiation", + params + }); +} + +function tsTypeParameterDeclaration(params) { + return (0, _validateNode.default)({ + type: "TSTypeParameterDeclaration", + params + }); +} + +function tsTypeParameter(constraint = null, _default = null, name) { + return (0, _validateNode.default)({ + type: "TSTypeParameter", + constraint, + default: _default, + name + }); +} + +function NumberLiteral(value) { + console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); + return numericLiteral(value); +} + +function RegexLiteral(pattern, flags = "") { + console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); + return regExpLiteral(pattern, flags); +} + +function RestProperty(argument) { + console.trace("The node type RestProperty has been renamed to RestElement"); + return restElement(argument); +} + +function SpreadProperty(argument) { + console.trace("The node type SpreadProperty has been renamed to SpreadElement"); + return spreadElement(argument); +} \ No newline at end of file diff --git a/node_modules/nyc/node_modules/@babel/types/lib/builders/generated/uppercase.js b/node_modules/nyc/node_modules/@babel/types/lib/builders/generated/uppercase.js new file mode 100644 index 000000000..0c49f05c4 --- /dev/null +++ b/node_modules/nyc/node_modules/@babel/types/lib/builders/generated/uppercase.js @@ -0,0 +1,1519 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +Object.defineProperty(exports, "AnyTypeAnnotation", { + enumerable: true, + get: function () { + return _index.anyTypeAnnotation; + } +}); +Object.defineProperty(exports, "ArgumentPlaceholder", { + enumerable: true, + get: function () { + return _index.argumentPlaceholder; + } +}); +Object.defineProperty(exports, "ArrayExpression", { + enumerable: true, + get: function () { + return _index.arrayExpression; + } +}); +Object.defineProperty(exports, "ArrayPattern", { + enumerable: true, + get: function () { + return _index.arrayPattern; + } +}); +Object.defineProperty(exports, "ArrayTypeAnnotation", { + enumerable: true, + get: function () { + return _index.arrayTypeAnnotation; + } +}); +Object.defineProperty(exports, "ArrowFunctionExpression", { + enumerable: true, + get: function () { + return _index.arrowFunctionExpression; + } +}); +Object.defineProperty(exports, "AssignmentExpression", { + enumerable: true, + get: function () { + return _index.assignmentExpression; + } +}); +Object.defineProperty(exports, "AssignmentPattern", { + enumerable: true, + get: function () { + return _index.assignmentPattern; + } +}); +Object.defineProperty(exports, "AwaitExpression", { + enumerable: true, + get: function () { + return _index.awaitExpression; + } +}); +Object.defineProperty(exports, "BigIntLiteral", { + enumerable: true, + get: function () { + return _index.bigIntLiteral; + } +}); +Object.defineProperty(exports, "BinaryExpression", { + enumerable: true, + get: function () { + return _index.binaryExpression; + } +}); +Object.defineProperty(exports, "BindExpression", { + enumerable: true, + get: function () { + return _index.bindExpression; + } +}); +Object.defineProperty(exports, "BlockStatement", { + enumerable: true, + get: function () { + return _index.blockStatement; + } +}); +Object.defineProperty(exports, "BooleanLiteral", { + enumerable: true, + get: function () { + return _index.booleanLiteral; + } +}); +Object.defineProperty(exports, "BooleanLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.booleanLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "BooleanTypeAnnotation", { + enumerable: true, + get: function () { + return _index.booleanTypeAnnotation; + } +}); +Object.defineProperty(exports, "BreakStatement", { + enumerable: true, + get: function () { + return _index.breakStatement; + } +}); +Object.defineProperty(exports, "CallExpression", { + enumerable: true, + get: function () { + return _index.callExpression; + } +}); +Object.defineProperty(exports, "CatchClause", { + enumerable: true, + get: function () { + return _index.catchClause; + } +}); +Object.defineProperty(exports, "ClassAccessorProperty", { + enumerable: true, + get: function () { + return _index.classAccessorProperty; + } +}); +Object.defineProperty(exports, "ClassBody", { + enumerable: true, + get: function () { + return _index.classBody; + } +}); +Object.defineProperty(exports, "ClassDeclaration", { + enumerable: true, + get: function () { + return _index.classDeclaration; + } +}); +Object.defineProperty(exports, "ClassExpression", { + enumerable: true, + get: function () { + return _index.classExpression; + } +}); +Object.defineProperty(exports, "ClassImplements", { + enumerable: true, + get: function () { + return _index.classImplements; + } +}); +Object.defineProperty(exports, "ClassMethod", { + enumerable: true, + get: function () { + return _index.classMethod; + } +}); +Object.defineProperty(exports, "ClassPrivateMethod", { + enumerable: true, + get: function () { + return _index.classPrivateMethod; + } +}); +Object.defineProperty(exports, "ClassPrivateProperty", { + enumerable: true, + get: function () { + return _index.classPrivateProperty; + } +}); +Object.defineProperty(exports, "ClassProperty", { + enumerable: true, + get: function () { + return _index.classProperty; + } +}); +Object.defineProperty(exports, "ConditionalExpression", { + enumerable: true, + get: function () { + return _index.conditionalExpression; + } +}); +Object.defineProperty(exports, "ContinueStatement", { + enumerable: true, + get: function () { + return _index.continueStatement; + } +}); +Object.defineProperty(exports, "DebuggerStatement", { + enumerable: true, + get: function () { + return _index.debuggerStatement; + } +}); +Object.defineProperty(exports, "DecimalLiteral", { + enumerable: true, + get: function () { + return _index.decimalLiteral; + } +}); +Object.defineProperty(exports, "DeclareClass", { + enumerable: true, + get: function () { + return _index.declareClass; + } +}); +Object.defineProperty(exports, "DeclareExportAllDeclaration", { + enumerable: true, + get: function () { + return _index.declareExportAllDeclaration; + } +}); +Object.defineProperty(exports, "DeclareExportDeclaration", { + enumerable: true, + get: function () { + return _index.declareExportDeclaration; + } +}); +Object.defineProperty(exports, "DeclareFunction", { + enumerable: true, + get: function () { + return _index.declareFunction; + } +}); +Object.defineProperty(exports, "DeclareInterface", { + enumerable: true, + get: function () { + return _index.declareInterface; + } +}); +Object.defineProperty(exports, "DeclareModule", { + enumerable: true, + get: function () { + return _index.declareModule; + } +}); +Object.defineProperty(exports, "DeclareModuleExports", { + enumerable: true, + get: function () { + return _index.declareModuleExports; + } +}); +Object.defineProperty(exports, "DeclareOpaqueType", { + enumerable: true, + get: function () { + return _index.declareOpaqueType; + } +}); +Object.defineProperty(exports, "DeclareTypeAlias", { + enumerable: true, + get: function () { + return _index.declareTypeAlias; + } +}); +Object.defineProperty(exports, "DeclareVariable", { + enumerable: true, + get: function () { + return _index.declareVariable; + } +}); +Object.defineProperty(exports, "DeclaredPredicate", { + enumerable: true, + get: function () { + return _index.declaredPredicate; + } +}); +Object.defineProperty(exports, "Decorator", { + enumerable: true, + get: function () { + return _index.decorator; + } +}); +Object.defineProperty(exports, "Directive", { + enumerable: true, + get: function () { + return _index.directive; + } +}); +Object.defineProperty(exports, "DirectiveLiteral", { + enumerable: true, + get: function () { + return _index.directiveLiteral; + } +}); +Object.defineProperty(exports, "DoExpression", { + enumerable: true, + get: function () { + return _index.doExpression; + } +}); +Object.defineProperty(exports, "DoWhileStatement", { + enumerable: true, + get: function () { + return _index.doWhileStatement; + } +}); +Object.defineProperty(exports, "EmptyStatement", { + enumerable: true, + get: function () { + return _index.emptyStatement; + } +}); +Object.defineProperty(exports, "EmptyTypeAnnotation", { + enumerable: true, + get: function () { + return _index.emptyTypeAnnotation; + } +}); +Object.defineProperty(exports, "EnumBooleanBody", { + enumerable: true, + get: function () { + return _index.enumBooleanBody; + } +}); +Object.defineProperty(exports, "EnumBooleanMember", { + enumerable: true, + get: function () { + return _index.enumBooleanMember; + } +}); +Object.defineProperty(exports, "EnumDeclaration", { + enumerable: true, + get: function () { + return _index.enumDeclaration; + } +}); +Object.defineProperty(exports, "EnumDefaultedMember", { + enumerable: true, + get: function () { + return _index.enumDefaultedMember; + } +}); +Object.defineProperty(exports, "EnumNumberBody", { + enumerable: true, + get: function () { + return _index.enumNumberBody; + } +}); +Object.defineProperty(exports, "EnumNumberMember", { + enumerable: true, + get: function () { + return _index.enumNumberMember; + } +}); +Object.defineProperty(exports, "EnumStringBody", { + enumerable: true, + get: function () { + return _index.enumStringBody; + } +}); +Object.defineProperty(exports, "EnumStringMember", { + enumerable: true, + get: function () { + return _index.enumStringMember; + } +}); +Object.defineProperty(exports, "EnumSymbolBody", { + enumerable: true, + get: function () { + return _index.enumSymbolBody; + } +}); +Object.defineProperty(exports, "ExistsTypeAnnotation", { + enumerable: true, + get: function () { + return _index.existsTypeAnnotation; + } +}); +Object.defineProperty(exports, "ExportAllDeclaration", { + enumerable: true, + get: function () { + return _index.exportAllDeclaration; + } +}); +Object.defineProperty(exports, "ExportDefaultDeclaration", { + enumerable: true, + get: function () { + return _index.exportDefaultDeclaration; + } +}); +Object.defineProperty(exports, "ExportDefaultSpecifier", { + enumerable: true, + get: function () { + return _index.exportDefaultSpecifier; + } +}); +Object.defineProperty(exports, "ExportNamedDeclaration", { + enumerable: true, + get: function () { + return _index.exportNamedDeclaration; + } +}); +Object.defineProperty(exports, "ExportNamespaceSpecifier", { + enumerable: true, + get: function () { + return _index.exportNamespaceSpecifier; + } +}); +Object.defineProperty(exports, "ExportSpecifier", { + enumerable: true, + get: function () { + return _index.exportSpecifier; + } +}); +Object.defineProperty(exports, "ExpressionStatement", { + enumerable: true, + get: function () { + return _index.expressionStatement; + } +}); +Object.defineProperty(exports, "File", { + enumerable: true, + get: function () { + return _index.file; + } +}); +Object.defineProperty(exports, "ForInStatement", { + enumerable: true, + get: function () { + return _index.forInStatement; + } +}); +Object.defineProperty(exports, "ForOfStatement", { + enumerable: true, + get: function () { + return _index.forOfStatement; + } +}); +Object.defineProperty(exports, "ForStatement", { + enumerable: true, + get: function () { + return _index.forStatement; + } +}); +Object.defineProperty(exports, "FunctionDeclaration", { + enumerable: true, + get: function () { + return _index.functionDeclaration; + } +}); +Object.defineProperty(exports, "FunctionExpression", { + enumerable: true, + get: function () { + return _index.functionExpression; + } +}); +Object.defineProperty(exports, "FunctionTypeAnnotation", { + enumerable: true, + get: function () { + return _index.functionTypeAnnotation; + } +}); +Object.defineProperty(exports, "FunctionTypeParam", { + enumerable: true, + get: function () { + return _index.functionTypeParam; + } +}); +Object.defineProperty(exports, "GenericTypeAnnotation", { + enumerable: true, + get: function () { + return _index.genericTypeAnnotation; + } +}); +Object.defineProperty(exports, "Identifier", { + enumerable: true, + get: function () { + return _index.identifier; + } +}); +Object.defineProperty(exports, "IfStatement", { + enumerable: true, + get: function () { + return _index.ifStatement; + } +}); +Object.defineProperty(exports, "Import", { + enumerable: true, + get: function () { + return _index.import; + } +}); +Object.defineProperty(exports, "ImportAttribute", { + enumerable: true, + get: function () { + return _index.importAttribute; + } +}); +Object.defineProperty(exports, "ImportDeclaration", { + enumerable: true, + get: function () { + return _index.importDeclaration; + } +}); +Object.defineProperty(exports, "ImportDefaultSpecifier", { + enumerable: true, + get: function () { + return _index.importDefaultSpecifier; + } +}); +Object.defineProperty(exports, "ImportNamespaceSpecifier", { + enumerable: true, + get: function () { + return _index.importNamespaceSpecifier; + } +}); +Object.defineProperty(exports, "ImportSpecifier", { + enumerable: true, + get: function () { + return _index.importSpecifier; + } +}); +Object.defineProperty(exports, "IndexedAccessType", { + enumerable: true, + get: function () { + return _index.indexedAccessType; + } +}); +Object.defineProperty(exports, "InferredPredicate", { + enumerable: true, + get: function () { + return _index.inferredPredicate; + } +}); +Object.defineProperty(exports, "InterfaceDeclaration", { + enumerable: true, + get: function () { + return _index.interfaceDeclaration; + } +}); +Object.defineProperty(exports, "InterfaceExtends", { + enumerable: true, + get: function () { + return _index.interfaceExtends; + } +}); +Object.defineProperty(exports, "InterfaceTypeAnnotation", { + enumerable: true, + get: function () { + return _index.interfaceTypeAnnotation; + } +}); +Object.defineProperty(exports, "InterpreterDirective", { + enumerable: true, + get: function () { + return _index.interpreterDirective; + } +}); +Object.defineProperty(exports, "IntersectionTypeAnnotation", { + enumerable: true, + get: function () { + return _index.intersectionTypeAnnotation; + } +}); +Object.defineProperty(exports, "JSXAttribute", { + enumerable: true, + get: function () { + return _index.jsxAttribute; + } +}); +Object.defineProperty(exports, "JSXClosingElement", { + enumerable: true, + get: function () { + return _index.jsxClosingElement; + } +}); +Object.defineProperty(exports, "JSXClosingFragment", { + enumerable: true, + get: function () { + return _index.jsxClosingFragment; + } +}); +Object.defineProperty(exports, "JSXElement", { + enumerable: true, + get: function () { + return _index.jsxElement; + } +}); +Object.defineProperty(exports, "JSXEmptyExpression", { + enumerable: true, + get: function () { + return _index.jsxEmptyExpression; + } +}); +Object.defineProperty(exports, "JSXExpressionContainer", { + enumerable: true, + get: function () { + return _index.jsxExpressionContainer; + } +}); +Object.defineProperty(exports, "JSXFragment", { + enumerable: true, + get: function () { + return _index.jsxFragment; + } +}); +Object.defineProperty(exports, "JSXIdentifier", { + enumerable: true, + get: function () { + return _index.jsxIdentifier; + } +}); +Object.defineProperty(exports, "JSXMemberExpression", { + enumerable: true, + get: function () { + return _index.jsxMemberExpression; + } +}); +Object.defineProperty(exports, "JSXNamespacedName", { + enumerable: true, + get: function () { + return _index.jsxNamespacedName; + } +}); +Object.defineProperty(exports, "JSXOpeningElement", { + enumerable: true, + get: function () { + return _index.jsxOpeningElement; + } +}); +Object.defineProperty(exports, "JSXOpeningFragment", { + enumerable: true, + get: function () { + return _index.jsxOpeningFragment; + } +}); +Object.defineProperty(exports, "JSXSpreadAttribute", { + enumerable: true, + get: function () { + return _index.jsxSpreadAttribute; + } +}); +Object.defineProperty(exports, "JSXSpreadChild", { + enumerable: true, + get: function () { + return _index.jsxSpreadChild; + } +}); +Object.defineProperty(exports, "JSXText", { + enumerable: true, + get: function () { + return _index.jsxText; + } +}); +Object.defineProperty(exports, "LabeledStatement", { + enumerable: true, + get: function () { + return _index.labeledStatement; + } +}); +Object.defineProperty(exports, "LogicalExpression", { + enumerable: true, + get: function () { + return _index.logicalExpression; + } +}); +Object.defineProperty(exports, "MemberExpression", { + enumerable: true, + get: function () { + return _index.memberExpression; + } +}); +Object.defineProperty(exports, "MetaProperty", { + enumerable: true, + get: function () { + return _index.metaProperty; + } +}); +Object.defineProperty(exports, "MixedTypeAnnotation", { + enumerable: true, + get: function () { + return _index.mixedTypeAnnotation; + } +}); +Object.defineProperty(exports, "ModuleExpression", { + enumerable: true, + get: function () { + return _index.moduleExpression; + } +}); +Object.defineProperty(exports, "NewExpression", { + enumerable: true, + get: function () { + return _index.newExpression; + } +}); +Object.defineProperty(exports, "Noop", { + enumerable: true, + get: function () { + return _index.noop; + } +}); +Object.defineProperty(exports, "NullLiteral", { + enumerable: true, + get: function () { + return _index.nullLiteral; + } +}); +Object.defineProperty(exports, "NullLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.nullLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "NullableTypeAnnotation", { + enumerable: true, + get: function () { + return _index.nullableTypeAnnotation; + } +}); +Object.defineProperty(exports, "NumberLiteral", { + enumerable: true, + get: function () { + return _index.numberLiteral; + } +}); +Object.defineProperty(exports, "NumberLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.numberLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "NumberTypeAnnotation", { + enumerable: true, + get: function () { + return _index.numberTypeAnnotation; + } +}); +Object.defineProperty(exports, "NumericLiteral", { + enumerable: true, + get: function () { + return _index.numericLiteral; + } +}); +Object.defineProperty(exports, "ObjectExpression", { + enumerable: true, + get: function () { + return _index.objectExpression; + } +}); +Object.defineProperty(exports, "ObjectMethod", { + enumerable: true, + get: function () { + return _index.objectMethod; + } +}); +Object.defineProperty(exports, "ObjectPattern", { + enumerable: true, + get: function () { + return _index.objectPattern; + } +}); +Object.defineProperty(exports, "ObjectProperty", { + enumerable: true, + get: function () { + return _index.objectProperty; + } +}); +Object.defineProperty(exports, "ObjectTypeAnnotation", { + enumerable: true, + get: function () { + return _index.objectTypeAnnotation; + } +}); +Object.defineProperty(exports, "ObjectTypeCallProperty", { + enumerable: true, + get: function () { + return _index.objectTypeCallProperty; + } +}); +Object.defineProperty(exports, "ObjectTypeIndexer", { + enumerable: true, + get: function () { + return _index.objectTypeIndexer; + } +}); +Object.defineProperty(exports, "ObjectTypeInternalSlot", { + enumerable: true, + get: function () { + return _index.objectTypeInternalSlot; + } +}); +Object.defineProperty(exports, "ObjectTypeProperty", { + enumerable: true, + get: function () { + return _index.objectTypeProperty; + } +}); +Object.defineProperty(exports, "ObjectTypeSpreadProperty", { + enumerable: true, + get: function () { + return _index.objectTypeSpreadProperty; + } +}); +Object.defineProperty(exports, "OpaqueType", { + enumerable: true, + get: function () { + return _index.opaqueType; + } +}); +Object.defineProperty(exports, "OptionalCallExpression", { + enumerable: true, + get: function () { + return _index.optionalCallExpression; + } +}); +Object.defineProperty(exports, "OptionalIndexedAccessType", { + enumerable: true, + get: function () { + return _index.optionalIndexedAccessType; + } +}); +Object.defineProperty(exports, "OptionalMemberExpression", { + enumerable: true, + get: function () { + return _index.optionalMemberExpression; + } +}); +Object.defineProperty(exports, "ParenthesizedExpression", { + enumerable: true, + get: function () { + return _index.parenthesizedExpression; + } +}); +Object.defineProperty(exports, "PipelineBareFunction", { + enumerable: true, + get: function () { + return _index.pipelineBareFunction; + } +}); +Object.defineProperty(exports, "PipelinePrimaryTopicReference", { + enumerable: true, + get: function () { + return _index.pipelinePrimaryTopicReference; + } +}); +Object.defineProperty(exports, "PipelineTopicExpression", { + enumerable: true, + get: function () { + return _index.pipelineTopicExpression; + } +}); +Object.defineProperty(exports, "Placeholder", { + enumerable: true, + get: function () { + return _index.placeholder; + } +}); +Object.defineProperty(exports, "PrivateName", { + enumerable: true, + get: function () { + return _index.privateName; + } +}); +Object.defineProperty(exports, "Program", { + enumerable: true, + get: function () { + return _index.program; + } +}); +Object.defineProperty(exports, "QualifiedTypeIdentifier", { + enumerable: true, + get: function () { + return _index.qualifiedTypeIdentifier; + } +}); +Object.defineProperty(exports, "RecordExpression", { + enumerable: true, + get: function () { + return _index.recordExpression; + } +}); +Object.defineProperty(exports, "RegExpLiteral", { + enumerable: true, + get: function () { + return _index.regExpLiteral; + } +}); +Object.defineProperty(exports, "RegexLiteral", { + enumerable: true, + get: function () { + return _index.regexLiteral; + } +}); +Object.defineProperty(exports, "RestElement", { + enumerable: true, + get: function () { + return _index.restElement; + } +}); +Object.defineProperty(exports, "RestProperty", { + enumerable: true, + get: function () { + return _index.restProperty; + } +}); +Object.defineProperty(exports, "ReturnStatement", { + enumerable: true, + get: function () { + return _index.returnStatement; + } +}); +Object.defineProperty(exports, "SequenceExpression", { + enumerable: true, + get: function () { + return _index.sequenceExpression; + } +}); +Object.defineProperty(exports, "SpreadElement", { + enumerable: true, + get: function () { + return _index.spreadElement; + } +}); +Object.defineProperty(exports, "SpreadProperty", { + enumerable: true, + get: function () { + return _index.spreadProperty; + } +}); +Object.defineProperty(exports, "StaticBlock", { + enumerable: true, + get: function () { + return _index.staticBlock; + } +}); +Object.defineProperty(exports, "StringLiteral", { + enumerable: true, + get: function () { + return _index.stringLiteral; + } +}); +Object.defineProperty(exports, "StringLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.stringLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "StringTypeAnnotation", { + enumerable: true, + get: function () { + return _index.stringTypeAnnotation; + } +}); +Object.defineProperty(exports, "Super", { + enumerable: true, + get: function () { + return _index.super; + } +}); +Object.defineProperty(exports, "SwitchCase", { + enumerable: true, + get: function () { + return _index.switchCase; + } +}); +Object.defineProperty(exports, "SwitchStatement", { + enumerable: true, + get: function () { + return _index.switchStatement; + } +}); +Object.defineProperty(exports, "SymbolTypeAnnotation", { + enumerable: true, + get: function () { + return _index.symbolTypeAnnotation; + } +}); +Object.defineProperty(exports, "TSAnyKeyword", { + enumerable: true, + get: function () { + return _index.tsAnyKeyword; + } +}); +Object.defineProperty(exports, "TSArrayType", { + enumerable: true, + get: function () { + return _index.tsArrayType; + } +}); +Object.defineProperty(exports, "TSAsExpression", { + enumerable: true, + get: function () { + return _index.tsAsExpression; + } +}); +Object.defineProperty(exports, "TSBigIntKeyword", { + enumerable: true, + get: function () { + return _index.tsBigIntKeyword; + } +}); +Object.defineProperty(exports, "TSBooleanKeyword", { + enumerable: true, + get: function () { + return _index.tsBooleanKeyword; + } +}); +Object.defineProperty(exports, "TSCallSignatureDeclaration", { + enumerable: true, + get: function () { + return _index.tsCallSignatureDeclaration; + } +}); +Object.defineProperty(exports, "TSConditionalType", { + enumerable: true, + get: function () { + return _index.tsConditionalType; + } +}); +Object.defineProperty(exports, "TSConstructSignatureDeclaration", { + enumerable: true, + get: function () { + return _index.tsConstructSignatureDeclaration; + } +}); +Object.defineProperty(exports, "TSConstructorType", { + enumerable: true, + get: function () { + return _index.tsConstructorType; + } +}); +Object.defineProperty(exports, "TSDeclareFunction", { + enumerable: true, + get: function () { + return _index.tsDeclareFunction; + } +}); +Object.defineProperty(exports, "TSDeclareMethod", { + enumerable: true, + get: function () { + return _index.tsDeclareMethod; + } +}); +Object.defineProperty(exports, "TSEnumDeclaration", { + enumerable: true, + get: function () { + return _index.tsEnumDeclaration; + } +}); +Object.defineProperty(exports, "TSEnumMember", { + enumerable: true, + get: function () { + return _index.tsEnumMember; + } +}); +Object.defineProperty(exports, "TSExportAssignment", { + enumerable: true, + get: function () { + return _index.tsExportAssignment; + } +}); +Object.defineProperty(exports, "TSExpressionWithTypeArguments", { + enumerable: true, + get: function () { + return _index.tsExpressionWithTypeArguments; + } +}); +Object.defineProperty(exports, "TSExternalModuleReference", { + enumerable: true, + get: function () { + return _index.tsExternalModuleReference; + } +}); +Object.defineProperty(exports, "TSFunctionType", { + enumerable: true, + get: function () { + return _index.tsFunctionType; + } +}); +Object.defineProperty(exports, "TSImportEqualsDeclaration", { + enumerable: true, + get: function () { + return _index.tsImportEqualsDeclaration; + } +}); +Object.defineProperty(exports, "TSImportType", { + enumerable: true, + get: function () { + return _index.tsImportType; + } +}); +Object.defineProperty(exports, "TSIndexSignature", { + enumerable: true, + get: function () { + return _index.tsIndexSignature; + } +}); +Object.defineProperty(exports, "TSIndexedAccessType", { + enumerable: true, + get: function () { + return _index.tsIndexedAccessType; + } +}); +Object.defineProperty(exports, "TSInferType", { + enumerable: true, + get: function () { + return _index.tsInferType; + } +}); +Object.defineProperty(exports, "TSInstantiationExpression", { + enumerable: true, + get: function () { + return _index.tsInstantiationExpression; + } +}); +Object.defineProperty(exports, "TSInterfaceBody", { + enumerable: true, + get: function () { + return _index.tsInterfaceBody; + } +}); +Object.defineProperty(exports, "TSInterfaceDeclaration", { + enumerable: true, + get: function () { + return _index.tsInterfaceDeclaration; + } +}); +Object.defineProperty(exports, "TSIntersectionType", { + enumerable: true, + get: function () { + return _index.tsIntersectionType; + } +}); +Object.defineProperty(exports, "TSIntrinsicKeyword", { + enumerable: true, + get: function () { + return _index.tsIntrinsicKeyword; + } +}); +Object.defineProperty(exports, "TSLiteralType", { + enumerable: true, + get: function () { + return _index.tsLiteralType; + } +}); +Object.defineProperty(exports, "TSMappedType", { + enumerable: true, + get: function () { + return _index.tsMappedType; + } +}); +Object.defineProperty(exports, "TSMethodSignature", { + enumerable: true, + get: function () { + return _index.tsMethodSignature; + } +}); +Object.defineProperty(exports, "TSModuleBlock", { + enumerable: true, + get: function () { + return _index.tsModuleBlock; + } +}); +Object.defineProperty(exports, "TSModuleDeclaration", { + enumerable: true, + get: function () { + return _index.tsModuleDeclaration; + } +}); +Object.defineProperty(exports, "TSNamedTupleMember", { + enumerable: true, + get: function () { + return _index.tsNamedTupleMember; + } +}); +Object.defineProperty(exports, "TSNamespaceExportDeclaration", { + enumerable: true, + get: function () { + return _index.tsNamespaceExportDeclaration; + } +}); +Object.defineProperty(exports, "TSNeverKeyword", { + enumerable: true, + get: function () { + return _index.tsNeverKeyword; + } +}); +Object.defineProperty(exports, "TSNonNullExpression", { + enumerable: true, + get: function () { + return _index.tsNonNullExpression; + } +}); +Object.defineProperty(exports, "TSNullKeyword", { + enumerable: true, + get: function () { + return _index.tsNullKeyword; + } +}); +Object.defineProperty(exports, "TSNumberKeyword", { + enumerable: true, + get: function () { + return _index.tsNumberKeyword; + } +}); +Object.defineProperty(exports, "TSObjectKeyword", { + enumerable: true, + get: function () { + return _index.tsObjectKeyword; + } +}); +Object.defineProperty(exports, "TSOptionalType", { + enumerable: true, + get: function () { + return _index.tsOptionalType; + } +}); +Object.defineProperty(exports, "TSParameterProperty", { + enumerable: true, + get: function () { + return _index.tsParameterProperty; + } +}); +Object.defineProperty(exports, "TSParenthesizedType", { + enumerable: true, + get: function () { + return _index.tsParenthesizedType; + } +}); +Object.defineProperty(exports, "TSPropertySignature", { + enumerable: true, + get: function () { + return _index.tsPropertySignature; + } +}); +Object.defineProperty(exports, "TSQualifiedName", { + enumerable: true, + get: function () { + return _index.tsQualifiedName; + } +}); +Object.defineProperty(exports, "TSRestType", { + enumerable: true, + get: function () { + return _index.tsRestType; + } +}); +Object.defineProperty(exports, "TSStringKeyword", { + enumerable: true, + get: function () { + return _index.tsStringKeyword; + } +}); +Object.defineProperty(exports, "TSSymbolKeyword", { + enumerable: true, + get: function () { + return _index.tsSymbolKeyword; + } +}); +Object.defineProperty(exports, "TSThisType", { + enumerable: true, + get: function () { + return _index.tsThisType; + } +}); +Object.defineProperty(exports, "TSTupleType", { + enumerable: true, + get: function () { + return _index.tsTupleType; + } +}); +Object.defineProperty(exports, "TSTypeAliasDeclaration", { + enumerable: true, + get: function () { + return _index.tsTypeAliasDeclaration; + } +}); +Object.defineProperty(exports, "TSTypeAnnotation", { + enumerable: true, + get: function () { + return _index.tsTypeAnnotation; + } +}); +Object.defineProperty(exports, "TSTypeAssertion", { + enumerable: true, + get: function () { + return _index.tsTypeAssertion; + } +}); +Object.defineProperty(exports, "TSTypeLiteral", { + enumerable: true, + get: function () { + return _index.tsTypeLiteral; + } +}); +Object.defineProperty(exports, "TSTypeOperator", { + enumerable: true, + get: function () { + return _index.tsTypeOperator; + } +}); +Object.defineProperty(exports, "TSTypeParameter", { + enumerable: true, + get: function () { + return _index.tsTypeParameter; + } +}); +Object.defineProperty(exports, "TSTypeParameterDeclaration", { + enumerable: true, + get: function () { + return _index.tsTypeParameterDeclaration; + } +}); +Object.defineProperty(exports, "TSTypeParameterInstantiation", { + enumerable: true, + get: function () { + return _index.tsTypeParameterInstantiation; + } +}); +Object.defineProperty(exports, "TSTypePredicate", { + enumerable: true, + get: function () { + return _index.tsTypePredicate; + } +}); +Object.defineProperty(exports, "TSTypeQuery", { + enumerable: true, + get: function () { + return _index.tsTypeQuery; + } +}); +Object.defineProperty(exports, "TSTypeReference", { + enumerable: true, + get: function () { + return _index.tsTypeReference; + } +}); +Object.defineProperty(exports, "TSUndefinedKeyword", { + enumerable: true, + get: function () { + return _index.tsUndefinedKeyword; + } +}); +Object.defineProperty(exports, "TSUnionType", { + enumerable: true, + get: function () { + return _index.tsUnionType; + } +}); +Object.defineProperty(exports, "TSUnknownKeyword", { + enumerable: true, + get: function () { + return _index.tsUnknownKeyword; + } +}); +Object.defineProperty(exports, "TSVoidKeyword", { + enumerable: true, + get: function () { + return _index.tsVoidKeyword; + } +}); +Object.defineProperty(exports, "TaggedTemplateExpression", { + enumerable: true, + get: function () { + return _index.taggedTemplateExpression; + } +}); +Object.defineProperty(exports, "TemplateElement", { + enumerable: true, + get: function () { + return _index.templateElement; + } +}); +Object.defineProperty(exports, "TemplateLiteral", { + enumerable: true, + get: function () { + return _index.templateLiteral; + } +}); +Object.defineProperty(exports, "ThisExpression", { + enumerable: true, + get: function () { + return _index.thisExpression; + } +}); +Object.defineProperty(exports, "ThisTypeAnnotation", { + enumerable: true, + get: function () { + return _index.thisTypeAnnotation; + } +}); +Object.defineProperty(exports, "ThrowStatement", { + enumerable: true, + get: function () { + return _index.throwStatement; + } +}); +Object.defineProperty(exports, "TopicReference", { + enumerable: true, + get: function () { + return _index.topicReference; + } +}); +Object.defineProperty(exports, "TryStatement", { + enumerable: true, + get: function () { + return _index.tryStatement; + } +}); +Object.defineProperty(exports, "TupleExpression", { + enumerable: true, + get: function () { + return _index.tupleExpression; + } +}); +Object.defineProperty(exports, "TupleTypeAnnotation", { + enumerable: true, + get: function () { + return _index.tupleTypeAnnotation; + } +}); +Object.defineProperty(exports, "TypeAlias", { + enumerable: true, + get: function () { + return _index.typeAlias; + } +}); +Object.defineProperty(exports, "TypeAnnotation", { + enumerable: true, + get: function () { + return _index.typeAnnotation; + } +}); +Object.defineProperty(exports, "TypeCastExpression", { + enumerable: true, + get: function () { + return _index.typeCastExpression; + } +}); +Object.defineProperty(exports, "TypeParameter", { + enumerable: true, + get: function () { + return _index.typeParameter; + } +}); +Object.defineProperty(exports, "TypeParameterDeclaration", { + enumerable: true, + get: function () { + return _index.typeParameterDeclaration; + } +}); +Object.defineProperty(exports, "TypeParameterInstantiation", { + enumerable: true, + get: function () { + return _index.typeParameterInstantiation; + } +}); +Object.defineProperty(exports, "TypeofTypeAnnotation", { + enumerable: true, + get: function () { + return _index.typeofTypeAnnotation; + } +}); +Object.defineProperty(exports, "UnaryExpression", { + enumerable: true, + get: function () { + return _index.unaryExpression; + } +}); +Object.defineProperty(exports, "UnionTypeAnnotation", { + enumerable: true, + get: function () { + return _index.unionTypeAnnotation; + } +}); +Object.defineProperty(exports, "UpdateExpression", { + enumerable: true, + get: function () { + return _index.updateExpression; + } +}); +Object.defineProperty(exports, "V8IntrinsicIdentifier", { + enumerable: true, + get: function () { + return _index.v8IntrinsicIdentifier; + } +}); +Object.defineProperty(exports, "VariableDeclaration", { + enumerable: true, + get: function () { + return _index.variableDeclaration; + } +}); +Object.defineProperty(exports, "VariableDeclarator", { + enumerable: true, + get: function () { + return _index.variableDeclarator; + } +}); +Object.defineProperty(exports, "Variance", { + enumerable: true, + get: function () { + return _index.variance; + } +}); +Object.defineProperty(exports, "VoidTypeAnnotation", { + enumerable: true, + get: function () { + return _index.voidTypeAnnotation; + } +}); +Object.defineProperty(exports, "WhileStatement", { + enumerable: true, + get: function () { + return _index.whileStatement; + } +}); +Object.defineProperty(exports, "WithStatement", { + enumerable: true, + get: function () { + return _index.withStatement; + } +}); +Object.defineProperty(exports, "YieldExpression", { + enumerable: true, + get: function () { + return _index.yieldExpression; + } +}); + +var _index = require("./index"); \ No newline at end of file diff --git a/node_modules/nyc/node_modules/@babel/types/lib/constants/generated/index.js b/node_modules/nyc/node_modules/@babel/types/lib/constants/generated/index.js new file mode 100644 index 000000000..1e109e6a4 --- /dev/null +++ b/node_modules/nyc/node_modules/@babel/types/lib/constants/generated/index.js @@ -0,0 +1,107 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.WHILE_TYPES = exports.USERWHITESPACABLE_TYPES = exports.UNARYLIKE_TYPES = exports.TYPESCRIPT_TYPES = exports.TSTYPE_TYPES = exports.TSTYPEELEMENT_TYPES = exports.TSENTITYNAME_TYPES = exports.TSBASETYPE_TYPES = exports.TERMINATORLESS_TYPES = exports.STATEMENT_TYPES = exports.STANDARDIZED_TYPES = exports.SCOPABLE_TYPES = exports.PUREISH_TYPES = exports.PROPERTY_TYPES = exports.PRIVATE_TYPES = exports.PATTERN_TYPES = exports.PATTERNLIKE_TYPES = exports.OBJECTMEMBER_TYPES = exports.MODULESPECIFIER_TYPES = exports.MODULEDECLARATION_TYPES = exports.MISCELLANEOUS_TYPES = exports.METHOD_TYPES = exports.LVAL_TYPES = exports.LOOP_TYPES = exports.LITERAL_TYPES = exports.JSX_TYPES = exports.IMMUTABLE_TYPES = exports.FUNCTION_TYPES = exports.FUNCTIONPARENT_TYPES = exports.FOR_TYPES = exports.FORXSTATEMENT_TYPES = exports.FLOW_TYPES = exports.FLOWTYPE_TYPES = exports.FLOWPREDICATE_TYPES = exports.FLOWDECLARATION_TYPES = exports.FLOWBASEANNOTATION_TYPES = exports.EXPRESSION_TYPES = exports.EXPRESSIONWRAPPER_TYPES = exports.EXPORTDECLARATION_TYPES = exports.ENUMMEMBER_TYPES = exports.ENUMBODY_TYPES = exports.DECLARATION_TYPES = exports.CONDITIONAL_TYPES = exports.COMPLETIONSTATEMENT_TYPES = exports.CLASS_TYPES = exports.BLOCK_TYPES = exports.BLOCKPARENT_TYPES = exports.BINARY_TYPES = exports.ACCESSOR_TYPES = void 0; + +var _definitions = require("../../definitions"); + +const STANDARDIZED_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Standardized"]; +exports.STANDARDIZED_TYPES = STANDARDIZED_TYPES; +const EXPRESSION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Expression"]; +exports.EXPRESSION_TYPES = EXPRESSION_TYPES; +const BINARY_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Binary"]; +exports.BINARY_TYPES = BINARY_TYPES; +const SCOPABLE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Scopable"]; +exports.SCOPABLE_TYPES = SCOPABLE_TYPES; +const BLOCKPARENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["BlockParent"]; +exports.BLOCKPARENT_TYPES = BLOCKPARENT_TYPES; +const BLOCK_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Block"]; +exports.BLOCK_TYPES = BLOCK_TYPES; +const STATEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Statement"]; +exports.STATEMENT_TYPES = STATEMENT_TYPES; +const TERMINATORLESS_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Terminatorless"]; +exports.TERMINATORLESS_TYPES = TERMINATORLESS_TYPES; +const COMPLETIONSTATEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["CompletionStatement"]; +exports.COMPLETIONSTATEMENT_TYPES = COMPLETIONSTATEMENT_TYPES; +const CONDITIONAL_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Conditional"]; +exports.CONDITIONAL_TYPES = CONDITIONAL_TYPES; +const LOOP_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Loop"]; +exports.LOOP_TYPES = LOOP_TYPES; +const WHILE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["While"]; +exports.WHILE_TYPES = WHILE_TYPES; +const EXPRESSIONWRAPPER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ExpressionWrapper"]; +exports.EXPRESSIONWRAPPER_TYPES = EXPRESSIONWRAPPER_TYPES; +const FOR_TYPES = _definitions.FLIPPED_ALIAS_KEYS["For"]; +exports.FOR_TYPES = FOR_TYPES; +const FORXSTATEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ForXStatement"]; +exports.FORXSTATEMENT_TYPES = FORXSTATEMENT_TYPES; +const FUNCTION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Function"]; +exports.FUNCTION_TYPES = FUNCTION_TYPES; +const FUNCTIONPARENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FunctionParent"]; +exports.FUNCTIONPARENT_TYPES = FUNCTIONPARENT_TYPES; +const PUREISH_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Pureish"]; +exports.PUREISH_TYPES = PUREISH_TYPES; +const DECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Declaration"]; +exports.DECLARATION_TYPES = DECLARATION_TYPES; +const PATTERNLIKE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["PatternLike"]; +exports.PATTERNLIKE_TYPES = PATTERNLIKE_TYPES; +const LVAL_TYPES = _definitions.FLIPPED_ALIAS_KEYS["LVal"]; +exports.LVAL_TYPES = LVAL_TYPES; +const TSENTITYNAME_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSEntityName"]; +exports.TSENTITYNAME_TYPES = TSENTITYNAME_TYPES; +const LITERAL_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Literal"]; +exports.LITERAL_TYPES = LITERAL_TYPES; +const IMMUTABLE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Immutable"]; +exports.IMMUTABLE_TYPES = IMMUTABLE_TYPES; +const USERWHITESPACABLE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["UserWhitespacable"]; +exports.USERWHITESPACABLE_TYPES = USERWHITESPACABLE_TYPES; +const METHOD_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Method"]; +exports.METHOD_TYPES = METHOD_TYPES; +const OBJECTMEMBER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ObjectMember"]; +exports.OBJECTMEMBER_TYPES = OBJECTMEMBER_TYPES; +const PROPERTY_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Property"]; +exports.PROPERTY_TYPES = PROPERTY_TYPES; +const UNARYLIKE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["UnaryLike"]; +exports.UNARYLIKE_TYPES = UNARYLIKE_TYPES; +const PATTERN_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Pattern"]; +exports.PATTERN_TYPES = PATTERN_TYPES; +const CLASS_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Class"]; +exports.CLASS_TYPES = CLASS_TYPES; +const MODULEDECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ModuleDeclaration"]; +exports.MODULEDECLARATION_TYPES = MODULEDECLARATION_TYPES; +const EXPORTDECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ExportDeclaration"]; +exports.EXPORTDECLARATION_TYPES = EXPORTDECLARATION_TYPES; +const MODULESPECIFIER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ModuleSpecifier"]; +exports.MODULESPECIFIER_TYPES = MODULESPECIFIER_TYPES; +const ACCESSOR_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Accessor"]; +exports.ACCESSOR_TYPES = ACCESSOR_TYPES; +const PRIVATE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Private"]; +exports.PRIVATE_TYPES = PRIVATE_TYPES; +const FLOW_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Flow"]; +exports.FLOW_TYPES = FLOW_TYPES; +const FLOWTYPE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowType"]; +exports.FLOWTYPE_TYPES = FLOWTYPE_TYPES; +const FLOWBASEANNOTATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowBaseAnnotation"]; +exports.FLOWBASEANNOTATION_TYPES = FLOWBASEANNOTATION_TYPES; +const FLOWDECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowDeclaration"]; +exports.FLOWDECLARATION_TYPES = FLOWDECLARATION_TYPES; +const FLOWPREDICATE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowPredicate"]; +exports.FLOWPREDICATE_TYPES = FLOWPREDICATE_TYPES; +const ENUMBODY_TYPES = _definitions.FLIPPED_ALIAS_KEYS["EnumBody"]; +exports.ENUMBODY_TYPES = ENUMBODY_TYPES; +const ENUMMEMBER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["EnumMember"]; +exports.ENUMMEMBER_TYPES = ENUMMEMBER_TYPES; +const JSX_TYPES = _definitions.FLIPPED_ALIAS_KEYS["JSX"]; +exports.JSX_TYPES = JSX_TYPES; +const MISCELLANEOUS_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Miscellaneous"]; +exports.MISCELLANEOUS_TYPES = MISCELLANEOUS_TYPES; +const TYPESCRIPT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TypeScript"]; +exports.TYPESCRIPT_TYPES = TYPESCRIPT_TYPES; +const TSTYPEELEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSTypeElement"]; +exports.TSTYPEELEMENT_TYPES = TSTYPEELEMENT_TYPES; +const TSTYPE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSType"]; +exports.TSTYPE_TYPES = TSTYPE_TYPES; +const TSBASETYPE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSBaseType"]; +exports.TSBASETYPE_TYPES = TSBASETYPE_TYPES; \ No newline at end of file diff --git a/node_modules/nyc/node_modules/@babel/types/lib/validators/generated/index.js b/node_modules/nyc/node_modules/@babel/types/lib/validators/generated/index.js new file mode 100644 index 000000000..f175aa495 --- /dev/null +++ b/node_modules/nyc/node_modules/@babel/types/lib/validators/generated/index.js @@ -0,0 +1,4827 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.isAccessor = isAccessor; +exports.isAnyTypeAnnotation = isAnyTypeAnnotation; +exports.isArgumentPlaceholder = isArgumentPlaceholder; +exports.isArrayExpression = isArrayExpression; +exports.isArrayPattern = isArrayPattern; +exports.isArrayTypeAnnotation = isArrayTypeAnnotation; +exports.isArrowFunctionExpression = isArrowFunctionExpression; +exports.isAssignmentExpression = isAssignmentExpression; +exports.isAssignmentPattern = isAssignmentPattern; +exports.isAwaitExpression = isAwaitExpression; +exports.isBigIntLiteral = isBigIntLiteral; +exports.isBinary = isBinary; +exports.isBinaryExpression = isBinaryExpression; +exports.isBindExpression = isBindExpression; +exports.isBlock = isBlock; +exports.isBlockParent = isBlockParent; +exports.isBlockStatement = isBlockStatement; +exports.isBooleanLiteral = isBooleanLiteral; +exports.isBooleanLiteralTypeAnnotation = isBooleanLiteralTypeAnnotation; +exports.isBooleanTypeAnnotation = isBooleanTypeAnnotation; +exports.isBreakStatement = isBreakStatement; +exports.isCallExpression = isCallExpression; +exports.isCatchClause = isCatchClause; +exports.isClass = isClass; +exports.isClassAccessorProperty = isClassAccessorProperty; +exports.isClassBody = isClassBody; +exports.isClassDeclaration = isClassDeclaration; +exports.isClassExpression = isClassExpression; +exports.isClassImplements = isClassImplements; +exports.isClassMethod = isClassMethod; +exports.isClassPrivateMethod = isClassPrivateMethod; +exports.isClassPrivateProperty = isClassPrivateProperty; +exports.isClassProperty = isClassProperty; +exports.isCompletionStatement = isCompletionStatement; +exports.isConditional = isConditional; +exports.isConditionalExpression = isConditionalExpression; +exports.isContinueStatement = isContinueStatement; +exports.isDebuggerStatement = isDebuggerStatement; +exports.isDecimalLiteral = isDecimalLiteral; +exports.isDeclaration = isDeclaration; +exports.isDeclareClass = isDeclareClass; +exports.isDeclareExportAllDeclaration = isDeclareExportAllDeclaration; +exports.isDeclareExportDeclaration = isDeclareExportDeclaration; +exports.isDeclareFunction = isDeclareFunction; +exports.isDeclareInterface = isDeclareInterface; +exports.isDeclareModule = isDeclareModule; +exports.isDeclareModuleExports = isDeclareModuleExports; +exports.isDeclareOpaqueType = isDeclareOpaqueType; +exports.isDeclareTypeAlias = isDeclareTypeAlias; +exports.isDeclareVariable = isDeclareVariable; +exports.isDeclaredPredicate = isDeclaredPredicate; +exports.isDecorator = isDecorator; +exports.isDirective = isDirective; +exports.isDirectiveLiteral = isDirectiveLiteral; +exports.isDoExpression = isDoExpression; +exports.isDoWhileStatement = isDoWhileStatement; +exports.isEmptyStatement = isEmptyStatement; +exports.isEmptyTypeAnnotation = isEmptyTypeAnnotation; +exports.isEnumBody = isEnumBody; +exports.isEnumBooleanBody = isEnumBooleanBody; +exports.isEnumBooleanMember = isEnumBooleanMember; +exports.isEnumDeclaration = isEnumDeclaration; +exports.isEnumDefaultedMember = isEnumDefaultedMember; +exports.isEnumMember = isEnumMember; +exports.isEnumNumberBody = isEnumNumberBody; +exports.isEnumNumberMember = isEnumNumberMember; +exports.isEnumStringBody = isEnumStringBody; +exports.isEnumStringMember = isEnumStringMember; +exports.isEnumSymbolBody = isEnumSymbolBody; +exports.isExistsTypeAnnotation = isExistsTypeAnnotation; +exports.isExportAllDeclaration = isExportAllDeclaration; +exports.isExportDeclaration = isExportDeclaration; +exports.isExportDefaultDeclaration = isExportDefaultDeclaration; +exports.isExportDefaultSpecifier = isExportDefaultSpecifier; +exports.isExportNamedDeclaration = isExportNamedDeclaration; +exports.isExportNamespaceSpecifier = isExportNamespaceSpecifier; +exports.isExportSpecifier = isExportSpecifier; +exports.isExpression = isExpression; +exports.isExpressionStatement = isExpressionStatement; +exports.isExpressionWrapper = isExpressionWrapper; +exports.isFile = isFile; +exports.isFlow = isFlow; +exports.isFlowBaseAnnotation = isFlowBaseAnnotation; +exports.isFlowDeclaration = isFlowDeclaration; +exports.isFlowPredicate = isFlowPredicate; +exports.isFlowType = isFlowType; +exports.isFor = isFor; +exports.isForInStatement = isForInStatement; +exports.isForOfStatement = isForOfStatement; +exports.isForStatement = isForStatement; +exports.isForXStatement = isForXStatement; +exports.isFunction = isFunction; +exports.isFunctionDeclaration = isFunctionDeclaration; +exports.isFunctionExpression = isFunctionExpression; +exports.isFunctionParent = isFunctionParent; +exports.isFunctionTypeAnnotation = isFunctionTypeAnnotation; +exports.isFunctionTypeParam = isFunctionTypeParam; +exports.isGenericTypeAnnotation = isGenericTypeAnnotation; +exports.isIdentifier = isIdentifier; +exports.isIfStatement = isIfStatement; +exports.isImmutable = isImmutable; +exports.isImport = isImport; +exports.isImportAttribute = isImportAttribute; +exports.isImportDeclaration = isImportDeclaration; +exports.isImportDefaultSpecifier = isImportDefaultSpecifier; +exports.isImportNamespaceSpecifier = isImportNamespaceSpecifier; +exports.isImportSpecifier = isImportSpecifier; +exports.isIndexedAccessType = isIndexedAccessType; +exports.isInferredPredicate = isInferredPredicate; +exports.isInterfaceDeclaration = isInterfaceDeclaration; +exports.isInterfaceExtends = isInterfaceExtends; +exports.isInterfaceTypeAnnotation = isInterfaceTypeAnnotation; +exports.isInterpreterDirective = isInterpreterDirective; +exports.isIntersectionTypeAnnotation = isIntersectionTypeAnnotation; +exports.isJSX = isJSX; +exports.isJSXAttribute = isJSXAttribute; +exports.isJSXClosingElement = isJSXClosingElement; +exports.isJSXClosingFragment = isJSXClosingFragment; +exports.isJSXElement = isJSXElement; +exports.isJSXEmptyExpression = isJSXEmptyExpression; +exports.isJSXExpressionContainer = isJSXExpressionContainer; +exports.isJSXFragment = isJSXFragment; +exports.isJSXIdentifier = isJSXIdentifier; +exports.isJSXMemberExpression = isJSXMemberExpression; +exports.isJSXNamespacedName = isJSXNamespacedName; +exports.isJSXOpeningElement = isJSXOpeningElement; +exports.isJSXOpeningFragment = isJSXOpeningFragment; +exports.isJSXSpreadAttribute = isJSXSpreadAttribute; +exports.isJSXSpreadChild = isJSXSpreadChild; +exports.isJSXText = isJSXText; +exports.isLVal = isLVal; +exports.isLabeledStatement = isLabeledStatement; +exports.isLiteral = isLiteral; +exports.isLogicalExpression = isLogicalExpression; +exports.isLoop = isLoop; +exports.isMemberExpression = isMemberExpression; +exports.isMetaProperty = isMetaProperty; +exports.isMethod = isMethod; +exports.isMiscellaneous = isMiscellaneous; +exports.isMixedTypeAnnotation = isMixedTypeAnnotation; +exports.isModuleDeclaration = isModuleDeclaration; +exports.isModuleExpression = isModuleExpression; +exports.isModuleSpecifier = isModuleSpecifier; +exports.isNewExpression = isNewExpression; +exports.isNoop = isNoop; +exports.isNullLiteral = isNullLiteral; +exports.isNullLiteralTypeAnnotation = isNullLiteralTypeAnnotation; +exports.isNullableTypeAnnotation = isNullableTypeAnnotation; +exports.isNumberLiteral = isNumberLiteral; +exports.isNumberLiteralTypeAnnotation = isNumberLiteralTypeAnnotation; +exports.isNumberTypeAnnotation = isNumberTypeAnnotation; +exports.isNumericLiteral = isNumericLiteral; +exports.isObjectExpression = isObjectExpression; +exports.isObjectMember = isObjectMember; +exports.isObjectMethod = isObjectMethod; +exports.isObjectPattern = isObjectPattern; +exports.isObjectProperty = isObjectProperty; +exports.isObjectTypeAnnotation = isObjectTypeAnnotation; +exports.isObjectTypeCallProperty = isObjectTypeCallProperty; +exports.isObjectTypeIndexer = isObjectTypeIndexer; +exports.isObjectTypeInternalSlot = isObjectTypeInternalSlot; +exports.isObjectTypeProperty = isObjectTypeProperty; +exports.isObjectTypeSpreadProperty = isObjectTypeSpreadProperty; +exports.isOpaqueType = isOpaqueType; +exports.isOptionalCallExpression = isOptionalCallExpression; +exports.isOptionalIndexedAccessType = isOptionalIndexedAccessType; +exports.isOptionalMemberExpression = isOptionalMemberExpression; +exports.isParenthesizedExpression = isParenthesizedExpression; +exports.isPattern = isPattern; +exports.isPatternLike = isPatternLike; +exports.isPipelineBareFunction = isPipelineBareFunction; +exports.isPipelinePrimaryTopicReference = isPipelinePrimaryTopicReference; +exports.isPipelineTopicExpression = isPipelineTopicExpression; +exports.isPlaceholder = isPlaceholder; +exports.isPrivate = isPrivate; +exports.isPrivateName = isPrivateName; +exports.isProgram = isProgram; +exports.isProperty = isProperty; +exports.isPureish = isPureish; +exports.isQualifiedTypeIdentifier = isQualifiedTypeIdentifier; +exports.isRecordExpression = isRecordExpression; +exports.isRegExpLiteral = isRegExpLiteral; +exports.isRegexLiteral = isRegexLiteral; +exports.isRestElement = isRestElement; +exports.isRestProperty = isRestProperty; +exports.isReturnStatement = isReturnStatement; +exports.isScopable = isScopable; +exports.isSequenceExpression = isSequenceExpression; +exports.isSpreadElement = isSpreadElement; +exports.isSpreadProperty = isSpreadProperty; +exports.isStandardized = isStandardized; +exports.isStatement = isStatement; +exports.isStaticBlock = isStaticBlock; +exports.isStringLiteral = isStringLiteral; +exports.isStringLiteralTypeAnnotation = isStringLiteralTypeAnnotation; +exports.isStringTypeAnnotation = isStringTypeAnnotation; +exports.isSuper = isSuper; +exports.isSwitchCase = isSwitchCase; +exports.isSwitchStatement = isSwitchStatement; +exports.isSymbolTypeAnnotation = isSymbolTypeAnnotation; +exports.isTSAnyKeyword = isTSAnyKeyword; +exports.isTSArrayType = isTSArrayType; +exports.isTSAsExpression = isTSAsExpression; +exports.isTSBaseType = isTSBaseType; +exports.isTSBigIntKeyword = isTSBigIntKeyword; +exports.isTSBooleanKeyword = isTSBooleanKeyword; +exports.isTSCallSignatureDeclaration = isTSCallSignatureDeclaration; +exports.isTSConditionalType = isTSConditionalType; +exports.isTSConstructSignatureDeclaration = isTSConstructSignatureDeclaration; +exports.isTSConstructorType = isTSConstructorType; +exports.isTSDeclareFunction = isTSDeclareFunction; +exports.isTSDeclareMethod = isTSDeclareMethod; +exports.isTSEntityName = isTSEntityName; +exports.isTSEnumDeclaration = isTSEnumDeclaration; +exports.isTSEnumMember = isTSEnumMember; +exports.isTSExportAssignment = isTSExportAssignment; +exports.isTSExpressionWithTypeArguments = isTSExpressionWithTypeArguments; +exports.isTSExternalModuleReference = isTSExternalModuleReference; +exports.isTSFunctionType = isTSFunctionType; +exports.isTSImportEqualsDeclaration = isTSImportEqualsDeclaration; +exports.isTSImportType = isTSImportType; +exports.isTSIndexSignature = isTSIndexSignature; +exports.isTSIndexedAccessType = isTSIndexedAccessType; +exports.isTSInferType = isTSInferType; +exports.isTSInstantiationExpression = isTSInstantiationExpression; +exports.isTSInterfaceBody = isTSInterfaceBody; +exports.isTSInterfaceDeclaration = isTSInterfaceDeclaration; +exports.isTSIntersectionType = isTSIntersectionType; +exports.isTSIntrinsicKeyword = isTSIntrinsicKeyword; +exports.isTSLiteralType = isTSLiteralType; +exports.isTSMappedType = isTSMappedType; +exports.isTSMethodSignature = isTSMethodSignature; +exports.isTSModuleBlock = isTSModuleBlock; +exports.isTSModuleDeclaration = isTSModuleDeclaration; +exports.isTSNamedTupleMember = isTSNamedTupleMember; +exports.isTSNamespaceExportDeclaration = isTSNamespaceExportDeclaration; +exports.isTSNeverKeyword = isTSNeverKeyword; +exports.isTSNonNullExpression = isTSNonNullExpression; +exports.isTSNullKeyword = isTSNullKeyword; +exports.isTSNumberKeyword = isTSNumberKeyword; +exports.isTSObjectKeyword = isTSObjectKeyword; +exports.isTSOptionalType = isTSOptionalType; +exports.isTSParameterProperty = isTSParameterProperty; +exports.isTSParenthesizedType = isTSParenthesizedType; +exports.isTSPropertySignature = isTSPropertySignature; +exports.isTSQualifiedName = isTSQualifiedName; +exports.isTSRestType = isTSRestType; +exports.isTSStringKeyword = isTSStringKeyword; +exports.isTSSymbolKeyword = isTSSymbolKeyword; +exports.isTSThisType = isTSThisType; +exports.isTSTupleType = isTSTupleType; +exports.isTSType = isTSType; +exports.isTSTypeAliasDeclaration = isTSTypeAliasDeclaration; +exports.isTSTypeAnnotation = isTSTypeAnnotation; +exports.isTSTypeAssertion = isTSTypeAssertion; +exports.isTSTypeElement = isTSTypeElement; +exports.isTSTypeLiteral = isTSTypeLiteral; +exports.isTSTypeOperator = isTSTypeOperator; +exports.isTSTypeParameter = isTSTypeParameter; +exports.isTSTypeParameterDeclaration = isTSTypeParameterDeclaration; +exports.isTSTypeParameterInstantiation = isTSTypeParameterInstantiation; +exports.isTSTypePredicate = isTSTypePredicate; +exports.isTSTypeQuery = isTSTypeQuery; +exports.isTSTypeReference = isTSTypeReference; +exports.isTSUndefinedKeyword = isTSUndefinedKeyword; +exports.isTSUnionType = isTSUnionType; +exports.isTSUnknownKeyword = isTSUnknownKeyword; +exports.isTSVoidKeyword = isTSVoidKeyword; +exports.isTaggedTemplateExpression = isTaggedTemplateExpression; +exports.isTemplateElement = isTemplateElement; +exports.isTemplateLiteral = isTemplateLiteral; +exports.isTerminatorless = isTerminatorless; +exports.isThisExpression = isThisExpression; +exports.isThisTypeAnnotation = isThisTypeAnnotation; +exports.isThrowStatement = isThrowStatement; +exports.isTopicReference = isTopicReference; +exports.isTryStatement = isTryStatement; +exports.isTupleExpression = isTupleExpression; +exports.isTupleTypeAnnotation = isTupleTypeAnnotation; +exports.isTypeAlias = isTypeAlias; +exports.isTypeAnnotation = isTypeAnnotation; +exports.isTypeCastExpression = isTypeCastExpression; +exports.isTypeParameter = isTypeParameter; +exports.isTypeParameterDeclaration = isTypeParameterDeclaration; +exports.isTypeParameterInstantiation = isTypeParameterInstantiation; +exports.isTypeScript = isTypeScript; +exports.isTypeofTypeAnnotation = isTypeofTypeAnnotation; +exports.isUnaryExpression = isUnaryExpression; +exports.isUnaryLike = isUnaryLike; +exports.isUnionTypeAnnotation = isUnionTypeAnnotation; +exports.isUpdateExpression = isUpdateExpression; +exports.isUserWhitespacable = isUserWhitespacable; +exports.isV8IntrinsicIdentifier = isV8IntrinsicIdentifier; +exports.isVariableDeclaration = isVariableDeclaration; +exports.isVariableDeclarator = isVariableDeclarator; +exports.isVariance = isVariance; +exports.isVoidTypeAnnotation = isVoidTypeAnnotation; +exports.isWhile = isWhile; +exports.isWhileStatement = isWhileStatement; +exports.isWithStatement = isWithStatement; +exports.isYieldExpression = isYieldExpression; + +var _shallowEqual = require("../../utils/shallowEqual"); + +function isArrayExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrayExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAssignmentExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AssignmentExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBinaryExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BinaryExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterpreterDirective(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterpreterDirective") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDirective(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Directive") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDirectiveLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DirectiveLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBlockStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BlockStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBreakStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BreakStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isCallExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "CallExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isCatchClause(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "CatchClause") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isConditionalExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ConditionalExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isContinueStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ContinueStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDebuggerStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DebuggerStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDoWhileStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DoWhileStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEmptyStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EmptyStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExpressionStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExpressionStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFile(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "File") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForInStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ForInStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ForStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Identifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIfStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "IfStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLabeledStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "LabeledStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStringLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StringLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumericLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumericLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNullLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NullLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBooleanLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BooleanLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRegExpLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RegExpLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLogicalExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "LogicalExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMemberExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "MemberExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNewExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NewExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isProgram(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Program") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRestElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RestElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isReturnStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ReturnStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSequenceExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SequenceExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isParenthesizedExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ParenthesizedExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSwitchCase(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SwitchCase") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSwitchStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SwitchStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isThisExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ThisExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isThrowStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ThrowStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTryStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TryStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUnaryExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "UnaryExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUpdateExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "UpdateExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVariableDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "VariableDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVariableDeclarator(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "VariableDeclarator") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isWhileStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "WhileStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isWithStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "WithStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAssignmentPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AssignmentPattern") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArrayPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrayPattern") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArrowFunctionExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrowFunctionExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportAllDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportAllDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportDefaultDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportDefaultDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportNamedDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportNamedDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForOfStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ForOfStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportDefaultSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportDefaultSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportNamespaceSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportNamespaceSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMetaProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "MetaProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectPattern") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSpreadElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SpreadElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSuper(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Super") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTaggedTemplateExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TaggedTemplateExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTemplateElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TemplateElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTemplateLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TemplateLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isYieldExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "YieldExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAwaitExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AwaitExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImport(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Import") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBigIntLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BigIntLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportNamespaceSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportNamespaceSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOptionalMemberExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OptionalMemberExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOptionalCallExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OptionalCallExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassAccessorProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassAccessorProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassPrivateProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassPrivateProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassPrivateMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassPrivateMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPrivateName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PrivateName") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStaticBlock(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StaticBlock") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAnyTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AnyTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArrayTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrayTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBooleanTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BooleanTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBooleanLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BooleanLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNullLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NullLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassImplements(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassImplements") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareClass(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareClass") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareFunction") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareInterface(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareInterface") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareModule(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareModule") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareModuleExports(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareModuleExports") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareTypeAlias(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareTypeAlias") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareOpaqueType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareOpaqueType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareVariable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareVariable") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareExportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareExportDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareExportAllDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareExportAllDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclaredPredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclaredPredicate") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExistsTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExistsTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionTypeParam(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionTypeParam") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isGenericTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "GenericTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInferredPredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InferredPredicate") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterfaceExtends(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterfaceExtends") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterfaceDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterfaceDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterfaceTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterfaceTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIntersectionTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "IntersectionTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMixedTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "MixedTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEmptyTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EmptyTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNullableTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NullableTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumberLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumberLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumberTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumberTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeInternalSlot(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeInternalSlot") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeCallProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeCallProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeIndexer(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeIndexer") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeSpreadProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeSpreadProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOpaqueType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OpaqueType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isQualifiedTypeIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "QualifiedTypeIdentifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStringLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StringLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStringTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StringTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSymbolTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SymbolTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isThisTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ThisTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTupleTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TupleTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeofTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeofTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeAlias(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeAlias") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeCastExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeCastExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeParameter(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeParameter") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeParameterDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeParameterDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeParameterInstantiation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeParameterInstantiation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUnionTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "UnionTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVariance(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Variance") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVoidTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "VoidTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumBooleanBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumBooleanBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumNumberBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumNumberBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumStringBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumStringBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumSymbolBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumSymbolBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumBooleanMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumBooleanMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumNumberMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumNumberMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumStringMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumStringMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumDefaultedMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumDefaultedMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIndexedAccessType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "IndexedAccessType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOptionalIndexedAccessType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OptionalIndexedAccessType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXAttribute(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXAttribute") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXClosingElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXClosingElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXEmptyExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXEmptyExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXExpressionContainer(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXExpressionContainer") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXSpreadChild(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXSpreadChild") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXIdentifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXMemberExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXMemberExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXNamespacedName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXNamespacedName") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXOpeningElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXOpeningElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXSpreadAttribute(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXSpreadAttribute") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXText(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXText") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXFragment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXFragment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXOpeningFragment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXOpeningFragment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXClosingFragment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXClosingFragment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNoop(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Noop") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPlaceholder(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Placeholder") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isV8IntrinsicIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "V8IntrinsicIdentifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArgumentPlaceholder(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArgumentPlaceholder") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBindExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BindExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportAttribute(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportAttribute") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDecorator(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Decorator") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDoExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DoExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportDefaultSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportDefaultSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRecordExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RecordExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTupleExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TupleExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDecimalLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DecimalLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isModuleExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ModuleExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTopicReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TopicReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPipelineTopicExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PipelineTopicExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPipelineBareFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PipelineBareFunction") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPipelinePrimaryTopicReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PipelinePrimaryTopicReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSParameterProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSParameterProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSDeclareFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSDeclareFunction") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSDeclareMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSDeclareMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSQualifiedName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSQualifiedName") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSCallSignatureDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSCallSignatureDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSConstructSignatureDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSConstructSignatureDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSPropertySignature(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSPropertySignature") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSMethodSignature(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSMethodSignature") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIndexSignature(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIndexSignature") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSAnyKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSAnyKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSBooleanKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSBooleanKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSBigIntKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSBigIntKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIntrinsicKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIntrinsicKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNeverKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNeverKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNullKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNullKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNumberKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNumberKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSObjectKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSObjectKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSStringKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSStringKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSSymbolKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSSymbolKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSUndefinedKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSUndefinedKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSUnknownKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSUnknownKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSVoidKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSVoidKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSThisType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSThisType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSFunctionType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSFunctionType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSConstructorType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSConstructorType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypePredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypePredicate") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeQuery(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeQuery") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSArrayType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSArrayType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTupleType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTupleType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSOptionalType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSOptionalType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSRestType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSRestType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNamedTupleMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNamedTupleMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSUnionType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSUnionType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIntersectionType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIntersectionType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSConditionalType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSConditionalType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSInferType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSInferType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSParenthesizedType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSParenthesizedType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeOperator(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeOperator") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIndexedAccessType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIndexedAccessType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSMappedType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSMappedType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSLiteralType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSLiteralType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSExpressionWithTypeArguments(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSExpressionWithTypeArguments") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSInterfaceDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSInterfaceDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSInterfaceBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSInterfaceBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeAliasDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeAliasDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSInstantiationExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSInstantiationExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSAsExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSAsExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeAssertion(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeAssertion") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSEnumDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSEnumDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSEnumMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSEnumMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSModuleDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSModuleDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSModuleBlock(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSModuleBlock") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSImportType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSImportType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSImportEqualsDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSImportEqualsDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSExternalModuleReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSExternalModuleReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNonNullExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNonNullExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSExportAssignment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSExportAssignment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNamespaceExportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNamespaceExportDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeParameterInstantiation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeParameterInstantiation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeParameterDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeParameterDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeParameter(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeParameter") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStandardized(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ArrayExpression" === nodeType || "AssignmentExpression" === nodeType || "BinaryExpression" === nodeType || "InterpreterDirective" === nodeType || "Directive" === nodeType || "DirectiveLiteral" === nodeType || "BlockStatement" === nodeType || "BreakStatement" === nodeType || "CallExpression" === nodeType || "CatchClause" === nodeType || "ConditionalExpression" === nodeType || "ContinueStatement" === nodeType || "DebuggerStatement" === nodeType || "DoWhileStatement" === nodeType || "EmptyStatement" === nodeType || "ExpressionStatement" === nodeType || "File" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "Identifier" === nodeType || "IfStatement" === nodeType || "LabeledStatement" === nodeType || "StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "LogicalExpression" === nodeType || "MemberExpression" === nodeType || "NewExpression" === nodeType || "Program" === nodeType || "ObjectExpression" === nodeType || "ObjectMethod" === nodeType || "ObjectProperty" === nodeType || "RestElement" === nodeType || "ReturnStatement" === nodeType || "SequenceExpression" === nodeType || "ParenthesizedExpression" === nodeType || "SwitchCase" === nodeType || "SwitchStatement" === nodeType || "ThisExpression" === nodeType || "ThrowStatement" === nodeType || "TryStatement" === nodeType || "UnaryExpression" === nodeType || "UpdateExpression" === nodeType || "VariableDeclaration" === nodeType || "VariableDeclarator" === nodeType || "WhileStatement" === nodeType || "WithStatement" === nodeType || "AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassBody" === nodeType || "ClassExpression" === nodeType || "ClassDeclaration" === nodeType || "ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ExportSpecifier" === nodeType || "ForOfStatement" === nodeType || "ImportDeclaration" === nodeType || "ImportDefaultSpecifier" === nodeType || "ImportNamespaceSpecifier" === nodeType || "ImportSpecifier" === nodeType || "MetaProperty" === nodeType || "ClassMethod" === nodeType || "ObjectPattern" === nodeType || "SpreadElement" === nodeType || "Super" === nodeType || "TaggedTemplateExpression" === nodeType || "TemplateElement" === nodeType || "TemplateLiteral" === nodeType || "YieldExpression" === nodeType || "AwaitExpression" === nodeType || "Import" === nodeType || "BigIntLiteral" === nodeType || "ExportNamespaceSpecifier" === nodeType || "OptionalMemberExpression" === nodeType || "OptionalCallExpression" === nodeType || "ClassProperty" === nodeType || "ClassAccessorProperty" === nodeType || "ClassPrivateProperty" === nodeType || "ClassPrivateMethod" === nodeType || "PrivateName" === nodeType || "StaticBlock" === nodeType || nodeType === "Placeholder" && ("Identifier" === node.expectedNode || "StringLiteral" === node.expectedNode || "BlockStatement" === node.expectedNode || "ClassBody" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ArrayExpression" === nodeType || "AssignmentExpression" === nodeType || "BinaryExpression" === nodeType || "CallExpression" === nodeType || "ConditionalExpression" === nodeType || "FunctionExpression" === nodeType || "Identifier" === nodeType || "StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "LogicalExpression" === nodeType || "MemberExpression" === nodeType || "NewExpression" === nodeType || "ObjectExpression" === nodeType || "SequenceExpression" === nodeType || "ParenthesizedExpression" === nodeType || "ThisExpression" === nodeType || "UnaryExpression" === nodeType || "UpdateExpression" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassExpression" === nodeType || "MetaProperty" === nodeType || "Super" === nodeType || "TaggedTemplateExpression" === nodeType || "TemplateLiteral" === nodeType || "YieldExpression" === nodeType || "AwaitExpression" === nodeType || "Import" === nodeType || "BigIntLiteral" === nodeType || "OptionalMemberExpression" === nodeType || "OptionalCallExpression" === nodeType || "TypeCastExpression" === nodeType || "JSXElement" === nodeType || "JSXFragment" === nodeType || "BindExpression" === nodeType || "DoExpression" === nodeType || "RecordExpression" === nodeType || "TupleExpression" === nodeType || "DecimalLiteral" === nodeType || "ModuleExpression" === nodeType || "TopicReference" === nodeType || "PipelineTopicExpression" === nodeType || "PipelineBareFunction" === nodeType || "PipelinePrimaryTopicReference" === nodeType || "TSInstantiationExpression" === nodeType || "TSAsExpression" === nodeType || "TSTypeAssertion" === nodeType || "TSNonNullExpression" === nodeType || nodeType === "Placeholder" && ("Expression" === node.expectedNode || "Identifier" === node.expectedNode || "StringLiteral" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBinary(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BinaryExpression" === nodeType || "LogicalExpression" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isScopable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "CatchClause" === nodeType || "DoWhileStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "Program" === nodeType || "ObjectMethod" === nodeType || "SwitchStatement" === nodeType || "WhileStatement" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassExpression" === nodeType || "ClassDeclaration" === nodeType || "ForOfStatement" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType || "StaticBlock" === nodeType || "TSModuleBlock" === nodeType || nodeType === "Placeholder" && "BlockStatement" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBlockParent(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "CatchClause" === nodeType || "DoWhileStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "Program" === nodeType || "ObjectMethod" === nodeType || "SwitchStatement" === nodeType || "WhileStatement" === nodeType || "ArrowFunctionExpression" === nodeType || "ForOfStatement" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType || "StaticBlock" === nodeType || "TSModuleBlock" === nodeType || nodeType === "Placeholder" && "BlockStatement" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBlock(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "Program" === nodeType || "TSModuleBlock" === nodeType || nodeType === "Placeholder" && "BlockStatement" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "BreakStatement" === nodeType || "ContinueStatement" === nodeType || "DebuggerStatement" === nodeType || "DoWhileStatement" === nodeType || "EmptyStatement" === nodeType || "ExpressionStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "IfStatement" === nodeType || "LabeledStatement" === nodeType || "ReturnStatement" === nodeType || "SwitchStatement" === nodeType || "ThrowStatement" === nodeType || "TryStatement" === nodeType || "VariableDeclaration" === nodeType || "WhileStatement" === nodeType || "WithStatement" === nodeType || "ClassDeclaration" === nodeType || "ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ForOfStatement" === nodeType || "ImportDeclaration" === nodeType || "DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "InterfaceDeclaration" === nodeType || "OpaqueType" === nodeType || "TypeAlias" === nodeType || "EnumDeclaration" === nodeType || "TSDeclareFunction" === nodeType || "TSInterfaceDeclaration" === nodeType || "TSTypeAliasDeclaration" === nodeType || "TSEnumDeclaration" === nodeType || "TSModuleDeclaration" === nodeType || "TSImportEqualsDeclaration" === nodeType || "TSExportAssignment" === nodeType || "TSNamespaceExportDeclaration" === nodeType || nodeType === "Placeholder" && ("Statement" === node.expectedNode || "Declaration" === node.expectedNode || "BlockStatement" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTerminatorless(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BreakStatement" === nodeType || "ContinueStatement" === nodeType || "ReturnStatement" === nodeType || "ThrowStatement" === nodeType || "YieldExpression" === nodeType || "AwaitExpression" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isCompletionStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BreakStatement" === nodeType || "ContinueStatement" === nodeType || "ReturnStatement" === nodeType || "ThrowStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isConditional(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ConditionalExpression" === nodeType || "IfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLoop(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DoWhileStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "WhileStatement" === nodeType || "ForOfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isWhile(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DoWhileStatement" === nodeType || "WhileStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExpressionWrapper(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExpressionStatement" === nodeType || "ParenthesizedExpression" === nodeType || "TypeCastExpression" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFor(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ForInStatement" === nodeType || "ForStatement" === nodeType || "ForOfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForXStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ForInStatement" === nodeType || "ForOfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "ObjectMethod" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionParent(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "ObjectMethod" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType || "StaticBlock" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPureish(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "ArrowFunctionExpression" === nodeType || "BigIntLiteral" === nodeType || "DecimalLiteral" === nodeType || nodeType === "Placeholder" && "StringLiteral" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "VariableDeclaration" === nodeType || "ClassDeclaration" === nodeType || "ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ImportDeclaration" === nodeType || "DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "InterfaceDeclaration" === nodeType || "OpaqueType" === nodeType || "TypeAlias" === nodeType || "EnumDeclaration" === nodeType || "TSDeclareFunction" === nodeType || "TSInterfaceDeclaration" === nodeType || "TSTypeAliasDeclaration" === nodeType || "TSEnumDeclaration" === nodeType || "TSModuleDeclaration" === nodeType || nodeType === "Placeholder" && "Declaration" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPatternLike(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Identifier" === nodeType || "RestElement" === nodeType || "AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ObjectPattern" === nodeType || "TSAsExpression" === nodeType || "TSTypeAssertion" === nodeType || "TSNonNullExpression" === nodeType || nodeType === "Placeholder" && ("Pattern" === node.expectedNode || "Identifier" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLVal(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Identifier" === nodeType || "MemberExpression" === nodeType || "RestElement" === nodeType || "AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ObjectPattern" === nodeType || "TSParameterProperty" === nodeType || "TSAsExpression" === nodeType || "TSTypeAssertion" === nodeType || "TSNonNullExpression" === nodeType || nodeType === "Placeholder" && ("Pattern" === node.expectedNode || "Identifier" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSEntityName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Identifier" === nodeType || "TSQualifiedName" === nodeType || nodeType === "Placeholder" && "Identifier" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "TemplateLiteral" === nodeType || "BigIntLiteral" === nodeType || "DecimalLiteral" === nodeType || nodeType === "Placeholder" && "StringLiteral" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImmutable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "BigIntLiteral" === nodeType || "JSXAttribute" === nodeType || "JSXClosingElement" === nodeType || "JSXElement" === nodeType || "JSXExpressionContainer" === nodeType || "JSXSpreadChild" === nodeType || "JSXOpeningElement" === nodeType || "JSXText" === nodeType || "JSXFragment" === nodeType || "JSXOpeningFragment" === nodeType || "JSXClosingFragment" === nodeType || "DecimalLiteral" === nodeType || nodeType === "Placeholder" && "StringLiteral" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUserWhitespacable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectMethod" === nodeType || "ObjectProperty" === nodeType || "ObjectTypeInternalSlot" === nodeType || "ObjectTypeCallProperty" === nodeType || "ObjectTypeIndexer" === nodeType || "ObjectTypeProperty" === nodeType || "ObjectTypeSpreadProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectMethod" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectMethod" === nodeType || "ObjectProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectProperty" === nodeType || "ClassProperty" === nodeType || "ClassAccessorProperty" === nodeType || "ClassPrivateProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUnaryLike(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("UnaryExpression" === nodeType || "SpreadElement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ObjectPattern" === nodeType || nodeType === "Placeholder" && "Pattern" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClass(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ClassExpression" === nodeType || "ClassDeclaration" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isModuleDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ImportDeclaration" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isModuleSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExportSpecifier" === nodeType || "ImportDefaultSpecifier" === nodeType || "ImportNamespaceSpecifier" === nodeType || "ImportSpecifier" === nodeType || "ExportNamespaceSpecifier" === nodeType || "ExportDefaultSpecifier" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAccessor(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ClassAccessorProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPrivate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ClassPrivateProperty" === nodeType || "ClassPrivateMethod" === nodeType || "PrivateName" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlow(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AnyTypeAnnotation" === nodeType || "ArrayTypeAnnotation" === nodeType || "BooleanTypeAnnotation" === nodeType || "BooleanLiteralTypeAnnotation" === nodeType || "NullLiteralTypeAnnotation" === nodeType || "ClassImplements" === nodeType || "DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "DeclaredPredicate" === nodeType || "ExistsTypeAnnotation" === nodeType || "FunctionTypeAnnotation" === nodeType || "FunctionTypeParam" === nodeType || "GenericTypeAnnotation" === nodeType || "InferredPredicate" === nodeType || "InterfaceExtends" === nodeType || "InterfaceDeclaration" === nodeType || "InterfaceTypeAnnotation" === nodeType || "IntersectionTypeAnnotation" === nodeType || "MixedTypeAnnotation" === nodeType || "EmptyTypeAnnotation" === nodeType || "NullableTypeAnnotation" === nodeType || "NumberLiteralTypeAnnotation" === nodeType || "NumberTypeAnnotation" === nodeType || "ObjectTypeAnnotation" === nodeType || "ObjectTypeInternalSlot" === nodeType || "ObjectTypeCallProperty" === nodeType || "ObjectTypeIndexer" === nodeType || "ObjectTypeProperty" === nodeType || "ObjectTypeSpreadProperty" === nodeType || "OpaqueType" === nodeType || "QualifiedTypeIdentifier" === nodeType || "StringLiteralTypeAnnotation" === nodeType || "StringTypeAnnotation" === nodeType || "SymbolTypeAnnotation" === nodeType || "ThisTypeAnnotation" === nodeType || "TupleTypeAnnotation" === nodeType || "TypeofTypeAnnotation" === nodeType || "TypeAlias" === nodeType || "TypeAnnotation" === nodeType || "TypeCastExpression" === nodeType || "TypeParameter" === nodeType || "TypeParameterDeclaration" === nodeType || "TypeParameterInstantiation" === nodeType || "UnionTypeAnnotation" === nodeType || "Variance" === nodeType || "VoidTypeAnnotation" === nodeType || "EnumDeclaration" === nodeType || "EnumBooleanBody" === nodeType || "EnumNumberBody" === nodeType || "EnumStringBody" === nodeType || "EnumSymbolBody" === nodeType || "EnumBooleanMember" === nodeType || "EnumNumberMember" === nodeType || "EnumStringMember" === nodeType || "EnumDefaultedMember" === nodeType || "IndexedAccessType" === nodeType || "OptionalIndexedAccessType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AnyTypeAnnotation" === nodeType || "ArrayTypeAnnotation" === nodeType || "BooleanTypeAnnotation" === nodeType || "BooleanLiteralTypeAnnotation" === nodeType || "NullLiteralTypeAnnotation" === nodeType || "ExistsTypeAnnotation" === nodeType || "FunctionTypeAnnotation" === nodeType || "GenericTypeAnnotation" === nodeType || "InterfaceTypeAnnotation" === nodeType || "IntersectionTypeAnnotation" === nodeType || "MixedTypeAnnotation" === nodeType || "EmptyTypeAnnotation" === nodeType || "NullableTypeAnnotation" === nodeType || "NumberLiteralTypeAnnotation" === nodeType || "NumberTypeAnnotation" === nodeType || "ObjectTypeAnnotation" === nodeType || "StringLiteralTypeAnnotation" === nodeType || "StringTypeAnnotation" === nodeType || "SymbolTypeAnnotation" === nodeType || "ThisTypeAnnotation" === nodeType || "TupleTypeAnnotation" === nodeType || "TypeofTypeAnnotation" === nodeType || "UnionTypeAnnotation" === nodeType || "VoidTypeAnnotation" === nodeType || "IndexedAccessType" === nodeType || "OptionalIndexedAccessType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowBaseAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AnyTypeAnnotation" === nodeType || "BooleanTypeAnnotation" === nodeType || "NullLiteralTypeAnnotation" === nodeType || "MixedTypeAnnotation" === nodeType || "EmptyTypeAnnotation" === nodeType || "NumberTypeAnnotation" === nodeType || "StringTypeAnnotation" === nodeType || "SymbolTypeAnnotation" === nodeType || "ThisTypeAnnotation" === nodeType || "VoidTypeAnnotation" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "InterfaceDeclaration" === nodeType || "OpaqueType" === nodeType || "TypeAlias" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowPredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DeclaredPredicate" === nodeType || "InferredPredicate" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("EnumBooleanBody" === nodeType || "EnumNumberBody" === nodeType || "EnumStringBody" === nodeType || "EnumSymbolBody" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("EnumBooleanMember" === nodeType || "EnumNumberMember" === nodeType || "EnumStringMember" === nodeType || "EnumDefaultedMember" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSX(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("JSXAttribute" === nodeType || "JSXClosingElement" === nodeType || "JSXElement" === nodeType || "JSXEmptyExpression" === nodeType || "JSXExpressionContainer" === nodeType || "JSXSpreadChild" === nodeType || "JSXIdentifier" === nodeType || "JSXMemberExpression" === nodeType || "JSXNamespacedName" === nodeType || "JSXOpeningElement" === nodeType || "JSXSpreadAttribute" === nodeType || "JSXText" === nodeType || "JSXFragment" === nodeType || "JSXOpeningFragment" === nodeType || "JSXClosingFragment" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMiscellaneous(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Noop" === nodeType || "Placeholder" === nodeType || "V8IntrinsicIdentifier" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeScript(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSParameterProperty" === nodeType || "TSDeclareFunction" === nodeType || "TSDeclareMethod" === nodeType || "TSQualifiedName" === nodeType || "TSCallSignatureDeclaration" === nodeType || "TSConstructSignatureDeclaration" === nodeType || "TSPropertySignature" === nodeType || "TSMethodSignature" === nodeType || "TSIndexSignature" === nodeType || "TSAnyKeyword" === nodeType || "TSBooleanKeyword" === nodeType || "TSBigIntKeyword" === nodeType || "TSIntrinsicKeyword" === nodeType || "TSNeverKeyword" === nodeType || "TSNullKeyword" === nodeType || "TSNumberKeyword" === nodeType || "TSObjectKeyword" === nodeType || "TSStringKeyword" === nodeType || "TSSymbolKeyword" === nodeType || "TSUndefinedKeyword" === nodeType || "TSUnknownKeyword" === nodeType || "TSVoidKeyword" === nodeType || "TSThisType" === nodeType || "TSFunctionType" === nodeType || "TSConstructorType" === nodeType || "TSTypeReference" === nodeType || "TSTypePredicate" === nodeType || "TSTypeQuery" === nodeType || "TSTypeLiteral" === nodeType || "TSArrayType" === nodeType || "TSTupleType" === nodeType || "TSOptionalType" === nodeType || "TSRestType" === nodeType || "TSNamedTupleMember" === nodeType || "TSUnionType" === nodeType || "TSIntersectionType" === nodeType || "TSConditionalType" === nodeType || "TSInferType" === nodeType || "TSParenthesizedType" === nodeType || "TSTypeOperator" === nodeType || "TSIndexedAccessType" === nodeType || "TSMappedType" === nodeType || "TSLiteralType" === nodeType || "TSExpressionWithTypeArguments" === nodeType || "TSInterfaceDeclaration" === nodeType || "TSInterfaceBody" === nodeType || "TSTypeAliasDeclaration" === nodeType || "TSInstantiationExpression" === nodeType || "TSAsExpression" === nodeType || "TSTypeAssertion" === nodeType || "TSEnumDeclaration" === nodeType || "TSEnumMember" === nodeType || "TSModuleDeclaration" === nodeType || "TSModuleBlock" === nodeType || "TSImportType" === nodeType || "TSImportEqualsDeclaration" === nodeType || "TSExternalModuleReference" === nodeType || "TSNonNullExpression" === nodeType || "TSExportAssignment" === nodeType || "TSNamespaceExportDeclaration" === nodeType || "TSTypeAnnotation" === nodeType || "TSTypeParameterInstantiation" === nodeType || "TSTypeParameterDeclaration" === nodeType || "TSTypeParameter" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSCallSignatureDeclaration" === nodeType || "TSConstructSignatureDeclaration" === nodeType || "TSPropertySignature" === nodeType || "TSMethodSignature" === nodeType || "TSIndexSignature" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSAnyKeyword" === nodeType || "TSBooleanKeyword" === nodeType || "TSBigIntKeyword" === nodeType || "TSIntrinsicKeyword" === nodeType || "TSNeverKeyword" === nodeType || "TSNullKeyword" === nodeType || "TSNumberKeyword" === nodeType || "TSObjectKeyword" === nodeType || "TSStringKeyword" === nodeType || "TSSymbolKeyword" === nodeType || "TSUndefinedKeyword" === nodeType || "TSUnknownKeyword" === nodeType || "TSVoidKeyword" === nodeType || "TSThisType" === nodeType || "TSFunctionType" === nodeType || "TSConstructorType" === nodeType || "TSTypeReference" === nodeType || "TSTypePredicate" === nodeType || "TSTypeQuery" === nodeType || "TSTypeLiteral" === nodeType || "TSArrayType" === nodeType || "TSTupleType" === nodeType || "TSOptionalType" === nodeType || "TSRestType" === nodeType || "TSUnionType" === nodeType || "TSIntersectionType" === nodeType || "TSConditionalType" === nodeType || "TSInferType" === nodeType || "TSParenthesizedType" === nodeType || "TSTypeOperator" === nodeType || "TSIndexedAccessType" === nodeType || "TSMappedType" === nodeType || "TSLiteralType" === nodeType || "TSExpressionWithTypeArguments" === nodeType || "TSImportType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSBaseType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSAnyKeyword" === nodeType || "TSBooleanKeyword" === nodeType || "TSBigIntKeyword" === nodeType || "TSIntrinsicKeyword" === nodeType || "TSNeverKeyword" === nodeType || "TSNullKeyword" === nodeType || "TSNumberKeyword" === nodeType || "TSObjectKeyword" === nodeType || "TSStringKeyword" === nodeType || "TSSymbolKeyword" === nodeType || "TSUndefinedKeyword" === nodeType || "TSUnknownKeyword" === nodeType || "TSVoidKeyword" === nodeType || "TSThisType" === nodeType || "TSLiteralType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumberLiteral(node, opts) { + console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumberLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRegexLiteral(node, opts) { + console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RegexLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRestProperty(node, opts) { + console.trace("The node type RestProperty has been renamed to RestElement"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RestProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSpreadProperty(node, opts) { + console.trace("The node type SpreadProperty has been renamed to SpreadElement"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SpreadProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} \ No newline at end of file diff --git a/node_modules/tap/node_modules/@babel/traverse/lib/path/generated/asserts.js b/node_modules/tap/node_modules/@babel/traverse/lib/path/generated/asserts.js new file mode 100644 index 000000000..bee8a438e --- /dev/null +++ b/node_modules/tap/node_modules/@babel/traverse/lib/path/generated/asserts.js @@ -0,0 +1,5 @@ +"use strict"; + +var t = require("@babel/types"); + +var _index = require("../index"); \ No newline at end of file diff --git a/node_modules/tap/node_modules/@babel/traverse/lib/path/generated/validators.js b/node_modules/tap/node_modules/@babel/traverse/lib/path/generated/validators.js new file mode 100644 index 000000000..bee8a438e --- /dev/null +++ b/node_modules/tap/node_modules/@babel/traverse/lib/path/generated/validators.js @@ -0,0 +1,5 @@ +"use strict"; + +var t = require("@babel/types"); + +var _index = require("../index"); \ No newline at end of file diff --git a/node_modules/tap/node_modules/@babel/traverse/lib/path/generated/virtual-types.js b/node_modules/tap/node_modules/@babel/traverse/lib/path/generated/virtual-types.js new file mode 100644 index 000000000..bf37ed937 --- /dev/null +++ b/node_modules/tap/node_modules/@babel/traverse/lib/path/generated/virtual-types.js @@ -0,0 +1,3 @@ +"use strict"; + +var t = require("@babel/types"); \ No newline at end of file diff --git a/node_modules/tap/node_modules/@babel/types/lib/asserts/generated/index.js b/node_modules/tap/node_modules/@babel/types/lib/asserts/generated/index.js new file mode 100644 index 000000000..53a55168d --- /dev/null +++ b/node_modules/tap/node_modules/@babel/types/lib/asserts/generated/index.js @@ -0,0 +1,1517 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.assertAccessor = assertAccessor; +exports.assertAnyTypeAnnotation = assertAnyTypeAnnotation; +exports.assertArgumentPlaceholder = assertArgumentPlaceholder; +exports.assertArrayExpression = assertArrayExpression; +exports.assertArrayPattern = assertArrayPattern; +exports.assertArrayTypeAnnotation = assertArrayTypeAnnotation; +exports.assertArrowFunctionExpression = assertArrowFunctionExpression; +exports.assertAssignmentExpression = assertAssignmentExpression; +exports.assertAssignmentPattern = assertAssignmentPattern; +exports.assertAwaitExpression = assertAwaitExpression; +exports.assertBigIntLiteral = assertBigIntLiteral; +exports.assertBinary = assertBinary; +exports.assertBinaryExpression = assertBinaryExpression; +exports.assertBindExpression = assertBindExpression; +exports.assertBlock = assertBlock; +exports.assertBlockParent = assertBlockParent; +exports.assertBlockStatement = assertBlockStatement; +exports.assertBooleanLiteral = assertBooleanLiteral; +exports.assertBooleanLiteralTypeAnnotation = assertBooleanLiteralTypeAnnotation; +exports.assertBooleanTypeAnnotation = assertBooleanTypeAnnotation; +exports.assertBreakStatement = assertBreakStatement; +exports.assertCallExpression = assertCallExpression; +exports.assertCatchClause = assertCatchClause; +exports.assertClass = assertClass; +exports.assertClassAccessorProperty = assertClassAccessorProperty; +exports.assertClassBody = assertClassBody; +exports.assertClassDeclaration = assertClassDeclaration; +exports.assertClassExpression = assertClassExpression; +exports.assertClassImplements = assertClassImplements; +exports.assertClassMethod = assertClassMethod; +exports.assertClassPrivateMethod = assertClassPrivateMethod; +exports.assertClassPrivateProperty = assertClassPrivateProperty; +exports.assertClassProperty = assertClassProperty; +exports.assertCompletionStatement = assertCompletionStatement; +exports.assertConditional = assertConditional; +exports.assertConditionalExpression = assertConditionalExpression; +exports.assertContinueStatement = assertContinueStatement; +exports.assertDebuggerStatement = assertDebuggerStatement; +exports.assertDecimalLiteral = assertDecimalLiteral; +exports.assertDeclaration = assertDeclaration; +exports.assertDeclareClass = assertDeclareClass; +exports.assertDeclareExportAllDeclaration = assertDeclareExportAllDeclaration; +exports.assertDeclareExportDeclaration = assertDeclareExportDeclaration; +exports.assertDeclareFunction = assertDeclareFunction; +exports.assertDeclareInterface = assertDeclareInterface; +exports.assertDeclareModule = assertDeclareModule; +exports.assertDeclareModuleExports = assertDeclareModuleExports; +exports.assertDeclareOpaqueType = assertDeclareOpaqueType; +exports.assertDeclareTypeAlias = assertDeclareTypeAlias; +exports.assertDeclareVariable = assertDeclareVariable; +exports.assertDeclaredPredicate = assertDeclaredPredicate; +exports.assertDecorator = assertDecorator; +exports.assertDirective = assertDirective; +exports.assertDirectiveLiteral = assertDirectiveLiteral; +exports.assertDoExpression = assertDoExpression; +exports.assertDoWhileStatement = assertDoWhileStatement; +exports.assertEmptyStatement = assertEmptyStatement; +exports.assertEmptyTypeAnnotation = assertEmptyTypeAnnotation; +exports.assertEnumBody = assertEnumBody; +exports.assertEnumBooleanBody = assertEnumBooleanBody; +exports.assertEnumBooleanMember = assertEnumBooleanMember; +exports.assertEnumDeclaration = assertEnumDeclaration; +exports.assertEnumDefaultedMember = assertEnumDefaultedMember; +exports.assertEnumMember = assertEnumMember; +exports.assertEnumNumberBody = assertEnumNumberBody; +exports.assertEnumNumberMember = assertEnumNumberMember; +exports.assertEnumStringBody = assertEnumStringBody; +exports.assertEnumStringMember = assertEnumStringMember; +exports.assertEnumSymbolBody = assertEnumSymbolBody; +exports.assertExistsTypeAnnotation = assertExistsTypeAnnotation; +exports.assertExportAllDeclaration = assertExportAllDeclaration; +exports.assertExportDeclaration = assertExportDeclaration; +exports.assertExportDefaultDeclaration = assertExportDefaultDeclaration; +exports.assertExportDefaultSpecifier = assertExportDefaultSpecifier; +exports.assertExportNamedDeclaration = assertExportNamedDeclaration; +exports.assertExportNamespaceSpecifier = assertExportNamespaceSpecifier; +exports.assertExportSpecifier = assertExportSpecifier; +exports.assertExpression = assertExpression; +exports.assertExpressionStatement = assertExpressionStatement; +exports.assertExpressionWrapper = assertExpressionWrapper; +exports.assertFile = assertFile; +exports.assertFlow = assertFlow; +exports.assertFlowBaseAnnotation = assertFlowBaseAnnotation; +exports.assertFlowDeclaration = assertFlowDeclaration; +exports.assertFlowPredicate = assertFlowPredicate; +exports.assertFlowType = assertFlowType; +exports.assertFor = assertFor; +exports.assertForInStatement = assertForInStatement; +exports.assertForOfStatement = assertForOfStatement; +exports.assertForStatement = assertForStatement; +exports.assertForXStatement = assertForXStatement; +exports.assertFunction = assertFunction; +exports.assertFunctionDeclaration = assertFunctionDeclaration; +exports.assertFunctionExpression = assertFunctionExpression; +exports.assertFunctionParent = assertFunctionParent; +exports.assertFunctionTypeAnnotation = assertFunctionTypeAnnotation; +exports.assertFunctionTypeParam = assertFunctionTypeParam; +exports.assertGenericTypeAnnotation = assertGenericTypeAnnotation; +exports.assertIdentifier = assertIdentifier; +exports.assertIfStatement = assertIfStatement; +exports.assertImmutable = assertImmutable; +exports.assertImport = assertImport; +exports.assertImportAttribute = assertImportAttribute; +exports.assertImportDeclaration = assertImportDeclaration; +exports.assertImportDefaultSpecifier = assertImportDefaultSpecifier; +exports.assertImportNamespaceSpecifier = assertImportNamespaceSpecifier; +exports.assertImportSpecifier = assertImportSpecifier; +exports.assertIndexedAccessType = assertIndexedAccessType; +exports.assertInferredPredicate = assertInferredPredicate; +exports.assertInterfaceDeclaration = assertInterfaceDeclaration; +exports.assertInterfaceExtends = assertInterfaceExtends; +exports.assertInterfaceTypeAnnotation = assertInterfaceTypeAnnotation; +exports.assertInterpreterDirective = assertInterpreterDirective; +exports.assertIntersectionTypeAnnotation = assertIntersectionTypeAnnotation; +exports.assertJSX = assertJSX; +exports.assertJSXAttribute = assertJSXAttribute; +exports.assertJSXClosingElement = assertJSXClosingElement; +exports.assertJSXClosingFragment = assertJSXClosingFragment; +exports.assertJSXElement = assertJSXElement; +exports.assertJSXEmptyExpression = assertJSXEmptyExpression; +exports.assertJSXExpressionContainer = assertJSXExpressionContainer; +exports.assertJSXFragment = assertJSXFragment; +exports.assertJSXIdentifier = assertJSXIdentifier; +exports.assertJSXMemberExpression = assertJSXMemberExpression; +exports.assertJSXNamespacedName = assertJSXNamespacedName; +exports.assertJSXOpeningElement = assertJSXOpeningElement; +exports.assertJSXOpeningFragment = assertJSXOpeningFragment; +exports.assertJSXSpreadAttribute = assertJSXSpreadAttribute; +exports.assertJSXSpreadChild = assertJSXSpreadChild; +exports.assertJSXText = assertJSXText; +exports.assertLVal = assertLVal; +exports.assertLabeledStatement = assertLabeledStatement; +exports.assertLiteral = assertLiteral; +exports.assertLogicalExpression = assertLogicalExpression; +exports.assertLoop = assertLoop; +exports.assertMemberExpression = assertMemberExpression; +exports.assertMetaProperty = assertMetaProperty; +exports.assertMethod = assertMethod; +exports.assertMiscellaneous = assertMiscellaneous; +exports.assertMixedTypeAnnotation = assertMixedTypeAnnotation; +exports.assertModuleDeclaration = assertModuleDeclaration; +exports.assertModuleExpression = assertModuleExpression; +exports.assertModuleSpecifier = assertModuleSpecifier; +exports.assertNewExpression = assertNewExpression; +exports.assertNoop = assertNoop; +exports.assertNullLiteral = assertNullLiteral; +exports.assertNullLiteralTypeAnnotation = assertNullLiteralTypeAnnotation; +exports.assertNullableTypeAnnotation = assertNullableTypeAnnotation; +exports.assertNumberLiteral = assertNumberLiteral; +exports.assertNumberLiteralTypeAnnotation = assertNumberLiteralTypeAnnotation; +exports.assertNumberTypeAnnotation = assertNumberTypeAnnotation; +exports.assertNumericLiteral = assertNumericLiteral; +exports.assertObjectExpression = assertObjectExpression; +exports.assertObjectMember = assertObjectMember; +exports.assertObjectMethod = assertObjectMethod; +exports.assertObjectPattern = assertObjectPattern; +exports.assertObjectProperty = assertObjectProperty; +exports.assertObjectTypeAnnotation = assertObjectTypeAnnotation; +exports.assertObjectTypeCallProperty = assertObjectTypeCallProperty; +exports.assertObjectTypeIndexer = assertObjectTypeIndexer; +exports.assertObjectTypeInternalSlot = assertObjectTypeInternalSlot; +exports.assertObjectTypeProperty = assertObjectTypeProperty; +exports.assertObjectTypeSpreadProperty = assertObjectTypeSpreadProperty; +exports.assertOpaqueType = assertOpaqueType; +exports.assertOptionalCallExpression = assertOptionalCallExpression; +exports.assertOptionalIndexedAccessType = assertOptionalIndexedAccessType; +exports.assertOptionalMemberExpression = assertOptionalMemberExpression; +exports.assertParenthesizedExpression = assertParenthesizedExpression; +exports.assertPattern = assertPattern; +exports.assertPatternLike = assertPatternLike; +exports.assertPipelineBareFunction = assertPipelineBareFunction; +exports.assertPipelinePrimaryTopicReference = assertPipelinePrimaryTopicReference; +exports.assertPipelineTopicExpression = assertPipelineTopicExpression; +exports.assertPlaceholder = assertPlaceholder; +exports.assertPrivate = assertPrivate; +exports.assertPrivateName = assertPrivateName; +exports.assertProgram = assertProgram; +exports.assertProperty = assertProperty; +exports.assertPureish = assertPureish; +exports.assertQualifiedTypeIdentifier = assertQualifiedTypeIdentifier; +exports.assertRecordExpression = assertRecordExpression; +exports.assertRegExpLiteral = assertRegExpLiteral; +exports.assertRegexLiteral = assertRegexLiteral; +exports.assertRestElement = assertRestElement; +exports.assertRestProperty = assertRestProperty; +exports.assertReturnStatement = assertReturnStatement; +exports.assertScopable = assertScopable; +exports.assertSequenceExpression = assertSequenceExpression; +exports.assertSpreadElement = assertSpreadElement; +exports.assertSpreadProperty = assertSpreadProperty; +exports.assertStandardized = assertStandardized; +exports.assertStatement = assertStatement; +exports.assertStaticBlock = assertStaticBlock; +exports.assertStringLiteral = assertStringLiteral; +exports.assertStringLiteralTypeAnnotation = assertStringLiteralTypeAnnotation; +exports.assertStringTypeAnnotation = assertStringTypeAnnotation; +exports.assertSuper = assertSuper; +exports.assertSwitchCase = assertSwitchCase; +exports.assertSwitchStatement = assertSwitchStatement; +exports.assertSymbolTypeAnnotation = assertSymbolTypeAnnotation; +exports.assertTSAnyKeyword = assertTSAnyKeyword; +exports.assertTSArrayType = assertTSArrayType; +exports.assertTSAsExpression = assertTSAsExpression; +exports.assertTSBaseType = assertTSBaseType; +exports.assertTSBigIntKeyword = assertTSBigIntKeyword; +exports.assertTSBooleanKeyword = assertTSBooleanKeyword; +exports.assertTSCallSignatureDeclaration = assertTSCallSignatureDeclaration; +exports.assertTSConditionalType = assertTSConditionalType; +exports.assertTSConstructSignatureDeclaration = assertTSConstructSignatureDeclaration; +exports.assertTSConstructorType = assertTSConstructorType; +exports.assertTSDeclareFunction = assertTSDeclareFunction; +exports.assertTSDeclareMethod = assertTSDeclareMethod; +exports.assertTSEntityName = assertTSEntityName; +exports.assertTSEnumDeclaration = assertTSEnumDeclaration; +exports.assertTSEnumMember = assertTSEnumMember; +exports.assertTSExportAssignment = assertTSExportAssignment; +exports.assertTSExpressionWithTypeArguments = assertTSExpressionWithTypeArguments; +exports.assertTSExternalModuleReference = assertTSExternalModuleReference; +exports.assertTSFunctionType = assertTSFunctionType; +exports.assertTSImportEqualsDeclaration = assertTSImportEqualsDeclaration; +exports.assertTSImportType = assertTSImportType; +exports.assertTSIndexSignature = assertTSIndexSignature; +exports.assertTSIndexedAccessType = assertTSIndexedAccessType; +exports.assertTSInferType = assertTSInferType; +exports.assertTSInterfaceBody = assertTSInterfaceBody; +exports.assertTSInterfaceDeclaration = assertTSInterfaceDeclaration; +exports.assertTSIntersectionType = assertTSIntersectionType; +exports.assertTSIntrinsicKeyword = assertTSIntrinsicKeyword; +exports.assertTSLiteralType = assertTSLiteralType; +exports.assertTSMappedType = assertTSMappedType; +exports.assertTSMethodSignature = assertTSMethodSignature; +exports.assertTSModuleBlock = assertTSModuleBlock; +exports.assertTSModuleDeclaration = assertTSModuleDeclaration; +exports.assertTSNamedTupleMember = assertTSNamedTupleMember; +exports.assertTSNamespaceExportDeclaration = assertTSNamespaceExportDeclaration; +exports.assertTSNeverKeyword = assertTSNeverKeyword; +exports.assertTSNonNullExpression = assertTSNonNullExpression; +exports.assertTSNullKeyword = assertTSNullKeyword; +exports.assertTSNumberKeyword = assertTSNumberKeyword; +exports.assertTSObjectKeyword = assertTSObjectKeyword; +exports.assertTSOptionalType = assertTSOptionalType; +exports.assertTSParameterProperty = assertTSParameterProperty; +exports.assertTSParenthesizedType = assertTSParenthesizedType; +exports.assertTSPropertySignature = assertTSPropertySignature; +exports.assertTSQualifiedName = assertTSQualifiedName; +exports.assertTSRestType = assertTSRestType; +exports.assertTSStringKeyword = assertTSStringKeyword; +exports.assertTSSymbolKeyword = assertTSSymbolKeyword; +exports.assertTSThisType = assertTSThisType; +exports.assertTSTupleType = assertTSTupleType; +exports.assertTSType = assertTSType; +exports.assertTSTypeAliasDeclaration = assertTSTypeAliasDeclaration; +exports.assertTSTypeAnnotation = assertTSTypeAnnotation; +exports.assertTSTypeAssertion = assertTSTypeAssertion; +exports.assertTSTypeElement = assertTSTypeElement; +exports.assertTSTypeLiteral = assertTSTypeLiteral; +exports.assertTSTypeOperator = assertTSTypeOperator; +exports.assertTSTypeParameter = assertTSTypeParameter; +exports.assertTSTypeParameterDeclaration = assertTSTypeParameterDeclaration; +exports.assertTSTypeParameterInstantiation = assertTSTypeParameterInstantiation; +exports.assertTSTypePredicate = assertTSTypePredicate; +exports.assertTSTypeQuery = assertTSTypeQuery; +exports.assertTSTypeReference = assertTSTypeReference; +exports.assertTSUndefinedKeyword = assertTSUndefinedKeyword; +exports.assertTSUnionType = assertTSUnionType; +exports.assertTSUnknownKeyword = assertTSUnknownKeyword; +exports.assertTSVoidKeyword = assertTSVoidKeyword; +exports.assertTaggedTemplateExpression = assertTaggedTemplateExpression; +exports.assertTemplateElement = assertTemplateElement; +exports.assertTemplateLiteral = assertTemplateLiteral; +exports.assertTerminatorless = assertTerminatorless; +exports.assertThisExpression = assertThisExpression; +exports.assertThisTypeAnnotation = assertThisTypeAnnotation; +exports.assertThrowStatement = assertThrowStatement; +exports.assertTopicReference = assertTopicReference; +exports.assertTryStatement = assertTryStatement; +exports.assertTupleExpression = assertTupleExpression; +exports.assertTupleTypeAnnotation = assertTupleTypeAnnotation; +exports.assertTypeAlias = assertTypeAlias; +exports.assertTypeAnnotation = assertTypeAnnotation; +exports.assertTypeCastExpression = assertTypeCastExpression; +exports.assertTypeParameter = assertTypeParameter; +exports.assertTypeParameterDeclaration = assertTypeParameterDeclaration; +exports.assertTypeParameterInstantiation = assertTypeParameterInstantiation; +exports.assertTypeScript = assertTypeScript; +exports.assertTypeofTypeAnnotation = assertTypeofTypeAnnotation; +exports.assertUnaryExpression = assertUnaryExpression; +exports.assertUnaryLike = assertUnaryLike; +exports.assertUnionTypeAnnotation = assertUnionTypeAnnotation; +exports.assertUpdateExpression = assertUpdateExpression; +exports.assertUserWhitespacable = assertUserWhitespacable; +exports.assertV8IntrinsicIdentifier = assertV8IntrinsicIdentifier; +exports.assertVariableDeclaration = assertVariableDeclaration; +exports.assertVariableDeclarator = assertVariableDeclarator; +exports.assertVariance = assertVariance; +exports.assertVoidTypeAnnotation = assertVoidTypeAnnotation; +exports.assertWhile = assertWhile; +exports.assertWhileStatement = assertWhileStatement; +exports.assertWithStatement = assertWithStatement; +exports.assertYieldExpression = assertYieldExpression; + +var _is = require("../../validators/is"); + +function assert(type, node, opts) { + if (!(0, _is.default)(type, node, opts)) { + throw new Error(`Expected type "${type}" with option ${JSON.stringify(opts)}, ` + `but instead got "${node.type}".`); + } +} + +function assertArrayExpression(node, opts) { + assert("ArrayExpression", node, opts); +} + +function assertAssignmentExpression(node, opts) { + assert("AssignmentExpression", node, opts); +} + +function assertBinaryExpression(node, opts) { + assert("BinaryExpression", node, opts); +} + +function assertInterpreterDirective(node, opts) { + assert("InterpreterDirective", node, opts); +} + +function assertDirective(node, opts) { + assert("Directive", node, opts); +} + +function assertDirectiveLiteral(node, opts) { + assert("DirectiveLiteral", node, opts); +} + +function assertBlockStatement(node, opts) { + assert("BlockStatement", node, opts); +} + +function assertBreakStatement(node, opts) { + assert("BreakStatement", node, opts); +} + +function assertCallExpression(node, opts) { + assert("CallExpression", node, opts); +} + +function assertCatchClause(node, opts) { + assert("CatchClause", node, opts); +} + +function assertConditionalExpression(node, opts) { + assert("ConditionalExpression", node, opts); +} + +function assertContinueStatement(node, opts) { + assert("ContinueStatement", node, opts); +} + +function assertDebuggerStatement(node, opts) { + assert("DebuggerStatement", node, opts); +} + +function assertDoWhileStatement(node, opts) { + assert("DoWhileStatement", node, opts); +} + +function assertEmptyStatement(node, opts) { + assert("EmptyStatement", node, opts); +} + +function assertExpressionStatement(node, opts) { + assert("ExpressionStatement", node, opts); +} + +function assertFile(node, opts) { + assert("File", node, opts); +} + +function assertForInStatement(node, opts) { + assert("ForInStatement", node, opts); +} + +function assertForStatement(node, opts) { + assert("ForStatement", node, opts); +} + +function assertFunctionDeclaration(node, opts) { + assert("FunctionDeclaration", node, opts); +} + +function assertFunctionExpression(node, opts) { + assert("FunctionExpression", node, opts); +} + +function assertIdentifier(node, opts) { + assert("Identifier", node, opts); +} + +function assertIfStatement(node, opts) { + assert("IfStatement", node, opts); +} + +function assertLabeledStatement(node, opts) { + assert("LabeledStatement", node, opts); +} + +function assertStringLiteral(node, opts) { + assert("StringLiteral", node, opts); +} + +function assertNumericLiteral(node, opts) { + assert("NumericLiteral", node, opts); +} + +function assertNullLiteral(node, opts) { + assert("NullLiteral", node, opts); +} + +function assertBooleanLiteral(node, opts) { + assert("BooleanLiteral", node, opts); +} + +function assertRegExpLiteral(node, opts) { + assert("RegExpLiteral", node, opts); +} + +function assertLogicalExpression(node, opts) { + assert("LogicalExpression", node, opts); +} + +function assertMemberExpression(node, opts) { + assert("MemberExpression", node, opts); +} + +function assertNewExpression(node, opts) { + assert("NewExpression", node, opts); +} + +function assertProgram(node, opts) { + assert("Program", node, opts); +} + +function assertObjectExpression(node, opts) { + assert("ObjectExpression", node, opts); +} + +function assertObjectMethod(node, opts) { + assert("ObjectMethod", node, opts); +} + +function assertObjectProperty(node, opts) { + assert("ObjectProperty", node, opts); +} + +function assertRestElement(node, opts) { + assert("RestElement", node, opts); +} + +function assertReturnStatement(node, opts) { + assert("ReturnStatement", node, opts); +} + +function assertSequenceExpression(node, opts) { + assert("SequenceExpression", node, opts); +} + +function assertParenthesizedExpression(node, opts) { + assert("ParenthesizedExpression", node, opts); +} + +function assertSwitchCase(node, opts) { + assert("SwitchCase", node, opts); +} + +function assertSwitchStatement(node, opts) { + assert("SwitchStatement", node, opts); +} + +function assertThisExpression(node, opts) { + assert("ThisExpression", node, opts); +} + +function assertThrowStatement(node, opts) { + assert("ThrowStatement", node, opts); +} + +function assertTryStatement(node, opts) { + assert("TryStatement", node, opts); +} + +function assertUnaryExpression(node, opts) { + assert("UnaryExpression", node, opts); +} + +function assertUpdateExpression(node, opts) { + assert("UpdateExpression", node, opts); +} + +function assertVariableDeclaration(node, opts) { + assert("VariableDeclaration", node, opts); +} + +function assertVariableDeclarator(node, opts) { + assert("VariableDeclarator", node, opts); +} + +function assertWhileStatement(node, opts) { + assert("WhileStatement", node, opts); +} + +function assertWithStatement(node, opts) { + assert("WithStatement", node, opts); +} + +function assertAssignmentPattern(node, opts) { + assert("AssignmentPattern", node, opts); +} + +function assertArrayPattern(node, opts) { + assert("ArrayPattern", node, opts); +} + +function assertArrowFunctionExpression(node, opts) { + assert("ArrowFunctionExpression", node, opts); +} + +function assertClassBody(node, opts) { + assert("ClassBody", node, opts); +} + +function assertClassExpression(node, opts) { + assert("ClassExpression", node, opts); +} + +function assertClassDeclaration(node, opts) { + assert("ClassDeclaration", node, opts); +} + +function assertExportAllDeclaration(node, opts) { + assert("ExportAllDeclaration", node, opts); +} + +function assertExportDefaultDeclaration(node, opts) { + assert("ExportDefaultDeclaration", node, opts); +} + +function assertExportNamedDeclaration(node, opts) { + assert("ExportNamedDeclaration", node, opts); +} + +function assertExportSpecifier(node, opts) { + assert("ExportSpecifier", node, opts); +} + +function assertForOfStatement(node, opts) { + assert("ForOfStatement", node, opts); +} + +function assertImportDeclaration(node, opts) { + assert("ImportDeclaration", node, opts); +} + +function assertImportDefaultSpecifier(node, opts) { + assert("ImportDefaultSpecifier", node, opts); +} + +function assertImportNamespaceSpecifier(node, opts) { + assert("ImportNamespaceSpecifier", node, opts); +} + +function assertImportSpecifier(node, opts) { + assert("ImportSpecifier", node, opts); +} + +function assertMetaProperty(node, opts) { + assert("MetaProperty", node, opts); +} + +function assertClassMethod(node, opts) { + assert("ClassMethod", node, opts); +} + +function assertObjectPattern(node, opts) { + assert("ObjectPattern", node, opts); +} + +function assertSpreadElement(node, opts) { + assert("SpreadElement", node, opts); +} + +function assertSuper(node, opts) { + assert("Super", node, opts); +} + +function assertTaggedTemplateExpression(node, opts) { + assert("TaggedTemplateExpression", node, opts); +} + +function assertTemplateElement(node, opts) { + assert("TemplateElement", node, opts); +} + +function assertTemplateLiteral(node, opts) { + assert("TemplateLiteral", node, opts); +} + +function assertYieldExpression(node, opts) { + assert("YieldExpression", node, opts); +} + +function assertAwaitExpression(node, opts) { + assert("AwaitExpression", node, opts); +} + +function assertImport(node, opts) { + assert("Import", node, opts); +} + +function assertBigIntLiteral(node, opts) { + assert("BigIntLiteral", node, opts); +} + +function assertExportNamespaceSpecifier(node, opts) { + assert("ExportNamespaceSpecifier", node, opts); +} + +function assertOptionalMemberExpression(node, opts) { + assert("OptionalMemberExpression", node, opts); +} + +function assertOptionalCallExpression(node, opts) { + assert("OptionalCallExpression", node, opts); +} + +function assertClassProperty(node, opts) { + assert("ClassProperty", node, opts); +} + +function assertClassAccessorProperty(node, opts) { + assert("ClassAccessorProperty", node, opts); +} + +function assertClassPrivateProperty(node, opts) { + assert("ClassPrivateProperty", node, opts); +} + +function assertClassPrivateMethod(node, opts) { + assert("ClassPrivateMethod", node, opts); +} + +function assertPrivateName(node, opts) { + assert("PrivateName", node, opts); +} + +function assertStaticBlock(node, opts) { + assert("StaticBlock", node, opts); +} + +function assertAnyTypeAnnotation(node, opts) { + assert("AnyTypeAnnotation", node, opts); +} + +function assertArrayTypeAnnotation(node, opts) { + assert("ArrayTypeAnnotation", node, opts); +} + +function assertBooleanTypeAnnotation(node, opts) { + assert("BooleanTypeAnnotation", node, opts); +} + +function assertBooleanLiteralTypeAnnotation(node, opts) { + assert("BooleanLiteralTypeAnnotation", node, opts); +} + +function assertNullLiteralTypeAnnotation(node, opts) { + assert("NullLiteralTypeAnnotation", node, opts); +} + +function assertClassImplements(node, opts) { + assert("ClassImplements", node, opts); +} + +function assertDeclareClass(node, opts) { + assert("DeclareClass", node, opts); +} + +function assertDeclareFunction(node, opts) { + assert("DeclareFunction", node, opts); +} + +function assertDeclareInterface(node, opts) { + assert("DeclareInterface", node, opts); +} + +function assertDeclareModule(node, opts) { + assert("DeclareModule", node, opts); +} + +function assertDeclareModuleExports(node, opts) { + assert("DeclareModuleExports", node, opts); +} + +function assertDeclareTypeAlias(node, opts) { + assert("DeclareTypeAlias", node, opts); +} + +function assertDeclareOpaqueType(node, opts) { + assert("DeclareOpaqueType", node, opts); +} + +function assertDeclareVariable(node, opts) { + assert("DeclareVariable", node, opts); +} + +function assertDeclareExportDeclaration(node, opts) { + assert("DeclareExportDeclaration", node, opts); +} + +function assertDeclareExportAllDeclaration(node, opts) { + assert("DeclareExportAllDeclaration", node, opts); +} + +function assertDeclaredPredicate(node, opts) { + assert("DeclaredPredicate", node, opts); +} + +function assertExistsTypeAnnotation(node, opts) { + assert("ExistsTypeAnnotation", node, opts); +} + +function assertFunctionTypeAnnotation(node, opts) { + assert("FunctionTypeAnnotation", node, opts); +} + +function assertFunctionTypeParam(node, opts) { + assert("FunctionTypeParam", node, opts); +} + +function assertGenericTypeAnnotation(node, opts) { + assert("GenericTypeAnnotation", node, opts); +} + +function assertInferredPredicate(node, opts) { + assert("InferredPredicate", node, opts); +} + +function assertInterfaceExtends(node, opts) { + assert("InterfaceExtends", node, opts); +} + +function assertInterfaceDeclaration(node, opts) { + assert("InterfaceDeclaration", node, opts); +} + +function assertInterfaceTypeAnnotation(node, opts) { + assert("InterfaceTypeAnnotation", node, opts); +} + +function assertIntersectionTypeAnnotation(node, opts) { + assert("IntersectionTypeAnnotation", node, opts); +} + +function assertMixedTypeAnnotation(node, opts) { + assert("MixedTypeAnnotation", node, opts); +} + +function assertEmptyTypeAnnotation(node, opts) { + assert("EmptyTypeAnnotation", node, opts); +} + +function assertNullableTypeAnnotation(node, opts) { + assert("NullableTypeAnnotation", node, opts); +} + +function assertNumberLiteralTypeAnnotation(node, opts) { + assert("NumberLiteralTypeAnnotation", node, opts); +} + +function assertNumberTypeAnnotation(node, opts) { + assert("NumberTypeAnnotation", node, opts); +} + +function assertObjectTypeAnnotation(node, opts) { + assert("ObjectTypeAnnotation", node, opts); +} + +function assertObjectTypeInternalSlot(node, opts) { + assert("ObjectTypeInternalSlot", node, opts); +} + +function assertObjectTypeCallProperty(node, opts) { + assert("ObjectTypeCallProperty", node, opts); +} + +function assertObjectTypeIndexer(node, opts) { + assert("ObjectTypeIndexer", node, opts); +} + +function assertObjectTypeProperty(node, opts) { + assert("ObjectTypeProperty", node, opts); +} + +function assertObjectTypeSpreadProperty(node, opts) { + assert("ObjectTypeSpreadProperty", node, opts); +} + +function assertOpaqueType(node, opts) { + assert("OpaqueType", node, opts); +} + +function assertQualifiedTypeIdentifier(node, opts) { + assert("QualifiedTypeIdentifier", node, opts); +} + +function assertStringLiteralTypeAnnotation(node, opts) { + assert("StringLiteralTypeAnnotation", node, opts); +} + +function assertStringTypeAnnotation(node, opts) { + assert("StringTypeAnnotation", node, opts); +} + +function assertSymbolTypeAnnotation(node, opts) { + assert("SymbolTypeAnnotation", node, opts); +} + +function assertThisTypeAnnotation(node, opts) { + assert("ThisTypeAnnotation", node, opts); +} + +function assertTupleTypeAnnotation(node, opts) { + assert("TupleTypeAnnotation", node, opts); +} + +function assertTypeofTypeAnnotation(node, opts) { + assert("TypeofTypeAnnotation", node, opts); +} + +function assertTypeAlias(node, opts) { + assert("TypeAlias", node, opts); +} + +function assertTypeAnnotation(node, opts) { + assert("TypeAnnotation", node, opts); +} + +function assertTypeCastExpression(node, opts) { + assert("TypeCastExpression", node, opts); +} + +function assertTypeParameter(node, opts) { + assert("TypeParameter", node, opts); +} + +function assertTypeParameterDeclaration(node, opts) { + assert("TypeParameterDeclaration", node, opts); +} + +function assertTypeParameterInstantiation(node, opts) { + assert("TypeParameterInstantiation", node, opts); +} + +function assertUnionTypeAnnotation(node, opts) { + assert("UnionTypeAnnotation", node, opts); +} + +function assertVariance(node, opts) { + assert("Variance", node, opts); +} + +function assertVoidTypeAnnotation(node, opts) { + assert("VoidTypeAnnotation", node, opts); +} + +function assertEnumDeclaration(node, opts) { + assert("EnumDeclaration", node, opts); +} + +function assertEnumBooleanBody(node, opts) { + assert("EnumBooleanBody", node, opts); +} + +function assertEnumNumberBody(node, opts) { + assert("EnumNumberBody", node, opts); +} + +function assertEnumStringBody(node, opts) { + assert("EnumStringBody", node, opts); +} + +function assertEnumSymbolBody(node, opts) { + assert("EnumSymbolBody", node, opts); +} + +function assertEnumBooleanMember(node, opts) { + assert("EnumBooleanMember", node, opts); +} + +function assertEnumNumberMember(node, opts) { + assert("EnumNumberMember", node, opts); +} + +function assertEnumStringMember(node, opts) { + assert("EnumStringMember", node, opts); +} + +function assertEnumDefaultedMember(node, opts) { + assert("EnumDefaultedMember", node, opts); +} + +function assertIndexedAccessType(node, opts) { + assert("IndexedAccessType", node, opts); +} + +function assertOptionalIndexedAccessType(node, opts) { + assert("OptionalIndexedAccessType", node, opts); +} + +function assertJSXAttribute(node, opts) { + assert("JSXAttribute", node, opts); +} + +function assertJSXClosingElement(node, opts) { + assert("JSXClosingElement", node, opts); +} + +function assertJSXElement(node, opts) { + assert("JSXElement", node, opts); +} + +function assertJSXEmptyExpression(node, opts) { + assert("JSXEmptyExpression", node, opts); +} + +function assertJSXExpressionContainer(node, opts) { + assert("JSXExpressionContainer", node, opts); +} + +function assertJSXSpreadChild(node, opts) { + assert("JSXSpreadChild", node, opts); +} + +function assertJSXIdentifier(node, opts) { + assert("JSXIdentifier", node, opts); +} + +function assertJSXMemberExpression(node, opts) { + assert("JSXMemberExpression", node, opts); +} + +function assertJSXNamespacedName(node, opts) { + assert("JSXNamespacedName", node, opts); +} + +function assertJSXOpeningElement(node, opts) { + assert("JSXOpeningElement", node, opts); +} + +function assertJSXSpreadAttribute(node, opts) { + assert("JSXSpreadAttribute", node, opts); +} + +function assertJSXText(node, opts) { + assert("JSXText", node, opts); +} + +function assertJSXFragment(node, opts) { + assert("JSXFragment", node, opts); +} + +function assertJSXOpeningFragment(node, opts) { + assert("JSXOpeningFragment", node, opts); +} + +function assertJSXClosingFragment(node, opts) { + assert("JSXClosingFragment", node, opts); +} + +function assertNoop(node, opts) { + assert("Noop", node, opts); +} + +function assertPlaceholder(node, opts) { + assert("Placeholder", node, opts); +} + +function assertV8IntrinsicIdentifier(node, opts) { + assert("V8IntrinsicIdentifier", node, opts); +} + +function assertArgumentPlaceholder(node, opts) { + assert("ArgumentPlaceholder", node, opts); +} + +function assertBindExpression(node, opts) { + assert("BindExpression", node, opts); +} + +function assertImportAttribute(node, opts) { + assert("ImportAttribute", node, opts); +} + +function assertDecorator(node, opts) { + assert("Decorator", node, opts); +} + +function assertDoExpression(node, opts) { + assert("DoExpression", node, opts); +} + +function assertExportDefaultSpecifier(node, opts) { + assert("ExportDefaultSpecifier", node, opts); +} + +function assertRecordExpression(node, opts) { + assert("RecordExpression", node, opts); +} + +function assertTupleExpression(node, opts) { + assert("TupleExpression", node, opts); +} + +function assertDecimalLiteral(node, opts) { + assert("DecimalLiteral", node, opts); +} + +function assertModuleExpression(node, opts) { + assert("ModuleExpression", node, opts); +} + +function assertTopicReference(node, opts) { + assert("TopicReference", node, opts); +} + +function assertPipelineTopicExpression(node, opts) { + assert("PipelineTopicExpression", node, opts); +} + +function assertPipelineBareFunction(node, opts) { + assert("PipelineBareFunction", node, opts); +} + +function assertPipelinePrimaryTopicReference(node, opts) { + assert("PipelinePrimaryTopicReference", node, opts); +} + +function assertTSParameterProperty(node, opts) { + assert("TSParameterProperty", node, opts); +} + +function assertTSDeclareFunction(node, opts) { + assert("TSDeclareFunction", node, opts); +} + +function assertTSDeclareMethod(node, opts) { + assert("TSDeclareMethod", node, opts); +} + +function assertTSQualifiedName(node, opts) { + assert("TSQualifiedName", node, opts); +} + +function assertTSCallSignatureDeclaration(node, opts) { + assert("TSCallSignatureDeclaration", node, opts); +} + +function assertTSConstructSignatureDeclaration(node, opts) { + assert("TSConstructSignatureDeclaration", node, opts); +} + +function assertTSPropertySignature(node, opts) { + assert("TSPropertySignature", node, opts); +} + +function assertTSMethodSignature(node, opts) { + assert("TSMethodSignature", node, opts); +} + +function assertTSIndexSignature(node, opts) { + assert("TSIndexSignature", node, opts); +} + +function assertTSAnyKeyword(node, opts) { + assert("TSAnyKeyword", node, opts); +} + +function assertTSBooleanKeyword(node, opts) { + assert("TSBooleanKeyword", node, opts); +} + +function assertTSBigIntKeyword(node, opts) { + assert("TSBigIntKeyword", node, opts); +} + +function assertTSIntrinsicKeyword(node, opts) { + assert("TSIntrinsicKeyword", node, opts); +} + +function assertTSNeverKeyword(node, opts) { + assert("TSNeverKeyword", node, opts); +} + +function assertTSNullKeyword(node, opts) { + assert("TSNullKeyword", node, opts); +} + +function assertTSNumberKeyword(node, opts) { + assert("TSNumberKeyword", node, opts); +} + +function assertTSObjectKeyword(node, opts) { + assert("TSObjectKeyword", node, opts); +} + +function assertTSStringKeyword(node, opts) { + assert("TSStringKeyword", node, opts); +} + +function assertTSSymbolKeyword(node, opts) { + assert("TSSymbolKeyword", node, opts); +} + +function assertTSUndefinedKeyword(node, opts) { + assert("TSUndefinedKeyword", node, opts); +} + +function assertTSUnknownKeyword(node, opts) { + assert("TSUnknownKeyword", node, opts); +} + +function assertTSVoidKeyword(node, opts) { + assert("TSVoidKeyword", node, opts); +} + +function assertTSThisType(node, opts) { + assert("TSThisType", node, opts); +} + +function assertTSFunctionType(node, opts) { + assert("TSFunctionType", node, opts); +} + +function assertTSConstructorType(node, opts) { + assert("TSConstructorType", node, opts); +} + +function assertTSTypeReference(node, opts) { + assert("TSTypeReference", node, opts); +} + +function assertTSTypePredicate(node, opts) { + assert("TSTypePredicate", node, opts); +} + +function assertTSTypeQuery(node, opts) { + assert("TSTypeQuery", node, opts); +} + +function assertTSTypeLiteral(node, opts) { + assert("TSTypeLiteral", node, opts); +} + +function assertTSArrayType(node, opts) { + assert("TSArrayType", node, opts); +} + +function assertTSTupleType(node, opts) { + assert("TSTupleType", node, opts); +} + +function assertTSOptionalType(node, opts) { + assert("TSOptionalType", node, opts); +} + +function assertTSRestType(node, opts) { + assert("TSRestType", node, opts); +} + +function assertTSNamedTupleMember(node, opts) { + assert("TSNamedTupleMember", node, opts); +} + +function assertTSUnionType(node, opts) { + assert("TSUnionType", node, opts); +} + +function assertTSIntersectionType(node, opts) { + assert("TSIntersectionType", node, opts); +} + +function assertTSConditionalType(node, opts) { + assert("TSConditionalType", node, opts); +} + +function assertTSInferType(node, opts) { + assert("TSInferType", node, opts); +} + +function assertTSParenthesizedType(node, opts) { + assert("TSParenthesizedType", node, opts); +} + +function assertTSTypeOperator(node, opts) { + assert("TSTypeOperator", node, opts); +} + +function assertTSIndexedAccessType(node, opts) { + assert("TSIndexedAccessType", node, opts); +} + +function assertTSMappedType(node, opts) { + assert("TSMappedType", node, opts); +} + +function assertTSLiteralType(node, opts) { + assert("TSLiteralType", node, opts); +} + +function assertTSExpressionWithTypeArguments(node, opts) { + assert("TSExpressionWithTypeArguments", node, opts); +} + +function assertTSInterfaceDeclaration(node, opts) { + assert("TSInterfaceDeclaration", node, opts); +} + +function assertTSInterfaceBody(node, opts) { + assert("TSInterfaceBody", node, opts); +} + +function assertTSTypeAliasDeclaration(node, opts) { + assert("TSTypeAliasDeclaration", node, opts); +} + +function assertTSAsExpression(node, opts) { + assert("TSAsExpression", node, opts); +} + +function assertTSTypeAssertion(node, opts) { + assert("TSTypeAssertion", node, opts); +} + +function assertTSEnumDeclaration(node, opts) { + assert("TSEnumDeclaration", node, opts); +} + +function assertTSEnumMember(node, opts) { + assert("TSEnumMember", node, opts); +} + +function assertTSModuleDeclaration(node, opts) { + assert("TSModuleDeclaration", node, opts); +} + +function assertTSModuleBlock(node, opts) { + assert("TSModuleBlock", node, opts); +} + +function assertTSImportType(node, opts) { + assert("TSImportType", node, opts); +} + +function assertTSImportEqualsDeclaration(node, opts) { + assert("TSImportEqualsDeclaration", node, opts); +} + +function assertTSExternalModuleReference(node, opts) { + assert("TSExternalModuleReference", node, opts); +} + +function assertTSNonNullExpression(node, opts) { + assert("TSNonNullExpression", node, opts); +} + +function assertTSExportAssignment(node, opts) { + assert("TSExportAssignment", node, opts); +} + +function assertTSNamespaceExportDeclaration(node, opts) { + assert("TSNamespaceExportDeclaration", node, opts); +} + +function assertTSTypeAnnotation(node, opts) { + assert("TSTypeAnnotation", node, opts); +} + +function assertTSTypeParameterInstantiation(node, opts) { + assert("TSTypeParameterInstantiation", node, opts); +} + +function assertTSTypeParameterDeclaration(node, opts) { + assert("TSTypeParameterDeclaration", node, opts); +} + +function assertTSTypeParameter(node, opts) { + assert("TSTypeParameter", node, opts); +} + +function assertStandardized(node, opts) { + assert("Standardized", node, opts); +} + +function assertExpression(node, opts) { + assert("Expression", node, opts); +} + +function assertBinary(node, opts) { + assert("Binary", node, opts); +} + +function assertScopable(node, opts) { + assert("Scopable", node, opts); +} + +function assertBlockParent(node, opts) { + assert("BlockParent", node, opts); +} + +function assertBlock(node, opts) { + assert("Block", node, opts); +} + +function assertStatement(node, opts) { + assert("Statement", node, opts); +} + +function assertTerminatorless(node, opts) { + assert("Terminatorless", node, opts); +} + +function assertCompletionStatement(node, opts) { + assert("CompletionStatement", node, opts); +} + +function assertConditional(node, opts) { + assert("Conditional", node, opts); +} + +function assertLoop(node, opts) { + assert("Loop", node, opts); +} + +function assertWhile(node, opts) { + assert("While", node, opts); +} + +function assertExpressionWrapper(node, opts) { + assert("ExpressionWrapper", node, opts); +} + +function assertFor(node, opts) { + assert("For", node, opts); +} + +function assertForXStatement(node, opts) { + assert("ForXStatement", node, opts); +} + +function assertFunction(node, opts) { + assert("Function", node, opts); +} + +function assertFunctionParent(node, opts) { + assert("FunctionParent", node, opts); +} + +function assertPureish(node, opts) { + assert("Pureish", node, opts); +} + +function assertDeclaration(node, opts) { + assert("Declaration", node, opts); +} + +function assertPatternLike(node, opts) { + assert("PatternLike", node, opts); +} + +function assertLVal(node, opts) { + assert("LVal", node, opts); +} + +function assertTSEntityName(node, opts) { + assert("TSEntityName", node, opts); +} + +function assertLiteral(node, opts) { + assert("Literal", node, opts); +} + +function assertImmutable(node, opts) { + assert("Immutable", node, opts); +} + +function assertUserWhitespacable(node, opts) { + assert("UserWhitespacable", node, opts); +} + +function assertMethod(node, opts) { + assert("Method", node, opts); +} + +function assertObjectMember(node, opts) { + assert("ObjectMember", node, opts); +} + +function assertProperty(node, opts) { + assert("Property", node, opts); +} + +function assertUnaryLike(node, opts) { + assert("UnaryLike", node, opts); +} + +function assertPattern(node, opts) { + assert("Pattern", node, opts); +} + +function assertClass(node, opts) { + assert("Class", node, opts); +} + +function assertModuleDeclaration(node, opts) { + assert("ModuleDeclaration", node, opts); +} + +function assertExportDeclaration(node, opts) { + assert("ExportDeclaration", node, opts); +} + +function assertModuleSpecifier(node, opts) { + assert("ModuleSpecifier", node, opts); +} + +function assertAccessor(node, opts) { + assert("Accessor", node, opts); +} + +function assertPrivate(node, opts) { + assert("Private", node, opts); +} + +function assertFlow(node, opts) { + assert("Flow", node, opts); +} + +function assertFlowType(node, opts) { + assert("FlowType", node, opts); +} + +function assertFlowBaseAnnotation(node, opts) { + assert("FlowBaseAnnotation", node, opts); +} + +function assertFlowDeclaration(node, opts) { + assert("FlowDeclaration", node, opts); +} + +function assertFlowPredicate(node, opts) { + assert("FlowPredicate", node, opts); +} + +function assertEnumBody(node, opts) { + assert("EnumBody", node, opts); +} + +function assertEnumMember(node, opts) { + assert("EnumMember", node, opts); +} + +function assertJSX(node, opts) { + assert("JSX", node, opts); +} + +function assertMiscellaneous(node, opts) { + assert("Miscellaneous", node, opts); +} + +function assertTypeScript(node, opts) { + assert("TypeScript", node, opts); +} + +function assertTSTypeElement(node, opts) { + assert("TSTypeElement", node, opts); +} + +function assertTSType(node, opts) { + assert("TSType", node, opts); +} + +function assertTSBaseType(node, opts) { + assert("TSBaseType", node, opts); +} + +function assertNumberLiteral(node, opts) { + console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); + assert("NumberLiteral", node, opts); +} + +function assertRegexLiteral(node, opts) { + console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); + assert("RegexLiteral", node, opts); +} + +function assertRestProperty(node, opts) { + console.trace("The node type RestProperty has been renamed to RestElement"); + assert("RestProperty", node, opts); +} + +function assertSpreadProperty(node, opts) { + console.trace("The node type SpreadProperty has been renamed to SpreadElement"); + assert("SpreadProperty", node, opts); +} \ No newline at end of file diff --git a/node_modules/tap/node_modules/@babel/types/lib/ast-types/generated/index.js b/node_modules/tap/node_modules/@babel/types/lib/ast-types/generated/index.js new file mode 100644 index 000000000..e69de29bb diff --git a/node_modules/tap/node_modules/@babel/types/lib/builders/generated/index.js b/node_modules/tap/node_modules/@babel/types/lib/builders/generated/index.js new file mode 100644 index 000000000..99851ee0b --- /dev/null +++ b/node_modules/tap/node_modules/@babel/types/lib/builders/generated/index.js @@ -0,0 +1,1266 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.anyTypeAnnotation = anyTypeAnnotation; +exports.argumentPlaceholder = argumentPlaceholder; +exports.arrayExpression = arrayExpression; +exports.arrayPattern = arrayPattern; +exports.arrayTypeAnnotation = arrayTypeAnnotation; +exports.arrowFunctionExpression = arrowFunctionExpression; +exports.assignmentExpression = assignmentExpression; +exports.assignmentPattern = assignmentPattern; +exports.awaitExpression = awaitExpression; +exports.bigIntLiteral = bigIntLiteral; +exports.binaryExpression = binaryExpression; +exports.bindExpression = bindExpression; +exports.blockStatement = blockStatement; +exports.booleanLiteral = booleanLiteral; +exports.booleanLiteralTypeAnnotation = booleanLiteralTypeAnnotation; +exports.booleanTypeAnnotation = booleanTypeAnnotation; +exports.breakStatement = breakStatement; +exports.callExpression = callExpression; +exports.catchClause = catchClause; +exports.classAccessorProperty = classAccessorProperty; +exports.classBody = classBody; +exports.classDeclaration = classDeclaration; +exports.classExpression = classExpression; +exports.classImplements = classImplements; +exports.classMethod = classMethod; +exports.classPrivateMethod = classPrivateMethod; +exports.classPrivateProperty = classPrivateProperty; +exports.classProperty = classProperty; +exports.conditionalExpression = conditionalExpression; +exports.continueStatement = continueStatement; +exports.debuggerStatement = debuggerStatement; +exports.decimalLiteral = decimalLiteral; +exports.declareClass = declareClass; +exports.declareExportAllDeclaration = declareExportAllDeclaration; +exports.declareExportDeclaration = declareExportDeclaration; +exports.declareFunction = declareFunction; +exports.declareInterface = declareInterface; +exports.declareModule = declareModule; +exports.declareModuleExports = declareModuleExports; +exports.declareOpaqueType = declareOpaqueType; +exports.declareTypeAlias = declareTypeAlias; +exports.declareVariable = declareVariable; +exports.declaredPredicate = declaredPredicate; +exports.decorator = decorator; +exports.directive = directive; +exports.directiveLiteral = directiveLiteral; +exports.doExpression = doExpression; +exports.doWhileStatement = doWhileStatement; +exports.emptyStatement = emptyStatement; +exports.emptyTypeAnnotation = emptyTypeAnnotation; +exports.enumBooleanBody = enumBooleanBody; +exports.enumBooleanMember = enumBooleanMember; +exports.enumDeclaration = enumDeclaration; +exports.enumDefaultedMember = enumDefaultedMember; +exports.enumNumberBody = enumNumberBody; +exports.enumNumberMember = enumNumberMember; +exports.enumStringBody = enumStringBody; +exports.enumStringMember = enumStringMember; +exports.enumSymbolBody = enumSymbolBody; +exports.existsTypeAnnotation = existsTypeAnnotation; +exports.exportAllDeclaration = exportAllDeclaration; +exports.exportDefaultDeclaration = exportDefaultDeclaration; +exports.exportDefaultSpecifier = exportDefaultSpecifier; +exports.exportNamedDeclaration = exportNamedDeclaration; +exports.exportNamespaceSpecifier = exportNamespaceSpecifier; +exports.exportSpecifier = exportSpecifier; +exports.expressionStatement = expressionStatement; +exports.file = file; +exports.forInStatement = forInStatement; +exports.forOfStatement = forOfStatement; +exports.forStatement = forStatement; +exports.functionDeclaration = functionDeclaration; +exports.functionExpression = functionExpression; +exports.functionTypeAnnotation = functionTypeAnnotation; +exports.functionTypeParam = functionTypeParam; +exports.genericTypeAnnotation = genericTypeAnnotation; +exports.identifier = identifier; +exports.ifStatement = ifStatement; +exports.import = _import; +exports.importAttribute = importAttribute; +exports.importDeclaration = importDeclaration; +exports.importDefaultSpecifier = importDefaultSpecifier; +exports.importNamespaceSpecifier = importNamespaceSpecifier; +exports.importSpecifier = importSpecifier; +exports.indexedAccessType = indexedAccessType; +exports.inferredPredicate = inferredPredicate; +exports.interfaceDeclaration = interfaceDeclaration; +exports.interfaceExtends = interfaceExtends; +exports.interfaceTypeAnnotation = interfaceTypeAnnotation; +exports.interpreterDirective = interpreterDirective; +exports.intersectionTypeAnnotation = intersectionTypeAnnotation; +exports.jSXAttribute = exports.jsxAttribute = jsxAttribute; +exports.jSXClosingElement = exports.jsxClosingElement = jsxClosingElement; +exports.jSXClosingFragment = exports.jsxClosingFragment = jsxClosingFragment; +exports.jSXElement = exports.jsxElement = jsxElement; +exports.jSXEmptyExpression = exports.jsxEmptyExpression = jsxEmptyExpression; +exports.jSXExpressionContainer = exports.jsxExpressionContainer = jsxExpressionContainer; +exports.jSXFragment = exports.jsxFragment = jsxFragment; +exports.jSXIdentifier = exports.jsxIdentifier = jsxIdentifier; +exports.jSXMemberExpression = exports.jsxMemberExpression = jsxMemberExpression; +exports.jSXNamespacedName = exports.jsxNamespacedName = jsxNamespacedName; +exports.jSXOpeningElement = exports.jsxOpeningElement = jsxOpeningElement; +exports.jSXOpeningFragment = exports.jsxOpeningFragment = jsxOpeningFragment; +exports.jSXSpreadAttribute = exports.jsxSpreadAttribute = jsxSpreadAttribute; +exports.jSXSpreadChild = exports.jsxSpreadChild = jsxSpreadChild; +exports.jSXText = exports.jsxText = jsxText; +exports.labeledStatement = labeledStatement; +exports.logicalExpression = logicalExpression; +exports.memberExpression = memberExpression; +exports.metaProperty = metaProperty; +exports.mixedTypeAnnotation = mixedTypeAnnotation; +exports.moduleExpression = moduleExpression; +exports.newExpression = newExpression; +exports.noop = noop; +exports.nullLiteral = nullLiteral; +exports.nullLiteralTypeAnnotation = nullLiteralTypeAnnotation; +exports.nullableTypeAnnotation = nullableTypeAnnotation; +exports.numberLiteral = NumberLiteral; +exports.numberLiteralTypeAnnotation = numberLiteralTypeAnnotation; +exports.numberTypeAnnotation = numberTypeAnnotation; +exports.numericLiteral = numericLiteral; +exports.objectExpression = objectExpression; +exports.objectMethod = objectMethod; +exports.objectPattern = objectPattern; +exports.objectProperty = objectProperty; +exports.objectTypeAnnotation = objectTypeAnnotation; +exports.objectTypeCallProperty = objectTypeCallProperty; +exports.objectTypeIndexer = objectTypeIndexer; +exports.objectTypeInternalSlot = objectTypeInternalSlot; +exports.objectTypeProperty = objectTypeProperty; +exports.objectTypeSpreadProperty = objectTypeSpreadProperty; +exports.opaqueType = opaqueType; +exports.optionalCallExpression = optionalCallExpression; +exports.optionalIndexedAccessType = optionalIndexedAccessType; +exports.optionalMemberExpression = optionalMemberExpression; +exports.parenthesizedExpression = parenthesizedExpression; +exports.pipelineBareFunction = pipelineBareFunction; +exports.pipelinePrimaryTopicReference = pipelinePrimaryTopicReference; +exports.pipelineTopicExpression = pipelineTopicExpression; +exports.placeholder = placeholder; +exports.privateName = privateName; +exports.program = program; +exports.qualifiedTypeIdentifier = qualifiedTypeIdentifier; +exports.recordExpression = recordExpression; +exports.regExpLiteral = regExpLiteral; +exports.regexLiteral = RegexLiteral; +exports.restElement = restElement; +exports.restProperty = RestProperty; +exports.returnStatement = returnStatement; +exports.sequenceExpression = sequenceExpression; +exports.spreadElement = spreadElement; +exports.spreadProperty = SpreadProperty; +exports.staticBlock = staticBlock; +exports.stringLiteral = stringLiteral; +exports.stringLiteralTypeAnnotation = stringLiteralTypeAnnotation; +exports.stringTypeAnnotation = stringTypeAnnotation; +exports.super = _super; +exports.switchCase = switchCase; +exports.switchStatement = switchStatement; +exports.symbolTypeAnnotation = symbolTypeAnnotation; +exports.taggedTemplateExpression = taggedTemplateExpression; +exports.templateElement = templateElement; +exports.templateLiteral = templateLiteral; +exports.thisExpression = thisExpression; +exports.thisTypeAnnotation = thisTypeAnnotation; +exports.throwStatement = throwStatement; +exports.topicReference = topicReference; +exports.tryStatement = tryStatement; +exports.tSAnyKeyword = exports.tsAnyKeyword = tsAnyKeyword; +exports.tSArrayType = exports.tsArrayType = tsArrayType; +exports.tSAsExpression = exports.tsAsExpression = tsAsExpression; +exports.tSBigIntKeyword = exports.tsBigIntKeyword = tsBigIntKeyword; +exports.tSBooleanKeyword = exports.tsBooleanKeyword = tsBooleanKeyword; +exports.tSCallSignatureDeclaration = exports.tsCallSignatureDeclaration = tsCallSignatureDeclaration; +exports.tSConditionalType = exports.tsConditionalType = tsConditionalType; +exports.tSConstructSignatureDeclaration = exports.tsConstructSignatureDeclaration = tsConstructSignatureDeclaration; +exports.tSConstructorType = exports.tsConstructorType = tsConstructorType; +exports.tSDeclareFunction = exports.tsDeclareFunction = tsDeclareFunction; +exports.tSDeclareMethod = exports.tsDeclareMethod = tsDeclareMethod; +exports.tSEnumDeclaration = exports.tsEnumDeclaration = tsEnumDeclaration; +exports.tSEnumMember = exports.tsEnumMember = tsEnumMember; +exports.tSExportAssignment = exports.tsExportAssignment = tsExportAssignment; +exports.tSExpressionWithTypeArguments = exports.tsExpressionWithTypeArguments = tsExpressionWithTypeArguments; +exports.tSExternalModuleReference = exports.tsExternalModuleReference = tsExternalModuleReference; +exports.tSFunctionType = exports.tsFunctionType = tsFunctionType; +exports.tSImportEqualsDeclaration = exports.tsImportEqualsDeclaration = tsImportEqualsDeclaration; +exports.tSImportType = exports.tsImportType = tsImportType; +exports.tSIndexSignature = exports.tsIndexSignature = tsIndexSignature; +exports.tSIndexedAccessType = exports.tsIndexedAccessType = tsIndexedAccessType; +exports.tSInferType = exports.tsInferType = tsInferType; +exports.tSInterfaceBody = exports.tsInterfaceBody = tsInterfaceBody; +exports.tSInterfaceDeclaration = exports.tsInterfaceDeclaration = tsInterfaceDeclaration; +exports.tSIntersectionType = exports.tsIntersectionType = tsIntersectionType; +exports.tSIntrinsicKeyword = exports.tsIntrinsicKeyword = tsIntrinsicKeyword; +exports.tSLiteralType = exports.tsLiteralType = tsLiteralType; +exports.tSMappedType = exports.tsMappedType = tsMappedType; +exports.tSMethodSignature = exports.tsMethodSignature = tsMethodSignature; +exports.tSModuleBlock = exports.tsModuleBlock = tsModuleBlock; +exports.tSModuleDeclaration = exports.tsModuleDeclaration = tsModuleDeclaration; +exports.tSNamedTupleMember = exports.tsNamedTupleMember = tsNamedTupleMember; +exports.tSNamespaceExportDeclaration = exports.tsNamespaceExportDeclaration = tsNamespaceExportDeclaration; +exports.tSNeverKeyword = exports.tsNeverKeyword = tsNeverKeyword; +exports.tSNonNullExpression = exports.tsNonNullExpression = tsNonNullExpression; +exports.tSNullKeyword = exports.tsNullKeyword = tsNullKeyword; +exports.tSNumberKeyword = exports.tsNumberKeyword = tsNumberKeyword; +exports.tSObjectKeyword = exports.tsObjectKeyword = tsObjectKeyword; +exports.tSOptionalType = exports.tsOptionalType = tsOptionalType; +exports.tSParameterProperty = exports.tsParameterProperty = tsParameterProperty; +exports.tSParenthesizedType = exports.tsParenthesizedType = tsParenthesizedType; +exports.tSPropertySignature = exports.tsPropertySignature = tsPropertySignature; +exports.tSQualifiedName = exports.tsQualifiedName = tsQualifiedName; +exports.tSRestType = exports.tsRestType = tsRestType; +exports.tSStringKeyword = exports.tsStringKeyword = tsStringKeyword; +exports.tSSymbolKeyword = exports.tsSymbolKeyword = tsSymbolKeyword; +exports.tSThisType = exports.tsThisType = tsThisType; +exports.tSTupleType = exports.tsTupleType = tsTupleType; +exports.tSTypeAliasDeclaration = exports.tsTypeAliasDeclaration = tsTypeAliasDeclaration; +exports.tSTypeAnnotation = exports.tsTypeAnnotation = tsTypeAnnotation; +exports.tSTypeAssertion = exports.tsTypeAssertion = tsTypeAssertion; +exports.tSTypeLiteral = exports.tsTypeLiteral = tsTypeLiteral; +exports.tSTypeOperator = exports.tsTypeOperator = tsTypeOperator; +exports.tSTypeParameter = exports.tsTypeParameter = tsTypeParameter; +exports.tSTypeParameterDeclaration = exports.tsTypeParameterDeclaration = tsTypeParameterDeclaration; +exports.tSTypeParameterInstantiation = exports.tsTypeParameterInstantiation = tsTypeParameterInstantiation; +exports.tSTypePredicate = exports.tsTypePredicate = tsTypePredicate; +exports.tSTypeQuery = exports.tsTypeQuery = tsTypeQuery; +exports.tSTypeReference = exports.tsTypeReference = tsTypeReference; +exports.tSUndefinedKeyword = exports.tsUndefinedKeyword = tsUndefinedKeyword; +exports.tSUnionType = exports.tsUnionType = tsUnionType; +exports.tSUnknownKeyword = exports.tsUnknownKeyword = tsUnknownKeyword; +exports.tSVoidKeyword = exports.tsVoidKeyword = tsVoidKeyword; +exports.tupleExpression = tupleExpression; +exports.tupleTypeAnnotation = tupleTypeAnnotation; +exports.typeAlias = typeAlias; +exports.typeAnnotation = typeAnnotation; +exports.typeCastExpression = typeCastExpression; +exports.typeParameter = typeParameter; +exports.typeParameterDeclaration = typeParameterDeclaration; +exports.typeParameterInstantiation = typeParameterInstantiation; +exports.typeofTypeAnnotation = typeofTypeAnnotation; +exports.unaryExpression = unaryExpression; +exports.unionTypeAnnotation = unionTypeAnnotation; +exports.updateExpression = updateExpression; +exports.v8IntrinsicIdentifier = v8IntrinsicIdentifier; +exports.variableDeclaration = variableDeclaration; +exports.variableDeclarator = variableDeclarator; +exports.variance = variance; +exports.voidTypeAnnotation = voidTypeAnnotation; +exports.whileStatement = whileStatement; +exports.withStatement = withStatement; +exports.yieldExpression = yieldExpression; + +var _builder = require("../builder"); + +function arrayExpression(elements) { + return _builder.default.apply("ArrayExpression", arguments); +} + +function assignmentExpression(operator, left, right) { + return _builder.default.apply("AssignmentExpression", arguments); +} + +function binaryExpression(operator, left, right) { + return _builder.default.apply("BinaryExpression", arguments); +} + +function interpreterDirective(value) { + return _builder.default.apply("InterpreterDirective", arguments); +} + +function directive(value) { + return _builder.default.apply("Directive", arguments); +} + +function directiveLiteral(value) { + return _builder.default.apply("DirectiveLiteral", arguments); +} + +function blockStatement(body, directives) { + return _builder.default.apply("BlockStatement", arguments); +} + +function breakStatement(label) { + return _builder.default.apply("BreakStatement", arguments); +} + +function callExpression(callee, _arguments) { + return _builder.default.apply("CallExpression", arguments); +} + +function catchClause(param, body) { + return _builder.default.apply("CatchClause", arguments); +} + +function conditionalExpression(test, consequent, alternate) { + return _builder.default.apply("ConditionalExpression", arguments); +} + +function continueStatement(label) { + return _builder.default.apply("ContinueStatement", arguments); +} + +function debuggerStatement() { + return _builder.default.apply("DebuggerStatement", arguments); +} + +function doWhileStatement(test, body) { + return _builder.default.apply("DoWhileStatement", arguments); +} + +function emptyStatement() { + return _builder.default.apply("EmptyStatement", arguments); +} + +function expressionStatement(expression) { + return _builder.default.apply("ExpressionStatement", arguments); +} + +function file(program, comments, tokens) { + return _builder.default.apply("File", arguments); +} + +function forInStatement(left, right, body) { + return _builder.default.apply("ForInStatement", arguments); +} + +function forStatement(init, test, update, body) { + return _builder.default.apply("ForStatement", arguments); +} + +function functionDeclaration(id, params, body, generator, async) { + return _builder.default.apply("FunctionDeclaration", arguments); +} + +function functionExpression(id, params, body, generator, async) { + return _builder.default.apply("FunctionExpression", arguments); +} + +function identifier(name) { + return _builder.default.apply("Identifier", arguments); +} + +function ifStatement(test, consequent, alternate) { + return _builder.default.apply("IfStatement", arguments); +} + +function labeledStatement(label, body) { + return _builder.default.apply("LabeledStatement", arguments); +} + +function stringLiteral(value) { + return _builder.default.apply("StringLiteral", arguments); +} + +function numericLiteral(value) { + return _builder.default.apply("NumericLiteral", arguments); +} + +function nullLiteral() { + return _builder.default.apply("NullLiteral", arguments); +} + +function booleanLiteral(value) { + return _builder.default.apply("BooleanLiteral", arguments); +} + +function regExpLiteral(pattern, flags) { + return _builder.default.apply("RegExpLiteral", arguments); +} + +function logicalExpression(operator, left, right) { + return _builder.default.apply("LogicalExpression", arguments); +} + +function memberExpression(object, property, computed, optional) { + return _builder.default.apply("MemberExpression", arguments); +} + +function newExpression(callee, _arguments) { + return _builder.default.apply("NewExpression", arguments); +} + +function program(body, directives, sourceType, interpreter) { + return _builder.default.apply("Program", arguments); +} + +function objectExpression(properties) { + return _builder.default.apply("ObjectExpression", arguments); +} + +function objectMethod(kind, key, params, body, computed, generator, async) { + return _builder.default.apply("ObjectMethod", arguments); +} + +function objectProperty(key, value, computed, shorthand, decorators) { + return _builder.default.apply("ObjectProperty", arguments); +} + +function restElement(argument) { + return _builder.default.apply("RestElement", arguments); +} + +function returnStatement(argument) { + return _builder.default.apply("ReturnStatement", arguments); +} + +function sequenceExpression(expressions) { + return _builder.default.apply("SequenceExpression", arguments); +} + +function parenthesizedExpression(expression) { + return _builder.default.apply("ParenthesizedExpression", arguments); +} + +function switchCase(test, consequent) { + return _builder.default.apply("SwitchCase", arguments); +} + +function switchStatement(discriminant, cases) { + return _builder.default.apply("SwitchStatement", arguments); +} + +function thisExpression() { + return _builder.default.apply("ThisExpression", arguments); +} + +function throwStatement(argument) { + return _builder.default.apply("ThrowStatement", arguments); +} + +function tryStatement(block, handler, finalizer) { + return _builder.default.apply("TryStatement", arguments); +} + +function unaryExpression(operator, argument, prefix) { + return _builder.default.apply("UnaryExpression", arguments); +} + +function updateExpression(operator, argument, prefix) { + return _builder.default.apply("UpdateExpression", arguments); +} + +function variableDeclaration(kind, declarations) { + return _builder.default.apply("VariableDeclaration", arguments); +} + +function variableDeclarator(id, init) { + return _builder.default.apply("VariableDeclarator", arguments); +} + +function whileStatement(test, body) { + return _builder.default.apply("WhileStatement", arguments); +} + +function withStatement(object, body) { + return _builder.default.apply("WithStatement", arguments); +} + +function assignmentPattern(left, right) { + return _builder.default.apply("AssignmentPattern", arguments); +} + +function arrayPattern(elements) { + return _builder.default.apply("ArrayPattern", arguments); +} + +function arrowFunctionExpression(params, body, async) { + return _builder.default.apply("ArrowFunctionExpression", arguments); +} + +function classBody(body) { + return _builder.default.apply("ClassBody", arguments); +} + +function classExpression(id, superClass, body, decorators) { + return _builder.default.apply("ClassExpression", arguments); +} + +function classDeclaration(id, superClass, body, decorators) { + return _builder.default.apply("ClassDeclaration", arguments); +} + +function exportAllDeclaration(source) { + return _builder.default.apply("ExportAllDeclaration", arguments); +} + +function exportDefaultDeclaration(declaration) { + return _builder.default.apply("ExportDefaultDeclaration", arguments); +} + +function exportNamedDeclaration(declaration, specifiers, source) { + return _builder.default.apply("ExportNamedDeclaration", arguments); +} + +function exportSpecifier(local, exported) { + return _builder.default.apply("ExportSpecifier", arguments); +} + +function forOfStatement(left, right, body, _await) { + return _builder.default.apply("ForOfStatement", arguments); +} + +function importDeclaration(specifiers, source) { + return _builder.default.apply("ImportDeclaration", arguments); +} + +function importDefaultSpecifier(local) { + return _builder.default.apply("ImportDefaultSpecifier", arguments); +} + +function importNamespaceSpecifier(local) { + return _builder.default.apply("ImportNamespaceSpecifier", arguments); +} + +function importSpecifier(local, imported) { + return _builder.default.apply("ImportSpecifier", arguments); +} + +function metaProperty(meta, property) { + return _builder.default.apply("MetaProperty", arguments); +} + +function classMethod(kind, key, params, body, computed, _static, generator, async) { + return _builder.default.apply("ClassMethod", arguments); +} + +function objectPattern(properties) { + return _builder.default.apply("ObjectPattern", arguments); +} + +function spreadElement(argument) { + return _builder.default.apply("SpreadElement", arguments); +} + +function _super() { + return _builder.default.apply("Super", arguments); +} + +function taggedTemplateExpression(tag, quasi) { + return _builder.default.apply("TaggedTemplateExpression", arguments); +} + +function templateElement(value, tail) { + return _builder.default.apply("TemplateElement", arguments); +} + +function templateLiteral(quasis, expressions) { + return _builder.default.apply("TemplateLiteral", arguments); +} + +function yieldExpression(argument, delegate) { + return _builder.default.apply("YieldExpression", arguments); +} + +function awaitExpression(argument) { + return _builder.default.apply("AwaitExpression", arguments); +} + +function _import() { + return _builder.default.apply("Import", arguments); +} + +function bigIntLiteral(value) { + return _builder.default.apply("BigIntLiteral", arguments); +} + +function exportNamespaceSpecifier(exported) { + return _builder.default.apply("ExportNamespaceSpecifier", arguments); +} + +function optionalMemberExpression(object, property, computed, optional) { + return _builder.default.apply("OptionalMemberExpression", arguments); +} + +function optionalCallExpression(callee, _arguments, optional) { + return _builder.default.apply("OptionalCallExpression", arguments); +} + +function classProperty(key, value, typeAnnotation, decorators, computed, _static) { + return _builder.default.apply("ClassProperty", arguments); +} + +function classAccessorProperty(key, value, typeAnnotation, decorators, computed, _static) { + return _builder.default.apply("ClassAccessorProperty", arguments); +} + +function classPrivateProperty(key, value, decorators, _static) { + return _builder.default.apply("ClassPrivateProperty", arguments); +} + +function classPrivateMethod(kind, key, params, body, _static) { + return _builder.default.apply("ClassPrivateMethod", arguments); +} + +function privateName(id) { + return _builder.default.apply("PrivateName", arguments); +} + +function staticBlock(body) { + return _builder.default.apply("StaticBlock", arguments); +} + +function anyTypeAnnotation() { + return _builder.default.apply("AnyTypeAnnotation", arguments); +} + +function arrayTypeAnnotation(elementType) { + return _builder.default.apply("ArrayTypeAnnotation", arguments); +} + +function booleanTypeAnnotation() { + return _builder.default.apply("BooleanTypeAnnotation", arguments); +} + +function booleanLiteralTypeAnnotation(value) { + return _builder.default.apply("BooleanLiteralTypeAnnotation", arguments); +} + +function nullLiteralTypeAnnotation() { + return _builder.default.apply("NullLiteralTypeAnnotation", arguments); +} + +function classImplements(id, typeParameters) { + return _builder.default.apply("ClassImplements", arguments); +} + +function declareClass(id, typeParameters, _extends, body) { + return _builder.default.apply("DeclareClass", arguments); +} + +function declareFunction(id) { + return _builder.default.apply("DeclareFunction", arguments); +} + +function declareInterface(id, typeParameters, _extends, body) { + return _builder.default.apply("DeclareInterface", arguments); +} + +function declareModule(id, body, kind) { + return _builder.default.apply("DeclareModule", arguments); +} + +function declareModuleExports(typeAnnotation) { + return _builder.default.apply("DeclareModuleExports", arguments); +} + +function declareTypeAlias(id, typeParameters, right) { + return _builder.default.apply("DeclareTypeAlias", arguments); +} + +function declareOpaqueType(id, typeParameters, supertype) { + return _builder.default.apply("DeclareOpaqueType", arguments); +} + +function declareVariable(id) { + return _builder.default.apply("DeclareVariable", arguments); +} + +function declareExportDeclaration(declaration, specifiers, source) { + return _builder.default.apply("DeclareExportDeclaration", arguments); +} + +function declareExportAllDeclaration(source) { + return _builder.default.apply("DeclareExportAllDeclaration", arguments); +} + +function declaredPredicate(value) { + return _builder.default.apply("DeclaredPredicate", arguments); +} + +function existsTypeAnnotation() { + return _builder.default.apply("ExistsTypeAnnotation", arguments); +} + +function functionTypeAnnotation(typeParameters, params, rest, returnType) { + return _builder.default.apply("FunctionTypeAnnotation", arguments); +} + +function functionTypeParam(name, typeAnnotation) { + return _builder.default.apply("FunctionTypeParam", arguments); +} + +function genericTypeAnnotation(id, typeParameters) { + return _builder.default.apply("GenericTypeAnnotation", arguments); +} + +function inferredPredicate() { + return _builder.default.apply("InferredPredicate", arguments); +} + +function interfaceExtends(id, typeParameters) { + return _builder.default.apply("InterfaceExtends", arguments); +} + +function interfaceDeclaration(id, typeParameters, _extends, body) { + return _builder.default.apply("InterfaceDeclaration", arguments); +} + +function interfaceTypeAnnotation(_extends, body) { + return _builder.default.apply("InterfaceTypeAnnotation", arguments); +} + +function intersectionTypeAnnotation(types) { + return _builder.default.apply("IntersectionTypeAnnotation", arguments); +} + +function mixedTypeAnnotation() { + return _builder.default.apply("MixedTypeAnnotation", arguments); +} + +function emptyTypeAnnotation() { + return _builder.default.apply("EmptyTypeAnnotation", arguments); +} + +function nullableTypeAnnotation(typeAnnotation) { + return _builder.default.apply("NullableTypeAnnotation", arguments); +} + +function numberLiteralTypeAnnotation(value) { + return _builder.default.apply("NumberLiteralTypeAnnotation", arguments); +} + +function numberTypeAnnotation() { + return _builder.default.apply("NumberTypeAnnotation", arguments); +} + +function objectTypeAnnotation(properties, indexers, callProperties, internalSlots, exact) { + return _builder.default.apply("ObjectTypeAnnotation", arguments); +} + +function objectTypeInternalSlot(id, value, optional, _static, method) { + return _builder.default.apply("ObjectTypeInternalSlot", arguments); +} + +function objectTypeCallProperty(value) { + return _builder.default.apply("ObjectTypeCallProperty", arguments); +} + +function objectTypeIndexer(id, key, value, variance) { + return _builder.default.apply("ObjectTypeIndexer", arguments); +} + +function objectTypeProperty(key, value, variance) { + return _builder.default.apply("ObjectTypeProperty", arguments); +} + +function objectTypeSpreadProperty(argument) { + return _builder.default.apply("ObjectTypeSpreadProperty", arguments); +} + +function opaqueType(id, typeParameters, supertype, impltype) { + return _builder.default.apply("OpaqueType", arguments); +} + +function qualifiedTypeIdentifier(id, qualification) { + return _builder.default.apply("QualifiedTypeIdentifier", arguments); +} + +function stringLiteralTypeAnnotation(value) { + return _builder.default.apply("StringLiteralTypeAnnotation", arguments); +} + +function stringTypeAnnotation() { + return _builder.default.apply("StringTypeAnnotation", arguments); +} + +function symbolTypeAnnotation() { + return _builder.default.apply("SymbolTypeAnnotation", arguments); +} + +function thisTypeAnnotation() { + return _builder.default.apply("ThisTypeAnnotation", arguments); +} + +function tupleTypeAnnotation(types) { + return _builder.default.apply("TupleTypeAnnotation", arguments); +} + +function typeofTypeAnnotation(argument) { + return _builder.default.apply("TypeofTypeAnnotation", arguments); +} + +function typeAlias(id, typeParameters, right) { + return _builder.default.apply("TypeAlias", arguments); +} + +function typeAnnotation(typeAnnotation) { + return _builder.default.apply("TypeAnnotation", arguments); +} + +function typeCastExpression(expression, typeAnnotation) { + return _builder.default.apply("TypeCastExpression", arguments); +} + +function typeParameter(bound, _default, variance) { + return _builder.default.apply("TypeParameter", arguments); +} + +function typeParameterDeclaration(params) { + return _builder.default.apply("TypeParameterDeclaration", arguments); +} + +function typeParameterInstantiation(params) { + return _builder.default.apply("TypeParameterInstantiation", arguments); +} + +function unionTypeAnnotation(types) { + return _builder.default.apply("UnionTypeAnnotation", arguments); +} + +function variance(kind) { + return _builder.default.apply("Variance", arguments); +} + +function voidTypeAnnotation() { + return _builder.default.apply("VoidTypeAnnotation", arguments); +} + +function enumDeclaration(id, body) { + return _builder.default.apply("EnumDeclaration", arguments); +} + +function enumBooleanBody(members) { + return _builder.default.apply("EnumBooleanBody", arguments); +} + +function enumNumberBody(members) { + return _builder.default.apply("EnumNumberBody", arguments); +} + +function enumStringBody(members) { + return _builder.default.apply("EnumStringBody", arguments); +} + +function enumSymbolBody(members) { + return _builder.default.apply("EnumSymbolBody", arguments); +} + +function enumBooleanMember(id) { + return _builder.default.apply("EnumBooleanMember", arguments); +} + +function enumNumberMember(id, init) { + return _builder.default.apply("EnumNumberMember", arguments); +} + +function enumStringMember(id, init) { + return _builder.default.apply("EnumStringMember", arguments); +} + +function enumDefaultedMember(id) { + return _builder.default.apply("EnumDefaultedMember", arguments); +} + +function indexedAccessType(objectType, indexType) { + return _builder.default.apply("IndexedAccessType", arguments); +} + +function optionalIndexedAccessType(objectType, indexType) { + return _builder.default.apply("OptionalIndexedAccessType", arguments); +} + +function jsxAttribute(name, value) { + return _builder.default.apply("JSXAttribute", arguments); +} + +function jsxClosingElement(name) { + return _builder.default.apply("JSXClosingElement", arguments); +} + +function jsxElement(openingElement, closingElement, children, selfClosing) { + return _builder.default.apply("JSXElement", arguments); +} + +function jsxEmptyExpression() { + return _builder.default.apply("JSXEmptyExpression", arguments); +} + +function jsxExpressionContainer(expression) { + return _builder.default.apply("JSXExpressionContainer", arguments); +} + +function jsxSpreadChild(expression) { + return _builder.default.apply("JSXSpreadChild", arguments); +} + +function jsxIdentifier(name) { + return _builder.default.apply("JSXIdentifier", arguments); +} + +function jsxMemberExpression(object, property) { + return _builder.default.apply("JSXMemberExpression", arguments); +} + +function jsxNamespacedName(namespace, name) { + return _builder.default.apply("JSXNamespacedName", arguments); +} + +function jsxOpeningElement(name, attributes, selfClosing) { + return _builder.default.apply("JSXOpeningElement", arguments); +} + +function jsxSpreadAttribute(argument) { + return _builder.default.apply("JSXSpreadAttribute", arguments); +} + +function jsxText(value) { + return _builder.default.apply("JSXText", arguments); +} + +function jsxFragment(openingFragment, closingFragment, children) { + return _builder.default.apply("JSXFragment", arguments); +} + +function jsxOpeningFragment() { + return _builder.default.apply("JSXOpeningFragment", arguments); +} + +function jsxClosingFragment() { + return _builder.default.apply("JSXClosingFragment", arguments); +} + +function noop() { + return _builder.default.apply("Noop", arguments); +} + +function placeholder(expectedNode, name) { + return _builder.default.apply("Placeholder", arguments); +} + +function v8IntrinsicIdentifier(name) { + return _builder.default.apply("V8IntrinsicIdentifier", arguments); +} + +function argumentPlaceholder() { + return _builder.default.apply("ArgumentPlaceholder", arguments); +} + +function bindExpression(object, callee) { + return _builder.default.apply("BindExpression", arguments); +} + +function importAttribute(key, value) { + return _builder.default.apply("ImportAttribute", arguments); +} + +function decorator(expression) { + return _builder.default.apply("Decorator", arguments); +} + +function doExpression(body, async) { + return _builder.default.apply("DoExpression", arguments); +} + +function exportDefaultSpecifier(exported) { + return _builder.default.apply("ExportDefaultSpecifier", arguments); +} + +function recordExpression(properties) { + return _builder.default.apply("RecordExpression", arguments); +} + +function tupleExpression(elements) { + return _builder.default.apply("TupleExpression", arguments); +} + +function decimalLiteral(value) { + return _builder.default.apply("DecimalLiteral", arguments); +} + +function moduleExpression(body) { + return _builder.default.apply("ModuleExpression", arguments); +} + +function topicReference() { + return _builder.default.apply("TopicReference", arguments); +} + +function pipelineTopicExpression(expression) { + return _builder.default.apply("PipelineTopicExpression", arguments); +} + +function pipelineBareFunction(callee) { + return _builder.default.apply("PipelineBareFunction", arguments); +} + +function pipelinePrimaryTopicReference() { + return _builder.default.apply("PipelinePrimaryTopicReference", arguments); +} + +function tsParameterProperty(parameter) { + return _builder.default.apply("TSParameterProperty", arguments); +} + +function tsDeclareFunction(id, typeParameters, params, returnType) { + return _builder.default.apply("TSDeclareFunction", arguments); +} + +function tsDeclareMethod(decorators, key, typeParameters, params, returnType) { + return _builder.default.apply("TSDeclareMethod", arguments); +} + +function tsQualifiedName(left, right) { + return _builder.default.apply("TSQualifiedName", arguments); +} + +function tsCallSignatureDeclaration(typeParameters, parameters, typeAnnotation) { + return _builder.default.apply("TSCallSignatureDeclaration", arguments); +} + +function tsConstructSignatureDeclaration(typeParameters, parameters, typeAnnotation) { + return _builder.default.apply("TSConstructSignatureDeclaration", arguments); +} + +function tsPropertySignature(key, typeAnnotation, initializer) { + return _builder.default.apply("TSPropertySignature", arguments); +} + +function tsMethodSignature(key, typeParameters, parameters, typeAnnotation) { + return _builder.default.apply("TSMethodSignature", arguments); +} + +function tsIndexSignature(parameters, typeAnnotation) { + return _builder.default.apply("TSIndexSignature", arguments); +} + +function tsAnyKeyword() { + return _builder.default.apply("TSAnyKeyword", arguments); +} + +function tsBooleanKeyword() { + return _builder.default.apply("TSBooleanKeyword", arguments); +} + +function tsBigIntKeyword() { + return _builder.default.apply("TSBigIntKeyword", arguments); +} + +function tsIntrinsicKeyword() { + return _builder.default.apply("TSIntrinsicKeyword", arguments); +} + +function tsNeverKeyword() { + return _builder.default.apply("TSNeverKeyword", arguments); +} + +function tsNullKeyword() { + return _builder.default.apply("TSNullKeyword", arguments); +} + +function tsNumberKeyword() { + return _builder.default.apply("TSNumberKeyword", arguments); +} + +function tsObjectKeyword() { + return _builder.default.apply("TSObjectKeyword", arguments); +} + +function tsStringKeyword() { + return _builder.default.apply("TSStringKeyword", arguments); +} + +function tsSymbolKeyword() { + return _builder.default.apply("TSSymbolKeyword", arguments); +} + +function tsUndefinedKeyword() { + return _builder.default.apply("TSUndefinedKeyword", arguments); +} + +function tsUnknownKeyword() { + return _builder.default.apply("TSUnknownKeyword", arguments); +} + +function tsVoidKeyword() { + return _builder.default.apply("TSVoidKeyword", arguments); +} + +function tsThisType() { + return _builder.default.apply("TSThisType", arguments); +} + +function tsFunctionType(typeParameters, parameters, typeAnnotation) { + return _builder.default.apply("TSFunctionType", arguments); +} + +function tsConstructorType(typeParameters, parameters, typeAnnotation) { + return _builder.default.apply("TSConstructorType", arguments); +} + +function tsTypeReference(typeName, typeParameters) { + return _builder.default.apply("TSTypeReference", arguments); +} + +function tsTypePredicate(parameterName, typeAnnotation, asserts) { + return _builder.default.apply("TSTypePredicate", arguments); +} + +function tsTypeQuery(exprName) { + return _builder.default.apply("TSTypeQuery", arguments); +} + +function tsTypeLiteral(members) { + return _builder.default.apply("TSTypeLiteral", arguments); +} + +function tsArrayType(elementType) { + return _builder.default.apply("TSArrayType", arguments); +} + +function tsTupleType(elementTypes) { + return _builder.default.apply("TSTupleType", arguments); +} + +function tsOptionalType(typeAnnotation) { + return _builder.default.apply("TSOptionalType", arguments); +} + +function tsRestType(typeAnnotation) { + return _builder.default.apply("TSRestType", arguments); +} + +function tsNamedTupleMember(label, elementType, optional) { + return _builder.default.apply("TSNamedTupleMember", arguments); +} + +function tsUnionType(types) { + return _builder.default.apply("TSUnionType", arguments); +} + +function tsIntersectionType(types) { + return _builder.default.apply("TSIntersectionType", arguments); +} + +function tsConditionalType(checkType, extendsType, trueType, falseType) { + return _builder.default.apply("TSConditionalType", arguments); +} + +function tsInferType(typeParameter) { + return _builder.default.apply("TSInferType", arguments); +} + +function tsParenthesizedType(typeAnnotation) { + return _builder.default.apply("TSParenthesizedType", arguments); +} + +function tsTypeOperator(typeAnnotation) { + return _builder.default.apply("TSTypeOperator", arguments); +} + +function tsIndexedAccessType(objectType, indexType) { + return _builder.default.apply("TSIndexedAccessType", arguments); +} + +function tsMappedType(typeParameter, typeAnnotation, nameType) { + return _builder.default.apply("TSMappedType", arguments); +} + +function tsLiteralType(literal) { + return _builder.default.apply("TSLiteralType", arguments); +} + +function tsExpressionWithTypeArguments(expression, typeParameters) { + return _builder.default.apply("TSExpressionWithTypeArguments", arguments); +} + +function tsInterfaceDeclaration(id, typeParameters, _extends, body) { + return _builder.default.apply("TSInterfaceDeclaration", arguments); +} + +function tsInterfaceBody(body) { + return _builder.default.apply("TSInterfaceBody", arguments); +} + +function tsTypeAliasDeclaration(id, typeParameters, typeAnnotation) { + return _builder.default.apply("TSTypeAliasDeclaration", arguments); +} + +function tsAsExpression(expression, typeAnnotation) { + return _builder.default.apply("TSAsExpression", arguments); +} + +function tsTypeAssertion(typeAnnotation, expression) { + return _builder.default.apply("TSTypeAssertion", arguments); +} + +function tsEnumDeclaration(id, members) { + return _builder.default.apply("TSEnumDeclaration", arguments); +} + +function tsEnumMember(id, initializer) { + return _builder.default.apply("TSEnumMember", arguments); +} + +function tsModuleDeclaration(id, body) { + return _builder.default.apply("TSModuleDeclaration", arguments); +} + +function tsModuleBlock(body) { + return _builder.default.apply("TSModuleBlock", arguments); +} + +function tsImportType(argument, qualifier, typeParameters) { + return _builder.default.apply("TSImportType", arguments); +} + +function tsImportEqualsDeclaration(id, moduleReference) { + return _builder.default.apply("TSImportEqualsDeclaration", arguments); +} + +function tsExternalModuleReference(expression) { + return _builder.default.apply("TSExternalModuleReference", arguments); +} + +function tsNonNullExpression(expression) { + return _builder.default.apply("TSNonNullExpression", arguments); +} + +function tsExportAssignment(expression) { + return _builder.default.apply("TSExportAssignment", arguments); +} + +function tsNamespaceExportDeclaration(id) { + return _builder.default.apply("TSNamespaceExportDeclaration", arguments); +} + +function tsTypeAnnotation(typeAnnotation) { + return _builder.default.apply("TSTypeAnnotation", arguments); +} + +function tsTypeParameterInstantiation(params) { + return _builder.default.apply("TSTypeParameterInstantiation", arguments); +} + +function tsTypeParameterDeclaration(params) { + return _builder.default.apply("TSTypeParameterDeclaration", arguments); +} + +function tsTypeParameter(constraint, _default, name) { + return _builder.default.apply("TSTypeParameter", arguments); +} + +function NumberLiteral(value) { + console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); + return _builder.default.apply("NumberLiteral", arguments); +} + +function RegexLiteral(pattern, flags) { + console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); + return _builder.default.apply("RegexLiteral", arguments); +} + +function RestProperty(argument) { + console.trace("The node type RestProperty has been renamed to RestElement"); + return _builder.default.apply("RestProperty", arguments); +} + +function SpreadProperty(argument) { + console.trace("The node type SpreadProperty has been renamed to SpreadElement"); + return _builder.default.apply("SpreadProperty", arguments); +} \ No newline at end of file diff --git a/node_modules/tap/node_modules/@babel/types/lib/builders/generated/uppercase.js b/node_modules/tap/node_modules/@babel/types/lib/builders/generated/uppercase.js new file mode 100644 index 000000000..95c9a5258 --- /dev/null +++ b/node_modules/tap/node_modules/@babel/types/lib/builders/generated/uppercase.js @@ -0,0 +1,1513 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +Object.defineProperty(exports, "AnyTypeAnnotation", { + enumerable: true, + get: function () { + return _index.anyTypeAnnotation; + } +}); +Object.defineProperty(exports, "ArgumentPlaceholder", { + enumerable: true, + get: function () { + return _index.argumentPlaceholder; + } +}); +Object.defineProperty(exports, "ArrayExpression", { + enumerable: true, + get: function () { + return _index.arrayExpression; + } +}); +Object.defineProperty(exports, "ArrayPattern", { + enumerable: true, + get: function () { + return _index.arrayPattern; + } +}); +Object.defineProperty(exports, "ArrayTypeAnnotation", { + enumerable: true, + get: function () { + return _index.arrayTypeAnnotation; + } +}); +Object.defineProperty(exports, "ArrowFunctionExpression", { + enumerable: true, + get: function () { + return _index.arrowFunctionExpression; + } +}); +Object.defineProperty(exports, "AssignmentExpression", { + enumerable: true, + get: function () { + return _index.assignmentExpression; + } +}); +Object.defineProperty(exports, "AssignmentPattern", { + enumerable: true, + get: function () { + return _index.assignmentPattern; + } +}); +Object.defineProperty(exports, "AwaitExpression", { + enumerable: true, + get: function () { + return _index.awaitExpression; + } +}); +Object.defineProperty(exports, "BigIntLiteral", { + enumerable: true, + get: function () { + return _index.bigIntLiteral; + } +}); +Object.defineProperty(exports, "BinaryExpression", { + enumerable: true, + get: function () { + return _index.binaryExpression; + } +}); +Object.defineProperty(exports, "BindExpression", { + enumerable: true, + get: function () { + return _index.bindExpression; + } +}); +Object.defineProperty(exports, "BlockStatement", { + enumerable: true, + get: function () { + return _index.blockStatement; + } +}); +Object.defineProperty(exports, "BooleanLiteral", { + enumerable: true, + get: function () { + return _index.booleanLiteral; + } +}); +Object.defineProperty(exports, "BooleanLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.booleanLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "BooleanTypeAnnotation", { + enumerable: true, + get: function () { + return _index.booleanTypeAnnotation; + } +}); +Object.defineProperty(exports, "BreakStatement", { + enumerable: true, + get: function () { + return _index.breakStatement; + } +}); +Object.defineProperty(exports, "CallExpression", { + enumerable: true, + get: function () { + return _index.callExpression; + } +}); +Object.defineProperty(exports, "CatchClause", { + enumerable: true, + get: function () { + return _index.catchClause; + } +}); +Object.defineProperty(exports, "ClassAccessorProperty", { + enumerable: true, + get: function () { + return _index.classAccessorProperty; + } +}); +Object.defineProperty(exports, "ClassBody", { + enumerable: true, + get: function () { + return _index.classBody; + } +}); +Object.defineProperty(exports, "ClassDeclaration", { + enumerable: true, + get: function () { + return _index.classDeclaration; + } +}); +Object.defineProperty(exports, "ClassExpression", { + enumerable: true, + get: function () { + return _index.classExpression; + } +}); +Object.defineProperty(exports, "ClassImplements", { + enumerable: true, + get: function () { + return _index.classImplements; + } +}); +Object.defineProperty(exports, "ClassMethod", { + enumerable: true, + get: function () { + return _index.classMethod; + } +}); +Object.defineProperty(exports, "ClassPrivateMethod", { + enumerable: true, + get: function () { + return _index.classPrivateMethod; + } +}); +Object.defineProperty(exports, "ClassPrivateProperty", { + enumerable: true, + get: function () { + return _index.classPrivateProperty; + } +}); +Object.defineProperty(exports, "ClassProperty", { + enumerable: true, + get: function () { + return _index.classProperty; + } +}); +Object.defineProperty(exports, "ConditionalExpression", { + enumerable: true, + get: function () { + return _index.conditionalExpression; + } +}); +Object.defineProperty(exports, "ContinueStatement", { + enumerable: true, + get: function () { + return _index.continueStatement; + } +}); +Object.defineProperty(exports, "DebuggerStatement", { + enumerable: true, + get: function () { + return _index.debuggerStatement; + } +}); +Object.defineProperty(exports, "DecimalLiteral", { + enumerable: true, + get: function () { + return _index.decimalLiteral; + } +}); +Object.defineProperty(exports, "DeclareClass", { + enumerable: true, + get: function () { + return _index.declareClass; + } +}); +Object.defineProperty(exports, "DeclareExportAllDeclaration", { + enumerable: true, + get: function () { + return _index.declareExportAllDeclaration; + } +}); +Object.defineProperty(exports, "DeclareExportDeclaration", { + enumerable: true, + get: function () { + return _index.declareExportDeclaration; + } +}); +Object.defineProperty(exports, "DeclareFunction", { + enumerable: true, + get: function () { + return _index.declareFunction; + } +}); +Object.defineProperty(exports, "DeclareInterface", { + enumerable: true, + get: function () { + return _index.declareInterface; + } +}); +Object.defineProperty(exports, "DeclareModule", { + enumerable: true, + get: function () { + return _index.declareModule; + } +}); +Object.defineProperty(exports, "DeclareModuleExports", { + enumerable: true, + get: function () { + return _index.declareModuleExports; + } +}); +Object.defineProperty(exports, "DeclareOpaqueType", { + enumerable: true, + get: function () { + return _index.declareOpaqueType; + } +}); +Object.defineProperty(exports, "DeclareTypeAlias", { + enumerable: true, + get: function () { + return _index.declareTypeAlias; + } +}); +Object.defineProperty(exports, "DeclareVariable", { + enumerable: true, + get: function () { + return _index.declareVariable; + } +}); +Object.defineProperty(exports, "DeclaredPredicate", { + enumerable: true, + get: function () { + return _index.declaredPredicate; + } +}); +Object.defineProperty(exports, "Decorator", { + enumerable: true, + get: function () { + return _index.decorator; + } +}); +Object.defineProperty(exports, "Directive", { + enumerable: true, + get: function () { + return _index.directive; + } +}); +Object.defineProperty(exports, "DirectiveLiteral", { + enumerable: true, + get: function () { + return _index.directiveLiteral; + } +}); +Object.defineProperty(exports, "DoExpression", { + enumerable: true, + get: function () { + return _index.doExpression; + } +}); +Object.defineProperty(exports, "DoWhileStatement", { + enumerable: true, + get: function () { + return _index.doWhileStatement; + } +}); +Object.defineProperty(exports, "EmptyStatement", { + enumerable: true, + get: function () { + return _index.emptyStatement; + } +}); +Object.defineProperty(exports, "EmptyTypeAnnotation", { + enumerable: true, + get: function () { + return _index.emptyTypeAnnotation; + } +}); +Object.defineProperty(exports, "EnumBooleanBody", { + enumerable: true, + get: function () { + return _index.enumBooleanBody; + } +}); +Object.defineProperty(exports, "EnumBooleanMember", { + enumerable: true, + get: function () { + return _index.enumBooleanMember; + } +}); +Object.defineProperty(exports, "EnumDeclaration", { + enumerable: true, + get: function () { + return _index.enumDeclaration; + } +}); +Object.defineProperty(exports, "EnumDefaultedMember", { + enumerable: true, + get: function () { + return _index.enumDefaultedMember; + } +}); +Object.defineProperty(exports, "EnumNumberBody", { + enumerable: true, + get: function () { + return _index.enumNumberBody; + } +}); +Object.defineProperty(exports, "EnumNumberMember", { + enumerable: true, + get: function () { + return _index.enumNumberMember; + } +}); +Object.defineProperty(exports, "EnumStringBody", { + enumerable: true, + get: function () { + return _index.enumStringBody; + } +}); +Object.defineProperty(exports, "EnumStringMember", { + enumerable: true, + get: function () { + return _index.enumStringMember; + } +}); +Object.defineProperty(exports, "EnumSymbolBody", { + enumerable: true, + get: function () { + return _index.enumSymbolBody; + } +}); +Object.defineProperty(exports, "ExistsTypeAnnotation", { + enumerable: true, + get: function () { + return _index.existsTypeAnnotation; + } +}); +Object.defineProperty(exports, "ExportAllDeclaration", { + enumerable: true, + get: function () { + return _index.exportAllDeclaration; + } +}); +Object.defineProperty(exports, "ExportDefaultDeclaration", { + enumerable: true, + get: function () { + return _index.exportDefaultDeclaration; + } +}); +Object.defineProperty(exports, "ExportDefaultSpecifier", { + enumerable: true, + get: function () { + return _index.exportDefaultSpecifier; + } +}); +Object.defineProperty(exports, "ExportNamedDeclaration", { + enumerable: true, + get: function () { + return _index.exportNamedDeclaration; + } +}); +Object.defineProperty(exports, "ExportNamespaceSpecifier", { + enumerable: true, + get: function () { + return _index.exportNamespaceSpecifier; + } +}); +Object.defineProperty(exports, "ExportSpecifier", { + enumerable: true, + get: function () { + return _index.exportSpecifier; + } +}); +Object.defineProperty(exports, "ExpressionStatement", { + enumerable: true, + get: function () { + return _index.expressionStatement; + } +}); +Object.defineProperty(exports, "File", { + enumerable: true, + get: function () { + return _index.file; + } +}); +Object.defineProperty(exports, "ForInStatement", { + enumerable: true, + get: function () { + return _index.forInStatement; + } +}); +Object.defineProperty(exports, "ForOfStatement", { + enumerable: true, + get: function () { + return _index.forOfStatement; + } +}); +Object.defineProperty(exports, "ForStatement", { + enumerable: true, + get: function () { + return _index.forStatement; + } +}); +Object.defineProperty(exports, "FunctionDeclaration", { + enumerable: true, + get: function () { + return _index.functionDeclaration; + } +}); +Object.defineProperty(exports, "FunctionExpression", { + enumerable: true, + get: function () { + return _index.functionExpression; + } +}); +Object.defineProperty(exports, "FunctionTypeAnnotation", { + enumerable: true, + get: function () { + return _index.functionTypeAnnotation; + } +}); +Object.defineProperty(exports, "FunctionTypeParam", { + enumerable: true, + get: function () { + return _index.functionTypeParam; + } +}); +Object.defineProperty(exports, "GenericTypeAnnotation", { + enumerable: true, + get: function () { + return _index.genericTypeAnnotation; + } +}); +Object.defineProperty(exports, "Identifier", { + enumerable: true, + get: function () { + return _index.identifier; + } +}); +Object.defineProperty(exports, "IfStatement", { + enumerable: true, + get: function () { + return _index.ifStatement; + } +}); +Object.defineProperty(exports, "Import", { + enumerable: true, + get: function () { + return _index.import; + } +}); +Object.defineProperty(exports, "ImportAttribute", { + enumerable: true, + get: function () { + return _index.importAttribute; + } +}); +Object.defineProperty(exports, "ImportDeclaration", { + enumerable: true, + get: function () { + return _index.importDeclaration; + } +}); +Object.defineProperty(exports, "ImportDefaultSpecifier", { + enumerable: true, + get: function () { + return _index.importDefaultSpecifier; + } +}); +Object.defineProperty(exports, "ImportNamespaceSpecifier", { + enumerable: true, + get: function () { + return _index.importNamespaceSpecifier; + } +}); +Object.defineProperty(exports, "ImportSpecifier", { + enumerable: true, + get: function () { + return _index.importSpecifier; + } +}); +Object.defineProperty(exports, "IndexedAccessType", { + enumerable: true, + get: function () { + return _index.indexedAccessType; + } +}); +Object.defineProperty(exports, "InferredPredicate", { + enumerable: true, + get: function () { + return _index.inferredPredicate; + } +}); +Object.defineProperty(exports, "InterfaceDeclaration", { + enumerable: true, + get: function () { + return _index.interfaceDeclaration; + } +}); +Object.defineProperty(exports, "InterfaceExtends", { + enumerable: true, + get: function () { + return _index.interfaceExtends; + } +}); +Object.defineProperty(exports, "InterfaceTypeAnnotation", { + enumerable: true, + get: function () { + return _index.interfaceTypeAnnotation; + } +}); +Object.defineProperty(exports, "InterpreterDirective", { + enumerable: true, + get: function () { + return _index.interpreterDirective; + } +}); +Object.defineProperty(exports, "IntersectionTypeAnnotation", { + enumerable: true, + get: function () { + return _index.intersectionTypeAnnotation; + } +}); +Object.defineProperty(exports, "JSXAttribute", { + enumerable: true, + get: function () { + return _index.jsxAttribute; + } +}); +Object.defineProperty(exports, "JSXClosingElement", { + enumerable: true, + get: function () { + return _index.jsxClosingElement; + } +}); +Object.defineProperty(exports, "JSXClosingFragment", { + enumerable: true, + get: function () { + return _index.jsxClosingFragment; + } +}); +Object.defineProperty(exports, "JSXElement", { + enumerable: true, + get: function () { + return _index.jsxElement; + } +}); +Object.defineProperty(exports, "JSXEmptyExpression", { + enumerable: true, + get: function () { + return _index.jsxEmptyExpression; + } +}); +Object.defineProperty(exports, "JSXExpressionContainer", { + enumerable: true, + get: function () { + return _index.jsxExpressionContainer; + } +}); +Object.defineProperty(exports, "JSXFragment", { + enumerable: true, + get: function () { + return _index.jsxFragment; + } +}); +Object.defineProperty(exports, "JSXIdentifier", { + enumerable: true, + get: function () { + return _index.jsxIdentifier; + } +}); +Object.defineProperty(exports, "JSXMemberExpression", { + enumerable: true, + get: function () { + return _index.jsxMemberExpression; + } +}); +Object.defineProperty(exports, "JSXNamespacedName", { + enumerable: true, + get: function () { + return _index.jsxNamespacedName; + } +}); +Object.defineProperty(exports, "JSXOpeningElement", { + enumerable: true, + get: function () { + return _index.jsxOpeningElement; + } +}); +Object.defineProperty(exports, "JSXOpeningFragment", { + enumerable: true, + get: function () { + return _index.jsxOpeningFragment; + } +}); +Object.defineProperty(exports, "JSXSpreadAttribute", { + enumerable: true, + get: function () { + return _index.jsxSpreadAttribute; + } +}); +Object.defineProperty(exports, "JSXSpreadChild", { + enumerable: true, + get: function () { + return _index.jsxSpreadChild; + } +}); +Object.defineProperty(exports, "JSXText", { + enumerable: true, + get: function () { + return _index.jsxText; + } +}); +Object.defineProperty(exports, "LabeledStatement", { + enumerable: true, + get: function () { + return _index.labeledStatement; + } +}); +Object.defineProperty(exports, "LogicalExpression", { + enumerable: true, + get: function () { + return _index.logicalExpression; + } +}); +Object.defineProperty(exports, "MemberExpression", { + enumerable: true, + get: function () { + return _index.memberExpression; + } +}); +Object.defineProperty(exports, "MetaProperty", { + enumerable: true, + get: function () { + return _index.metaProperty; + } +}); +Object.defineProperty(exports, "MixedTypeAnnotation", { + enumerable: true, + get: function () { + return _index.mixedTypeAnnotation; + } +}); +Object.defineProperty(exports, "ModuleExpression", { + enumerable: true, + get: function () { + return _index.moduleExpression; + } +}); +Object.defineProperty(exports, "NewExpression", { + enumerable: true, + get: function () { + return _index.newExpression; + } +}); +Object.defineProperty(exports, "Noop", { + enumerable: true, + get: function () { + return _index.noop; + } +}); +Object.defineProperty(exports, "NullLiteral", { + enumerable: true, + get: function () { + return _index.nullLiteral; + } +}); +Object.defineProperty(exports, "NullLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.nullLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "NullableTypeAnnotation", { + enumerable: true, + get: function () { + return _index.nullableTypeAnnotation; + } +}); +Object.defineProperty(exports, "NumberLiteral", { + enumerable: true, + get: function () { + return _index.numberLiteral; + } +}); +Object.defineProperty(exports, "NumberLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.numberLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "NumberTypeAnnotation", { + enumerable: true, + get: function () { + return _index.numberTypeAnnotation; + } +}); +Object.defineProperty(exports, "NumericLiteral", { + enumerable: true, + get: function () { + return _index.numericLiteral; + } +}); +Object.defineProperty(exports, "ObjectExpression", { + enumerable: true, + get: function () { + return _index.objectExpression; + } +}); +Object.defineProperty(exports, "ObjectMethod", { + enumerable: true, + get: function () { + return _index.objectMethod; + } +}); +Object.defineProperty(exports, "ObjectPattern", { + enumerable: true, + get: function () { + return _index.objectPattern; + } +}); +Object.defineProperty(exports, "ObjectProperty", { + enumerable: true, + get: function () { + return _index.objectProperty; + } +}); +Object.defineProperty(exports, "ObjectTypeAnnotation", { + enumerable: true, + get: function () { + return _index.objectTypeAnnotation; + } +}); +Object.defineProperty(exports, "ObjectTypeCallProperty", { + enumerable: true, + get: function () { + return _index.objectTypeCallProperty; + } +}); +Object.defineProperty(exports, "ObjectTypeIndexer", { + enumerable: true, + get: function () { + return _index.objectTypeIndexer; + } +}); +Object.defineProperty(exports, "ObjectTypeInternalSlot", { + enumerable: true, + get: function () { + return _index.objectTypeInternalSlot; + } +}); +Object.defineProperty(exports, "ObjectTypeProperty", { + enumerable: true, + get: function () { + return _index.objectTypeProperty; + } +}); +Object.defineProperty(exports, "ObjectTypeSpreadProperty", { + enumerable: true, + get: function () { + return _index.objectTypeSpreadProperty; + } +}); +Object.defineProperty(exports, "OpaqueType", { + enumerable: true, + get: function () { + return _index.opaqueType; + } +}); +Object.defineProperty(exports, "OptionalCallExpression", { + enumerable: true, + get: function () { + return _index.optionalCallExpression; + } +}); +Object.defineProperty(exports, "OptionalIndexedAccessType", { + enumerable: true, + get: function () { + return _index.optionalIndexedAccessType; + } +}); +Object.defineProperty(exports, "OptionalMemberExpression", { + enumerable: true, + get: function () { + return _index.optionalMemberExpression; + } +}); +Object.defineProperty(exports, "ParenthesizedExpression", { + enumerable: true, + get: function () { + return _index.parenthesizedExpression; + } +}); +Object.defineProperty(exports, "PipelineBareFunction", { + enumerable: true, + get: function () { + return _index.pipelineBareFunction; + } +}); +Object.defineProperty(exports, "PipelinePrimaryTopicReference", { + enumerable: true, + get: function () { + return _index.pipelinePrimaryTopicReference; + } +}); +Object.defineProperty(exports, "PipelineTopicExpression", { + enumerable: true, + get: function () { + return _index.pipelineTopicExpression; + } +}); +Object.defineProperty(exports, "Placeholder", { + enumerable: true, + get: function () { + return _index.placeholder; + } +}); +Object.defineProperty(exports, "PrivateName", { + enumerable: true, + get: function () { + return _index.privateName; + } +}); +Object.defineProperty(exports, "Program", { + enumerable: true, + get: function () { + return _index.program; + } +}); +Object.defineProperty(exports, "QualifiedTypeIdentifier", { + enumerable: true, + get: function () { + return _index.qualifiedTypeIdentifier; + } +}); +Object.defineProperty(exports, "RecordExpression", { + enumerable: true, + get: function () { + return _index.recordExpression; + } +}); +Object.defineProperty(exports, "RegExpLiteral", { + enumerable: true, + get: function () { + return _index.regExpLiteral; + } +}); +Object.defineProperty(exports, "RegexLiteral", { + enumerable: true, + get: function () { + return _index.regexLiteral; + } +}); +Object.defineProperty(exports, "RestElement", { + enumerable: true, + get: function () { + return _index.restElement; + } +}); +Object.defineProperty(exports, "RestProperty", { + enumerable: true, + get: function () { + return _index.restProperty; + } +}); +Object.defineProperty(exports, "ReturnStatement", { + enumerable: true, + get: function () { + return _index.returnStatement; + } +}); +Object.defineProperty(exports, "SequenceExpression", { + enumerable: true, + get: function () { + return _index.sequenceExpression; + } +}); +Object.defineProperty(exports, "SpreadElement", { + enumerable: true, + get: function () { + return _index.spreadElement; + } +}); +Object.defineProperty(exports, "SpreadProperty", { + enumerable: true, + get: function () { + return _index.spreadProperty; + } +}); +Object.defineProperty(exports, "StaticBlock", { + enumerable: true, + get: function () { + return _index.staticBlock; + } +}); +Object.defineProperty(exports, "StringLiteral", { + enumerable: true, + get: function () { + return _index.stringLiteral; + } +}); +Object.defineProperty(exports, "StringLiteralTypeAnnotation", { + enumerable: true, + get: function () { + return _index.stringLiteralTypeAnnotation; + } +}); +Object.defineProperty(exports, "StringTypeAnnotation", { + enumerable: true, + get: function () { + return _index.stringTypeAnnotation; + } +}); +Object.defineProperty(exports, "Super", { + enumerable: true, + get: function () { + return _index.super; + } +}); +Object.defineProperty(exports, "SwitchCase", { + enumerable: true, + get: function () { + return _index.switchCase; + } +}); +Object.defineProperty(exports, "SwitchStatement", { + enumerable: true, + get: function () { + return _index.switchStatement; + } +}); +Object.defineProperty(exports, "SymbolTypeAnnotation", { + enumerable: true, + get: function () { + return _index.symbolTypeAnnotation; + } +}); +Object.defineProperty(exports, "TSAnyKeyword", { + enumerable: true, + get: function () { + return _index.tsAnyKeyword; + } +}); +Object.defineProperty(exports, "TSArrayType", { + enumerable: true, + get: function () { + return _index.tsArrayType; + } +}); +Object.defineProperty(exports, "TSAsExpression", { + enumerable: true, + get: function () { + return _index.tsAsExpression; + } +}); +Object.defineProperty(exports, "TSBigIntKeyword", { + enumerable: true, + get: function () { + return _index.tsBigIntKeyword; + } +}); +Object.defineProperty(exports, "TSBooleanKeyword", { + enumerable: true, + get: function () { + return _index.tsBooleanKeyword; + } +}); +Object.defineProperty(exports, "TSCallSignatureDeclaration", { + enumerable: true, + get: function () { + return _index.tsCallSignatureDeclaration; + } +}); +Object.defineProperty(exports, "TSConditionalType", { + enumerable: true, + get: function () { + return _index.tsConditionalType; + } +}); +Object.defineProperty(exports, "TSConstructSignatureDeclaration", { + enumerable: true, + get: function () { + return _index.tsConstructSignatureDeclaration; + } +}); +Object.defineProperty(exports, "TSConstructorType", { + enumerable: true, + get: function () { + return _index.tsConstructorType; + } +}); +Object.defineProperty(exports, "TSDeclareFunction", { + enumerable: true, + get: function () { + return _index.tsDeclareFunction; + } +}); +Object.defineProperty(exports, "TSDeclareMethod", { + enumerable: true, + get: function () { + return _index.tsDeclareMethod; + } +}); +Object.defineProperty(exports, "TSEnumDeclaration", { + enumerable: true, + get: function () { + return _index.tsEnumDeclaration; + } +}); +Object.defineProperty(exports, "TSEnumMember", { + enumerable: true, + get: function () { + return _index.tsEnumMember; + } +}); +Object.defineProperty(exports, "TSExportAssignment", { + enumerable: true, + get: function () { + return _index.tsExportAssignment; + } +}); +Object.defineProperty(exports, "TSExpressionWithTypeArguments", { + enumerable: true, + get: function () { + return _index.tsExpressionWithTypeArguments; + } +}); +Object.defineProperty(exports, "TSExternalModuleReference", { + enumerable: true, + get: function () { + return _index.tsExternalModuleReference; + } +}); +Object.defineProperty(exports, "TSFunctionType", { + enumerable: true, + get: function () { + return _index.tsFunctionType; + } +}); +Object.defineProperty(exports, "TSImportEqualsDeclaration", { + enumerable: true, + get: function () { + return _index.tsImportEqualsDeclaration; + } +}); +Object.defineProperty(exports, "TSImportType", { + enumerable: true, + get: function () { + return _index.tsImportType; + } +}); +Object.defineProperty(exports, "TSIndexSignature", { + enumerable: true, + get: function () { + return _index.tsIndexSignature; + } +}); +Object.defineProperty(exports, "TSIndexedAccessType", { + enumerable: true, + get: function () { + return _index.tsIndexedAccessType; + } +}); +Object.defineProperty(exports, "TSInferType", { + enumerable: true, + get: function () { + return _index.tsInferType; + } +}); +Object.defineProperty(exports, "TSInterfaceBody", { + enumerable: true, + get: function () { + return _index.tsInterfaceBody; + } +}); +Object.defineProperty(exports, "TSInterfaceDeclaration", { + enumerable: true, + get: function () { + return _index.tsInterfaceDeclaration; + } +}); +Object.defineProperty(exports, "TSIntersectionType", { + enumerable: true, + get: function () { + return _index.tsIntersectionType; + } +}); +Object.defineProperty(exports, "TSIntrinsicKeyword", { + enumerable: true, + get: function () { + return _index.tsIntrinsicKeyword; + } +}); +Object.defineProperty(exports, "TSLiteralType", { + enumerable: true, + get: function () { + return _index.tsLiteralType; + } +}); +Object.defineProperty(exports, "TSMappedType", { + enumerable: true, + get: function () { + return _index.tsMappedType; + } +}); +Object.defineProperty(exports, "TSMethodSignature", { + enumerable: true, + get: function () { + return _index.tsMethodSignature; + } +}); +Object.defineProperty(exports, "TSModuleBlock", { + enumerable: true, + get: function () { + return _index.tsModuleBlock; + } +}); +Object.defineProperty(exports, "TSModuleDeclaration", { + enumerable: true, + get: function () { + return _index.tsModuleDeclaration; + } +}); +Object.defineProperty(exports, "TSNamedTupleMember", { + enumerable: true, + get: function () { + return _index.tsNamedTupleMember; + } +}); +Object.defineProperty(exports, "TSNamespaceExportDeclaration", { + enumerable: true, + get: function () { + return _index.tsNamespaceExportDeclaration; + } +}); +Object.defineProperty(exports, "TSNeverKeyword", { + enumerable: true, + get: function () { + return _index.tsNeverKeyword; + } +}); +Object.defineProperty(exports, "TSNonNullExpression", { + enumerable: true, + get: function () { + return _index.tsNonNullExpression; + } +}); +Object.defineProperty(exports, "TSNullKeyword", { + enumerable: true, + get: function () { + return _index.tsNullKeyword; + } +}); +Object.defineProperty(exports, "TSNumberKeyword", { + enumerable: true, + get: function () { + return _index.tsNumberKeyword; + } +}); +Object.defineProperty(exports, "TSObjectKeyword", { + enumerable: true, + get: function () { + return _index.tsObjectKeyword; + } +}); +Object.defineProperty(exports, "TSOptionalType", { + enumerable: true, + get: function () { + return _index.tsOptionalType; + } +}); +Object.defineProperty(exports, "TSParameterProperty", { + enumerable: true, + get: function () { + return _index.tsParameterProperty; + } +}); +Object.defineProperty(exports, "TSParenthesizedType", { + enumerable: true, + get: function () { + return _index.tsParenthesizedType; + } +}); +Object.defineProperty(exports, "TSPropertySignature", { + enumerable: true, + get: function () { + return _index.tsPropertySignature; + } +}); +Object.defineProperty(exports, "TSQualifiedName", { + enumerable: true, + get: function () { + return _index.tsQualifiedName; + } +}); +Object.defineProperty(exports, "TSRestType", { + enumerable: true, + get: function () { + return _index.tsRestType; + } +}); +Object.defineProperty(exports, "TSStringKeyword", { + enumerable: true, + get: function () { + return _index.tsStringKeyword; + } +}); +Object.defineProperty(exports, "TSSymbolKeyword", { + enumerable: true, + get: function () { + return _index.tsSymbolKeyword; + } +}); +Object.defineProperty(exports, "TSThisType", { + enumerable: true, + get: function () { + return _index.tsThisType; + } +}); +Object.defineProperty(exports, "TSTupleType", { + enumerable: true, + get: function () { + return _index.tsTupleType; + } +}); +Object.defineProperty(exports, "TSTypeAliasDeclaration", { + enumerable: true, + get: function () { + return _index.tsTypeAliasDeclaration; + } +}); +Object.defineProperty(exports, "TSTypeAnnotation", { + enumerable: true, + get: function () { + return _index.tsTypeAnnotation; + } +}); +Object.defineProperty(exports, "TSTypeAssertion", { + enumerable: true, + get: function () { + return _index.tsTypeAssertion; + } +}); +Object.defineProperty(exports, "TSTypeLiteral", { + enumerable: true, + get: function () { + return _index.tsTypeLiteral; + } +}); +Object.defineProperty(exports, "TSTypeOperator", { + enumerable: true, + get: function () { + return _index.tsTypeOperator; + } +}); +Object.defineProperty(exports, "TSTypeParameter", { + enumerable: true, + get: function () { + return _index.tsTypeParameter; + } +}); +Object.defineProperty(exports, "TSTypeParameterDeclaration", { + enumerable: true, + get: function () { + return _index.tsTypeParameterDeclaration; + } +}); +Object.defineProperty(exports, "TSTypeParameterInstantiation", { + enumerable: true, + get: function () { + return _index.tsTypeParameterInstantiation; + } +}); +Object.defineProperty(exports, "TSTypePredicate", { + enumerable: true, + get: function () { + return _index.tsTypePredicate; + } +}); +Object.defineProperty(exports, "TSTypeQuery", { + enumerable: true, + get: function () { + return _index.tsTypeQuery; + } +}); +Object.defineProperty(exports, "TSTypeReference", { + enumerable: true, + get: function () { + return _index.tsTypeReference; + } +}); +Object.defineProperty(exports, "TSUndefinedKeyword", { + enumerable: true, + get: function () { + return _index.tsUndefinedKeyword; + } +}); +Object.defineProperty(exports, "TSUnionType", { + enumerable: true, + get: function () { + return _index.tsUnionType; + } +}); +Object.defineProperty(exports, "TSUnknownKeyword", { + enumerable: true, + get: function () { + return _index.tsUnknownKeyword; + } +}); +Object.defineProperty(exports, "TSVoidKeyword", { + enumerable: true, + get: function () { + return _index.tsVoidKeyword; + } +}); +Object.defineProperty(exports, "TaggedTemplateExpression", { + enumerable: true, + get: function () { + return _index.taggedTemplateExpression; + } +}); +Object.defineProperty(exports, "TemplateElement", { + enumerable: true, + get: function () { + return _index.templateElement; + } +}); +Object.defineProperty(exports, "TemplateLiteral", { + enumerable: true, + get: function () { + return _index.templateLiteral; + } +}); +Object.defineProperty(exports, "ThisExpression", { + enumerable: true, + get: function () { + return _index.thisExpression; + } +}); +Object.defineProperty(exports, "ThisTypeAnnotation", { + enumerable: true, + get: function () { + return _index.thisTypeAnnotation; + } +}); +Object.defineProperty(exports, "ThrowStatement", { + enumerable: true, + get: function () { + return _index.throwStatement; + } +}); +Object.defineProperty(exports, "TopicReference", { + enumerable: true, + get: function () { + return _index.topicReference; + } +}); +Object.defineProperty(exports, "TryStatement", { + enumerable: true, + get: function () { + return _index.tryStatement; + } +}); +Object.defineProperty(exports, "TupleExpression", { + enumerable: true, + get: function () { + return _index.tupleExpression; + } +}); +Object.defineProperty(exports, "TupleTypeAnnotation", { + enumerable: true, + get: function () { + return _index.tupleTypeAnnotation; + } +}); +Object.defineProperty(exports, "TypeAlias", { + enumerable: true, + get: function () { + return _index.typeAlias; + } +}); +Object.defineProperty(exports, "TypeAnnotation", { + enumerable: true, + get: function () { + return _index.typeAnnotation; + } +}); +Object.defineProperty(exports, "TypeCastExpression", { + enumerable: true, + get: function () { + return _index.typeCastExpression; + } +}); +Object.defineProperty(exports, "TypeParameter", { + enumerable: true, + get: function () { + return _index.typeParameter; + } +}); +Object.defineProperty(exports, "TypeParameterDeclaration", { + enumerable: true, + get: function () { + return _index.typeParameterDeclaration; + } +}); +Object.defineProperty(exports, "TypeParameterInstantiation", { + enumerable: true, + get: function () { + return _index.typeParameterInstantiation; + } +}); +Object.defineProperty(exports, "TypeofTypeAnnotation", { + enumerable: true, + get: function () { + return _index.typeofTypeAnnotation; + } +}); +Object.defineProperty(exports, "UnaryExpression", { + enumerable: true, + get: function () { + return _index.unaryExpression; + } +}); +Object.defineProperty(exports, "UnionTypeAnnotation", { + enumerable: true, + get: function () { + return _index.unionTypeAnnotation; + } +}); +Object.defineProperty(exports, "UpdateExpression", { + enumerable: true, + get: function () { + return _index.updateExpression; + } +}); +Object.defineProperty(exports, "V8IntrinsicIdentifier", { + enumerable: true, + get: function () { + return _index.v8IntrinsicIdentifier; + } +}); +Object.defineProperty(exports, "VariableDeclaration", { + enumerable: true, + get: function () { + return _index.variableDeclaration; + } +}); +Object.defineProperty(exports, "VariableDeclarator", { + enumerable: true, + get: function () { + return _index.variableDeclarator; + } +}); +Object.defineProperty(exports, "Variance", { + enumerable: true, + get: function () { + return _index.variance; + } +}); +Object.defineProperty(exports, "VoidTypeAnnotation", { + enumerable: true, + get: function () { + return _index.voidTypeAnnotation; + } +}); +Object.defineProperty(exports, "WhileStatement", { + enumerable: true, + get: function () { + return _index.whileStatement; + } +}); +Object.defineProperty(exports, "WithStatement", { + enumerable: true, + get: function () { + return _index.withStatement; + } +}); +Object.defineProperty(exports, "YieldExpression", { + enumerable: true, + get: function () { + return _index.yieldExpression; + } +}); + +var _index = require("./index"); \ No newline at end of file diff --git a/node_modules/tap/node_modules/@babel/types/lib/constants/generated/index.js b/node_modules/tap/node_modules/@babel/types/lib/constants/generated/index.js new file mode 100644 index 000000000..1e109e6a4 --- /dev/null +++ b/node_modules/tap/node_modules/@babel/types/lib/constants/generated/index.js @@ -0,0 +1,107 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.WHILE_TYPES = exports.USERWHITESPACABLE_TYPES = exports.UNARYLIKE_TYPES = exports.TYPESCRIPT_TYPES = exports.TSTYPE_TYPES = exports.TSTYPEELEMENT_TYPES = exports.TSENTITYNAME_TYPES = exports.TSBASETYPE_TYPES = exports.TERMINATORLESS_TYPES = exports.STATEMENT_TYPES = exports.STANDARDIZED_TYPES = exports.SCOPABLE_TYPES = exports.PUREISH_TYPES = exports.PROPERTY_TYPES = exports.PRIVATE_TYPES = exports.PATTERN_TYPES = exports.PATTERNLIKE_TYPES = exports.OBJECTMEMBER_TYPES = exports.MODULESPECIFIER_TYPES = exports.MODULEDECLARATION_TYPES = exports.MISCELLANEOUS_TYPES = exports.METHOD_TYPES = exports.LVAL_TYPES = exports.LOOP_TYPES = exports.LITERAL_TYPES = exports.JSX_TYPES = exports.IMMUTABLE_TYPES = exports.FUNCTION_TYPES = exports.FUNCTIONPARENT_TYPES = exports.FOR_TYPES = exports.FORXSTATEMENT_TYPES = exports.FLOW_TYPES = exports.FLOWTYPE_TYPES = exports.FLOWPREDICATE_TYPES = exports.FLOWDECLARATION_TYPES = exports.FLOWBASEANNOTATION_TYPES = exports.EXPRESSION_TYPES = exports.EXPRESSIONWRAPPER_TYPES = exports.EXPORTDECLARATION_TYPES = exports.ENUMMEMBER_TYPES = exports.ENUMBODY_TYPES = exports.DECLARATION_TYPES = exports.CONDITIONAL_TYPES = exports.COMPLETIONSTATEMENT_TYPES = exports.CLASS_TYPES = exports.BLOCK_TYPES = exports.BLOCKPARENT_TYPES = exports.BINARY_TYPES = exports.ACCESSOR_TYPES = void 0; + +var _definitions = require("../../definitions"); + +const STANDARDIZED_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Standardized"]; +exports.STANDARDIZED_TYPES = STANDARDIZED_TYPES; +const EXPRESSION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Expression"]; +exports.EXPRESSION_TYPES = EXPRESSION_TYPES; +const BINARY_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Binary"]; +exports.BINARY_TYPES = BINARY_TYPES; +const SCOPABLE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Scopable"]; +exports.SCOPABLE_TYPES = SCOPABLE_TYPES; +const BLOCKPARENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["BlockParent"]; +exports.BLOCKPARENT_TYPES = BLOCKPARENT_TYPES; +const BLOCK_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Block"]; +exports.BLOCK_TYPES = BLOCK_TYPES; +const STATEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Statement"]; +exports.STATEMENT_TYPES = STATEMENT_TYPES; +const TERMINATORLESS_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Terminatorless"]; +exports.TERMINATORLESS_TYPES = TERMINATORLESS_TYPES; +const COMPLETIONSTATEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["CompletionStatement"]; +exports.COMPLETIONSTATEMENT_TYPES = COMPLETIONSTATEMENT_TYPES; +const CONDITIONAL_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Conditional"]; +exports.CONDITIONAL_TYPES = CONDITIONAL_TYPES; +const LOOP_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Loop"]; +exports.LOOP_TYPES = LOOP_TYPES; +const WHILE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["While"]; +exports.WHILE_TYPES = WHILE_TYPES; +const EXPRESSIONWRAPPER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ExpressionWrapper"]; +exports.EXPRESSIONWRAPPER_TYPES = EXPRESSIONWRAPPER_TYPES; +const FOR_TYPES = _definitions.FLIPPED_ALIAS_KEYS["For"]; +exports.FOR_TYPES = FOR_TYPES; +const FORXSTATEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ForXStatement"]; +exports.FORXSTATEMENT_TYPES = FORXSTATEMENT_TYPES; +const FUNCTION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Function"]; +exports.FUNCTION_TYPES = FUNCTION_TYPES; +const FUNCTIONPARENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FunctionParent"]; +exports.FUNCTIONPARENT_TYPES = FUNCTIONPARENT_TYPES; +const PUREISH_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Pureish"]; +exports.PUREISH_TYPES = PUREISH_TYPES; +const DECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Declaration"]; +exports.DECLARATION_TYPES = DECLARATION_TYPES; +const PATTERNLIKE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["PatternLike"]; +exports.PATTERNLIKE_TYPES = PATTERNLIKE_TYPES; +const LVAL_TYPES = _definitions.FLIPPED_ALIAS_KEYS["LVal"]; +exports.LVAL_TYPES = LVAL_TYPES; +const TSENTITYNAME_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSEntityName"]; +exports.TSENTITYNAME_TYPES = TSENTITYNAME_TYPES; +const LITERAL_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Literal"]; +exports.LITERAL_TYPES = LITERAL_TYPES; +const IMMUTABLE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Immutable"]; +exports.IMMUTABLE_TYPES = IMMUTABLE_TYPES; +const USERWHITESPACABLE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["UserWhitespacable"]; +exports.USERWHITESPACABLE_TYPES = USERWHITESPACABLE_TYPES; +const METHOD_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Method"]; +exports.METHOD_TYPES = METHOD_TYPES; +const OBJECTMEMBER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ObjectMember"]; +exports.OBJECTMEMBER_TYPES = OBJECTMEMBER_TYPES; +const PROPERTY_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Property"]; +exports.PROPERTY_TYPES = PROPERTY_TYPES; +const UNARYLIKE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["UnaryLike"]; +exports.UNARYLIKE_TYPES = UNARYLIKE_TYPES; +const PATTERN_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Pattern"]; +exports.PATTERN_TYPES = PATTERN_TYPES; +const CLASS_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Class"]; +exports.CLASS_TYPES = CLASS_TYPES; +const MODULEDECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ModuleDeclaration"]; +exports.MODULEDECLARATION_TYPES = MODULEDECLARATION_TYPES; +const EXPORTDECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ExportDeclaration"]; +exports.EXPORTDECLARATION_TYPES = EXPORTDECLARATION_TYPES; +const MODULESPECIFIER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ModuleSpecifier"]; +exports.MODULESPECIFIER_TYPES = MODULESPECIFIER_TYPES; +const ACCESSOR_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Accessor"]; +exports.ACCESSOR_TYPES = ACCESSOR_TYPES; +const PRIVATE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Private"]; +exports.PRIVATE_TYPES = PRIVATE_TYPES; +const FLOW_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Flow"]; +exports.FLOW_TYPES = FLOW_TYPES; +const FLOWTYPE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowType"]; +exports.FLOWTYPE_TYPES = FLOWTYPE_TYPES; +const FLOWBASEANNOTATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowBaseAnnotation"]; +exports.FLOWBASEANNOTATION_TYPES = FLOWBASEANNOTATION_TYPES; +const FLOWDECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowDeclaration"]; +exports.FLOWDECLARATION_TYPES = FLOWDECLARATION_TYPES; +const FLOWPREDICATE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowPredicate"]; +exports.FLOWPREDICATE_TYPES = FLOWPREDICATE_TYPES; +const ENUMBODY_TYPES = _definitions.FLIPPED_ALIAS_KEYS["EnumBody"]; +exports.ENUMBODY_TYPES = ENUMBODY_TYPES; +const ENUMMEMBER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["EnumMember"]; +exports.ENUMMEMBER_TYPES = ENUMMEMBER_TYPES; +const JSX_TYPES = _definitions.FLIPPED_ALIAS_KEYS["JSX"]; +exports.JSX_TYPES = JSX_TYPES; +const MISCELLANEOUS_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Miscellaneous"]; +exports.MISCELLANEOUS_TYPES = MISCELLANEOUS_TYPES; +const TYPESCRIPT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TypeScript"]; +exports.TYPESCRIPT_TYPES = TYPESCRIPT_TYPES; +const TSTYPEELEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSTypeElement"]; +exports.TSTYPEELEMENT_TYPES = TSTYPEELEMENT_TYPES; +const TSTYPE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSType"]; +exports.TSTYPE_TYPES = TSTYPE_TYPES; +const TSBASETYPE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSBaseType"]; +exports.TSBASETYPE_TYPES = TSBASETYPE_TYPES; \ No newline at end of file diff --git a/node_modules/tap/node_modules/@babel/types/lib/validators/generated/index.js b/node_modules/tap/node_modules/@babel/types/lib/validators/generated/index.js new file mode 100644 index 000000000..f2956ec01 --- /dev/null +++ b/node_modules/tap/node_modules/@babel/types/lib/validators/generated/index.js @@ -0,0 +1,4811 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.isAccessor = isAccessor; +exports.isAnyTypeAnnotation = isAnyTypeAnnotation; +exports.isArgumentPlaceholder = isArgumentPlaceholder; +exports.isArrayExpression = isArrayExpression; +exports.isArrayPattern = isArrayPattern; +exports.isArrayTypeAnnotation = isArrayTypeAnnotation; +exports.isArrowFunctionExpression = isArrowFunctionExpression; +exports.isAssignmentExpression = isAssignmentExpression; +exports.isAssignmentPattern = isAssignmentPattern; +exports.isAwaitExpression = isAwaitExpression; +exports.isBigIntLiteral = isBigIntLiteral; +exports.isBinary = isBinary; +exports.isBinaryExpression = isBinaryExpression; +exports.isBindExpression = isBindExpression; +exports.isBlock = isBlock; +exports.isBlockParent = isBlockParent; +exports.isBlockStatement = isBlockStatement; +exports.isBooleanLiteral = isBooleanLiteral; +exports.isBooleanLiteralTypeAnnotation = isBooleanLiteralTypeAnnotation; +exports.isBooleanTypeAnnotation = isBooleanTypeAnnotation; +exports.isBreakStatement = isBreakStatement; +exports.isCallExpression = isCallExpression; +exports.isCatchClause = isCatchClause; +exports.isClass = isClass; +exports.isClassAccessorProperty = isClassAccessorProperty; +exports.isClassBody = isClassBody; +exports.isClassDeclaration = isClassDeclaration; +exports.isClassExpression = isClassExpression; +exports.isClassImplements = isClassImplements; +exports.isClassMethod = isClassMethod; +exports.isClassPrivateMethod = isClassPrivateMethod; +exports.isClassPrivateProperty = isClassPrivateProperty; +exports.isClassProperty = isClassProperty; +exports.isCompletionStatement = isCompletionStatement; +exports.isConditional = isConditional; +exports.isConditionalExpression = isConditionalExpression; +exports.isContinueStatement = isContinueStatement; +exports.isDebuggerStatement = isDebuggerStatement; +exports.isDecimalLiteral = isDecimalLiteral; +exports.isDeclaration = isDeclaration; +exports.isDeclareClass = isDeclareClass; +exports.isDeclareExportAllDeclaration = isDeclareExportAllDeclaration; +exports.isDeclareExportDeclaration = isDeclareExportDeclaration; +exports.isDeclareFunction = isDeclareFunction; +exports.isDeclareInterface = isDeclareInterface; +exports.isDeclareModule = isDeclareModule; +exports.isDeclareModuleExports = isDeclareModuleExports; +exports.isDeclareOpaqueType = isDeclareOpaqueType; +exports.isDeclareTypeAlias = isDeclareTypeAlias; +exports.isDeclareVariable = isDeclareVariable; +exports.isDeclaredPredicate = isDeclaredPredicate; +exports.isDecorator = isDecorator; +exports.isDirective = isDirective; +exports.isDirectiveLiteral = isDirectiveLiteral; +exports.isDoExpression = isDoExpression; +exports.isDoWhileStatement = isDoWhileStatement; +exports.isEmptyStatement = isEmptyStatement; +exports.isEmptyTypeAnnotation = isEmptyTypeAnnotation; +exports.isEnumBody = isEnumBody; +exports.isEnumBooleanBody = isEnumBooleanBody; +exports.isEnumBooleanMember = isEnumBooleanMember; +exports.isEnumDeclaration = isEnumDeclaration; +exports.isEnumDefaultedMember = isEnumDefaultedMember; +exports.isEnumMember = isEnumMember; +exports.isEnumNumberBody = isEnumNumberBody; +exports.isEnumNumberMember = isEnumNumberMember; +exports.isEnumStringBody = isEnumStringBody; +exports.isEnumStringMember = isEnumStringMember; +exports.isEnumSymbolBody = isEnumSymbolBody; +exports.isExistsTypeAnnotation = isExistsTypeAnnotation; +exports.isExportAllDeclaration = isExportAllDeclaration; +exports.isExportDeclaration = isExportDeclaration; +exports.isExportDefaultDeclaration = isExportDefaultDeclaration; +exports.isExportDefaultSpecifier = isExportDefaultSpecifier; +exports.isExportNamedDeclaration = isExportNamedDeclaration; +exports.isExportNamespaceSpecifier = isExportNamespaceSpecifier; +exports.isExportSpecifier = isExportSpecifier; +exports.isExpression = isExpression; +exports.isExpressionStatement = isExpressionStatement; +exports.isExpressionWrapper = isExpressionWrapper; +exports.isFile = isFile; +exports.isFlow = isFlow; +exports.isFlowBaseAnnotation = isFlowBaseAnnotation; +exports.isFlowDeclaration = isFlowDeclaration; +exports.isFlowPredicate = isFlowPredicate; +exports.isFlowType = isFlowType; +exports.isFor = isFor; +exports.isForInStatement = isForInStatement; +exports.isForOfStatement = isForOfStatement; +exports.isForStatement = isForStatement; +exports.isForXStatement = isForXStatement; +exports.isFunction = isFunction; +exports.isFunctionDeclaration = isFunctionDeclaration; +exports.isFunctionExpression = isFunctionExpression; +exports.isFunctionParent = isFunctionParent; +exports.isFunctionTypeAnnotation = isFunctionTypeAnnotation; +exports.isFunctionTypeParam = isFunctionTypeParam; +exports.isGenericTypeAnnotation = isGenericTypeAnnotation; +exports.isIdentifier = isIdentifier; +exports.isIfStatement = isIfStatement; +exports.isImmutable = isImmutable; +exports.isImport = isImport; +exports.isImportAttribute = isImportAttribute; +exports.isImportDeclaration = isImportDeclaration; +exports.isImportDefaultSpecifier = isImportDefaultSpecifier; +exports.isImportNamespaceSpecifier = isImportNamespaceSpecifier; +exports.isImportSpecifier = isImportSpecifier; +exports.isIndexedAccessType = isIndexedAccessType; +exports.isInferredPredicate = isInferredPredicate; +exports.isInterfaceDeclaration = isInterfaceDeclaration; +exports.isInterfaceExtends = isInterfaceExtends; +exports.isInterfaceTypeAnnotation = isInterfaceTypeAnnotation; +exports.isInterpreterDirective = isInterpreterDirective; +exports.isIntersectionTypeAnnotation = isIntersectionTypeAnnotation; +exports.isJSX = isJSX; +exports.isJSXAttribute = isJSXAttribute; +exports.isJSXClosingElement = isJSXClosingElement; +exports.isJSXClosingFragment = isJSXClosingFragment; +exports.isJSXElement = isJSXElement; +exports.isJSXEmptyExpression = isJSXEmptyExpression; +exports.isJSXExpressionContainer = isJSXExpressionContainer; +exports.isJSXFragment = isJSXFragment; +exports.isJSXIdentifier = isJSXIdentifier; +exports.isJSXMemberExpression = isJSXMemberExpression; +exports.isJSXNamespacedName = isJSXNamespacedName; +exports.isJSXOpeningElement = isJSXOpeningElement; +exports.isJSXOpeningFragment = isJSXOpeningFragment; +exports.isJSXSpreadAttribute = isJSXSpreadAttribute; +exports.isJSXSpreadChild = isJSXSpreadChild; +exports.isJSXText = isJSXText; +exports.isLVal = isLVal; +exports.isLabeledStatement = isLabeledStatement; +exports.isLiteral = isLiteral; +exports.isLogicalExpression = isLogicalExpression; +exports.isLoop = isLoop; +exports.isMemberExpression = isMemberExpression; +exports.isMetaProperty = isMetaProperty; +exports.isMethod = isMethod; +exports.isMiscellaneous = isMiscellaneous; +exports.isMixedTypeAnnotation = isMixedTypeAnnotation; +exports.isModuleDeclaration = isModuleDeclaration; +exports.isModuleExpression = isModuleExpression; +exports.isModuleSpecifier = isModuleSpecifier; +exports.isNewExpression = isNewExpression; +exports.isNoop = isNoop; +exports.isNullLiteral = isNullLiteral; +exports.isNullLiteralTypeAnnotation = isNullLiteralTypeAnnotation; +exports.isNullableTypeAnnotation = isNullableTypeAnnotation; +exports.isNumberLiteral = isNumberLiteral; +exports.isNumberLiteralTypeAnnotation = isNumberLiteralTypeAnnotation; +exports.isNumberTypeAnnotation = isNumberTypeAnnotation; +exports.isNumericLiteral = isNumericLiteral; +exports.isObjectExpression = isObjectExpression; +exports.isObjectMember = isObjectMember; +exports.isObjectMethod = isObjectMethod; +exports.isObjectPattern = isObjectPattern; +exports.isObjectProperty = isObjectProperty; +exports.isObjectTypeAnnotation = isObjectTypeAnnotation; +exports.isObjectTypeCallProperty = isObjectTypeCallProperty; +exports.isObjectTypeIndexer = isObjectTypeIndexer; +exports.isObjectTypeInternalSlot = isObjectTypeInternalSlot; +exports.isObjectTypeProperty = isObjectTypeProperty; +exports.isObjectTypeSpreadProperty = isObjectTypeSpreadProperty; +exports.isOpaqueType = isOpaqueType; +exports.isOptionalCallExpression = isOptionalCallExpression; +exports.isOptionalIndexedAccessType = isOptionalIndexedAccessType; +exports.isOptionalMemberExpression = isOptionalMemberExpression; +exports.isParenthesizedExpression = isParenthesizedExpression; +exports.isPattern = isPattern; +exports.isPatternLike = isPatternLike; +exports.isPipelineBareFunction = isPipelineBareFunction; +exports.isPipelinePrimaryTopicReference = isPipelinePrimaryTopicReference; +exports.isPipelineTopicExpression = isPipelineTopicExpression; +exports.isPlaceholder = isPlaceholder; +exports.isPrivate = isPrivate; +exports.isPrivateName = isPrivateName; +exports.isProgram = isProgram; +exports.isProperty = isProperty; +exports.isPureish = isPureish; +exports.isQualifiedTypeIdentifier = isQualifiedTypeIdentifier; +exports.isRecordExpression = isRecordExpression; +exports.isRegExpLiteral = isRegExpLiteral; +exports.isRegexLiteral = isRegexLiteral; +exports.isRestElement = isRestElement; +exports.isRestProperty = isRestProperty; +exports.isReturnStatement = isReturnStatement; +exports.isScopable = isScopable; +exports.isSequenceExpression = isSequenceExpression; +exports.isSpreadElement = isSpreadElement; +exports.isSpreadProperty = isSpreadProperty; +exports.isStandardized = isStandardized; +exports.isStatement = isStatement; +exports.isStaticBlock = isStaticBlock; +exports.isStringLiteral = isStringLiteral; +exports.isStringLiteralTypeAnnotation = isStringLiteralTypeAnnotation; +exports.isStringTypeAnnotation = isStringTypeAnnotation; +exports.isSuper = isSuper; +exports.isSwitchCase = isSwitchCase; +exports.isSwitchStatement = isSwitchStatement; +exports.isSymbolTypeAnnotation = isSymbolTypeAnnotation; +exports.isTSAnyKeyword = isTSAnyKeyword; +exports.isTSArrayType = isTSArrayType; +exports.isTSAsExpression = isTSAsExpression; +exports.isTSBaseType = isTSBaseType; +exports.isTSBigIntKeyword = isTSBigIntKeyword; +exports.isTSBooleanKeyword = isTSBooleanKeyword; +exports.isTSCallSignatureDeclaration = isTSCallSignatureDeclaration; +exports.isTSConditionalType = isTSConditionalType; +exports.isTSConstructSignatureDeclaration = isTSConstructSignatureDeclaration; +exports.isTSConstructorType = isTSConstructorType; +exports.isTSDeclareFunction = isTSDeclareFunction; +exports.isTSDeclareMethod = isTSDeclareMethod; +exports.isTSEntityName = isTSEntityName; +exports.isTSEnumDeclaration = isTSEnumDeclaration; +exports.isTSEnumMember = isTSEnumMember; +exports.isTSExportAssignment = isTSExportAssignment; +exports.isTSExpressionWithTypeArguments = isTSExpressionWithTypeArguments; +exports.isTSExternalModuleReference = isTSExternalModuleReference; +exports.isTSFunctionType = isTSFunctionType; +exports.isTSImportEqualsDeclaration = isTSImportEqualsDeclaration; +exports.isTSImportType = isTSImportType; +exports.isTSIndexSignature = isTSIndexSignature; +exports.isTSIndexedAccessType = isTSIndexedAccessType; +exports.isTSInferType = isTSInferType; +exports.isTSInterfaceBody = isTSInterfaceBody; +exports.isTSInterfaceDeclaration = isTSInterfaceDeclaration; +exports.isTSIntersectionType = isTSIntersectionType; +exports.isTSIntrinsicKeyword = isTSIntrinsicKeyword; +exports.isTSLiteralType = isTSLiteralType; +exports.isTSMappedType = isTSMappedType; +exports.isTSMethodSignature = isTSMethodSignature; +exports.isTSModuleBlock = isTSModuleBlock; +exports.isTSModuleDeclaration = isTSModuleDeclaration; +exports.isTSNamedTupleMember = isTSNamedTupleMember; +exports.isTSNamespaceExportDeclaration = isTSNamespaceExportDeclaration; +exports.isTSNeverKeyword = isTSNeverKeyword; +exports.isTSNonNullExpression = isTSNonNullExpression; +exports.isTSNullKeyword = isTSNullKeyword; +exports.isTSNumberKeyword = isTSNumberKeyword; +exports.isTSObjectKeyword = isTSObjectKeyword; +exports.isTSOptionalType = isTSOptionalType; +exports.isTSParameterProperty = isTSParameterProperty; +exports.isTSParenthesizedType = isTSParenthesizedType; +exports.isTSPropertySignature = isTSPropertySignature; +exports.isTSQualifiedName = isTSQualifiedName; +exports.isTSRestType = isTSRestType; +exports.isTSStringKeyword = isTSStringKeyword; +exports.isTSSymbolKeyword = isTSSymbolKeyword; +exports.isTSThisType = isTSThisType; +exports.isTSTupleType = isTSTupleType; +exports.isTSType = isTSType; +exports.isTSTypeAliasDeclaration = isTSTypeAliasDeclaration; +exports.isTSTypeAnnotation = isTSTypeAnnotation; +exports.isTSTypeAssertion = isTSTypeAssertion; +exports.isTSTypeElement = isTSTypeElement; +exports.isTSTypeLiteral = isTSTypeLiteral; +exports.isTSTypeOperator = isTSTypeOperator; +exports.isTSTypeParameter = isTSTypeParameter; +exports.isTSTypeParameterDeclaration = isTSTypeParameterDeclaration; +exports.isTSTypeParameterInstantiation = isTSTypeParameterInstantiation; +exports.isTSTypePredicate = isTSTypePredicate; +exports.isTSTypeQuery = isTSTypeQuery; +exports.isTSTypeReference = isTSTypeReference; +exports.isTSUndefinedKeyword = isTSUndefinedKeyword; +exports.isTSUnionType = isTSUnionType; +exports.isTSUnknownKeyword = isTSUnknownKeyword; +exports.isTSVoidKeyword = isTSVoidKeyword; +exports.isTaggedTemplateExpression = isTaggedTemplateExpression; +exports.isTemplateElement = isTemplateElement; +exports.isTemplateLiteral = isTemplateLiteral; +exports.isTerminatorless = isTerminatorless; +exports.isThisExpression = isThisExpression; +exports.isThisTypeAnnotation = isThisTypeAnnotation; +exports.isThrowStatement = isThrowStatement; +exports.isTopicReference = isTopicReference; +exports.isTryStatement = isTryStatement; +exports.isTupleExpression = isTupleExpression; +exports.isTupleTypeAnnotation = isTupleTypeAnnotation; +exports.isTypeAlias = isTypeAlias; +exports.isTypeAnnotation = isTypeAnnotation; +exports.isTypeCastExpression = isTypeCastExpression; +exports.isTypeParameter = isTypeParameter; +exports.isTypeParameterDeclaration = isTypeParameterDeclaration; +exports.isTypeParameterInstantiation = isTypeParameterInstantiation; +exports.isTypeScript = isTypeScript; +exports.isTypeofTypeAnnotation = isTypeofTypeAnnotation; +exports.isUnaryExpression = isUnaryExpression; +exports.isUnaryLike = isUnaryLike; +exports.isUnionTypeAnnotation = isUnionTypeAnnotation; +exports.isUpdateExpression = isUpdateExpression; +exports.isUserWhitespacable = isUserWhitespacable; +exports.isV8IntrinsicIdentifier = isV8IntrinsicIdentifier; +exports.isVariableDeclaration = isVariableDeclaration; +exports.isVariableDeclarator = isVariableDeclarator; +exports.isVariance = isVariance; +exports.isVoidTypeAnnotation = isVoidTypeAnnotation; +exports.isWhile = isWhile; +exports.isWhileStatement = isWhileStatement; +exports.isWithStatement = isWithStatement; +exports.isYieldExpression = isYieldExpression; + +var _shallowEqual = require("../../utils/shallowEqual"); + +function isArrayExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrayExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAssignmentExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AssignmentExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBinaryExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BinaryExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterpreterDirective(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterpreterDirective") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDirective(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Directive") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDirectiveLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DirectiveLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBlockStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BlockStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBreakStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BreakStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isCallExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "CallExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isCatchClause(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "CatchClause") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isConditionalExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ConditionalExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isContinueStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ContinueStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDebuggerStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DebuggerStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDoWhileStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DoWhileStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEmptyStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EmptyStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExpressionStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExpressionStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFile(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "File") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForInStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ForInStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ForStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Identifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIfStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "IfStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLabeledStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "LabeledStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStringLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StringLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumericLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumericLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNullLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NullLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBooleanLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BooleanLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRegExpLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RegExpLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLogicalExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "LogicalExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMemberExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "MemberExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNewExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NewExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isProgram(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Program") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRestElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RestElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isReturnStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ReturnStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSequenceExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SequenceExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isParenthesizedExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ParenthesizedExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSwitchCase(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SwitchCase") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSwitchStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SwitchStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isThisExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ThisExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isThrowStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ThrowStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTryStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TryStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUnaryExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "UnaryExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUpdateExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "UpdateExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVariableDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "VariableDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVariableDeclarator(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "VariableDeclarator") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isWhileStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "WhileStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isWithStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "WithStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAssignmentPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AssignmentPattern") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArrayPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrayPattern") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArrowFunctionExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrowFunctionExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportAllDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportAllDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportDefaultDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportDefaultDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportNamedDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportNamedDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForOfStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ForOfStatement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportDefaultSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportDefaultSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportNamespaceSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportNamespaceSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMetaProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "MetaProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectPattern") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSpreadElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SpreadElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSuper(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Super") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTaggedTemplateExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TaggedTemplateExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTemplateElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TemplateElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTemplateLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TemplateLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isYieldExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "YieldExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAwaitExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AwaitExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImport(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Import") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBigIntLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BigIntLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportNamespaceSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportNamespaceSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOptionalMemberExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OptionalMemberExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOptionalCallExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OptionalCallExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassAccessorProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassAccessorProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassPrivateProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassPrivateProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassPrivateMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassPrivateMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPrivateName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PrivateName") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStaticBlock(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StaticBlock") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAnyTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "AnyTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArrayTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArrayTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBooleanTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BooleanTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBooleanLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BooleanLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNullLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NullLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClassImplements(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ClassImplements") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareClass(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareClass") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareFunction") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareInterface(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareInterface") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareModule(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareModule") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareModuleExports(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareModuleExports") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareTypeAlias(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareTypeAlias") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareOpaqueType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareOpaqueType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareVariable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareVariable") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareExportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareExportDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclareExportAllDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclareExportAllDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclaredPredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DeclaredPredicate") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExistsTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExistsTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionTypeParam(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "FunctionTypeParam") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isGenericTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "GenericTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInferredPredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InferredPredicate") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterfaceExtends(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterfaceExtends") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterfaceDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterfaceDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isInterfaceTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "InterfaceTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIntersectionTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "IntersectionTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMixedTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "MixedTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEmptyTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EmptyTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNullableTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NullableTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumberLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumberLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumberTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumberTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeInternalSlot(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeInternalSlot") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeCallProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeCallProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeIndexer(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeIndexer") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectTypeSpreadProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ObjectTypeSpreadProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOpaqueType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OpaqueType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isQualifiedTypeIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "QualifiedTypeIdentifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStringLiteralTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StringLiteralTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStringTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "StringTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSymbolTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SymbolTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isThisTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ThisTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTupleTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TupleTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeofTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeofTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeAlias(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeAlias") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeCastExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeCastExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeParameter(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeParameter") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeParameterDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeParameterDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeParameterInstantiation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TypeParameterInstantiation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUnionTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "UnionTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVariance(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Variance") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isVoidTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "VoidTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumBooleanBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumBooleanBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumNumberBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumNumberBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumStringBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumStringBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumSymbolBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumSymbolBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumBooleanMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumBooleanMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumNumberMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumNumberMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumStringMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumStringMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumDefaultedMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "EnumDefaultedMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isIndexedAccessType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "IndexedAccessType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isOptionalIndexedAccessType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "OptionalIndexedAccessType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXAttribute(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXAttribute") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXClosingElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXClosingElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXEmptyExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXEmptyExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXExpressionContainer(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXExpressionContainer") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXSpreadChild(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXSpreadChild") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXIdentifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXMemberExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXMemberExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXNamespacedName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXNamespacedName") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXOpeningElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXOpeningElement") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXSpreadAttribute(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXSpreadAttribute") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXText(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXText") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXFragment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXFragment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXOpeningFragment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXOpeningFragment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSXClosingFragment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "JSXClosingFragment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNoop(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Noop") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPlaceholder(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Placeholder") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isV8IntrinsicIdentifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "V8IntrinsicIdentifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isArgumentPlaceholder(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ArgumentPlaceholder") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBindExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "BindExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImportAttribute(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ImportAttribute") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDecorator(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "Decorator") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDoExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DoExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportDefaultSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ExportDefaultSpecifier") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRecordExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RecordExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTupleExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TupleExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDecimalLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "DecimalLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isModuleExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "ModuleExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTopicReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TopicReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPipelineTopicExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PipelineTopicExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPipelineBareFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PipelineBareFunction") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPipelinePrimaryTopicReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "PipelinePrimaryTopicReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSParameterProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSParameterProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSDeclareFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSDeclareFunction") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSDeclareMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSDeclareMethod") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSQualifiedName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSQualifiedName") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSCallSignatureDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSCallSignatureDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSConstructSignatureDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSConstructSignatureDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSPropertySignature(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSPropertySignature") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSMethodSignature(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSMethodSignature") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIndexSignature(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIndexSignature") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSAnyKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSAnyKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSBooleanKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSBooleanKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSBigIntKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSBigIntKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIntrinsicKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIntrinsicKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNeverKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNeverKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNullKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNullKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNumberKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNumberKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSObjectKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSObjectKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSStringKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSStringKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSSymbolKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSSymbolKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSUndefinedKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSUndefinedKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSUnknownKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSUnknownKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSVoidKeyword(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSVoidKeyword") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSThisType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSThisType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSFunctionType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSFunctionType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSConstructorType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSConstructorType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypePredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypePredicate") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeQuery(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeQuery") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSArrayType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSArrayType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTupleType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTupleType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSOptionalType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSOptionalType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSRestType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSRestType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNamedTupleMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNamedTupleMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSUnionType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSUnionType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIntersectionType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIntersectionType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSConditionalType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSConditionalType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSInferType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSInferType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSParenthesizedType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSParenthesizedType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeOperator(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeOperator") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSIndexedAccessType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSIndexedAccessType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSMappedType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSMappedType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSLiteralType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSLiteralType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSExpressionWithTypeArguments(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSExpressionWithTypeArguments") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSInterfaceDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSInterfaceDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSInterfaceBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSInterfaceBody") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeAliasDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeAliasDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSAsExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSAsExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeAssertion(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeAssertion") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSEnumDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSEnumDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSEnumMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSEnumMember") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSModuleDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSModuleDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSModuleBlock(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSModuleBlock") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSImportType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSImportType") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSImportEqualsDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSImportEqualsDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSExternalModuleReference(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSExternalModuleReference") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNonNullExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNonNullExpression") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSExportAssignment(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSExportAssignment") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSNamespaceExportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSNamespaceExportDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeAnnotation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeParameterInstantiation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeParameterInstantiation") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeParameterDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeParameterDeclaration") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeParameter(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "TSTypeParameter") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStandardized(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ArrayExpression" === nodeType || "AssignmentExpression" === nodeType || "BinaryExpression" === nodeType || "InterpreterDirective" === nodeType || "Directive" === nodeType || "DirectiveLiteral" === nodeType || "BlockStatement" === nodeType || "BreakStatement" === nodeType || "CallExpression" === nodeType || "CatchClause" === nodeType || "ConditionalExpression" === nodeType || "ContinueStatement" === nodeType || "DebuggerStatement" === nodeType || "DoWhileStatement" === nodeType || "EmptyStatement" === nodeType || "ExpressionStatement" === nodeType || "File" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "Identifier" === nodeType || "IfStatement" === nodeType || "LabeledStatement" === nodeType || "StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "LogicalExpression" === nodeType || "MemberExpression" === nodeType || "NewExpression" === nodeType || "Program" === nodeType || "ObjectExpression" === nodeType || "ObjectMethod" === nodeType || "ObjectProperty" === nodeType || "RestElement" === nodeType || "ReturnStatement" === nodeType || "SequenceExpression" === nodeType || "ParenthesizedExpression" === nodeType || "SwitchCase" === nodeType || "SwitchStatement" === nodeType || "ThisExpression" === nodeType || "ThrowStatement" === nodeType || "TryStatement" === nodeType || "UnaryExpression" === nodeType || "UpdateExpression" === nodeType || "VariableDeclaration" === nodeType || "VariableDeclarator" === nodeType || "WhileStatement" === nodeType || "WithStatement" === nodeType || "AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassBody" === nodeType || "ClassExpression" === nodeType || "ClassDeclaration" === nodeType || "ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ExportSpecifier" === nodeType || "ForOfStatement" === nodeType || "ImportDeclaration" === nodeType || "ImportDefaultSpecifier" === nodeType || "ImportNamespaceSpecifier" === nodeType || "ImportSpecifier" === nodeType || "MetaProperty" === nodeType || "ClassMethod" === nodeType || "ObjectPattern" === nodeType || "SpreadElement" === nodeType || "Super" === nodeType || "TaggedTemplateExpression" === nodeType || "TemplateElement" === nodeType || "TemplateLiteral" === nodeType || "YieldExpression" === nodeType || "AwaitExpression" === nodeType || "Import" === nodeType || "BigIntLiteral" === nodeType || "ExportNamespaceSpecifier" === nodeType || "OptionalMemberExpression" === nodeType || "OptionalCallExpression" === nodeType || "ClassProperty" === nodeType || "ClassAccessorProperty" === nodeType || "ClassPrivateProperty" === nodeType || "ClassPrivateMethod" === nodeType || "PrivateName" === nodeType || "StaticBlock" === nodeType || nodeType === "Placeholder" && ("Identifier" === node.expectedNode || "StringLiteral" === node.expectedNode || "BlockStatement" === node.expectedNode || "ClassBody" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExpression(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ArrayExpression" === nodeType || "AssignmentExpression" === nodeType || "BinaryExpression" === nodeType || "CallExpression" === nodeType || "ConditionalExpression" === nodeType || "FunctionExpression" === nodeType || "Identifier" === nodeType || "StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "LogicalExpression" === nodeType || "MemberExpression" === nodeType || "NewExpression" === nodeType || "ObjectExpression" === nodeType || "SequenceExpression" === nodeType || "ParenthesizedExpression" === nodeType || "ThisExpression" === nodeType || "UnaryExpression" === nodeType || "UpdateExpression" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassExpression" === nodeType || "MetaProperty" === nodeType || "Super" === nodeType || "TaggedTemplateExpression" === nodeType || "TemplateLiteral" === nodeType || "YieldExpression" === nodeType || "AwaitExpression" === nodeType || "Import" === nodeType || "BigIntLiteral" === nodeType || "OptionalMemberExpression" === nodeType || "OptionalCallExpression" === nodeType || "TypeCastExpression" === nodeType || "JSXElement" === nodeType || "JSXFragment" === nodeType || "BindExpression" === nodeType || "DoExpression" === nodeType || "RecordExpression" === nodeType || "TupleExpression" === nodeType || "DecimalLiteral" === nodeType || "ModuleExpression" === nodeType || "TopicReference" === nodeType || "PipelineTopicExpression" === nodeType || "PipelineBareFunction" === nodeType || "PipelinePrimaryTopicReference" === nodeType || "TSAsExpression" === nodeType || "TSTypeAssertion" === nodeType || "TSNonNullExpression" === nodeType || nodeType === "Placeholder" && ("Expression" === node.expectedNode || "Identifier" === node.expectedNode || "StringLiteral" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBinary(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BinaryExpression" === nodeType || "LogicalExpression" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isScopable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "CatchClause" === nodeType || "DoWhileStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "Program" === nodeType || "ObjectMethod" === nodeType || "SwitchStatement" === nodeType || "WhileStatement" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassExpression" === nodeType || "ClassDeclaration" === nodeType || "ForOfStatement" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType || "StaticBlock" === nodeType || "TSModuleBlock" === nodeType || nodeType === "Placeholder" && "BlockStatement" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBlockParent(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "CatchClause" === nodeType || "DoWhileStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "Program" === nodeType || "ObjectMethod" === nodeType || "SwitchStatement" === nodeType || "WhileStatement" === nodeType || "ArrowFunctionExpression" === nodeType || "ForOfStatement" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType || "StaticBlock" === nodeType || "TSModuleBlock" === nodeType || nodeType === "Placeholder" && "BlockStatement" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isBlock(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "Program" === nodeType || "TSModuleBlock" === nodeType || nodeType === "Placeholder" && "BlockStatement" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BlockStatement" === nodeType || "BreakStatement" === nodeType || "ContinueStatement" === nodeType || "DebuggerStatement" === nodeType || "DoWhileStatement" === nodeType || "EmptyStatement" === nodeType || "ExpressionStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "IfStatement" === nodeType || "LabeledStatement" === nodeType || "ReturnStatement" === nodeType || "SwitchStatement" === nodeType || "ThrowStatement" === nodeType || "TryStatement" === nodeType || "VariableDeclaration" === nodeType || "WhileStatement" === nodeType || "WithStatement" === nodeType || "ClassDeclaration" === nodeType || "ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ForOfStatement" === nodeType || "ImportDeclaration" === nodeType || "DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "InterfaceDeclaration" === nodeType || "OpaqueType" === nodeType || "TypeAlias" === nodeType || "EnumDeclaration" === nodeType || "TSDeclareFunction" === nodeType || "TSInterfaceDeclaration" === nodeType || "TSTypeAliasDeclaration" === nodeType || "TSEnumDeclaration" === nodeType || "TSModuleDeclaration" === nodeType || "TSImportEqualsDeclaration" === nodeType || "TSExportAssignment" === nodeType || "TSNamespaceExportDeclaration" === nodeType || nodeType === "Placeholder" && ("Statement" === node.expectedNode || "Declaration" === node.expectedNode || "BlockStatement" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTerminatorless(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BreakStatement" === nodeType || "ContinueStatement" === nodeType || "ReturnStatement" === nodeType || "ThrowStatement" === nodeType || "YieldExpression" === nodeType || "AwaitExpression" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isCompletionStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("BreakStatement" === nodeType || "ContinueStatement" === nodeType || "ReturnStatement" === nodeType || "ThrowStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isConditional(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ConditionalExpression" === nodeType || "IfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLoop(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DoWhileStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "WhileStatement" === nodeType || "ForOfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isWhile(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DoWhileStatement" === nodeType || "WhileStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExpressionWrapper(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExpressionStatement" === nodeType || "ParenthesizedExpression" === nodeType || "TypeCastExpression" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFor(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ForInStatement" === nodeType || "ForStatement" === nodeType || "ForOfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isForXStatement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ForInStatement" === nodeType || "ForOfStatement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunction(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "ObjectMethod" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFunctionParent(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "ObjectMethod" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType || "StaticBlock" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPureish(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "ArrowFunctionExpression" === nodeType || "BigIntLiteral" === nodeType || "DecimalLiteral" === nodeType || nodeType === "Placeholder" && "StringLiteral" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("FunctionDeclaration" === nodeType || "VariableDeclaration" === nodeType || "ClassDeclaration" === nodeType || "ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ImportDeclaration" === nodeType || "DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "InterfaceDeclaration" === nodeType || "OpaqueType" === nodeType || "TypeAlias" === nodeType || "EnumDeclaration" === nodeType || "TSDeclareFunction" === nodeType || "TSInterfaceDeclaration" === nodeType || "TSTypeAliasDeclaration" === nodeType || "TSEnumDeclaration" === nodeType || "TSModuleDeclaration" === nodeType || nodeType === "Placeholder" && "Declaration" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPatternLike(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Identifier" === nodeType || "RestElement" === nodeType || "AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ObjectPattern" === nodeType || nodeType === "Placeholder" && ("Pattern" === node.expectedNode || "Identifier" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLVal(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Identifier" === nodeType || "MemberExpression" === nodeType || "RestElement" === nodeType || "AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ObjectPattern" === nodeType || "TSParameterProperty" === nodeType || nodeType === "Placeholder" && ("Pattern" === node.expectedNode || "Identifier" === node.expectedNode)) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSEntityName(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Identifier" === nodeType || "TSQualifiedName" === nodeType || nodeType === "Placeholder" && "Identifier" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isLiteral(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "TemplateLiteral" === nodeType || "BigIntLiteral" === nodeType || "DecimalLiteral" === nodeType || nodeType === "Placeholder" && "StringLiteral" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isImmutable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "BigIntLiteral" === nodeType || "JSXAttribute" === nodeType || "JSXClosingElement" === nodeType || "JSXElement" === nodeType || "JSXExpressionContainer" === nodeType || "JSXSpreadChild" === nodeType || "JSXOpeningElement" === nodeType || "JSXText" === nodeType || "JSXFragment" === nodeType || "JSXOpeningFragment" === nodeType || "JSXClosingFragment" === nodeType || "DecimalLiteral" === nodeType || nodeType === "Placeholder" && "StringLiteral" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUserWhitespacable(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectMethod" === nodeType || "ObjectProperty" === nodeType || "ObjectTypeInternalSlot" === nodeType || "ObjectTypeCallProperty" === nodeType || "ObjectTypeIndexer" === nodeType || "ObjectTypeProperty" === nodeType || "ObjectTypeSpreadProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMethod(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectMethod" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isObjectMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectMethod" === nodeType || "ObjectProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isProperty(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ObjectProperty" === nodeType || "ClassProperty" === nodeType || "ClassAccessorProperty" === nodeType || "ClassPrivateProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isUnaryLike(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("UnaryExpression" === nodeType || "SpreadElement" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPattern(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ObjectPattern" === nodeType || nodeType === "Placeholder" && "Pattern" === node.expectedNode) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isClass(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ClassExpression" === nodeType || "ClassDeclaration" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isModuleDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ImportDeclaration" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isExportDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isModuleSpecifier(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ExportSpecifier" === nodeType || "ImportDefaultSpecifier" === nodeType || "ImportNamespaceSpecifier" === nodeType || "ImportSpecifier" === nodeType || "ExportNamespaceSpecifier" === nodeType || "ExportDefaultSpecifier" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isAccessor(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ClassAccessorProperty" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isPrivate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("ClassPrivateProperty" === nodeType || "ClassPrivateMethod" === nodeType || "PrivateName" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlow(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AnyTypeAnnotation" === nodeType || "ArrayTypeAnnotation" === nodeType || "BooleanTypeAnnotation" === nodeType || "BooleanLiteralTypeAnnotation" === nodeType || "NullLiteralTypeAnnotation" === nodeType || "ClassImplements" === nodeType || "DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "DeclaredPredicate" === nodeType || "ExistsTypeAnnotation" === nodeType || "FunctionTypeAnnotation" === nodeType || "FunctionTypeParam" === nodeType || "GenericTypeAnnotation" === nodeType || "InferredPredicate" === nodeType || "InterfaceExtends" === nodeType || "InterfaceDeclaration" === nodeType || "InterfaceTypeAnnotation" === nodeType || "IntersectionTypeAnnotation" === nodeType || "MixedTypeAnnotation" === nodeType || "EmptyTypeAnnotation" === nodeType || "NullableTypeAnnotation" === nodeType || "NumberLiteralTypeAnnotation" === nodeType || "NumberTypeAnnotation" === nodeType || "ObjectTypeAnnotation" === nodeType || "ObjectTypeInternalSlot" === nodeType || "ObjectTypeCallProperty" === nodeType || "ObjectTypeIndexer" === nodeType || "ObjectTypeProperty" === nodeType || "ObjectTypeSpreadProperty" === nodeType || "OpaqueType" === nodeType || "QualifiedTypeIdentifier" === nodeType || "StringLiteralTypeAnnotation" === nodeType || "StringTypeAnnotation" === nodeType || "SymbolTypeAnnotation" === nodeType || "ThisTypeAnnotation" === nodeType || "TupleTypeAnnotation" === nodeType || "TypeofTypeAnnotation" === nodeType || "TypeAlias" === nodeType || "TypeAnnotation" === nodeType || "TypeCastExpression" === nodeType || "TypeParameter" === nodeType || "TypeParameterDeclaration" === nodeType || "TypeParameterInstantiation" === nodeType || "UnionTypeAnnotation" === nodeType || "Variance" === nodeType || "VoidTypeAnnotation" === nodeType || "EnumDeclaration" === nodeType || "EnumBooleanBody" === nodeType || "EnumNumberBody" === nodeType || "EnumStringBody" === nodeType || "EnumSymbolBody" === nodeType || "EnumBooleanMember" === nodeType || "EnumNumberMember" === nodeType || "EnumStringMember" === nodeType || "EnumDefaultedMember" === nodeType || "IndexedAccessType" === nodeType || "OptionalIndexedAccessType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AnyTypeAnnotation" === nodeType || "ArrayTypeAnnotation" === nodeType || "BooleanTypeAnnotation" === nodeType || "BooleanLiteralTypeAnnotation" === nodeType || "NullLiteralTypeAnnotation" === nodeType || "ExistsTypeAnnotation" === nodeType || "FunctionTypeAnnotation" === nodeType || "GenericTypeAnnotation" === nodeType || "InterfaceTypeAnnotation" === nodeType || "IntersectionTypeAnnotation" === nodeType || "MixedTypeAnnotation" === nodeType || "EmptyTypeAnnotation" === nodeType || "NullableTypeAnnotation" === nodeType || "NumberLiteralTypeAnnotation" === nodeType || "NumberTypeAnnotation" === nodeType || "ObjectTypeAnnotation" === nodeType || "StringLiteralTypeAnnotation" === nodeType || "StringTypeAnnotation" === nodeType || "SymbolTypeAnnotation" === nodeType || "ThisTypeAnnotation" === nodeType || "TupleTypeAnnotation" === nodeType || "TypeofTypeAnnotation" === nodeType || "UnionTypeAnnotation" === nodeType || "VoidTypeAnnotation" === nodeType || "IndexedAccessType" === nodeType || "OptionalIndexedAccessType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowBaseAnnotation(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("AnyTypeAnnotation" === nodeType || "BooleanTypeAnnotation" === nodeType || "NullLiteralTypeAnnotation" === nodeType || "MixedTypeAnnotation" === nodeType || "EmptyTypeAnnotation" === nodeType || "NumberTypeAnnotation" === nodeType || "StringTypeAnnotation" === nodeType || "SymbolTypeAnnotation" === nodeType || "ThisTypeAnnotation" === nodeType || "VoidTypeAnnotation" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowDeclaration(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "InterfaceDeclaration" === nodeType || "OpaqueType" === nodeType || "TypeAlias" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isFlowPredicate(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("DeclaredPredicate" === nodeType || "InferredPredicate" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumBody(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("EnumBooleanBody" === nodeType || "EnumNumberBody" === nodeType || "EnumStringBody" === nodeType || "EnumSymbolBody" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isEnumMember(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("EnumBooleanMember" === nodeType || "EnumNumberMember" === nodeType || "EnumStringMember" === nodeType || "EnumDefaultedMember" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isJSX(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("JSXAttribute" === nodeType || "JSXClosingElement" === nodeType || "JSXElement" === nodeType || "JSXEmptyExpression" === nodeType || "JSXExpressionContainer" === nodeType || "JSXSpreadChild" === nodeType || "JSXIdentifier" === nodeType || "JSXMemberExpression" === nodeType || "JSXNamespacedName" === nodeType || "JSXOpeningElement" === nodeType || "JSXSpreadAttribute" === nodeType || "JSXText" === nodeType || "JSXFragment" === nodeType || "JSXOpeningFragment" === nodeType || "JSXClosingFragment" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isMiscellaneous(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("Noop" === nodeType || "Placeholder" === nodeType || "V8IntrinsicIdentifier" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTypeScript(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSParameterProperty" === nodeType || "TSDeclareFunction" === nodeType || "TSDeclareMethod" === nodeType || "TSQualifiedName" === nodeType || "TSCallSignatureDeclaration" === nodeType || "TSConstructSignatureDeclaration" === nodeType || "TSPropertySignature" === nodeType || "TSMethodSignature" === nodeType || "TSIndexSignature" === nodeType || "TSAnyKeyword" === nodeType || "TSBooleanKeyword" === nodeType || "TSBigIntKeyword" === nodeType || "TSIntrinsicKeyword" === nodeType || "TSNeverKeyword" === nodeType || "TSNullKeyword" === nodeType || "TSNumberKeyword" === nodeType || "TSObjectKeyword" === nodeType || "TSStringKeyword" === nodeType || "TSSymbolKeyword" === nodeType || "TSUndefinedKeyword" === nodeType || "TSUnknownKeyword" === nodeType || "TSVoidKeyword" === nodeType || "TSThisType" === nodeType || "TSFunctionType" === nodeType || "TSConstructorType" === nodeType || "TSTypeReference" === nodeType || "TSTypePredicate" === nodeType || "TSTypeQuery" === nodeType || "TSTypeLiteral" === nodeType || "TSArrayType" === nodeType || "TSTupleType" === nodeType || "TSOptionalType" === nodeType || "TSRestType" === nodeType || "TSNamedTupleMember" === nodeType || "TSUnionType" === nodeType || "TSIntersectionType" === nodeType || "TSConditionalType" === nodeType || "TSInferType" === nodeType || "TSParenthesizedType" === nodeType || "TSTypeOperator" === nodeType || "TSIndexedAccessType" === nodeType || "TSMappedType" === nodeType || "TSLiteralType" === nodeType || "TSExpressionWithTypeArguments" === nodeType || "TSInterfaceDeclaration" === nodeType || "TSInterfaceBody" === nodeType || "TSTypeAliasDeclaration" === nodeType || "TSAsExpression" === nodeType || "TSTypeAssertion" === nodeType || "TSEnumDeclaration" === nodeType || "TSEnumMember" === nodeType || "TSModuleDeclaration" === nodeType || "TSModuleBlock" === nodeType || "TSImportType" === nodeType || "TSImportEqualsDeclaration" === nodeType || "TSExternalModuleReference" === nodeType || "TSNonNullExpression" === nodeType || "TSExportAssignment" === nodeType || "TSNamespaceExportDeclaration" === nodeType || "TSTypeAnnotation" === nodeType || "TSTypeParameterInstantiation" === nodeType || "TSTypeParameterDeclaration" === nodeType || "TSTypeParameter" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSTypeElement(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSCallSignatureDeclaration" === nodeType || "TSConstructSignatureDeclaration" === nodeType || "TSPropertySignature" === nodeType || "TSMethodSignature" === nodeType || "TSIndexSignature" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSAnyKeyword" === nodeType || "TSBooleanKeyword" === nodeType || "TSBigIntKeyword" === nodeType || "TSIntrinsicKeyword" === nodeType || "TSNeverKeyword" === nodeType || "TSNullKeyword" === nodeType || "TSNumberKeyword" === nodeType || "TSObjectKeyword" === nodeType || "TSStringKeyword" === nodeType || "TSSymbolKeyword" === nodeType || "TSUndefinedKeyword" === nodeType || "TSUnknownKeyword" === nodeType || "TSVoidKeyword" === nodeType || "TSThisType" === nodeType || "TSFunctionType" === nodeType || "TSConstructorType" === nodeType || "TSTypeReference" === nodeType || "TSTypePredicate" === nodeType || "TSTypeQuery" === nodeType || "TSTypeLiteral" === nodeType || "TSArrayType" === nodeType || "TSTupleType" === nodeType || "TSOptionalType" === nodeType || "TSRestType" === nodeType || "TSUnionType" === nodeType || "TSIntersectionType" === nodeType || "TSConditionalType" === nodeType || "TSInferType" === nodeType || "TSParenthesizedType" === nodeType || "TSTypeOperator" === nodeType || "TSIndexedAccessType" === nodeType || "TSMappedType" === nodeType || "TSLiteralType" === nodeType || "TSExpressionWithTypeArguments" === nodeType || "TSImportType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isTSBaseType(node, opts) { + if (!node) return false; + const nodeType = node.type; + + if ("TSAnyKeyword" === nodeType || "TSBooleanKeyword" === nodeType || "TSBigIntKeyword" === nodeType || "TSIntrinsicKeyword" === nodeType || "TSNeverKeyword" === nodeType || "TSNullKeyword" === nodeType || "TSNumberKeyword" === nodeType || "TSObjectKeyword" === nodeType || "TSStringKeyword" === nodeType || "TSSymbolKeyword" === nodeType || "TSUndefinedKeyword" === nodeType || "TSUnknownKeyword" === nodeType || "TSVoidKeyword" === nodeType || "TSThisType" === nodeType || "TSLiteralType" === nodeType) { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isNumberLiteral(node, opts) { + console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "NumberLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRegexLiteral(node, opts) { + console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RegexLiteral") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isRestProperty(node, opts) { + console.trace("The node type RestProperty has been renamed to RestElement"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "RestProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} + +function isSpreadProperty(node, opts) { + console.trace("The node type SpreadProperty has been renamed to SpreadElement"); + if (!node) return false; + const nodeType = node.type; + + if (nodeType === "SpreadProperty") { + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } + } + + return false; +} \ No newline at end of file diff --git a/node_modules/workerpool/src/generated/embeddedWorker.js b/node_modules/workerpool/src/generated/embeddedWorker.js new file mode 100644 index 000000000..eac758495 --- /dev/null +++ b/node_modules/workerpool/src/generated/embeddedWorker.js @@ -0,0 +1,6 @@ +/** + * embeddedWorker.js contains an embedded version of worker.js. + * This file is automatically generated, + * changes made in this file will be overwritten. + */ +module.exports = "!function(){var __webpack_exports__={};!function(){var exports=__webpack_exports__,__webpack_unused_export__;function _typeof(r){return(_typeof=\"function\"==typeof Symbol&&\"symbol\"==typeof Symbol.iterator?function(r){return typeof r}:function(r){return r&&\"function\"==typeof Symbol&&r.constructor===Symbol&&r!==Symbol.prototype?\"symbol\":typeof r})(r)}var requireFoolWebpack=eval(\"typeof require !== 'undefined' ? require : function (module) { throw new Error('Module \\\" + module + \\\" not found.') }\"),TERMINATE_METHOD_ID=\"__workerpool-terminate__\",worker={exit:function(){}},WorkerThreads,parentPort;if(\"undefined\"!=typeof self&&\"function\"==typeof postMessage&&\"function\"==typeof addEventListener)worker.on=function(r,e){addEventListener(r,function(r){e(r.data)})},worker.send=function(r){postMessage(r)};else{if(\"undefined\"==typeof process)throw new Error(\"Script must be executed as a worker\");try{WorkerThreads=requireFoolWebpack(\"worker_threads\")}catch(error){if(\"object\"!==_typeof(error)||null===error||\"MODULE_NOT_FOUND\"!==error.code)throw error}WorkerThreads&&null!==WorkerThreads.parentPort?(parentPort=WorkerThreads.parentPort,worker.send=parentPort.postMessage.bind(parentPort),worker.on=parentPort.on.bind(parentPort)):(worker.on=process.on.bind(process),worker.send=process.send.bind(process),worker.on(\"disconnect\",function(){process.exit(1)}),worker.exit=process.exit.bind(process))}function convertError(o){return Object.getOwnPropertyNames(o).reduce(function(r,e){return Object.defineProperty(r,e,{value:o[e],enumerable:!0})},{})}function isPromise(r){return r&&\"function\"==typeof r.then&&\"function\"==typeof r.catch}worker.methods={},worker.methods.run=function(r,e){r=new Function(\"return (\"+r+\").apply(null, arguments);\");return r.apply(r,e)},worker.methods.methods=function(){return Object.keys(worker.methods)};var currentRequestId=null;worker.on(\"message\",function(e){if(e===TERMINATE_METHOD_ID)return worker.exit(0);try{var r=worker.methods[e.method];if(!r)throw new Error('Unknown method \"'+e.method+'\"');currentRequestId=e.id;var o=r.apply(r,e.params);isPromise(o)?o.then(function(r){worker.send({id:e.id,result:r,error:null}),currentRequestId=null}).catch(function(r){worker.send({id:e.id,result:null,error:convertError(r)}),currentRequestId=null}):(worker.send({id:e.id,result:o,error:null}),currentRequestId=null)}catch(r){worker.send({id:e.id,result:null,error:convertError(r)})}}),worker.register=function(r){if(r)for(var e in r)r.hasOwnProperty(e)&&(worker.methods[e]=r[e]);worker.send(\"ready\")},worker.emit=function(r){currentRequestId&&worker.send({id:currentRequestId,isEvent:!0,payload:r})},__webpack_unused_export__=worker.register,worker.emit}()}();"; diff --git a/packages/dapp/dist/build/asset-manifest.json b/packages/dapp/dist/build/asset-manifest.json new file mode 100644 index 000000000..23b79cd94 --- /dev/null +++ b/packages/dapp/dist/build/asset-manifest.json @@ -0,0 +1,26 @@ +{ + "files": { + "main.css": "/static/css/main.ca0d9543.css", + "main.js": "/static/js/main.c752446b.js", + "static/media/Garamond.ttf": "/static/media/Garamond.3fb4dd2923a5b4136a34.ttf", + "static/media/3.png": "/static/media/3.83d8744175cded03d685.png", + "static/media/5.png": "/static/media/5.36ecaf0b97cf14b2c388.png", + "static/media/1.png": "/static/media/1.bf908819053c51093c4a.png", + "static/media/8.png": "/static/media/8.b0a4b14db9afc5164409.png", + "static/media/6.png": "/static/media/6.c2a0fa198ae86c6ebbfe.png", + "static/media/4.png": "/static/media/4.b07a0b292754e0b601e3.png", + "static/media/7.png": "/static/media/7.82c4cce8676a52699edf.png", + "static/media/2.png": "/static/media/2.d0636426f422908753e6.png", + "static/media/Redaction50-Italic.otf": "/static/media/Redaction50-Italic.63c05c6fe83090bfeae8.otf", + "static/media/signature_derrida.png": "/static/media/signature_derrida.53722673323938038550.png", + "static/media/kernel_logo.png": "/static/media/kernel_logo.ad8f047ef531c1a35319.png", + "static/media/signature_ethblock.png": "/static/media/signature_ethblock.0ebfb16597a4a6753690.png", + "index.html": "/index.html", + "main.ca0d9543.css.map": "/static/css/main.ca0d9543.css.map", + "main.c752446b.js.map": "/static/js/main.c752446b.js.map" + }, + "entrypoints": [ + "static/css/main.ca0d9543.css", + "static/js/main.c752446b.js" + ] +} \ No newline at end of file diff --git a/packages/dapp/dist/build/fonts/Redaction50-Italic.otf b/packages/dapp/dist/build/fonts/Redaction50-Italic.otf new file mode 100644 index 000000000..0c4fc84b1 Binary files /dev/null and b/packages/dapp/dist/build/fonts/Redaction50-Italic.otf differ diff --git a/packages/dapp/dist/build/index.html b/packages/dapp/dist/build/index.html new file mode 100644 index 000000000..9bcc569dc --- /dev/null +++ b/packages/dapp/dist/build/index.html @@ -0,0 +1 @@ +Signature Economies
\ No newline at end of file diff --git a/packages/dapp/dist/build/manifest.json b/packages/dapp/dist/build/manifest.json new file mode 100644 index 000000000..36a9129eb --- /dev/null +++ b/packages/dapp/dist/build/manifest.json @@ -0,0 +1,25 @@ +{ + "short_name": "Signature Economies | Kernel", + "name": "Signature Economies | Kernel", + "icons": [ + { + "src": "favicon.ico", + "sizes": "64x64 32x32 24x24 16x16", + "type": "image/x-icon" + }, + { + "src": "logo192.png", + "type": "image/png", + "sizes": "192x192" + }, + { + "src": "logo512.png", + "type": "image/png", + "sizes": "512x512" + } + ], + "start_url": ".", + "display": "standalone", + "theme_color": "#000000", + "background_color": "#ffffff" +} diff --git a/packages/dapp/dist/build/robots.txt b/packages/dapp/dist/build/robots.txt new file mode 100644 index 000000000..e9e57dc4d --- /dev/null +++ b/packages/dapp/dist/build/robots.txt @@ -0,0 +1,3 @@ +# https://www.robotstxt.org/robotstxt.html +User-agent: * +Disallow: diff --git a/packages/dapp/dist/build/static/css/main.ca0d9543.css b/packages/dapp/dist/build/static/css/main.ca0d9543.css new file mode 100644 index 000000000..dfc63bee5 --- /dev/null +++ b/packages/dapp/dist/build/static/css/main.ca0d9543.css @@ -0,0 +1,5 @@ +@import url(https://fonts.googleapis.com/css2?family=EB+Garamond:ital,wght@0,400;0,500;0,600;0,700;0,800;1,400;1,500;1,600;1,700;1,800&display=swap); +/* +! tailwindcss v3.0.24 | MIT License | https://tailwindcss.com +*/*,:after,:before{border:0 solid #e5e7eb;box-sizing:border-box}:after,:before{--tw-content:""}html{-webkit-text-size-adjust:100%;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;line-height:1.5;tab-size:4}body{line-height:inherit;margin:0}hr{border-top-width:1px;color:inherit;height:0}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{border-collapse:collapse;border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{color:inherit;font-family:inherit;font-size:100%;line-height:inherit;margin:0;padding:0}button,select{text-transform:none}[type=button],[type=reset],[type=submit],button{-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}textarea{resize:vertical}input::-webkit-input-placeholder,textarea::-webkit-input-placeholder{color:#9ca3af;opacity:1}input:-ms-input-placeholder,textarea:-ms-input-placeholder{color:#9ca3af;opacity:1}input::placeholder,textarea::placeholder{color:#9ca3af;opacity:1}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}[hidden]{display:none}*,:after,:before{--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }.container{width:100%}@media (min-width:640px){.container{max-width:640px}}@media (min-width:768px){.container{max-width:768px}}@media (min-width:1024px){.container{max-width:1024px}}@media (min-width:1280px){.container{max-width:1280px}}@media (min-width:1536px){.container{max-width:1536px}}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.bottom-0{bottom:0}.top-0{top:0}.left-0{left:0}.z-10{z-index:10}.z-\[999\]{z-index:999}.z-\[100\]{z-index:100}.z-50{z-index:50}.mx-auto{margin-left:auto;margin-right:auto}.my-auto{margin-bottom:auto;margin-top:auto}.mx-10{margin-left:2.5rem;margin-right:2.5rem}.mx-96{margin-left:24rem;margin-right:24rem}.my-5{margin-bottom:1.25rem;margin-top:1.25rem}.mb-36{margin-bottom:9rem}.mt-16{margin-top:4rem}.mt-10{margin-top:2.5rem}.mt-4{margin-top:1rem}.mb-2{margin-bottom:.5rem}.mr-2{margin-right:.5rem}.block{display:block}.inline{display:inline}.flex{display:flex}.hidden{display:none}.h-12{height:3rem}.h-screen{height:100vh}.h-96{height:24rem}.h-auto{height:auto}.h-min{height:-webkit-min-content;height:min-content}.h-\[40rem\]{height:40rem}.h-64{height:16rem}.h-32{height:8rem}.h-4{height:1rem}.min-h-screen{min-height:100vh}.w-full{width:100%}.w-screen{width:100vw}.w-max{width:-webkit-max-content;width:max-content}.w-32{width:8rem}.w-28{width:7rem}.w-4\/5{width:80%}.w-2\/3{width:66.666667%}.w-3\/4{width:75%}.w-auto{width:auto}.w-48{width:12rem}.w-\[60px\]{width:60px}.w-\[52rem\]{width:52rem}.w-\[18rem\]{width:18rem}.w-\[22rem\]{width:22rem}.w-\[20rem\]{width:20rem}.w-24{width:6rem}.w-64{width:16rem}.w-4{width:1rem}.min-w-\[14rem\]{min-width:14rem}.max-w-\[14rem\]{max-width:14rem}.max-w-\[128px\]{max-width:128px}.flex-1{flex:1 1}.flex-shrink-0{flex-shrink:0}.flex-grow,.grow{flex-grow:1}.scale-95{--tw-scale-x:.95;--tw-scale-y:.95;-webkit-transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@-webkit-keyframes pulse{50%{opacity:.5}}@keyframes pulse{50%{opacity:.5}}.animate-pulse{-webkit-animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite;animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}@-webkit-keyframes spin{to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}@keyframes spin{to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}.animate-spin{-webkit-animation:spin 1s linear infinite;animation:spin 1s linear infinite}.cursor-pointer{cursor:pointer}.cursor-wait{cursor:wait}.select-none{-webkit-user-select:none;-ms-user-select:none;user-select:none}.flex-row{flex-direction:row}.flex-col{flex-direction:column}.content-center{align-content:center}.items-center{align-items:center}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-2{gap:.5rem}.gap-1{gap:.25rem}.gap-6{gap:1.5rem}.gap-4{gap:1rem}.gap-0{gap:0}.gap-8{gap:2rem}.gap-y-12{row-gap:3rem}.gap-y-4{row-gap:1rem}.gap-y-8{row-gap:2rem}.gap-x-8{-webkit-column-gap:2rem;column-gap:2rem}.gap-x-4{-webkit-column-gap:1rem;column-gap:1rem}.space-y-3>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(.75rem*var(--tw-space-y-reverse));margin-top:calc(.75rem*(1 - var(--tw-space-y-reverse)))}.place-self-center{place-self:center}.self-end{align-self:flex-end}.self-center{align-self:center}.overflow-hidden{overflow:hidden}.overflow-scroll{overflow:scroll}.overflow-y-visible{overflow-y:visible}.overflow-x-scroll{overflow-x:scroll}.text-ellipsis{text-overflow:ellipsis}.rounded-lg{border-radius:.5rem}.rounded-md{border-radius:.375rem}.rounded-2xl{border-radius:1rem}.rounded-full{border-radius:9999px}.border-2{border-width:2px}.border-4{border-width:4px}.border-b-2{border-bottom-width:2px}.border-t-0{border-top-width:0}.border-gray-600{--tw-border-opacity:1;border-color:rgb(75 85 99/var(--tw-border-opacity))}.border-transparent{border-color:transparent}.border-slate-200{--tw-border-opacity:1;border-color:rgb(226 232 240/var(--tw-border-opacity))}.border-gray-500{--tw-border-opacity:1;border-color:rgb(107 114 128/var(--tw-border-opacity))}.border-gray-200{--tw-border-opacity:1;border-color:rgb(229 231 235/var(--tw-border-opacity))}.border-gray-300{--tw-border-opacity:1;border-color:rgb(209 213 219/var(--tw-border-opacity))}.border-t-\[\#07eb9f\]{--tw-border-opacity:1;border-top-color:rgb(7 235 159/var(--tw-border-opacity))}.bg-gray-200{--tw-bg-opacity:1;background-color:rgb(229 231 235/var(--tw-bg-opacity))}.bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity))}.bg-slate-200{--tw-bg-opacity:1;background-color:rgb(226 232 240/var(--tw-bg-opacity))}.bg-gray-500\/30{background-color:hsla(220,9%,46%,.3)}.bg-gray-100{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity))}.bg-transparent{background-color:transparent}.bg-gray-600{--tw-bg-opacity:1;background-color:rgb(75 85 99/var(--tw-bg-opacity))}.bg-gray-300{--tw-bg-opacity:1;background-color:rgb(209 213 219/var(--tw-bg-opacity))}.fill-gray-600{fill:#4b5563}.p-8{padding:2rem}.p-2{padding:.5rem}.p-1\.5{padding:.375rem}.p-1{padding:.25rem}.p-4{padding:1rem}.py-6{padding-bottom:1.5rem;padding-top:1.5rem}.px-4{padding-left:1rem;padding-right:1rem}.py-16{padding-bottom:4rem;padding-top:4rem}.px-8{padding-left:2rem;padding-right:2rem}.py-2{padding-bottom:.5rem;padding-top:.5rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.py-10{padding-bottom:2.5rem;padding-top:2.5rem}.px-2{padding-left:.5rem;padding-right:.5rem}.py-4{padding-bottom:1rem;padding-top:1rem}.py-1{padding-bottom:.25rem;padding-top:.25rem}.pt-6{padding-top:1.5rem}.pl-6{padding-left:1.5rem}.pr-6{padding-right:1.5rem}.pb-32{padding-bottom:8rem}.pt-16{padding-top:4rem}.pb-8{padding-bottom:2rem}.pb-16{padding-bottom:4rem}.pb-4{padding-bottom:1rem}.pb-48{padding-bottom:12rem}.pt-4{padding-top:1rem}.text-left{text-align:left}.text-center{text-align:center}.text-justify{text-align:justify}.font-redaction{font-family:Redaction,sans-serif}.font-garamond{font-family:EB Garamond,sans-serif}.font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.text-base{font-size:1rem;line-height:1.5rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-xs{font-size:.75rem;line-height:1rem}.text-5xl{font-size:3rem;line-height:1}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-4xl{font-size:2.25rem;line-height:2.5rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-2xl{font-size:1.5rem;line-height:2rem}.font-normal{font-weight:400}.font-bold{font-weight:700}.font-thin{font-weight:100}.italic{font-style:italic}.text-gray-500{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity))}.text-gray-800{--tw-text-opacity:1;color:rgb(31 41 55/var(--tw-text-opacity))}.text-gray-400{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity))}.text-black{--tw-text-opacity:1;color:rgb(0 0 0/var(--tw-text-opacity))}.text-black\/60{color:rgba(0,0,0,.6)}.text-gray-600{--tw-text-opacity:1;color:rgb(75 85 99/var(--tw-text-opacity))}.text-gray-300{--tw-text-opacity:1;color:rgb(209 213 219/var(--tw-text-opacity))}.text-gray-700{--tw-text-opacity:1;color:rgb(55 65 81/var(--tw-text-opacity))}.text-slate-800{--tw-text-opacity:1;color:rgb(30 41 59/var(--tw-text-opacity))}.text-slate-400{--tw-text-opacity:1;color:rgb(148 163 184/var(--tw-text-opacity))}.text-red-400{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity))}.text-white{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity))}.text-red-600{--tw-text-opacity:1;color:rgb(220 38 38/var(--tw-text-opacity))}.text-gray-200{--tw-text-opacity:1;color:rgb(229 231 235/var(--tw-text-opacity))}.underline{-webkit-text-decoration-line:underline;text-decoration-line:underline}.no-underline{-webkit-text-decoration-line:none;text-decoration-line:none}.opacity-30{opacity:.3}.shadow-xl{--tw-shadow:0 20px 25px -5px rgba(0,0,0,.1),0 8px 10px -6px rgba(0,0,0,.1);--tw-shadow-colored:0 20px 25px -5px var(--tw-shadow-color),0 8px 10px -6px var(--tw-shadow-color)}.shadow-lg,.shadow-xl{box-shadow:0 0 #0000,0 0 #0000,var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.shadow-lg{--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1);--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color)}.filter{-webkit-filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.backdrop-blur-lg{--tw-backdrop-blur:blur(16px)}.backdrop-blur-lg,.backdrop-blur-md{-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.backdrop-blur-md{--tw-backdrop-blur:blur(12px)}.transition{transition-duration:.15s;transition-property:color,background-color,border-color,fill,stroke,opacity,box-shadow,-webkit-text-decoration-color,-webkit-transform,-webkit-filter,-webkit-backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-text-decoration-color,-webkit-transform,-webkit-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1)}.transition-all{transition-duration:.15s;transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1)}.duration-200{transition-duration:.2s}.ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}@font-face{font-family:Redaction;src:url(/static/media/Redaction50-Italic.63c05c6fe83090bfeae8.otf)}html{-ms-overflow-style:none;scroll-behavior:smooth;scrollbar-width:none}html::-webkit-scrollbar{background:transparent;width:0}a{color:#233447;font-weight:700;text-decoration:underline}.p5Canvas{max-height:550px;max-width:370px}.signatures>div>.p5Canvas{max-height:330px;max-width:14rem}.flip-card{background-color:transparent;height:24rem;-webkit-perspective:2500px;perspective:2500px;width:24rem}@media screen and (max-width:600px){.flip-card{height:15rem;width:15rem}.p5Canvas{background-repeat:no-repeat;max-height:450px;max-width:300px}}.flip-card-inner,.flip-card-inner-flipped{height:100%;position:relative;text-align:center;-webkit-transform-style:preserve-3d;transform-style:preserve-3d;transition:-webkit-transform 1.2s;transition:transform 1.2s;transition:transform 1.2s,-webkit-transform 1.2s;width:100%}.flip-card-inner-flipped{-webkit-transform:rotateY(180deg);transform:rotateY(180deg)}.flip-card-back,.flip-card-front{-webkit-backface-visibility:hidden;backface-visibility:hidden;height:100%;position:absolute;width:100%}.flip-card-front{color:#000}.flip-card-back{-webkit-transform:rotateY(180deg);transform:rotateY(180deg)}.selection\:bg-green-300 ::selection{--tw-bg-opacity:1;background-color:rgb(134 239 172/var(--tw-bg-opacity))}.selection\:text-green-900 ::selection{--tw-text-opacity:1;color:rgb(20 83 45/var(--tw-text-opacity))}.selection\:bg-green-300::selection{--tw-bg-opacity:1;background-color:rgb(134 239 172/var(--tw-bg-opacity))}.selection\:text-green-900::selection{--tw-text-opacity:1;color:rgb(20 83 45/var(--tw-text-opacity))}.hover\:scale-100:hover{--tw-scale-x:1;--tw-scale-y:1;-webkit-transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\:border-gray-200:hover{--tw-border-opacity:1;border-color:rgb(229 231 235/var(--tw-border-opacity))}.hover\:border-slate-300:hover{--tw-border-opacity:1;border-color:rgb(203 213 225/var(--tw-border-opacity))}.hover\:border-black:hover{--tw-border-opacity:1;border-color:rgb(0 0 0/var(--tw-border-opacity))}.hover\:border-gray-400:hover{--tw-border-opacity:1;border-color:rgb(156 163 175/var(--tw-border-opacity))}.hover\:border-slate-400:hover{--tw-border-opacity:1;border-color:rgb(148 163 184/var(--tw-border-opacity))}.hover\:bg-slate-300:hover{--tw-bg-opacity:1;background-color:rgb(203 213 225/var(--tw-bg-opacity))}.hover\:bg-gray-100:hover{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity))}.hover\:text-black:hover{--tw-text-opacity:1;color:rgb(0 0 0/var(--tw-text-opacity))}.hover\:text-gray-800:hover{--tw-text-opacity:1;color:rgb(31 41 55/var(--tw-text-opacity))}.hover\:text-slate-800:hover{--tw-text-opacity:1;color:rgb(30 41 59/var(--tw-text-opacity))}.hover\:underline:hover{-webkit-text-decoration-line:underline;text-decoration-line:underline}.hover\:shadow-md:hover{--tw-shadow:0 4px 6px -1px rgba(0,0,0,.1),0 2px 4px -2px rgba(0,0,0,.1);--tw-shadow-colored:0 4px 6px -1px var(--tw-shadow-color),0 2px 4px -2px var(--tw-shadow-color);box-shadow:0 0 #0000,0 0 #0000,var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.hover\:shadow-gray-500:hover{--tw-shadow-color:#6b7280;--tw-shadow:var(--tw-shadow-colored)}@media (prefers-color-scheme:dark){.dark\:fill-gray-300{fill:#d1d5db}.dark\:text-gray-600{--tw-text-opacity:1;color:rgb(75 85 99/var(--tw-text-opacity))}}@media (min-width:640px){.sm\:block{display:block}.sm\:flex{display:flex}.sm\:hidden{display:none}.sm\:w-80{width:20rem}.sm\:w-\[100px\]{width:100px}.sm\:w-min{width:-webkit-min-content;width:min-content}.sm\:w-32{width:8rem}.sm\:w-64{width:16rem}.sm\:w-96{width:24rem}.sm\:items-center{align-items:center}.sm\:justify-center{justify-content:center}.sm\:gap-6{gap:1.5rem}.sm\:overflow-visible{overflow:visible}.sm\:p-2{padding:.5rem}.sm\:py-6{padding-bottom:1.5rem;padding-top:1.5rem}.sm\:px-4{padding-left:1rem;padding-right:1rem}.sm\:py-2{padding-bottom:.5rem;padding-top:.5rem}.sm\:py-0{padding-bottom:0;padding-top:0}.sm\:text-2xl{font-size:1.5rem;line-height:2rem}.sm\:text-base{font-size:1rem;line-height:1.5rem}.sm\:shadow{--tw-shadow:0 1px 3px 0 rgba(0,0,0,.1),0 1px 2px -1px rgba(0,0,0,.1);--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color);box-shadow:0 0 #0000,0 0 #0000,var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.sm\:shadow-gray-300{--tw-shadow-color:#d1d5db;--tw-shadow:var(--tw-shadow-colored)}.sm\:transition-all{transition-duration:.15s;transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1)}}@media (min-width:768px){.md\:block{display:block}.md\:w-\[800px\]{width:800px}.md\:w-\[600px\]{width:600px}.md\:w-2\/3{width:66.666667%}.md\:w-min{width:-webkit-min-content;width:min-content}.md\:w-64{width:16rem}.md\:w-80{width:20rem}.md\:max-w-3xl{max-width:48rem}.md\:p-8{padding:2rem}.md\:px-0{padding-left:0;padding-right:0}.md\:px-20{padding-left:5rem;padding-right:5rem}.md\:px-16{padding-left:4rem;padding-right:4rem}.md\:px-12{padding-left:3rem;padding-right:3rem}.md\:py-4{padding-bottom:1rem;padding-top:1rem}.md\:text-2xl{font-size:1.5rem;line-height:2rem}.md\:text-6xl{font-size:3.75rem;line-height:1}.md\:text-sm{font-size:.875rem;line-height:1.25rem}.md\:text-8xl{font-size:6rem;line-height:1}.md\:text-4xl{font-size:2.25rem;line-height:2.5rem}}.rc-slider{border-radius:6px;height:14px;padding:5px 0;position:relative;touch-action:none;width:100%}.rc-slider,.rc-slider *{-webkit-tap-highlight-color:rgba(0,0,0,0);box-sizing:border-box}.rc-slider-rail{background-color:#e9e9e9;width:100%}.rc-slider-rail,.rc-slider-track{border-radius:6px;height:4px;position:absolute}.rc-slider-track{background-color:#abe2fb}.rc-slider-handle{background-color:#fff;border:2px solid #96dbfa;border-radius:50%;cursor:pointer;cursor:-webkit-grab;cursor:grab;height:14px;margin-top:-5px;opacity:.8;position:absolute;touch-action:pan-x;width:14px}.rc-slider-handle-dragging.rc-slider-handle-dragging.rc-slider-handle-dragging{border-color:#57c5f7;box-shadow:0 0 0 5px #96dbfa}.rc-slider-handle:focus{box-shadow:none;outline:none}.rc-slider-handle:focus-visible{border-color:#2db7f5;box-shadow:0 0 0 3px #96dbfa}.rc-slider-handle-click-focused:focus{border-color:#96dbfa;box-shadow:unset}.rc-slider-handle:hover{border-color:#57c5f7}.rc-slider-handle:active{border-color:#57c5f7;box-shadow:0 0 5px #57c5f7;cursor:-webkit-grabbing;cursor:grabbing}.rc-slider-mark{font-size:12px;left:0;position:absolute;top:18px;width:100%}.rc-slider-mark-text{color:#999;cursor:pointer;display:inline-block;position:absolute;text-align:center;vertical-align:middle}.rc-slider-mark-text-active{color:#666}.rc-slider-step{background:transparent;height:4px;pointer-events:none;position:absolute;width:100%}.rc-slider-dot{background-color:#fff;border:2px solid #e9e9e9;border-radius:50%;bottom:-2px;cursor:pointer;height:8px;position:absolute;vertical-align:middle;width:8px}.rc-slider-dot-active{border-color:#96dbfa}.rc-slider-dot-reverse{margin-right:-4px}.rc-slider-disabled{background-color:#e9e9e9}.rc-slider-disabled .rc-slider-track{background-color:#ccc}.rc-slider-disabled .rc-slider-dot,.rc-slider-disabled .rc-slider-handle{background-color:#fff;border-color:#ccc;box-shadow:none;cursor:not-allowed}.rc-slider-disabled .rc-slider-dot,.rc-slider-disabled .rc-slider-mark-text{cursor:not-allowed!important}.rc-slider-vertical{height:100%;padding:0 5px;width:14px}.rc-slider-vertical .rc-slider-rail{height:100%;width:4px}.rc-slider-vertical .rc-slider-track{bottom:0;left:5px;width:4px}.rc-slider-vertical .rc-slider-handle{margin-left:-5px;margin-top:0;touch-action:pan-y}.rc-slider-vertical .rc-slider-mark{height:100%;left:18px;top:0}.rc-slider-vertical .rc-slider-step{height:100%;width:4px}.rc-slider-vertical .rc-slider-dot{margin-left:-2px}.rc-slider-tooltip-zoom-down-appear,.rc-slider-tooltip-zoom-down-enter,.rc-slider-tooltip-zoom-down-leave{-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-play-state:paused;animation-play-state:paused;display:block!important}.rc-slider-tooltip-zoom-down-appear.rc-slider-tooltip-zoom-down-appear-active,.rc-slider-tooltip-zoom-down-enter.rc-slider-tooltip-zoom-down-enter-active{-webkit-animation-name:rcSliderTooltipZoomDownIn;animation-name:rcSliderTooltipZoomDownIn;-webkit-animation-play-state:running;animation-play-state:running}.rc-slider-tooltip-zoom-down-leave.rc-slider-tooltip-zoom-down-leave-active{-webkit-animation-name:rcSliderTooltipZoomDownOut;animation-name:rcSliderTooltipZoomDownOut;-webkit-animation-play-state:running;animation-play-state:running}.rc-slider-tooltip-zoom-down-appear,.rc-slider-tooltip-zoom-down-enter{-webkit-animation-timing-function:cubic-bezier(.23,1,.32,1);animation-timing-function:cubic-bezier(.23,1,.32,1);transform:scale(0)}.rc-slider-tooltip-zoom-down-leave{-webkit-animation-timing-function:cubic-bezier(.755,.05,.855,.06);animation-timing-function:cubic-bezier(.755,.05,.855,.06)}@-webkit-keyframes rcSliderTooltipZoomDownIn{0%{opacity:0;transform:scale(0);transform-origin:50% 100%}to{transform:scale(1);transform-origin:50% 100%}}@keyframes rcSliderTooltipZoomDownIn{0%{opacity:0;transform:scale(0);transform-origin:50% 100%}to{transform:scale(1);transform-origin:50% 100%}}@-webkit-keyframes rcSliderTooltipZoomDownOut{0%{transform:scale(1);transform-origin:50% 100%}to{opacity:0;transform:scale(0);transform-origin:50% 100%}}@keyframes rcSliderTooltipZoomDownOut{0%{transform:scale(1);transform-origin:50% 100%}to{opacity:0;transform:scale(0);transform-origin:50% 100%}}.rc-slider-tooltip{left:-9999px;position:absolute;top:-9999px;visibility:visible}.rc-slider-tooltip,.rc-slider-tooltip *{-webkit-tap-highlight-color:rgba(0,0,0,0);box-sizing:border-box}.rc-slider-tooltip-hidden{display:none}.rc-slider-tooltip-placement-top{padding:4px 0 8px}.rc-slider-tooltip-inner{background-color:#6c6c6c;border-radius:6px;box-shadow:0 0 4px #d9d9d9;color:#fff;font-size:12px;height:24px;line-height:1;min-width:24px;padding:6px 2px;text-align:center;text-decoration:none}.rc-slider-tooltip-arrow{border-color:transparent;border-style:solid;height:0;position:absolute;width:0}.rc-slider-tooltip-placement-top .rc-slider-tooltip-arrow{border-top-color:#6c6c6c;border-width:4px 4px 0;bottom:4px;left:50%;margin-left:-4px} +/*# sourceMappingURL=main.ca0d9543.css.map*/ \ No newline at end of file diff --git a/packages/dapp/dist/build/static/css/main.ca0d9543.css.map b/packages/dapp/dist/build/static/css/main.ca0d9543.css.map new file mode 100644 index 000000000..4ee30a058 --- /dev/null +++ b/packages/dapp/dist/build/static/css/main.ca0d9543.css.map @@ -0,0 +1 @@ +{"version":3,"file":"static/css/main.ca0d9543.css","mappings":";AAAA;;CAAc,CAAd,uCAAc,CAAd,qBAAc,CAAd,8BAAc,CAAd,kCAAc,CAAd,gMAAc,CAAd,eAAc,CAAd,UAAc,CAAd,wBAAc,CAAd,QAAc,CAAd,uBAAc,CAAd,aAAc,CAAd,QAAc,CAAd,4DAAc,CAAd,gCAAc,CAAd,mCAAc,CAAd,mBAAc,CAAd,eAAc,CAAd,uBAAc,CAAd,2BAAc,CAAd,qHAAc,CAAd,aAAc,CAAd,mBAAc,CAAd,qBAAc,CAAd,aAAc,CAAd,iBAAc,CAAd,uBAAc,CAAd,iBAAc,CAAd,aAAc,CAAd,8BAAc,CAAd,oBAAc,CAAd,aAAc,CAAd,mDAAc,CAAd,mBAAc,CAAd,cAAc,CAAd,mBAAc,CAAd,QAAc,CAAd,SAAc,CAAd,iCAAc,CAAd,yEAAc,CAAd,4BAAc,CAAd,qBAAc,CAAd,4BAAc,CAAd,gCAAc,CAAd,gCAAc,CAAd,mEAAc,CAAd,0CAAc,CAAd,mBAAc,CAAd,mDAAc,CAAd,sDAAc,CAAd,YAAc,CAAd,yBAAc,CAAd,2DAAc,CAAd,iBAAc,CAAd,yBAAc,CAAd,0BAAc,CAAd,QAAc,CAAd,SAAc,CAAd,wBAAc,CAAd,kFAAc,CAAd,SAAc,CAAd,wEAAc,CAAd,SAAc,CAAd,sDAAc,CAAd,SAAc,CAAd,mCAAc,CAAd,wBAAc,CAAd,4DAAc,CAAd,qBAAc,CAAd,qBAAc,CAAd,cAAc,CAAd,qBAAc,CAAd,mCAAc,CAAd,kBAAc,CAAd,aAAc,CAAd,aAAc,CAAd,aAAc,CAAd,cAAc,CAAd,cAAc,CAAd,YAAc,CAAd,YAAc,CAAd,iBAAc,CAAd,qCAAc,CAAd,cAAc,CAAd,mBAAc,CAAd,qBAAc,CAAd,sBAAc,CAAd,uBAAc,CAAd,iBAAc,CAAd,0BAAc,CAAd,2BAAc,CAAd,mCAAc,CAAd,iCAAc,CAAd,0BAAc,CAAd,qBAAc,CAAd,6BAAc,CAAd,WAAc,CAAd,iBAAc,CAAd,eAAc,CAAd,gBAAc,CAAd,iBAAc,CAAd,aAAc,CAAd,eAAc,CAAd,YAAc,CAAd,kBAAc,CAAd,oBAAc,CAAd,0BAAc,CAAd,wBAAc,CAAd,yBAAc,CAAd,0BAAc,CAAd,sBAAc,CAAd,uBAAc,CAAd,wBAAc,CAAd,qBAAc,CACd,qBAAoB,CAApB,mDAAoB,EAApB,mDAAoB,EAApB,qDAAoB,EAApB,qDAAoB,EAApB,qDAAoB,EACpB,qBAAmB,CAAnB,2BAAmB,CAAnB,2BAAmB,CAAnB,kBAAmB,CAAnB,YAAmB,CAAnB,cAAmB,CAAnB,gBAAmB,CAAnB,sBAAmB,CAAnB,sBAAmB,CAAnB,gBAAmB,CAAnB,yBAAmB,CAAnB,iBAAmB,CAAnB,2CAAmB,CAAnB,yBAAmB,CAAnB,mBAAmB,CAAnB,wBAAmB,CAAnB,kBAAmB,CAAnB,8CAAmB,CAAnB,yBAAmB,CAAnB,sBAAmB,CAAnB,wBAAmB,CAAnB,qBAAmB,CAAnB,yBAAmB,CAAnB,wBAAmB,CAAnB,oBAAmB,CAAnB,sBAAmB,CAAnB,kBAAmB,CAAnB,oBAAmB,CAAnB,iBAAmB,CAAnB,sBAAmB,CAAnB,kBAAmB,CAAnB,mBAAmB,CAAnB,iCAAmB,CAAnB,kBAAmB,CAAnB,yBAAmB,CAAnB,kBAAmB,CAAnB,iBAAmB,CAAnB,gBAAmB,CAAnB,8BAAmB,CAAnB,kBAAmB,CAAnB,qBAAmB,CAAnB,gCAAmB,CAAnB,iBAAmB,CAAnB,gBAAmB,CAAnB,gBAAmB,CAAnB,iBAAmB,CAAnB,wBAAmB,CAAnB,iBAAmB,CAAnB,kBAAmB,CAAnB,iBAAmB,CAAnB,sBAAmB,CAAnB,wBAAmB,CAAnB,wBAAmB,CAAnB,wBAAmB,CAAnB,wBAAmB,CAAnB,gBAAmB,CAAnB,iBAAmB,CAAnB,eAAmB,CAAnB,gCAAmB,CAAnB,gCAAmB,CAAnB,gCAAmB,CAAnB,gBAAmB,CAAnB,4BAAmB,CAAnB,4BAAmB,CAAnB,0BAAmB,CAAnB,gBAAmB,CAAnB,qMAAmB,CAAnB,6LAAmB,CAAnB,uCAAmB,EAAnB,+BAAmB,EAAnB,0EAAmB,CAAnB,mDAAmB,CAAnB,0DAAmB,CAAnB,uBAAmB,EAAnB,kDAAmB,CAAnB,uBAAmB,EAAnB,uDAAmB,CAAnB,iCAAmB,CAAnB,8BAAmB,CAAnB,wBAAmB,CAAnB,qCAAmB,CAAnB,oBAAmB,CAAnB,gBAAmB,CAAnB,4BAAmB,CAAnB,+BAAmB,CAAnB,oCAAmB,CAAnB,gCAAmB,CAAnB,sCAAmB,CAAnB,8CAAmB,CAAnB,gBAAmB,CAAnB,iBAAmB,CAAnB,iBAAmB,CAAnB,eAAmB,CAAnB,YAAmB,CAAnB,eAAmB,CAAnB,sBAAmB,CAAnB,qBAAmB,CAAnB,qBAAmB,CAAnB,gCAAmB,CAAnB,eAAmB,CAAnB,gCAAmB,CAAnB,eAAmB,CAAnB,+DAAmB,CAAnB,4GAAmB,CAAnB,oCAAmB,CAAnB,6BAAmB,CAAnB,8BAAmB,CAAnB,gCAAmB,CAAnB,gCAAmB,CAAnB,sCAAmB,CAAnB,oCAAmB,CAAnB,qCAAmB,CAAnB,+BAAmB,CAAnB,iCAAmB,CAAnB,+BAAmB,CAAnB,kCAAmB,CAAnB,0BAAmB,CAAnB,0BAAmB,CAAnB,mCAAmB,CAAnB,8BAAmB,CAAnB,sCAAmB,CAAnB,mDAAmB,CAAnB,4CAAmB,CAAnB,uCAAmB,CAAnB,sDAAmB,CAAnB,sCAAmB,CAAnB,sDAAmB,CAAnB,sCAAmB,CAAnB,sDAAmB,CAAnB,sCAAmB,CAAnB,sDAAmB,CAAnB,4CAAmB,CAAnB,wDAAmB,CAAnB,8BAAmB,CAAnB,sDAAmB,CAAnB,2BAAmB,CAAnB,sDAAmB,CAAnB,+BAAmB,CAAnB,sDAAmB,CAAnB,qDAAmB,CAAnB,8BAAmB,CAAnB,sDAAmB,CAAnB,4CAAmB,CAAnB,8BAAmB,CAAnB,mDAAmB,CAAnB,8BAAmB,CAAnB,sDAAmB,CAAnB,2BAAmB,CAAnB,iBAAmB,CAAnB,kBAAmB,CAAnB,uBAAmB,CAAnB,mBAAmB,CAAnB,iBAAmB,CAAnB,8CAAmB,CAAnB,uBAAmB,CAAnB,kBAAmB,CAAnB,2CAAmB,CAAnB,uBAAmB,CAAnB,kBAAmB,CAAnB,4CAAmB,CAAnB,yBAAmB,CAAnB,oBAAmB,CAAnB,+CAAmB,CAAnB,wBAAmB,CAAnB,mBAAmB,CAAnB,0CAAmB,CAAnB,8CAAmB,CAAnB,wBAAmB,CAAnB,yBAAmB,CAAnB,0BAAmB,CAAnB,0BAAmB,CAAnB,uBAAmB,CAAnB,yBAAmB,CAAnB,0BAAmB,CAAnB,yBAAmB,CAAnB,2BAAmB,CAAnB,sBAAmB,CAAnB,0BAAmB,CAAnB,8BAAmB,CAAnB,gCAAmB,CAAnB,gDAAmB,CAAnB,iDAAmB,CAAnB,8GAAmB,CAAnB,yBAAmB,CAAnB,kBAAmB,CAAnB,2BAAmB,CAAnB,mBAAmB,CAAnB,yBAAmB,CAAnB,gBAAmB,CAAnB,wBAAmB,CAAnB,aAAmB,CAAnB,0BAAmB,CAAnB,mBAAmB,CAAnB,2BAAmB,CAAnB,kBAAmB,CAAnB,0BAAmB,CAAnB,mBAAmB,CAAnB,0BAAmB,CAAnB,gBAAmB,CAAnB,4BAAmB,CAAnB,0BAAmB,CAAnB,0BAAmB,CAAnB,yBAAmB,CAAnB,kCAAmB,CAAnB,6CAAmB,CAAnB,kCAAmB,CAAnB,0CAAmB,CAAnB,kCAAmB,CAAnB,6CAAmB,CAAnB,+BAAmB,CAAnB,uCAAmB,CAAnB,oCAAmB,CAAnB,kCAAmB,CAAnB,0CAAmB,CAAnB,kCAAmB,CAAnB,6CAAmB,CAAnB,kCAAmB,CAAnB,0CAAmB,CAAnB,mCAAmB,CAAnB,0CAAmB,CAAnB,mCAAmB,CAAnB,6CAAmB,CAAnB,iCAAmB,CAAnB,6CAAmB,CAAnB,+BAAmB,CAAnB,6CAAmB,CAAnB,iCAAmB,CAAnB,2CAAmB,CAAnB,kCAAmB,CAAnB,6CAAmB,CAAnB,iDAAmB,CAAnB,8BAAmB,CAAnB,+CAAmB,CAAnB,yBAAmB,CAAnB,sBAAmB,CAAnB,qFAAmB,CAAnB,kGAAmB,CAAnB,qEAAmB,CAAnB,kGAAmB,CAAnB,oFAAmB,CAAnB,iGAAmB,CAAnB,gMAAmB,CAAnB,gLAAmB,CAAnB,+CAAmB,CAAnB,kTAAmB,CAAnB,sQAAmB,CAAnB,+CAAmB,CAAnB,kNAAmB,CAAnB,6IAAmB,CAAnB,oOAAmB,CAAnB,kDAAmB,CAAnB,gEAAmB,CAAnB,kDAAmB,CAAnB,qCAAmB,CAAnB,+DAAmB,CAInB,WACE,qBAAwB,CACxB,kEACF,CAEA,KAGE,uBAAwB,CAFxB,sBAAuB,CACvB,oBAEF,CAEA,wBAEE,sBAAuB,CADvB,OAEF,CAEA,EACE,aAAc,CAEd,eAAgB,CADhB,yBAEF,CAEA,UAEE,gBAAiB,CADjB,eAEF,CAEA,0BAEE,gBAAiB,CADjB,eAEF,CAEA,WACE,4BAA6B,CAE7B,YAAa,CACb,0BAAmB,CAAnB,kBAAmB,CAFnB,WAGF,CAEA,oCACE,WAEE,YAAa,CADb,WAEF,CAEA,UAGE,2BAA4B,CAD5B,gBAAiB,CADjB,eAGF,CACF,CAYA,0CANE,WAAY,CAFZ,iBAAkB,CAGlB,iBAAkB,CAElB,mCAA4B,CAA5B,2BAA4B,CAD5B,iCAA0B,CAA1B,yBAA0B,CAA1B,gDAA0B,CAH1B,UAeF,CARA,yBAOE,iCAA0B,CAA1B,yBACF,CAGA,iCAIE,kCAAmC,CACnC,0BAA2B,CAF3B,WAAY,CAFZ,iBAAkB,CAClB,UAIF,CAGA,iBACE,UACF,CAGA,gBACE,iCAA0B,CAA1B,yBACF,CA/FA,6G,CAAA,qG,CAAA,4G,CAAA,oG,CAAA,yb,CAAA,0G,CAAA,2G,CAAA,iG,CAAA,0G,CAAA,2G,CAAA,mG,CAAA,kG,CAAA,oF,CAAA,0F,CAAA,2F,CAAA,6F,CAAA,kV,CAAA,4F,CAAA,oE,CAAA,mF,EAAA,iD,CAAA,sB,CAAA,wB,CAAA,qB,CAAA,4B,CAAA,sD,CAAA,oB,CAAA,qB,CAAA,qB,CAAA,oC,CAAA,0C,CAAA,qB,CAAA,sC,CAAA,sB,CAAA,kD,CAAA,8C,CAAA,gD,CAAA,wC,CAAA,+C,CAAA,gD,CAAA,gU,CAAA,mF,CAAA,uH,EAAA,iD,CAAA,4B,CAAA,4B,CAAA,4B,CAAA,sD,CAAA,qB,CAAA,qB,CAAA,8B,CAAA,qB,CAAA,wC,CAAA,+C,CAAA,+C,CAAA,+C,CAAA,8C,CAAA,+C,CAAA,6C,CAAA,kD,CAAA,0C,CAAA,kD,ECAA,WAKE,iBAAkB,CAFlB,WAAY,CACZ,aAAc,CAHd,iBAAkB,CAKlB,iBAAkB,CAJlB,UAOF,CACA,wBAFE,yCAA6C,CAD7C,qBAMF,CACA,gBAIE,wBAAyB,CAFzB,UAIF,CACA,iCAFE,iBAAkB,CAFlB,UAAW,CAFX,iBAWF,CALA,iBAGE,wBAEF,CACA,kBAKE,qBAAsB,CACtB,wBAAyB,CACzB,iBAAkB,CAClB,cAAe,CACf,mBAAoB,CACpB,WAAY,CAPZ,WAAY,CACZ,eAAgB,CAOhB,UAAY,CAVZ,iBAAkB,CAWlB,kBAAmB,CAVnB,UAWF,CACA,+EACE,oBAAqB,CACrB,4BACF,CACA,wBAEE,eAAgB,CADhB,YAEF,CACA,gCACE,oBAAqB,CACrB,4BACF,CACA,sCACE,oBAAqB,CACrB,gBACF,CACA,wBACE,oBACF,CACA,yBACE,oBAAqB,CACrB,0BAA2B,CAC3B,uBAAwB,CACxB,eACF,CACA,gBAKE,cAAe,CAFf,MAAO,CAFP,iBAAkB,CAClB,QAAS,CAET,UAEF,CACA,qBAGE,UAAW,CAGX,cAAe,CAJf,oBAAqB,CADrB,iBAAkB,CAGlB,iBAAkB,CAClB,qBAEF,CACA,4BACE,UACF,CACA,gBAIE,sBAAuB,CADvB,UAAW,CAEX,mBAAoB,CAJpB,iBAAkB,CAClB,UAIF,CACA,eAME,qBAAsB,CACtB,wBAAyB,CACzB,iBAAkB,CANlB,WAAY,CAOZ,cAAe,CALf,UAAW,CAHX,iBAAkB,CAIlB,qBAAsB,CAFtB,SAOF,CACA,sBACE,oBACF,CACA,uBACE,iBACF,CACA,oBACE,wBACF,CACA,qCACE,qBACF,CACA,yEAEE,qBAAsB,CACtB,iBAAkB,CAClB,eAAgB,CAChB,kBACF,CACA,4EAEE,4BACF,CACA,oBAEE,WAAY,CACZ,aAAc,CAFd,UAGF,CACA,oCAEE,WAAY,CADZ,SAEF,CACA,qCACE,QAAS,CACT,QAAS,CACT,SACF,CACA,sCAEE,gBAAiB,CADjB,YAAa,CAEb,kBACF,CACA,oCAGE,WAAY,CADZ,SAAU,CADV,KAGF,CACA,oCAEE,WAAY,CADZ,SAEF,CACA,mCACE,gBACF,CAQA,0GAEE,8BAAwB,CAAxB,sBAAwB,CACxB,gCAAyB,CAAzB,wBAAyB,CACzB,mCAA4B,CAA5B,2BAA4B,CAH5B,uBAIF,CACA,0JAEE,gDAAyC,CAAzC,wCAAyC,CACzC,oCAA6B,CAA7B,4BACF,CACA,4EACE,iDAA0C,CAA1C,yCAA0C,CAC1C,oCAA6B,CAA7B,4BACF,CACA,uEAGE,2DAAyD,CAAzD,mDAAyD,CADzD,kBAEF,CACA,mCACE,iEAAiE,CAAjE,yDACF,CACA,6CACE,GAGE,SAAU,CAFV,kBAAsB,CACtB,yBAEF,CACA,GACE,kBAAsB,CACtB,yBACF,CACF,CAVA,qCACE,GAGE,SAAU,CAFV,kBAAsB,CACtB,yBAEF,CACA,GACE,kBAAsB,CACtB,yBACF,CACF,CACA,8CACE,GACE,kBAAsB,CACtB,yBACF,CACA,GAGE,SAAU,CAFV,kBAAsB,CACtB,yBAEF,CACF,CAVA,sCACE,GACE,kBAAsB,CACtB,yBACF,CACA,GAGE,SAAU,CAFV,kBAAsB,CACtB,yBAEF,CACF,CACA,mBAGE,YAAa,CAFb,iBAAkB,CAClB,WAAY,CAEZ,kBAGF,CACA,wCAFE,yCAA6C,CAD7C,qBAMF,CACA,0BACE,YACF,CACA,iCACE,iBACF,CACA,yBASE,wBAAyB,CACzB,iBAAkB,CAClB,0BAA2B,CAP3B,UAAW,CACX,cAAe,CAHf,WAAY,CAIZ,aAAc,CALd,cAAe,CAEf,eAAgB,CAIhB,iBAAkB,CAClB,oBAIF,CACA,yBAIE,wBAAyB,CACzB,kBAAmB,CAFnB,QAAS,CAFT,iBAAkB,CAClB,OAIF,CACA,0DAKE,wBAAyB,CADzB,sBAAuB,CAHvB,UAAW,CACX,QAAS,CACT,gBAGF","sources":["index.css","../../../node_modules/rc-slider/assets/index.css"],"sourcesContent":["@tailwind base;\n@tailwind components;\n@tailwind utilities;\n\n@import url('https://fonts.googleapis.com/css2?family=EB+Garamond:ital,wght@0,400;0,500;0,600;0,700;0,800;1,400;1,500;1,600;1,700;1,800&display=swap');\n\n@font-face {\n font-family: \"Redaction\";\n src: url(\"../public/fonts/Redaction50-Italic.otf\");\n}\n\nhtml {\n scroll-behavior: smooth;\n scrollbar-width: none; /* Firefox */\n -ms-overflow-style: none; /* IE 10+ */\n}\n\nhtml::-webkit-scrollbar {\n width: 0px;\n background: transparent; /* make scrollbar transparent */\n}\n\na {\n color: #233447;\n text-decoration: underline;\n font-weight: 700;\n}\n\n.p5Canvas {\n max-width: 370px;\n max-height: 550px;\n}\n\n.signatures > div > .p5Canvas {\n max-width: 14rem;\n max-height: 330px;\n}\n\n.flip-card {\n background-color: transparent;\n width: 24rem;\n height: 24rem;\n perspective: 2500px; /* Remove this if you don't want the 3D effect */\n}\n\n@media screen and (max-width: 600px) {\n .flip-card {\n width: 15rem;\n height: 15rem;\n }\n\n .p5Canvas {\n max-width: 300px;\n max-height: 450px;\n background-repeat: no-repeat;\n }\n}\n\n/* This container is needed to position the front and back side */\n.flip-card-inner {\n position: relative;\n width: 100%;\n height: 100%;\n text-align: center;\n transition: transform 1.2s;\n transform-style: preserve-3d;\n}\n\n.flip-card-inner-flipped {\n position: relative;\n width: 100%;\n height: 100%;\n text-align: center;\n transition: transform 1.2s;\n transform-style: preserve-3d;\n transform: rotateY(180deg);\n}\n\n/* Position the front and back side */\n.flip-card-front, .flip-card-back {\n position: absolute;\n width: 100%;\n height: 100%;\n -webkit-backface-visibility: hidden; /* Safari */\n backface-visibility: hidden;\n}\n\n/* Style the front side (fallback if image is missing) */\n.flip-card-front {\n color: black;\n}\n\n/* Style the back side */\n.flip-card-back {\n transform: rotateY(180deg);\n}",".rc-slider {\n position: relative;\n width: 100%;\n height: 14px;\n padding: 5px 0;\n border-radius: 6px;\n touch-action: none;\n box-sizing: border-box;\n -webkit-tap-highlight-color: rgba(0, 0, 0, 0);\n}\n.rc-slider * {\n box-sizing: border-box;\n -webkit-tap-highlight-color: rgba(0, 0, 0, 0);\n}\n.rc-slider-rail {\n position: absolute;\n width: 100%;\n height: 4px;\n background-color: #e9e9e9;\n border-radius: 6px;\n}\n.rc-slider-track {\n position: absolute;\n height: 4px;\n background-color: #abe2fb;\n border-radius: 6px;\n}\n.rc-slider-handle {\n position: absolute;\n width: 14px;\n height: 14px;\n margin-top: -5px;\n background-color: #fff;\n border: solid 2px #96dbfa;\n border-radius: 50%;\n cursor: pointer;\n cursor: -webkit-grab;\n cursor: grab;\n opacity: 0.8;\n touch-action: pan-x;\n}\n.rc-slider-handle-dragging.rc-slider-handle-dragging.rc-slider-handle-dragging {\n border-color: #57c5f7;\n box-shadow: 0 0 0 5px #96dbfa;\n}\n.rc-slider-handle:focus {\n outline: none;\n box-shadow: none;\n}\n.rc-slider-handle:focus-visible {\n border-color: #2db7f5;\n box-shadow: 0 0 0 3px #96dbfa;\n}\n.rc-slider-handle-click-focused:focus {\n border-color: #96dbfa;\n box-shadow: unset;\n}\n.rc-slider-handle:hover {\n border-color: #57c5f7;\n}\n.rc-slider-handle:active {\n border-color: #57c5f7;\n box-shadow: 0 0 5px #57c5f7;\n cursor: -webkit-grabbing;\n cursor: grabbing;\n}\n.rc-slider-mark {\n position: absolute;\n top: 18px;\n left: 0;\n width: 100%;\n font-size: 12px;\n}\n.rc-slider-mark-text {\n position: absolute;\n display: inline-block;\n color: #999;\n text-align: center;\n vertical-align: middle;\n cursor: pointer;\n}\n.rc-slider-mark-text-active {\n color: #666;\n}\n.rc-slider-step {\n position: absolute;\n width: 100%;\n height: 4px;\n background: transparent;\n pointer-events: none;\n}\n.rc-slider-dot {\n position: absolute;\n bottom: -2px;\n width: 8px;\n height: 8px;\n vertical-align: middle;\n background-color: #fff;\n border: 2px solid #e9e9e9;\n border-radius: 50%;\n cursor: pointer;\n}\n.rc-slider-dot-active {\n border-color: #96dbfa;\n}\n.rc-slider-dot-reverse {\n margin-right: -4px;\n}\n.rc-slider-disabled {\n background-color: #e9e9e9;\n}\n.rc-slider-disabled .rc-slider-track {\n background-color: #ccc;\n}\n.rc-slider-disabled .rc-slider-handle,\n.rc-slider-disabled .rc-slider-dot {\n background-color: #fff;\n border-color: #ccc;\n box-shadow: none;\n cursor: not-allowed;\n}\n.rc-slider-disabled .rc-slider-mark-text,\n.rc-slider-disabled .rc-slider-dot {\n cursor: not-allowed !important;\n}\n.rc-slider-vertical {\n width: 14px;\n height: 100%;\n padding: 0 5px;\n}\n.rc-slider-vertical .rc-slider-rail {\n width: 4px;\n height: 100%;\n}\n.rc-slider-vertical .rc-slider-track {\n bottom: 0;\n left: 5px;\n width: 4px;\n}\n.rc-slider-vertical .rc-slider-handle {\n margin-top: 0;\n margin-left: -5px;\n touch-action: pan-y;\n}\n.rc-slider-vertical .rc-slider-mark {\n top: 0;\n left: 18px;\n height: 100%;\n}\n.rc-slider-vertical .rc-slider-step {\n width: 4px;\n height: 100%;\n}\n.rc-slider-vertical .rc-slider-dot {\n margin-left: -2px;\n}\n.rc-slider-tooltip-zoom-down-enter,\n.rc-slider-tooltip-zoom-down-appear {\n display: block !important;\n animation-duration: 0.3s;\n animation-fill-mode: both;\n animation-play-state: paused;\n}\n.rc-slider-tooltip-zoom-down-leave {\n display: block !important;\n animation-duration: 0.3s;\n animation-fill-mode: both;\n animation-play-state: paused;\n}\n.rc-slider-tooltip-zoom-down-enter.rc-slider-tooltip-zoom-down-enter-active,\n.rc-slider-tooltip-zoom-down-appear.rc-slider-tooltip-zoom-down-appear-active {\n animation-name: rcSliderTooltipZoomDownIn;\n animation-play-state: running;\n}\n.rc-slider-tooltip-zoom-down-leave.rc-slider-tooltip-zoom-down-leave-active {\n animation-name: rcSliderTooltipZoomDownOut;\n animation-play-state: running;\n}\n.rc-slider-tooltip-zoom-down-enter,\n.rc-slider-tooltip-zoom-down-appear {\n transform: scale(0, 0);\n animation-timing-function: cubic-bezier(0.23, 1, 0.32, 1);\n}\n.rc-slider-tooltip-zoom-down-leave {\n animation-timing-function: cubic-bezier(0.755, 0.05, 0.855, 0.06);\n}\n@keyframes rcSliderTooltipZoomDownIn {\n 0% {\n transform: scale(0, 0);\n transform-origin: 50% 100%;\n opacity: 0;\n }\n 100% {\n transform: scale(1, 1);\n transform-origin: 50% 100%;\n }\n}\n@keyframes rcSliderTooltipZoomDownOut {\n 0% {\n transform: scale(1, 1);\n transform-origin: 50% 100%;\n }\n 100% {\n transform: scale(0, 0);\n transform-origin: 50% 100%;\n opacity: 0;\n }\n}\n.rc-slider-tooltip {\n position: absolute;\n top: -9999px;\n left: -9999px;\n visibility: visible;\n box-sizing: border-box;\n -webkit-tap-highlight-color: rgba(0, 0, 0, 0);\n}\n.rc-slider-tooltip * {\n box-sizing: border-box;\n -webkit-tap-highlight-color: rgba(0, 0, 0, 0);\n}\n.rc-slider-tooltip-hidden {\n display: none;\n}\n.rc-slider-tooltip-placement-top {\n padding: 4px 0 8px 0;\n}\n.rc-slider-tooltip-inner {\n min-width: 24px;\n height: 24px;\n padding: 6px 2px;\n color: #fff;\n font-size: 12px;\n line-height: 1;\n text-align: center;\n text-decoration: none;\n background-color: #6c6c6c;\n border-radius: 6px;\n box-shadow: 0 0 4px #d9d9d9;\n}\n.rc-slider-tooltip-arrow {\n position: absolute;\n width: 0;\n height: 0;\n border-color: transparent;\n border-style: solid;\n}\n.rc-slider-tooltip-placement-top .rc-slider-tooltip-arrow {\n bottom: 4px;\n left: 50%;\n margin-left: -4px;\n border-width: 4px 4px 0;\n border-top-color: #6c6c6c;\n}\n"],"names":[],"sourceRoot":""} \ No newline at end of file diff --git a/packages/dapp/dist/build/static/js/main.c752446b.js b/packages/dapp/dist/build/static/js/main.c752446b.js new file mode 100644 index 000000000..93d969568 --- /dev/null +++ b/packages/dapp/dist/build/static/js/main.c752446b.js @@ -0,0 +1,3 @@ +/*! For license information please see main.c752446b.js.LICENSE.txt */ +!function(){var e={7162:function(e,t,r){e.exports=r(5743)},3098:function(e,t,r){"use strict";r.d(t,{i:function(){return n}});var n="abi/5.6.1"},4062:function(e,t,r){"use strict";r.d(t,{R:function(){return N},$:function(){return D}});var n=r(9249),i=r(7371),o=r(2917),a=r(6574),s=r(1755),u=r(3098),l=r(2378),c=r(5754),f=r(6906),d=r(3652),h=function(e){(0,c.Z)(r,e);var t=(0,f.Z)(r);function r(e){return(0,n.Z)(this,r),t.call(this,"address","address",e,!1)}return(0,i.Z)(r,[{key:"defaultValue",value:function(){return"0x0000000000000000000000000000000000000000"}},{key:"encode",value:function(e,t){try{t=(0,d.getAddress)(t)}catch(r){this._throwError(r.message,t)}return e.writeValue(t)}},{key:"decode",value:function(e){return(0,d.getAddress)((0,o.hexZeroPad)(e.readValue().toHexString(),20))}}]),r}(l.XI),p=function(e){(0,c.Z)(r,e);var t=(0,f.Z)(r);function r(e){var i;return(0,n.Z)(this,r),(i=t.call(this,e.name,e.type,void 0,e.dynamic)).coder=e,i}return(0,i.Z)(r,[{key:"defaultValue",value:function(){return this.coder.defaultValue()}},{key:"encode",value:function(e,t){return this.coder.encode(e,t)}},{key:"decode",value:function(e){return this.coder.decode(e)}}]),r}(l.XI),m=new s.Logger(u.i);function y(e,t,r){var n=null;if(Array.isArray(r))n=r;else if(r&&"object"===typeof r){var i={};n=t.map((function(e){var t=e.localName;return t||m.throwError("cannot encode object for signature with missing names",s.Logger.errors.INVALID_ARGUMENT,{argument:"values",coder:e,value:r}),i[t]&&m.throwError("cannot encode object for signature with duplicate names",s.Logger.errors.INVALID_ARGUMENT,{argument:"values",coder:e,value:r}),i[t]=!0,r[t]}))}else m.throwArgumentError("invalid tuple value","tuple",r);t.length!==n.length&&m.throwArgumentError("types/value length mismatch","tuple",r);var o=new l.QV(e.wordSize),a=new l.QV(e.wordSize),u=[];t.forEach((function(e,t){var r=n[t];if(e.dynamic){var i=a.length;e.encode(a,r);var s=o.writeUpdatableValue();u.push((function(e){s(e+i)}))}else e.encode(o,r)})),u.forEach((function(e){e(o.length)}));var c=e.appendWriter(o);return c+=e.appendWriter(a)}function v(e,t){var r=[],n=e.subReader(0);t.forEach((function(t){var i=null;if(t.dynamic){var o=e.readValue(),a=n.subReader(o.toNumber());try{i=t.decode(a)}catch(u){if(u.code===s.Logger.errors.BUFFER_OVERRUN)throw u;(i=u).baseType=t.name,i.name=t.localName,i.type=t.type}}else try{i=t.decode(e)}catch(u){if(u.code===s.Logger.errors.BUFFER_OVERRUN)throw u;(i=u).baseType=t.name,i.name=t.localName,i.type=t.type}void 0!=i&&r.push(i)}));var i=t.reduce((function(e,t){var r=t.localName;return r&&(e[r]||(e[r]=0),e[r]++),e}),{});t.forEach((function(e,t){var n=e.localName;if(n&&1===i[n]&&("length"===n&&(n="_length"),null==r[n])){var o=r[t];o instanceof Error?Object.defineProperty(r,n,{enumerable:!0,get:function(){throw o}}):r[n]=o}}));for(var o=function(e){var t=r[e];t instanceof Error&&Object.defineProperty(r,e,{enumerable:!0,get:function(){throw t}})},a=0;a=0?i:"")+"]",u=-1===i||e.dynamic;return(a=t.call(this,"array",s,o,u)).coder=e,a.length=i,a}return(0,i.Z)(r,[{key:"defaultValue",value:function(){for(var e=this.coder.defaultValue(),t=[],r=0;re._data.length&&m.throwError("insufficient data length",s.Logger.errors.BUFFER_OVERRUN,{length:e._data.length,count:t});for(var r=[],n=0;n256||n%8!==0)&&R.throwArgumentError("invalid "+r[1]+" bit length","param",e),new M(n/8,"int"===r[1],e.name)}if(r=e.type.match(I)){var i=parseInt(r[1]);return(0===i||i>32)&&R.throwArgumentError("invalid bytes length","param",e),new k(i,e.name)}return R.throwArgumentError("invalid type","type",e.type)}},{key:"_getWordSize",value:function(){return 32}},{key:"_getReader",value:function(e,t){return new l.Ej(e,this._getWordSize(),this.coerceFunc,t)}},{key:"_getWriter",value:function(){return new l.QV(this._getWordSize())}},{key:"getDefaultValue",value:function(e){var t=this,r=e.map((function(e){return t._getCoder(O._R.from(e))}));return new C(r,"_").defaultValue()}},{key:"encode",value:function(e,t){var r=this;e.length!==t.length&&R.throwError("types/values length mismatch",s.Logger.errors.INVALID_ARGUMENT,{count:{types:e.length,values:t.length},value:{types:e,values:t}});var n=e.map((function(e){return r._getCoder(O._R.from(e))})),i=new C(n,"_"),o=this._getWriter();return i.encode(o,t),o.data}},{key:"decode",value:function(e,t,r){var n=this,i=e.map((function(e){return n._getCoder(O._R.from(e))}));return new C(i,"_").decode(this._getReader((0,o.arrayify)(t),r))}}]),e}(),D=new N},2378:function(e,t,r){"use strict";r.d(t,{BR:function(){return f},Ej:function(){return p},QV:function(){return h},XI:function(){return d}});var n=r(9249),i=r(7371),o=r(2917),a=r(8738),s=r(6574),u=r(1755),l=r(3098),c=new u.Logger(l.i);function f(e){var t=[];return function e(r,n){if(Array.isArray(n))for(var i in n){var o=r.slice();o.push(i);try{e(o,n[i])}catch(a){t.push({path:o,error:a})}}}([],e),t}var d=function(){function e(t,r,i,o){(0,n.Z)(this,e),this.name=t,this.type=r,this.localName=i,this.dynamic=o}return(0,i.Z)(e,[{key:"_throwError",value:function(e,t){c.throwArgumentError(e,this.localName,t)}}]),e}(),h=function(){function e(t){(0,n.Z)(this,e),(0,s.defineReadOnly)(this,"wordSize",t||32),this._data=[],this._dataLength=0,this._padding=new Uint8Array(t)}return(0,i.Z)(e,[{key:"data",get:function(){return(0,o.hexConcat)(this._data)}},{key:"length",get:function(){return this._dataLength}},{key:"_writeData",value:function(e){return this._data.push(e),this._dataLength+=e.length,e.length}},{key:"appendWriter",value:function(e){return this._writeData((0,o.concat)(e._data))}},{key:"writeBytes",value:function(e){var t=(0,o.arrayify)(e),r=t.length%this.wordSize;return r&&(t=(0,o.concat)([t,this._padding.slice(r)])),this._writeData(t)}},{key:"_getValue",value:function(e){var t=(0,o.arrayify)(a.O$.from(e));return t.length>this.wordSize&&c.throwError("value out-of-bounds",u.Logger.errors.BUFFER_OVERRUN,{length:this.wordSize,offset:t.length}),t.length%this.wordSize&&(t=(0,o.concat)([this._padding.slice(t.length%this.wordSize),t])),t}},{key:"writeValue",value:function(e){return this._writeData(this._getValue(e))}},{key:"writeUpdatableValue",value:function(){var e=this,t=this._data.length;return this._data.push(this._padding),this._dataLength+=this.wordSize,function(r){e._data[t]=e._getValue(r)}}}]),e}(),p=function(){function e(t,r,i,a){(0,n.Z)(this,e),(0,s.defineReadOnly)(this,"_data",(0,o.arrayify)(t)),(0,s.defineReadOnly)(this,"wordSize",r||32),(0,s.defineReadOnly)(this,"_coerceFunc",i),(0,s.defineReadOnly)(this,"allowLoose",a),this._offset=0}return(0,i.Z)(e,[{key:"data",get:function(){return(0,o.hexlify)(this._data)}},{key:"consumed",get:function(){return this._offset}},{key:"coerce",value:function(t,r){return this._coerceFunc?this._coerceFunc(t,r):e.coerce(t,r)}},{key:"_peekBytes",value:function(e,t,r){var n=Math.ceil(t/this.wordSize)*this.wordSize;return this._offset+n>this._data.length&&(this.allowLoose&&r&&this._offset+t<=this._data.length?n=t:c.throwError("data out-of-bounds",u.Logger.errors.BUFFER_OVERRUN,{length:this._data.length,offset:this._offset+n})),this._data.slice(this._offset,this._offset+n)}},{key:"subReader",value:function(t){return new e(this._data.slice(this._offset+t),this.wordSize,this._coerceFunc,this.allowLoose)}},{key:"readBytes",value:function(e,t){var r=this._peekBytes(0,e,!!t);return this._offset+=r.length,r.slice(0,e)}},{key:"readValue",value:function(){return a.O$.from(this.readBytes(this.wordSize))}}],[{key:"coerce",value:function(e,t){var r=e.match("^u?int([0-9]+)$");return r&&parseInt(r[1])<=48&&(t=t.toNumber()),t}}]),e}()},524:function(e,t,r){"use strict";r.d(t,{HY:function(){return x},IC:function(){return T},QV:function(){return _},Xg:function(){return A},YW:function(){return j},_R:function(){return b},pc:function(){return v}});var n=r(5754),i=r(6906),o=r(9249),a=r(7371),s=r(8738),u=r(6574),l=r(1755),c=r(3098),f=new l.Logger(c.i),d={},h={calldata:!0,memory:!0,storage:!0},p={calldata:!0,memory:!0};function m(e,t){if("bytes"===e||"string"===e){if(h[t])return!0}else if("address"===e){if("payable"===t)return!0}else if((e.indexOf("[")>=0||"tuple"===e)&&p[t])return!0;return(h[t]||"payable"===t)&&f.throwArgumentError("invalid modifier","name",t),!1}function y(e,t){for(var r in t)(0,u.defineReadOnly)(e,r,t[r])}var v=Object.freeze({sighash:"sighash",minimal:"minimal",full:"full",json:"json"}),g=new RegExp(/^(.*)\[([0-9]*)\]$/),b=function(){function e(t,r){(0,o.Z)(this,e),t!==d&&f.throwError("use fromString",l.Logger.errors.UNSUPPORTED_OPERATION,{operation:"new ParamType()"}),y(this,r);var n=this.type.match(g);y(this,n?{arrayLength:parseInt(n[2]||"-1"),arrayChildren:e.fromObject({type:n[1],components:this.components}),baseType:"array"}:{arrayLength:null,arrayChildren:null,baseType:null!=this.components?"tuple":this.type}),this._isParamType=!0,Object.freeze(this)}return(0,a.Z)(e,[{key:"format",value:function(e){if(e||(e=v.sighash),v[e]||f.throwArgumentError("invalid format type","format",e),e===v.json){var t={type:"tuple"===this.baseType?"tuple":this.type,name:this.name||void 0};return"boolean"===typeof this.indexed&&(t.indexed=this.indexed),this.components&&(t.components=this.components.map((function(t){return JSON.parse(t.format(e))}))),JSON.stringify(t)}var r="";return"array"===this.baseType?(r+=this.arrayChildren.format(e),r+="["+(this.arrayLength<0?"":String(this.arrayLength))+"]"):"tuple"===this.baseType?(e!==v.sighash&&(r+=this.type),r+="("+this.components.map((function(t){return t.format(e)})).join(e===v.full?", ":",")+")"):r+=this.type,e!==v.sighash&&(!0===this.indexed&&(r+=" indexed"),e===v.full&&this.name&&(r+=" "+this.name)),r}}],[{key:"from",value:function(t,r){return"string"===typeof t?e.fromString(t,r):e.fromObject(t)}},{key:"fromObject",value:function(t){return e.isParamType(t)?t:new e(d,{name:t.name||null,type:P(t.type),indexed:null==t.indexed?null:!!t.indexed,components:t.components?t.components.map(e.fromObject):null})}},{key:"fromString",value:function(t,r){return n=function(e,t){var r=e;function n(t){f.throwArgumentError("unexpected character at position ".concat(t),"param",e)}function i(e){var r={type:"",name:"",parent:e,state:{allowType:!0}};return t&&(r.indexed=!1),r}e=e.replace(/\s/g," ");for(var o={type:"",name:"",state:{allowType:!0}},a=o,s=0;s2&&f.throwArgumentError("invalid human-readable ABI signature","value",e),r[1].match(/^[0-9]+$/)||f.throwArgumentError("invalid human-readable ABI signature gas","value",e),t.gas=s.O$.from(r[1]),r[0]):e}function k(e,t){t.constant=!1,t.payable=!1,t.stateMutability="nonpayable",e.split(" ").forEach((function(e){switch(e.trim()){case"constant":t.constant=!0;break;case"payable":t.payable=!0,t.stateMutability="payable";break;case"nonpayable":t.payable=!1,t.stateMutability="nonpayable";break;case"pure":t.constant=!0,t.stateMutability="pure";break;case"view":t.constant=!0,t.stateMutability="view";break;case"external":case"public":case"":break;default:console.log("unknown modifier: "+e)}}))}function E(e){var t={constant:!1,payable:!0,stateMutability:"payable"};return null!=e.stateMutability?(t.stateMutability=e.stateMutability,t.constant="view"===t.stateMutability||"pure"===t.stateMutability,null!=e.constant&&!!e.constant!==t.constant&&f.throwArgumentError("cannot have constant function with mutability "+t.stateMutability,"value",e),t.payable="payable"===t.stateMutability,null!=e.payable&&!!e.payable!==t.payable&&f.throwArgumentError("cannot have payable function with mutability "+t.stateMutability,"value",e)):null!=e.payable?(t.payable=!!e.payable,null!=e.constant||t.payable||"constructor"===e.type||f.throwArgumentError("unable to determine stateMutability","value",e),t.constant=!!e.constant,t.constant?t.stateMutability="view":t.stateMutability=t.payable?"payable":"nonpayable",t.payable&&t.constant&&f.throwArgumentError("cannot have constant payable function","value",e)):null!=e.constant?(t.constant=!!e.constant,t.payable=!t.constant,t.stateMutability=t.constant?"view":"payable"):"constructor"!==e.type&&f.throwArgumentError("unable to determine stateMutability","value",e),t}var A=function(e){(0,n.Z)(r,e);var t=(0,i.Z)(r);function r(){return(0,o.Z)(this,r),t.apply(this,arguments)}return(0,a.Z)(r,[{key:"format",value:function(e){if(e||(e=v.sighash),v[e]||f.throwArgumentError("invalid format type","format",e),e===v.json)return JSON.stringify({type:"constructor",stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((function(t){return JSON.parse(t.format(e))}))});e===v.sighash&&f.throwError("cannot format a constructor for sighash",l.Logger.errors.UNSUPPORTED_OPERATION,{operation:"format(sighash)"});var t="constructor("+this.inputs.map((function(t){return t.format(e)})).join(e===v.full?", ":",")+") ";return this.stateMutability&&"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "),t.trim()}}],[{key:"from",value:function(e){return"string"===typeof e?r.fromString(e):r.fromObject(e)}},{key:"fromObject",value:function(e){if(r.isConstructorFragment(e))return e;"constructor"!==e.type&&f.throwArgumentError("invalid constructor object","value",e);var t=E(e);t.constant&&f.throwArgumentError("constructor cannot be constant","value",e);var n={name:null,type:e.type,inputs:e.inputs?e.inputs.map(b.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?s.O$.from(e.gas):null};return new r(d,n)}},{key:"fromString",value:function(e){var t={type:"constructor"},n=(e=S(e,t)).match(R);return n&&"constructor"===n[1].trim()||f.throwArgumentError("invalid constructor string","value",e),t.inputs=w(n[2].trim(),!1),k(n[3].trim(),t),r.fromObject(t)}},{key:"isConstructorFragment",value:function(e){return e&&e._isFragment&&"constructor"===e.type}}]),r}(x),j=function(e){(0,n.Z)(r,e);var t=(0,i.Z)(r);function r(){return(0,o.Z)(this,r),t.apply(this,arguments)}return(0,a.Z)(r,[{key:"format",value:function(e){if(e||(e=v.sighash),v[e]||f.throwArgumentError("invalid format type","format",e),e===v.json)return JSON.stringify({type:"function",name:this.name,constant:this.constant,stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((function(t){return JSON.parse(t.format(e))})),outputs:this.outputs.map((function(t){return JSON.parse(t.format(e))}))});var t="";return e!==v.sighash&&(t+="function "),t+=this.name+"("+this.inputs.map((function(t){return t.format(e)})).join(e===v.full?", ":",")+") ",e!==v.sighash&&(this.stateMutability?"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "):this.constant&&(t+="view "),this.outputs&&this.outputs.length&&(t+="returns ("+this.outputs.map((function(t){return t.format(e)})).join(", ")+") "),null!=this.gas&&(t+="@"+this.gas.toString()+" ")),t.trim()}}],[{key:"from",value:function(e){return"string"===typeof e?r.fromString(e):r.fromObject(e)}},{key:"fromObject",value:function(e){if(r.isFunctionFragment(e))return e;"function"!==e.type&&f.throwArgumentError("invalid function object","value",e);var t=E(e),n={type:e.type,name:O(e.name),constant:t.constant,inputs:e.inputs?e.inputs.map(b.fromObject):[],outputs:e.outputs?e.outputs.map(b.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?s.O$.from(e.gas):null};return new r(d,n)}},{key:"fromString",value:function(e){var t={type:"function"},n=(e=S(e,t)).split(" returns ");n.length>2&&f.throwArgumentError("invalid function string","value",e);var i=n[0].match(R);if(i||f.throwArgumentError("invalid function signature","value",e),t.name=i[1].trim(),t.name&&O(t.name),t.inputs=w(i[2],!1),k(i[3].trim(),t),n.length>1){var o=n[1].match(R);""==o[1].trim()&&""==o[3].trim()||f.throwArgumentError("unexpected tokens","value",e),t.outputs=w(o[2],!1)}else t.outputs=[];return r.fromObject(t)}},{key:"isFunctionFragment",value:function(e){return e&&e._isFragment&&"function"===e.type}}]),r}(A);function M(e){var t=e.format();return"Error(string)"!==t&&"Panic(uint256)"!==t||f.throwArgumentError("cannot specify user defined ".concat(t," error"),"fragment",e),e}var T=function(e){(0,n.Z)(r,e);var t=(0,i.Z)(r);function r(){return(0,o.Z)(this,r),t.apply(this,arguments)}return(0,a.Z)(r,[{key:"format",value:function(e){if(e||(e=v.sighash),v[e]||f.throwArgumentError("invalid format type","format",e),e===v.json)return JSON.stringify({type:"error",name:this.name,inputs:this.inputs.map((function(t){return JSON.parse(t.format(e))}))});var t="";return e!==v.sighash&&(t+="error "),(t+=this.name+"("+this.inputs.map((function(t){return t.format(e)})).join(e===v.full?", ":",")+") ").trim()}}],[{key:"from",value:function(e){return"string"===typeof e?r.fromString(e):r.fromObject(e)}},{key:"fromObject",value:function(e){if(r.isErrorFragment(e))return e;"error"!==e.type&&f.throwArgumentError("invalid error object","value",e);var t={type:e.type,name:O(e.name),inputs:e.inputs?e.inputs.map(b.fromObject):[]};return M(new r(d,t))}},{key:"fromString",value:function(e){var t={type:"error"},n=e.match(R);return n||f.throwArgumentError("invalid error signature","value",e),t.name=n[1].trim(),t.name&&O(t.name),t.inputs=w(n[2],!1),M(r.fromObject(t))}},{key:"isErrorFragment",value:function(e){return e&&e._isFragment&&"error"===e.type}}]),r}(x);function P(e){return e.match(/^uint($|[^1-9])/)?e="uint256"+e.substring(4):e.match(/^int($|[^1-9])/)&&(e="int256"+e.substring(3)),e}var C=new RegExp("^[a-zA-Z$_][a-zA-Z0-9$_]*$");function O(e){return e&&e.match(C)||f.throwArgumentError('invalid identifier "'.concat(e,'"'),"value",e),e}var R=new RegExp("^([^)(]*)\\((.*)\\)([^)(]*)$")},8085:function(e,t,r){"use strict";r.r(t),r.d(t,{AbiCoder:function(){return i.R},ConstructorFragment:function(){return n.Xg},ErrorFragment:function(){return n.IC},EventFragment:function(){return n.QV},FormatTypes:function(){return n.pc},Fragment:function(){return n.HY},FunctionFragment:function(){return n.YW},Indexed:function(){return o.Hk},Interface:function(){return o.vU},LogDescription:function(){return o.CC},ParamType:function(){return n._R},TransactionDescription:function(){return o.vk},checkResultErrors:function(){return a.BR},defaultAbiCoder:function(){return i.$}});var n=r(524),i=r(4062),o=r(7601),a=r(2378)},7601:function(e,t,r){"use strict";r.d(t,{CC:function(){return g},Hk:function(){return x},vU:function(){return k},vk:function(){return b}});var n=r(7371),i=r(9249),o=r(5754),a=r(6906),s=r(3652),u=r(8738),l=r(2917),c=r(1235),f=r(6220),d=r(6574),h=r(4062),p=r(524),m=r(1755),y=r(3098),v=new m.Logger(y.i),g=function(e){(0,o.Z)(r,e);var t=(0,a.Z)(r);function r(){return(0,i.Z)(this,r),t.apply(this,arguments)}return(0,n.Z)(r)}(d.Description),b=function(e){(0,o.Z)(r,e);var t=(0,a.Z)(r);function r(){return(0,i.Z)(this,r),t.apply(this,arguments)}return(0,n.Z)(r)}(d.Description),w=function(e){(0,o.Z)(r,e);var t=(0,a.Z)(r);function r(){return(0,i.Z)(this,r),t.apply(this,arguments)}return(0,n.Z)(r)}(d.Description),x=function(e){(0,o.Z)(r,e);var t=(0,a.Z)(r);function r(){return(0,i.Z)(this,r),t.apply(this,arguments)}return(0,n.Z)(r,null,[{key:"isIndexed",value:function(e){return!(!e||!e._isIndexed)}}]),r}(d.Description),_={"0x08c379a0":{signature:"Error(string)",name:"Error",inputs:["string"],reason:!0},"0x4e487b71":{signature:"Panic(uint256)",name:"Panic",inputs:["uint256"]}};function S(e,t){var r=new Error("deferred error during ABI decoding triggered accessing ".concat(e));return r.error=t,r}var k=function(){function e(t){var r=this;(0,i.Z)(this,e),v.checkNew(this instanceof e?this.constructor:void 0,e);var n=[];n="string"===typeof t?JSON.parse(t):t,(0,d.defineReadOnly)(this,"fragments",n.map((function(e){return p.HY.from(e)})).filter((function(e){return null!=e}))),(0,d.defineReadOnly)(this,"_abiCoder",(0,d.getStatic)(this instanceof e?this.constructor:void 0,"getAbiCoder")()),(0,d.defineReadOnly)(this,"functions",{}),(0,d.defineReadOnly)(this,"errors",{}),(0,d.defineReadOnly)(this,"events",{}),(0,d.defineReadOnly)(this,"structs",{}),this.fragments.forEach((function(e){var t=null;switch(e.type){case"constructor":return r.deploy?void v.warn("duplicate definition - constructor"):void(0,d.defineReadOnly)(r,"deploy",e);case"function":t=r.functions;break;case"event":t=r.events;break;case"error":t=r.errors;break;default:return}var n=e.format();t[n]?v.warn("duplicate definition - "+n):t[n]=e})),this.deploy||(0,d.defineReadOnly)(this,"deploy",p.Xg.from({payable:!1,type:"constructor"})),(0,d.defineReadOnly)(this,"_isInterface",!0)}return(0,n.Z)(e,[{key:"format",value:function(e){e||(e=p.pc.full),e===p.pc.sighash&&v.throwArgumentError("interface does not support formatting sighash","format",e);var t=this.fragments.map((function(t){return t.format(e)}));return e===p.pc.json?JSON.stringify(t.map((function(e){return JSON.parse(e)}))):t}},{key:"getFunction",value:function(e){if((0,l.isHexString)(e)){for(var t in this.functions)if(e===this.getSighash(t))return this.functions[t];v.throwArgumentError("no matching function","sighash",e)}if(-1===e.indexOf("(")){var r=e.trim(),n=Object.keys(this.functions).filter((function(e){return e.split("(")[0]===r}));return 0===n.length?v.throwArgumentError("no matching function","name",r):n.length>1&&v.throwArgumentError("multiple matching functions","name",r),this.functions[n[0]]}var i=this.functions[p.YW.fromString(e).format()];return i||v.throwArgumentError("no matching function","signature",e),i}},{key:"getEvent",value:function(e){if((0,l.isHexString)(e)){var t=e.toLowerCase();for(var r in this.events)if(t===this.getEventTopic(r))return this.events[r];v.throwArgumentError("no matching event","topichash",t)}if(-1===e.indexOf("(")){var n=e.trim(),i=Object.keys(this.events).filter((function(e){return e.split("(")[0]===n}));return 0===i.length?v.throwArgumentError("no matching event","name",n):i.length>1&&v.throwArgumentError("multiple matching events","name",n),this.events[i[0]]}var o=this.events[p.QV.fromString(e).format()];return o||v.throwArgumentError("no matching event","signature",e),o}},{key:"getError",value:function(e){if((0,l.isHexString)(e)){var t=(0,d.getStatic)(this.constructor,"getSighash");for(var r in this.errors){if(e===t(this.errors[r]))return this.errors[r]}v.throwArgumentError("no matching error","sighash",e)}if(-1===e.indexOf("(")){var n=e.trim(),i=Object.keys(this.errors).filter((function(e){return e.split("(")[0]===n}));return 0===i.length?v.throwArgumentError("no matching error","name",n):i.length>1&&v.throwArgumentError("multiple matching errors","name",n),this.errors[i[0]]}var o=this.errors[p.YW.fromString(e).format()];return o||v.throwArgumentError("no matching error","signature",e),o}},{key:"getSighash",value:function(e){if("string"===typeof e)try{e=this.getFunction(e)}catch(t){try{e=this.getError(e)}catch(r){throw t}}return(0,d.getStatic)(this.constructor,"getSighash")(e)}},{key:"getEventTopic",value:function(e){return"string"===typeof e&&(e=this.getEvent(e)),(0,d.getStatic)(this.constructor,"getEventTopic")(e)}},{key:"_decodeParams",value:function(e,t){return this._abiCoder.decode(e,t)}},{key:"_encodeParams",value:function(e,t){return this._abiCoder.encode(e,t)}},{key:"encodeDeploy",value:function(e){return this._encodeParams(this.deploy.inputs,e||[])}},{key:"decodeErrorResult",value:function(e,t){"string"===typeof e&&(e=this.getError(e));var r=(0,l.arrayify)(t);return(0,l.hexlify)(r.slice(0,4))!==this.getSighash(e)&&v.throwArgumentError("data signature does not match error ".concat(e.name,"."),"data",(0,l.hexlify)(r)),this._decodeParams(e.inputs,r.slice(4))}},{key:"encodeErrorResult",value:function(e,t){return"string"===typeof e&&(e=this.getError(e)),(0,l.hexlify)((0,l.concat)([this.getSighash(e),this._encodeParams(e.inputs,t||[])]))}},{key:"decodeFunctionData",value:function(e,t){"string"===typeof e&&(e=this.getFunction(e));var r=(0,l.arrayify)(t);return(0,l.hexlify)(r.slice(0,4))!==this.getSighash(e)&&v.throwArgumentError("data signature does not match function ".concat(e.name,"."),"data",(0,l.hexlify)(r)),this._decodeParams(e.inputs,r.slice(4))}},{key:"encodeFunctionData",value:function(e,t){return"string"===typeof e&&(e=this.getFunction(e)),(0,l.hexlify)((0,l.concat)([this.getSighash(e),this._encodeParams(e.inputs,t||[])]))}},{key:"decodeFunctionResult",value:function(e,t){"string"===typeof e&&(e=this.getFunction(e));var r=(0,l.arrayify)(t),n=null,i="",o=null,a=null,s=null;switch(r.length%this._abiCoder._getWordSize()){case 0:try{return this._abiCoder.decode(e.outputs,r)}catch(f){}break;case 4:var u=(0,l.hexlify)(r.slice(0,4)),c=_[u];if(c)o=this._abiCoder.decode(c.inputs,r.slice(4)),a=c.name,s=c.signature,c.reason&&(n=o[0]),"Error"===a?i="; VM Exception while processing transaction: reverted with reason string ".concat(JSON.stringify(o[0])):"Panic"===a&&(i="; VM Exception while processing transaction: reverted with panic code ".concat(o[0]));else try{var f=this.getError(u);o=this._abiCoder.decode(f.inputs,r.slice(4)),a=f.name,s=f.format()}catch(f){}}return v.throwError("call revert exception"+i,m.Logger.errors.CALL_EXCEPTION,{method:e.format(),data:(0,l.hexlify)(t),errorArgs:o,errorName:a,errorSignature:s,reason:n})}},{key:"encodeFunctionResult",value:function(e,t){return"string"===typeof e&&(e=this.getFunction(e)),(0,l.hexlify)(this._abiCoder.encode(e.outputs,t||[]))}},{key:"encodeFilterTopics",value:function(e,t){var r=this;"string"===typeof e&&(e=this.getEvent(e)),t.length>e.inputs.length&&v.throwError("too many arguments for "+e.format(),m.Logger.errors.UNEXPECTED_ARGUMENT,{argument:"values",value:t});var n=[];e.anonymous||n.push(this.getEventTopic(e));var i=function(e,t){return"string"===e.type?(0,c.id)(t):"bytes"===e.type?(0,f.keccak256)((0,l.hexlify)(t)):("address"===e.type&&r._abiCoder.encode(["address"],[t]),(0,l.hexZeroPad)((0,l.hexlify)(t),32))};for(t.forEach((function(t,r){var o=e.inputs[r];o.indexed?null==t?n.push(null):"array"===o.baseType||"tuple"===o.baseType?v.throwArgumentError("filtering with tuples or arrays not supported","contract."+o.name,t):Array.isArray(t)?n.push(t.map((function(e){return i(o,e)}))):n.push(i(o,t)):null!=t&&v.throwArgumentError("cannot filter non-indexed parameters; must be null","contract."+o.name,t)}));n.length&&null===n[n.length-1];)n.pop();return n}},{key:"encodeEventLog",value:function(e,t){var r=this;"string"===typeof e&&(e=this.getEvent(e));var n=[],i=[],o=[];return e.anonymous||n.push(this.getEventTopic(e)),t.length!==e.inputs.length&&v.throwArgumentError("event arguments/values mismatch","values",t),e.inputs.forEach((function(e,a){var s=t[a];if(e.indexed)if("string"===e.type)n.push((0,c.id)(s));else if("bytes"===e.type)n.push((0,f.keccak256)(s));else{if("tuple"===e.baseType||"array"===e.baseType)throw new Error("not implemented");n.push(r._abiCoder.encode([e.type],[s]))}else i.push(e),o.push(s)})),{data:this._abiCoder.encode(i,o),topics:n}}},{key:"decodeEventLog",value:function(e,t,r){if("string"===typeof e&&(e=this.getEvent(e)),null!=r&&!e.anonymous){var n=this.getEventTopic(e);(0,l.isHexString)(r[0],32)&&r[0].toLowerCase()===n||v.throwError("fragment/topic mismatch",m.Logger.errors.INVALID_ARGUMENT,{argument:"topics[0]",expected:n,value:r[0]}),r=r.slice(1)}var i=[],o=[],a=[];e.inputs.forEach((function(e,t){e.indexed?"string"===e.type||"bytes"===e.type||"tuple"===e.baseType||"array"===e.baseType?(i.push(p._R.fromObject({type:"bytes32",name:e.name})),a.push(!0)):(i.push(e),a.push(!1)):(o.push(e),a.push(!1))}));var s=null!=r?this._abiCoder.decode(i,(0,l.concat)(r)):null,u=this._abiCoder.decode(o,t,!0),c=[],f=0,d=0;e.inputs.forEach((function(e,t){if(e.indexed)if(null==s)c[t]=new x({_isIndexed:!0,hash:null});else if(a[t])c[t]=new x({_isIndexed:!0,hash:s[d++]});else try{c[t]=s[d++]}catch(n){c[t]=n}else try{c[t]=u[f++]}catch(n){c[t]=n}if(e.name&&null==c[e.name]){var r=c[t];r instanceof Error?Object.defineProperty(c,e.name,{enumerable:!0,get:function(){throw S("property ".concat(JSON.stringify(e.name)),r)}}):c[e.name]=r}}));for(var h=function(e){var t=c[e];t instanceof Error&&Object.defineProperty(c,e,{enumerable:!0,get:function(){throw S("index ".concat(e),t)}})},y=0;y=0)throw e;return h.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",f.Logger.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,tx:r})}))),null==r.chainId?r.chainId=this.getChainId():r.chainId=Promise.all([Promise.resolve(r.chainId),this.getChainId()]).then((function(t){return 0!==t[1]&&t[0]!==t[1]&&h.throwArgumentError("chainId address mismatch","transaction",e),t[0]})),t.next=23,(0,c.resolveProperties)(r);case 23:return t.abrupt("return",t.sent);case 24:case"end":return t.stop()}}),t,this)})))}},{key:"_checkProvider",value:function(e){this.provider||h.throwError("missing provider",f.Logger.errors.UNSUPPORTED_OPERATION,{operation:e||"_checkProvider"})}}],[{key:"isSigner",value:function(e){return!(!e||!e._isSigner)}}]),e}(),v=function(e){(0,i.Z)(r,e);var t=(0,o.Z)(r);function r(e,i){var o;return(0,a.Z)(this,r),h.checkNew(this instanceof r?this.constructor:void 0,r),o=t.call(this),(0,c.defineReadOnly)((0,n.Z)(o),"address",e),(0,c.defineReadOnly)((0,n.Z)(o),"provider",i||null),o}return(0,s.Z)(r,[{key:"getAddress",value:function(){return Promise.resolve(this.address)}},{key:"_fail",value:function(e,t){return Promise.resolve().then((function(){h.throwError(e,f.Logger.errors.UNSUPPORTED_OPERATION,{operation:t})}))}},{key:"signMessage",value:function(e){return this._fail("VoidSigner cannot sign messages","signMessage")}},{key:"signTransaction",value:function(e){return this._fail("VoidSigner cannot sign transactions","signTransaction")}},{key:"_signTypedData",value:function(e,t,r){return this._fail("VoidSigner cannot sign typed data","signTypedData")}},{key:"connect",value:function(e){return new r(this.address,e)}}]),r}(y)},3652:function(e,t,r){"use strict";r.r(t),r.d(t,{getAddress:function(){return m},getContractAddress:function(){return g},getCreate2Address:function(){return b},getIcapAddress:function(){return v},isAddress:function(){return y}});var n=r(2917),i=r(8738),o=r(6220),a=r(4228),s=new(r(1755).Logger)("address/5.6.0");function u(e){(0,n.isHexString)(e,20)||s.throwArgumentError("invalid address","address",e);for(var t=(e=e.toLowerCase()).substring(2).split(""),r=new Uint8Array(40),i=0;i<40;i++)r[i]=t[i].charCodeAt(0);for(var a=(0,n.arrayify)((0,o.keccak256)(r)),u=0;u<40;u+=2)a[u>>1]>>4>=8&&(t[u]=t[u].toUpperCase()),(15&a[u>>1])>=8&&(t[u+1]=t[u+1].toUpperCase());return"0x"+t.join("")}for(var l={},c=0;c<10;c++)l[String(c)]=String(c);for(var f=0;f<26;f++)l[String.fromCharCode(65+f)]=String(10+f);var d,h=Math.floor((d=9007199254740991,Math.log10?Math.log10(d):Math.log(d)/Math.LN10));function p(e){for(var t=(e=(e=e.toUpperCase()).substring(4)+e.substring(0,2)+"00").split("").map((function(e){return l[e]})).join("");t.length>=h;){var r=t.substring(0,h);t=parseInt(r,10)%97+t.substring(r.length)}for(var n=String(98-parseInt(t,10)%97);n.length<2;)n="0"+n;return n}function m(e){var t=null;if("string"!==typeof e&&s.throwArgumentError("invalid address","address",e),e.match(/^(0x)?[0-9a-fA-F]{40}$/))"0x"!==e.substring(0,2)&&(e="0x"+e),t=u(e),e.match(/([A-F].*[a-f])|([a-f].*[A-F])/)&&t!==e&&s.throwArgumentError("bad address checksum","address",e);else if(e.match(/^XE[0-9]{2}[0-9A-Za-z]{30,31}$/)){for(e.substring(2,4)!==p(e)&&s.throwArgumentError("bad icap checksum","address",e),t=(0,i.g$)(e.substring(4));t.length<40;)t="0"+t;t=u("0x"+t)}else s.throwArgumentError("invalid address","address",e);return t}function y(e){try{return m(e),!0}catch(t){}return!1}function v(e){for(var t=(0,i.t2)(m(e).substring(2)).toUpperCase();t.length<30;)t="0"+t;return"XE"+p("XE00"+t)+t}function g(e){var t=null;try{t=m(e.from)}catch(u){s.throwArgumentError("missing from address","transaction",e)}var r=(0,n.stripZeros)((0,n.arrayify)(i.O$.from(e.nonce).toHexString()));return m((0,n.hexDataSlice)((0,o.keccak256)((0,a.encode)([t,r])),12))}function b(e,t,r){return 32!==(0,n.hexDataLength)(t)&&s.throwArgumentError("salt must be 32 bytes","salt",t),32!==(0,n.hexDataLength)(r)&&s.throwArgumentError("initCodeHash must be 32 bytes","initCodeHash",r),m((0,n.hexDataSlice)((0,o.keccak256)((0,n.concat)(["0xff",m(e),t,r])),12))}},9911:function(e,t,r){"use strict";r.d(t,{J:function(){return i},c:function(){return o}});var n=r(2917);function i(e){e=atob(e);for(var t=[],r=0;r0;)r.push(i%this.base),i=i/this.base|0}for(var s="",u=0;0===t[u]&&u=0;--l)s+=this.alphabet[r[l]];return s}},{key:"decode",value:function(e){if("string"!==typeof e)throw new TypeError("Expected String");var t=[];if(0===e.length)return new Uint8Array(t);t.push(0);for(var r=0;r>=8;for(;i>0;)t.push(255&i),i>>=8}for(var s=0;e[s]===this._leader&&s0&&(10===arguments[0]?m||(m=!0,f.warn("BigNumber.toString does not accept any parameters; base-10 is assumed")):16===arguments[0]?f.throwError("BigNumber.toString does not accept any parameters; use bigNumber.toHexString()",u.Logger.errors.UNEXPECTED_ARGUMENT,{}):f.throwError("BigNumber.toString does not accept parameters",u.Logger.errors.UNEXPECTED_ARGUMENT,{})),b(this).toString(10)}},{key:"toHexString",value:function(){return this._hex}},{key:"toJSON",value:function(e){return{type:"BigNumber",hex:this.toHexString()}}}],[{key:"from",value:function(t){if(t instanceof e)return t;if("string"===typeof t)return t.match(/^-?0x[0-9a-f]+$/i)?new e(d,v(t)):t.match(/^-?[0-9]+$/)?new e(d,v(new c(t))):f.throwArgumentError("invalid BigNumber string","value",t);if("number"===typeof t)return t%1&&w("underflow","BigNumber.from",t),(t>=h||t<=-h)&&w("overflow","BigNumber.from",t),e.from(String(t));var r=t;if("bigint"===typeof r)return e.from(r.toString());if((0,s.isBytes)(r))return e.from((0,s.hexlify)(r));if(r)if(r.toHexString){var n=r.toHexString();if("string"===typeof n)return e.from(n)}else{var i=r._hex;if(null==i&&"BigNumber"===r.type&&(i=r.hex),"string"===typeof i&&((0,s.isHexString)(i)||"-"===i[0]&&(0,s.isHexString)(i.substring(1))))return e.from(i)}return f.throwArgumentError("invalid BigNumber value","value",t)}},{key:"isBigNumber",value:function(e){return!(!e||!e._isBigNumber)}}]),e}();function v(e){if("string"!==typeof e)return v(e.toString(16));if("-"===e[0])return"-"===(e=e.substring(1))[0]&&f.throwArgumentError("invalid hex","value",e),"0x00"===(e=v(e))?e:"-"+e;if("0x"!==e.substring(0,2)&&(e="0x"+e),"0x"===e)return"0x00";for(e.length%2&&(e="0x0"+e.substring(2));e.length>4&&"0x00"===e.substring(0,4);)e="0x"+e.substring(4);return e}function g(e){return y.from(v(e))}function b(e){var t=y.from(e).toHexString();return"-"===t[0]?new c("-"+t.substring(3),16):new c(t.substring(2),16)}function w(e,t,r){var n={fault:e,operation:t};return null!=r&&(n.value=r),f.throwError(e,u.Logger.errors.NUMERIC_FAULT,n)}function x(e){return new c(e,36).toString(16)}function _(e){return new c(e,16).toString(36)}},5494:function(e,t,r){"use strict";r.d(t,{Ox:function(){return v},S5:function(){return y},xO:function(){return g},xs:function(){return b}});var n=r(9249),i=r(7371),o=r(2917),a=r(1755),s=r(4918),u=r(8738),l=new a.Logger(s.i),c={},f=u.O$.from(0),d=u.O$.from(-1);function h(e,t,r,n){var i={fault:t,operation:r};return void 0!==n&&(i.value=n),l.throwError(e,a.Logger.errors.NUMERIC_FAULT,i)}for(var p="0";p.length<256;)p+=p;function m(e){if("number"!==typeof e)try{e=u.O$.from(e).toNumber()}catch(t){}return"number"===typeof e&&e>=0&&e<=256&&!(e%1)?"1"+p.substring(0,e):l.throwArgumentError("invalid decimal size","decimals",e)}function y(e,t){null==t&&(t=0);var r=m(t),n=(e=u.O$.from(e)).lt(f);n&&(e=e.mul(d));for(var i=e.mod(r).toString();i.length2&&l.throwArgumentError("too many decimal points","value",e);var o=i[0],a=i[1];for(o||(o="0"),a||(a="0");"0"===a[a.length-1];)a=a.substring(0,a.length-1);for(a.length>r.length-1&&h("fractional component exceeds decimals","underflow","parseFixed"),""===a&&(a="0");a.length80&&l.throwArgumentError("invalid fixed format (decimals too large)","format.decimals",i),new e(c,r,n,i)}}]),e}(),b=function(){function e(t,r,i,o){(0,n.Z)(this,e),l.checkNew(this instanceof e?this.constructor:void 0,e),t!==c&&l.throwError("cannot use FixedNumber constructor; use FixedNumber.from",a.Logger.errors.UNSUPPORTED_OPERATION,{operation:"new FixedFormat"}),this.format=o,this._hex=r,this._value=i,this._isFixedNumber=!0,Object.freeze(this)}return(0,i.Z)(e,[{key:"_checkFormat",value:function(e){this.format.name!==e.format.name&&l.throwArgumentError("incompatible format; use fixedNumber.toFormat","other",e)}},{key:"addUnsafe",value:function(t){this._checkFormat(t);var r=v(this._value,this.format.decimals),n=v(t._value,t.format.decimals);return e.fromValue(r.add(n),this.format.decimals,this.format)}},{key:"subUnsafe",value:function(t){this._checkFormat(t);var r=v(this._value,this.format.decimals),n=v(t._value,t.format.decimals);return e.fromValue(r.sub(n),this.format.decimals,this.format)}},{key:"mulUnsafe",value:function(t){this._checkFormat(t);var r=v(this._value,this.format.decimals),n=v(t._value,t.format.decimals);return e.fromValue(r.mul(n).div(this.format._multiplier),this.format.decimals,this.format)}},{key:"divUnsafe",value:function(t){this._checkFormat(t);var r=v(this._value,this.format.decimals),n=v(t._value,t.format.decimals);return e.fromValue(r.mul(this.format._multiplier).div(n),this.format.decimals,this.format)}},{key:"floor",value:function(){var t=this.toString().split(".");1===t.length&&t.push("0");var r=e.from(t[0],this.format),n=!t[1].match(/^(0*)$/);return this.isNegative()&&n&&(r=r.subUnsafe(w.toFormat(r.format))),r}},{key:"ceiling",value:function(){var t=this.toString().split(".");1===t.length&&t.push("0");var r=e.from(t[0],this.format),n=!t[1].match(/^(0*)$/);return!this.isNegative()&&n&&(r=r.addUnsafe(w.toFormat(r.format))),r}},{key:"round",value:function(t){null==t&&(t=0);var r=this.toString().split(".");if(1===r.length&&r.push("0"),(t<0||t>80||t%1)&&l.throwArgumentError("invalid decimal count","decimals",t),r[1].length<=t)return this;var n=e.from("1"+p.substring(0,t),this.format),i=x.toFormat(this.format);return this.mulUnsafe(n).addUnsafe(i).floor().divUnsafe(n)}},{key:"isZero",value:function(){return"0.0"===this._value||"0"===this._value}},{key:"isNegative",value:function(){return"-"===this._value[0]}},{key:"toString",value:function(){return this._value}},{key:"toHexString",value:function(e){if(null==e)return this._hex;e%8&&l.throwArgumentError("invalid byte width","width",e);var t=u.O$.from(this._hex).fromTwos(this.format.width).toTwos(e).toHexString();return(0,o.hexZeroPad)(t,e/8)}},{key:"toUnsafeFloat",value:function(){return parseFloat(this.toString())}},{key:"toFormat",value:function(t){return e.fromString(this._value,t)}}],[{key:"fromValue",value:function(t,r,n){return null!=n||null==r||(0,u.Zm)(r)||(n=r,r=null),null==r&&(r=0),null==n&&(n="fixed"),e.fromString(y(t,r),g.from(n))}},{key:"fromString",value:function(t,r){null==r&&(r="fixed");var n=g.from(r),i=v(t,n.decimals);!n.signed&&i.lt(f)&&h("unsigned value cannot be negative","overflow","value",t);var a=null;n.signed?a=i.toTwos(n.width).toHexString():(a=i.toHexString(),a=(0,o.hexZeroPad)(a,n.width/8));var s=y(i,n.decimals);return new e(c,a,s,n)}},{key:"fromBytes",value:function(t,r){null==r&&(r="fixed");var n=g.from(r);if((0,o.arrayify)(t).length>n.width/8)throw new Error("overflow");var i=u.O$.from(t);n.signed&&(i=i.fromTwos(n.width));var a=i.toTwos((n.signed?0:1)+n.width).toHexString(),s=y(i,n.decimals);return new e(c,a,s,n)}},{key:"from",value:function(t,r){if("string"===typeof t)return e.fromString(t,r);if((0,o.isBytes)(t))return e.fromBytes(t,r);try{return e.fromValue(t,0,r)}catch(n){if(n.code!==a.Logger.errors.INVALID_ARGUMENT)throw n}return l.throwArgumentError("invalid FixedNumber value","value",t)}},{key:"isFixedNumber",value:function(e){return!(!e||!e._isFixedNumber)}}]),e}(),w=b.from(1),x=b.from("0.5")},5177:function(e,t,r){"use strict";r.r(t),r.d(t,{BigNumber:function(){return n.O$},FixedFormat:function(){return i.xO},FixedNumber:function(){return i.xs},_base16To36:function(){return n.t2},_base36To16:function(){return n.g$},formatFixed:function(){return i.S5},parseFixed:function(){return i.Ox}});var n=r(8738),i=r(5494)},2917:function(e,t,r){"use strict";r.r(t),r.d(t,{arrayify:function(){return l},concat:function(){return c},hexConcat:function(){return g},hexDataLength:function(){return y},hexDataSlice:function(){return v},hexStripZeros:function(){return w},hexValue:function(){return b},hexZeroPad:function(){return x},hexlify:function(){return m},isBytes:function(){return u},isBytesLike:function(){return a},isHexString:function(){return h},joinSignature:function(){return S},splitSignature:function(){return _},stripZeros:function(){return f},zeroPad:function(){return d}});var n=new(r(1755).Logger)("bytes/5.6.1");function i(e){return!!e.toHexString}function o(e){return e.slice||(e.slice=function(){var t=Array.prototype.slice.call(arguments);return o(new Uint8Array(Array.prototype.slice.apply(e,t)))}),e}function a(e){return h(e)&&!(e.length%2)||u(e)}function s(e){return"number"===typeof e&&e==e&&e%1===0}function u(e){if(null==e)return!1;if(e.constructor===Uint8Array)return!0;if("string"===typeof e)return!1;if(!s(e.length)||e.length<0)return!1;for(var t=0;t=256)return!1}return!0}function l(e,t){if(t||(t={}),"number"===typeof e){n.checkSafeUint53(e,"invalid arrayify value");for(var r=[];e;)r.unshift(255&e),e=parseInt(String(e/256));return 0===r.length&&r.push(0),o(new Uint8Array(r))}if(t.allowMissingPrefix&&"string"===typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),i(e)&&(e=e.toHexString()),h(e)){var a=e.substring(2);a.length%2&&("left"===t.hexPad?a="0"+a:"right"===t.hexPad?a+="0":n.throwArgumentError("hex data is odd-length","value",e));for(var s=[],l=0;lt&&n.throwArgumentError("value out of range","value",arguments[0]);var r=new Uint8Array(t);return r.set(e,t-e.length),o(r)}function h(e,t){return!("string"!==typeof e||!e.match(/^0x[0-9A-Fa-f]*$/))&&(!t||e.length===2+2*t)}var p="0123456789abcdef";function m(e,t){if(t||(t={}),"number"===typeof e){n.checkSafeUint53(e,"invalid hexlify value");for(var r="";e;)r=p[15&e]+r,e=Math.floor(e/16);return r.length?(r.length%2&&(r="0"+r),"0x"+r):"0x00"}if("bigint"===typeof e)return(e=e.toString(16)).length%2?"0x0"+e:"0x"+e;if(t.allowMissingPrefix&&"string"===typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),i(e))return e.toHexString();if(h(e))return e.length%2&&("left"===t.hexPad?e="0x0"+e.substring(2):"right"===t.hexPad?e+="0":n.throwArgumentError("hex data is odd-length","value",e)),e.toLowerCase();if(u(e)){for(var o="0x",a=0;a>4]+p[15&s]}return o}return n.throwArgumentError("invalid hexlify value","value",e)}function y(e){if("string"!==typeof e)e=m(e);else if(!h(e)||e.length%2)return null;return(e.length-2)/2}function v(e,t,r){return"string"!==typeof e?e=m(e):(!h(e)||e.length%2)&&n.throwArgumentError("invalid hexData","value",e),t=2+2*t,null!=r?"0x"+e.substring(t,2+2*r):"0x"+e.substring(t)}function g(e){var t="0x";return e.forEach((function(e){t+=m(e).substring(2)})),t}function b(e){var t=w(m(e,{hexPad:"left"}));return"0x"===t?"0x0":t}function w(e){"string"!==typeof e&&(e=m(e)),h(e)||n.throwArgumentError("invalid hex string","value",e),e=e.substring(2);for(var t=0;t2*t+2&&n.throwArgumentError("value out of range","value",arguments[1]);e.length<2*t+2;)e="0x0"+e.substring(2);return e}function _(e){var t={r:"0x",s:"0x",_vs:"0x",recoveryParam:0,v:0,yParityAndS:"0x",compact:"0x"};if(a(e)){var r=l(e);64===r.length?(t.v=27+(r[32]>>7),r[32]&=127,t.r=m(r.slice(0,32)),t.s=m(r.slice(32,64))):65===r.length?(t.r=m(r.slice(0,32)),t.s=m(r.slice(32,64)),t.v=r[64]):n.throwArgumentError("invalid signature string","signature",e),t.v<27&&(0===t.v||1===t.v?t.v+=27:n.throwArgumentError("signature invalid v byte","signature",e)),t.recoveryParam=1-t.v%2,t.recoveryParam&&(r[32]|=128),t._vs=m(r.slice(32,64))}else{if(t.r=e.r,t.s=e.s,t.v=e.v,t.recoveryParam=e.recoveryParam,t._vs=e._vs,null!=t._vs){var i=d(l(t._vs),32);t._vs=m(i);var o=i[0]>=128?1:0;null==t.recoveryParam?t.recoveryParam=o:t.recoveryParam!==o&&n.throwArgumentError("signature recoveryParam mismatch _vs","signature",e),i[0]&=127;var s=m(i);null==t.s?t.s=s:t.s!==s&&n.throwArgumentError("signature v mismatch _vs","signature",e)}if(null==t.recoveryParam)null==t.v?n.throwArgumentError("signature missing v and recoveryParam","signature",e):0===t.v||1===t.v?t.recoveryParam=t.v:t.recoveryParam=1-t.v%2;else if(null==t.v)t.v=27+t.recoveryParam;else{var u=0===t.v||1===t.v?t.v:1-t.v%2;t.recoveryParam!==u&&n.throwArgumentError("signature recoveryParam mismatch v","signature",e)}null!=t.r&&h(t.r)?t.r=x(t.r,32):n.throwArgumentError("signature missing or invalid r","signature",e),null!=t.s&&h(t.s)?t.s=x(t.s,32):n.throwArgumentError("signature missing or invalid s","signature",e);var c=l(t.s);c[0]>=128&&n.throwArgumentError("signature s out of range","signature",e),t.recoveryParam&&(c[0]|=128);var f=m(c);t._vs&&(h(t._vs)||n.throwArgumentError("signature invalid _vs","signature",e),t._vs=x(t._vs,32)),null==t._vs?t._vs=f:t._vs!==f&&n.throwArgumentError("signature _vs mismatch v and s","signature",e)}return t.yParityAndS=t._vs,t.compact=t.r+t.yParityAndS.substring(2),t}function S(e){return m(c([(e=_(e)).r,e.s,e.recoveryParam?"0x1c":"0x1b"]))}},4167:function(e,t,r){"use strict";r.d(t,{d:function(){return n}});var n="0x0000000000000000000000000000000000000000"},2742:function(e,t,r){"use strict";r.d(t,{$B:function(){return c},Bz:function(){return l},Ce:function(){return u},PS:function(){return f},Py:function(){return s},_Y:function(){return o},fh:function(){return a},tL:function(){return i}});var n=r(8738),i=n.O$.from(-1),o=n.O$.from(0),a=n.O$.from(1),s=n.O$.from(2),u=n.O$.from("1000000000000000000"),l=n.O$.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"),c=n.O$.from("-0x8000000000000000000000000000000000000000000000000000000000000000"),f=n.O$.from("0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff")},6926:function(e,t,r){"use strict";r.d(t,{R:function(){return n}});var n="0x0000000000000000000000000000000000000000000000000000000000000000"},1145:function(e,t,r){"use strict";r.r(t),r.d(t,{AddressZero:function(){return n.d},EtherSymbol:function(){return a},HashZero:function(){return o.R},MaxInt256:function(){return i.PS},MaxUint256:function(){return i.Bz},MinInt256:function(){return i.$B},NegativeOne:function(){return i.tL},One:function(){return i.fh},Two:function(){return i.Py},WeiPerEther:function(){return i.Ce},Zero:function(){return i._Y}});var n=r(4167),i=r(2742),o=r(6926),a="\u039e"},4536:function(e,t,r){"use strict";r.r(t),r.d(t,{BaseContract:function(){return D},Contract:function(){return F},ContractFactory:function(){return U}});var n=r(8777),i=r(753),o=r(3069),a=r(5058),s=r(5754),u=r(6906),l=r(9249),c=r(7371),f=r(7162),d=r.n(f),h=r(2378),p=r(7601),m=r(2116),y=r(3660),v=r(3652),g=r(8738),b=r(2917),w=r(6574),x=r(2563),_=r(1755),S=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(t){o(t)}}function s(e){try{u(n.throw(e))}catch(t){o(t)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))},k=new _.Logger("contracts/5.6.0"),E={chainId:!0,data:!0,from:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0,maxFeePerGas:!0,maxPriorityFeePerGas:!0,customData:!0,ccipReadEnabled:!0};function A(e,t){return S(this,void 0,void 0,d().mark((function r(){var n,i;return d().wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,t;case 2:return"string"!==typeof(n=r.sent)&&k.throwArgumentError("invalid address or ENS name","name",n),r.prev=4,r.abrupt("return",(0,v.getAddress)(n));case 8:r.prev=8,r.t0=r.catch(4);case 10:return e||k.throwError("a provider or signer is needed to resolve ENS names",_.Logger.errors.UNSUPPORTED_OPERATION,{operation:"resolveName"}),r.next=13,e.resolveName(n);case 13:return null==(i=r.sent)&&k.throwArgumentError("resolver or addr is not configured for ENS name","name",n),r.abrupt("return",i);case 16:case"end":return r.stop()}}),r,null,[[4,8]])})))}function j(e,t,r){return S(this,void 0,void 0,d().mark((function n(){return d().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(!Array.isArray(r)){n.next=4;break}return n.next=3,Promise.all(r.map((function(r,n){return j(e,Array.isArray(t)?t[n]:t[r.name],r)})));case 3:case 7:case 11:case 17:return n.abrupt("return",n.sent);case 4:if("address"!==r.type){n.next=8;break}return n.next=7,A(e,t);case 8:if("tuple"!==r.type){n.next=12;break}return n.next=11,j(e,t,r.components);case 12:if("array"!==r.baseType){n.next=18;break}if(Array.isArray(t)){n.next=15;break}return n.abrupt("return",Promise.reject(k.makeError("invalid value for array",_.Logger.errors.INVALID_ARGUMENT,{argument:"value",value:t})));case 15:return n.next=17,Promise.all(t.map((function(t){return j(e,t,r.arrayChildren)})));case 18:return n.abrupt("return",t);case 19:case"end":return n.stop()}}),n)})))}function M(e,t,r){return S(this,void 0,void 0,d().mark((function n(){var i,o,a,s,u,l,c,f,h,p,m=this;return d().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return i={},r.length===t.inputs.length+1&&"object"===typeof r[r.length-1]&&(i=(0,w.shallowCopy)(r.pop())),k.checkArgumentCount(r.length,t.inputs.length,"passed to contract"),e.signer?i.from?i.from=(0,w.resolveProperties)({override:A(e.signer,i.from),signer:e.signer.getAddress()}).then((function(e){return S(m,void 0,void 0,d().mark((function t(){return d().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return(0,v.getAddress)(e.signer)!==e.override&&k.throwError("Contract with a Signer cannot override from",_.Logger.errors.UNSUPPORTED_OPERATION,{operation:"overrides.from"}),t.abrupt("return",e.override);case 2:case"end":return t.stop()}}),t)})))})):i.from=e.signer.getAddress():i.from&&(i.from=A(e.provider,i.from)),n.next=6,(0,w.resolveProperties)({args:j(e.signer||e.provider,r,t.inputs),address:e.resolvedAddress,overrides:(0,w.resolveProperties)(i)||{}});case 6:if(o=n.sent,a=e.interface.encodeFunctionData(t,o.args),s={data:a,to:o.address},null!=(u=o.overrides).nonce&&(s.nonce=g.O$.from(u.nonce).toNumber()),null!=u.gasLimit&&(s.gasLimit=g.O$.from(u.gasLimit)),null!=u.gasPrice&&(s.gasPrice=g.O$.from(u.gasPrice)),null!=u.maxFeePerGas&&(s.maxFeePerGas=g.O$.from(u.maxFeePerGas)),null!=u.maxPriorityFeePerGas&&(s.maxPriorityFeePerGas=g.O$.from(u.maxPriorityFeePerGas)),null!=u.from&&(s.from=u.from),null!=u.type&&(s.type=u.type),null!=u.accessList&&(s.accessList=(0,x.accessListify)(u.accessList)),null==s.gasLimit&&null!=t.gas){for(l=21e3,c=(0,b.arrayify)(a),f=0;f1)){e=e.substring(1);var r=t[0];try{null==i[e]&&(0,w.defineReadOnly)(i,e,i[r])}catch(n){}null==i.functions[e]&&(0,w.defineReadOnly)(i.functions,e,i.functions[r]),null==i.callStatic[e]&&(0,w.defineReadOnly)(i.callStatic,e,i.callStatic[r]),null==i.populateTransaction[e]&&(0,w.defineReadOnly)(i.populateTransaction,e,i.populateTransaction[r]),null==i.estimateGas[e]&&(0,w.defineReadOnly)(i.estimateGas,e,i.estimateGas[r])}}))}return(0,c.Z)(e,[{key:"deployed",value:function(){return this._deployed()}},{key:"_deployed",value:function(e){var t=this;return this._deployedPromise||(this.deployTransaction?this._deployedPromise=this.deployTransaction.wait().then((function(){return t})):this._deployedPromise=this.provider.getCode(this.address,e).then((function(e){return"0x"===e&&k.throwError("contract not deployed",_.Logger.errors.UNSUPPORTED_OPERATION,{contractAddress:t.address,operation:"getDeployed"}),t}))),this._deployedPromise}},{key:"fallback",value:function(e){var t=this;this.signer||k.throwError("sending a transactions require a signer",_.Logger.errors.UNSUPPORTED_OPERATION,{operation:"sendTransaction(fallback)"});var r=(0,w.shallowCopy)(e||{});return["from","to"].forEach((function(e){null!=r[e]&&k.throwError("cannot override "+e,_.Logger.errors.UNSUPPORTED_OPERATION,{operation:e})})),r.to=this.resolvedAddress,this.deployed().then((function(){return t.signer.sendTransaction(r)}))}},{key:"connect",value:function(e){"string"===typeof e&&(e=new y.VoidSigner(e,this.provider));var t=new this.constructor(this.address,this.interface,e);return this.deployTransaction&&(0,w.defineReadOnly)(t,"deployTransaction",this.deployTransaction),t}},{key:"attach",value:function(e){return new this.constructor(e,this.interface,this.signer||this.provider)}},{key:"_normalizeRunningEvent",value:function(e){return this._runningEvents[e.tag]?this._runningEvents[e.tag]:e}},{key:"_getRunningEvent",value:function(e){if("string"===typeof e){if("error"===e)return this._normalizeRunningEvent(new I);if("event"===e)return this._normalizeRunningEvent(new R("event",null));if("*"===e)return this._normalizeRunningEvent(new N(this.address,this.interface));var t=this.interface.getEvent(e);return this._normalizeRunningEvent(new L(this.address,this.interface,t))}if(e.topics&&e.topics.length>0){try{var r=e.topics[0];if("string"!==typeof r)throw new Error("invalid topic");var n=this.interface.getEvent(r);return this._normalizeRunningEvent(new L(this.address,this.interface,n,e.topics))}catch(o){}var i={address:this.address,topics:e.topics};return this._normalizeRunningEvent(new R(O(i),i))}return this._normalizeRunningEvent(new N(this.address,this.interface))}},{key:"_checkRunningEvents",value:function(e){if(0===e.listenerCount()){delete this._runningEvents[e.tag];var t=this._wrappedEmits[e.tag];t&&e.filter&&(this.provider.off(e.filter,t),delete this._wrappedEmits[e.tag])}}},{key:"_wrapEvent",value:function(e,t,r){var n=this,i=(0,w.deepCopy)(t);return i.removeListener=function(){r&&(e.removeListener(r),n._checkRunningEvents(e))},i.getBlock=function(){return n.provider.getBlock(t.blockHash)},i.getTransaction=function(){return n.provider.getTransaction(t.transactionHash)},i.getTransactionReceipt=function(){return n.provider.getTransactionReceipt(t.transactionHash)},e.prepareEvent(i),i}},{key:"_addEventListener",value:function(e,t,r){var i=this;if(this.provider||k.throwError("events require a provider or a signer with a provider",_.Logger.errors.UNSUPPORTED_OPERATION,{operation:"once"}),e.addListener(t,r),this._runningEvents[e.tag]=e,!this._wrappedEmits[e.tag]){var o=function(r){var o=i._wrapEvent(e,r,t);if(null==o.decodeError)try{var a=e.getEmit(o);i.emit.apply(i,[e.filter].concat((0,n.Z)(a)))}catch(s){o.decodeError=s.error}null!=e.filter&&i.emit("event",o),null!=o.decodeError&&i.emit("error",o.decodeError,o)};this._wrappedEmits[e.tag]=o,null!=e.filter&&this.provider.on(e.filter,o)}}},{key:"queryFilter",value:function(e,t,r){var n=this,i=this._getRunningEvent(e),o=(0,w.shallowCopy)(i.filter);return"string"===typeof t&&(0,b.isHexString)(t,32)?(null!=r&&k.throwArgumentError("cannot specify toBlock with blockhash","toBlock",r),o.blockHash=t):(o.fromBlock=null!=t?t:0,o.toBlock=null!=r?r:"latest"),this.provider.getLogs(o).then((function(e){return e.map((function(e){return n._wrapEvent(i,e,null)}))}))}},{key:"on",value:function(e,t){return this._addEventListener(this._getRunningEvent(e),t,!1),this}},{key:"once",value:function(e,t){return this._addEventListener(this._getRunningEvent(e),t,!0),this}},{key:"emit",value:function(e){if(!this.provider)return!1;for(var t=this._getRunningEvent(e),r=arguments.length,n=new Array(r>1?r-1:0),i=1;i0;return this._checkRunningEvents(t),o}},{key:"listenerCount",value:function(e){var t=this;return this.provider?null==e?Object.keys(this._runningEvents).reduce((function(e,r){return e+t._runningEvents[r].listenerCount()}),0):this._getRunningEvent(e).listenerCount():0}},{key:"listeners",value:function(e){var t=this;if(!this.provider)return[];if(null==e){var r=function(){var e=[];for(var r in t._runningEvents)t._runningEvents[r].listeners().forEach((function(t){e.push(t)}));return{v:e}}();if("object"===typeof r)return r.v}return this._getRunningEvent(e).listeners()}},{key:"removeAllListeners",value:function(e){if(!this.provider)return this;if(null==e){for(var t in this._runningEvents){var r=this._runningEvents[t];r.removeAllListeners(),this._checkRunningEvents(r)}return this}var n=this._getRunningEvent(e);return n.removeAllListeners(),this._checkRunningEvents(n),this}},{key:"off",value:function(e,t){if(!this.provider)return this;var r=this._getRunningEvent(e);return r.removeListener(t),this._checkRunningEvents(r),this}},{key:"removeListener",value:function(e,t){return this.off(e,t)}}],[{key:"getContractAddress",value:function(e){return(0,v.getContractAddress)(e)}},{key:"getInterface",value:function(e){return p.vU.isInterface(e)?e:new p.vU(e)}},{key:"isIndexed",value:function(e){return p.Hk.isIndexed(e)}}]),e}(),F=function(e){(0,s.Z)(r,e);var t=(0,u.Z)(r);function r(){return(0,l.Z)(this,r),t.apply(this,arguments)}return(0,c.Z)(r)}(D),U=function(){function e(t,r,n){(0,l.Z)(this,e);var i=null;"0x"!==(i="string"===typeof r?r:(0,b.isBytes)(r)?(0,b.hexlify)(r):r&&"string"===typeof r.object?r.object:"!").substring(0,2)&&(i="0x"+i),(!(0,b.isHexString)(i)||i.length%2)&&k.throwArgumentError("invalid bytecode","bytecode",r),n&&!y.Signer.isSigner(n)&&k.throwArgumentError("invalid signer","signer",n),(0,w.defineReadOnly)(this,"bytecode",i),(0,w.defineReadOnly)(this,"interface",(0,w.getStatic)(this instanceof e?this.constructor:void 0,"getInterface")(t)),(0,w.defineReadOnly)(this,"signer",n||null)}return(0,c.Z)(e,[{key:"getDeployTransaction",value:function(){for(var e={},t=arguments.length,r=new Array(t),n=0;n256||t[2]&&t[2]!==String(n))&&y.throwArgumentError("invalid numeric width","type",e);var i=x.mask(r?n-1:n),o=r?i.add(w).mul(g):b;return function(t){var r=u.O$.from(t);return(r.lt(o)||r.gt(i))&&y.throwArgumentError("value out-of-bounds for ".concat(e),"value",t),(0,l.hexZeroPad)(r.toTwos(256).toHexString(),32)}}var a=e.match(/^bytes(\d+)$/);if(a){var f=parseInt(a[1]);return(0===f||f>32||a[1]!==String(f))&&y.throwArgumentError("invalid bytes width","type",e),function(t){return(0,l.arrayify)(t).length!==f&&y.throwArgumentError("invalid length for ".concat(e),"value",t),function(e){var t=(0,l.arrayify)(e),r=t.length%32;return r?(0,l.hexConcat)([t,v.slice(r)]):(0,l.hexlify)(t)}(t)}}switch(e){case"address":return function(e){return(0,l.hexZeroPad)((0,s.getAddress)(e),32)};case"bool":return function(e){return e?_:S};case"bytes":return function(e){return(0,c.keccak256)(e)};case"string":return function(e){return(0,p.id)(e)}}return null}function T(e,t){return"".concat(e,"(").concat(t.map((function(e){var t=e.name;return e.type+" "+t})).join(","),")")}var P=function(){function e(t){(0,n.Z)(this,e),(0,f.defineReadOnly)(this,"types",Object.freeze((0,f.deepCopy)(t))),(0,f.defineReadOnly)(this,"_encoderCache",{}),(0,f.defineReadOnly)(this,"_types",{});var r={},i={},o={};Object.keys(t).forEach((function(e){r[e]={},i[e]=[],o[e]={}}));var a=function(e){var n={};t[e].forEach((function(o){n[o.name]&&y.throwArgumentError("duplicate variable name ".concat(JSON.stringify(o.name)," in ").concat(JSON.stringify(e)),"types",t),n[o.name]=!0;var a=o.type.match(/^([^\x5b]*)(\x5b|$)/)[1];a===e&&y.throwArgumentError("circular type reference to ".concat(JSON.stringify(a)),"types",t),M(a)||(i[a]||y.throwArgumentError("unknown type ".concat(JSON.stringify(a)),"types",t),i[a].push(e),r[e][a]=!0)}))};for(var s in t)a(s);var u=Object.keys(i).filter((function(e){return 0===i[e].length}));for(var l in 0===u.length?y.throwArgumentError("missing primary type","types",t):u.length>1&&y.throwArgumentError("ambiguous primary types or unused types: ".concat(u.map((function(e){return JSON.stringify(e)})).join(", ")),"types",t),(0,f.defineReadOnly)(this,"primaryType",u[0]),function e(n,a){a[n]&&y.throwArgumentError("circular type reference to ".concat(JSON.stringify(n)),"types",t),a[n]=!0,Object.keys(r[n]).forEach((function(t){i[t]&&(e(t,a),Object.keys(a).forEach((function(e){o[e][t]=!0})))})),delete a[n]}(this.primaryType,{}),o){var c=Object.keys(o[l]);c.sort(),this._types[l]=T(l,t[l])+c.map((function(e){return T(e,t[e])})).join("")}}return(0,i.Z)(e,[{key:"getEncoder",value:function(e){var t=this._encoderCache[e];return t||(t=this._encoderCache[e]=this._getEncoder(e)),t}},{key:"_getEncoder",value:function(e){var t=this,r=M(e);if(r)return r;var n=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(n){var i=n[1],o=this.getEncoder(i),a=parseInt(n[3]);return function(e){a>=0&&e.length!==a&&y.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",e);var r=e.map(o);return t._types[i]&&(r=r.map(c.keccak256)),(0,c.keccak256)((0,l.hexConcat)(r))}}var s=this.types[e];if(s){var u=(0,p.id)(this._types[e]);return function(e){var r=s.map((function(r){var n=r.name,i=r.type,o=t.getEncoder(i)(e[n]);return t._types[i]?(0,c.keccak256)(o):o}));return r.unshift(u),(0,l.hexConcat)(r)}}return y.throwArgumentError("unknown type: ".concat(e),"type",e)}},{key:"encodeType",value:function(e){var t=this._types[e];return t||y.throwArgumentError("unknown type: ".concat(JSON.stringify(e)),"name",e),t}},{key:"encodeData",value:function(e,t){return this.getEncoder(e)(t)}},{key:"hashStruct",value:function(e,t){return(0,c.keccak256)(this.encodeData(e,t))}},{key:"encode",value:function(e){return this.encodeData(this.primaryType,e)}},{key:"hash",value:function(e){return this.hashStruct(this.primaryType,e)}},{key:"_visit",value:function(e,t,r){var n=this;if(M(e))return r(e,t);var i=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(i){var o=i[1],a=parseInt(i[3]);return a>=0&&t.length!==a&&y.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",t),t.map((function(e){return n._visit(o,e,r)}))}var s=this.types[e];return s?s.reduce((function(e,i){var o=i.name,a=i.type;return e[o]=n._visit(a,t[o],r),e}),{}):y.throwArgumentError("unknown type: ".concat(e),"type",e)}},{key:"visit",value:function(e,t){return this._visit(this.primaryType,e,t)}}],[{key:"from",value:function(t){return new e(t)}},{key:"getPrimaryType",value:function(t){return e.from(t).primaryType}},{key:"hashStruct",value:function(t,r,n){return e.from(r).hashStruct(t,n)}},{key:"hashDomain",value:function(t){var r=[];for(var n in t){var i=k[n];i||y.throwArgumentError("invalid typed-data domain key: ".concat(JSON.stringify(n)),"domain",t),r.push({name:n,type:i})}return r.sort((function(e,t){return E.indexOf(e.name)-E.indexOf(t.name)})),e.hashStruct("EIP712Domain",{EIP712Domain:r},t)}},{key:"encode",value:function(t,r,n){return(0,l.hexConcat)(["0x1901",e.hashDomain(t),e.from(r).hash(n)])}},{key:"hash",value:function(t,r,n){return(0,c.keccak256)(e.encode(t,r,n))}},{key:"resolveNames",value:function(t,r,n,i){return m(this,void 0,void 0,a().mark((function o(){var s,u,c;return a().wrap((function(o){for(;;)switch(o.prev=o.next){case 0:t=(0,f.shallowCopy)(t),s={},t.verifyingContract&&!(0,l.isHexString)(t.verifyingContract,20)&&(s[t.verifyingContract]="0x"),(u=e.from(r)).visit(n,(function(e,t){return"address"!==e||(0,l.isHexString)(t,20)||(s[t]="0x"),t})),o.t0=a().keys(s);case 6:if((o.t1=o.t0()).done){o.next=13;break}return c=o.t1.value,o.next=10,i(c);case 10:s[c]=o.sent,o.next=6;break;case 13:return t.verifyingContract&&s[t.verifyingContract]&&(t.verifyingContract=s[t.verifyingContract]),n=u.visit(n,(function(e,t){return"address"===e&&s[t]?s[t]:t})),o.abrupt("return",{domain:t,value:n});case 16:case"end":return o.stop()}}),o)})))}},{key:"getPayload",value:function(t,r,n){e.hashDomain(t);var i={},o=[];E.forEach((function(e){var r=t[e];null!=r&&(i[e]=j[e](r),o.push({name:e,type:k[e]}))}));var a=e.from(r),s=(0,f.shallowCopy)(r);return s.EIP712Domain?y.throwArgumentError("types must not contain EIP712Domain type","types.EIP712Domain",r):s.EIP712Domain=o,a.encode(n),{types:s,domain:i,primaryType:a.primaryType,message:a.visit(n,(function(e,t){if(e.match(/^bytes(\d*)/))return(0,l.hexlify)((0,l.arrayify)(t));if(e.match(/^u?int/))return u.O$.from(t).toString();switch(e){case"address":return t.toLowerCase();case"bool":return!!t;case"string":return"string"!==typeof t&&y.throwArgumentError("invalid string","value",t),t}return y.throwArgumentError("unsupported type","type",e)}))}}}]),e}()},9400:function(e,t,r){"use strict";r.r(t),r.d(t,{HDNode:function(){return A},defaultPath:function(){return E},entropyToMnemonic:function(){return T},getAccountPath:function(){return C},isValidMnemonic:function(){return P},mnemonicToEntropy:function(){return M},mnemonicToSeed:function(){return j}});var n=r(9249),i=r(7371),o=r(2548),a=r(2917),s=r(8738),u=r(2981),l=r(3044),c=r(6574),f=r(3005),d=r(9721),h=r(9149),p=r(2563),m=r(2687),y=new(r(1755).Logger)("hdnode/5.6.0"),v=s.O$.from("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),g=(0,u.Y0)("Bitcoin seed"),b=2147483648;function w(e){return(1<=256)throw new Error("Depth too large!");return _((0,a.concat)([null!=this.privateKey?"0x0488ADE4":"0x0488B21E",(0,a.hexlify)(this.depth),this.parentFingerprint,(0,a.hexZeroPad)((0,a.hexlify)(this.index),4),this.chainCode,null!=this.privateKey?(0,a.concat)(["0x00",this.privateKey]):this.publicKey]))}},{key:"neuter",value:function(){return new e(k,null,this.publicKey,this.parentFingerprint,this.chainCode,this.index,this.depth,this.path)}},{key:"_derive",value:function(t){if(t>4294967295)throw new Error("invalid index - "+String(t));var r=this.path;r&&(r+="/"+(2147483647&t));var n=new Uint8Array(37);if(t&b){if(!this.privateKey)throw new Error("cannot derive child of neutered node");n.set((0,a.arrayify)(this.privateKey),1),r&&(r+="'")}else n.set((0,a.arrayify)(this.publicKey));for(var i=24;i>=0;i-=8)n[33+(i>>3)]=t>>24-i&255;var o=(0,a.arrayify)((0,d.Gy)(h.p.sha512,this.chainCode,n)),u=o.slice(0,32),l=o.slice(32),c=null,p=null;this.privateKey?c=x(s.O$.from(u).add(this.privateKey).mod(v)):p=new f.Et((0,a.hexlify)(u))._addPoint(this.publicKey);var m=r,y=this.mnemonic;return y&&(m=Object.freeze({phrase:y.phrase,path:r,locale:y.locale||"en"})),new e(k,c,p,this.fingerprint,x(l),t,this.depth+1,m)}},{key:"derivePath",value:function(e){var t=e.split("/");if(0===t.length||"m"===t[0]&&0!==this.depth)throw new Error("invalid path - "+e);"m"===t[0]&&t.shift();for(var r=this,n=0;n=b)throw new Error("invalid path index - "+i);r=r._derive(b+o)}else{if(!i.match(/^[0-9]+$/))throw new Error("invalid path component - "+i);var a=parseInt(i);if(a>=b)throw new Error("invalid path index - "+i);r=r._derive(a)}}return r}}],[{key:"_fromSeed",value:function(t,r){var n=(0,a.arrayify)(t);if(n.length<16||n.length>64)throw new Error("invalid seed");var i=(0,a.arrayify)((0,d.Gy)(h.p.sha512,g,n));return new e(k,x(i.slice(0,32)),null,"0x00000000",x(i.slice(32)),0,0,r)}},{key:"fromMnemonic",value:function(t,r,n){return t=T(M(t,n=S(n)),n),e._fromSeed(j(t,r),{phrase:t,path:"m",locale:n.locale})}},{key:"fromSeed",value:function(t){return e._fromSeed(t,null)}},{key:"fromExtendedKey",value:function(t){var r=o.Base58.decode(t);82===r.length&&_(r.slice(0,78))===t||y.throwArgumentError("invalid extended key","extendedKey","[REDACTED]");var n=r[4],i=(0,a.hexlify)(r.slice(5,9)),s=parseInt((0,a.hexlify)(r.slice(9,13)).substring(2),16),u=(0,a.hexlify)(r.slice(13,45)),l=r.slice(45,78);switch((0,a.hexlify)(r.slice(0,4))){case"0x0488b21e":case"0x043587cf":return new e(k,null,(0,a.hexlify)(l),i,u,s,n,null);case"0x0488ade4":case"0x04358394 ":if(0!==l[0])break;return new e(k,(0,a.hexlify)(l.slice(1)),null,i,u,s,n,null)}return y.throwArgumentError("invalid extended key","extendedKey","[REDACTED]")}}]),e}();function j(e,t){t||(t="");var r=(0,u.Y0)("mnemonic"+t,u.Uj.NFKD);return(0,l.n)((0,u.Y0)(e,u.Uj.NFKD),r,2048,64,"sha512")}function M(e,t){t=S(t),y.checkNormalize();var r=t.split(e);if(r.length%3!==0)throw new Error("invalid mnemonic");for(var n=(0,a.arrayify)(new Uint8Array(Math.ceil(11*r.length/8))),i=0,o=0;o>3]|=1<<7-i%8),i++}var l=32*r.length/3,c=w(r.length/3);if(((0,a.arrayify)((0,d.JQ)(n.slice(0,l/8)))[0]&c)!==(n[n.length-1]&c))throw new Error("invalid checksum");return(0,a.hexlify)(n.slice(0,l/8))}function T(e,t){if(t=S(t),(e=(0,a.arrayify)(e)).length%4!==0||e.length<16||e.length>32)throw new Error("invalid entropy");for(var r=[0],n=11,i=0;i8?(r[r.length-1]<<=8,r[r.length-1]|=e[i],n-=8):(r[r.length-1]<<=n,r[r.length-1]|=e[i]>>8-n,r.push(e[i]&(1<<8-n)-1),n+=3);var o=e.length/4,s=(0,a.arrayify)((0,d.JQ)(e))[0]&w(o);return r[r.length-1]<<=o,r[r.length-1]|=s>>8-o,t.join(r.map((function(e){return t.getWord(e)})))}function P(e,t){try{return M(e,t),!0}catch(r){}return!1}function C(e){return("number"!==typeof e||e<0||e>=b||e%1)&&y.throwArgumentError("invalid account index","index",e),"m/44'/60'/".concat(e,"'/0/0")}},9848:function(e,t,r){"use strict";r.d(t,{i:function(){return n}});var n="json-wallets/5.6.0"},4101:function(e,t,r){"use strict";r.r(t),r.d(t,{decryptCrowdsale:function(){return w},decryptJsonWallet:function(){return E},decryptJsonWalletSync:function(){return A},decryptKeystore:function(){return k.pe},decryptKeystoreSync:function(){return k.hb},encryptKeystore:function(){return k.HI},getJsonWalletAddress:function(){return S},isCrowdsaleWallet:function(){return x},isKeystoreWallet:function(){return _}});var n=r(9249),i=r(7371),o=r(5754),a=r(6906),s=r(2615),u=r.n(s),l=r(3652),c=r(2917),f=r(6220),d=r(3044),h=r(2981),p=r(6574),m=r(1755),y=r(9848),v=r(4938),g=new m.Logger(y.i),b=function(e){(0,o.Z)(r,e);var t=(0,a.Z)(r);function r(){return(0,n.Z)(this,r),t.apply(this,arguments)}return(0,i.Z)(r,[{key:"isCrowdsaleAccount",value:function(e){return!(!e||!e._isCrowdsaleAccount)}}]),r}(p.Description);function w(e,t){var r=JSON.parse(e);t=(0,v.Ij)(t);var n=(0,l.getAddress)((0,v.gx)(r,"ethaddr")),i=(0,v.p3)((0,v.gx)(r,"encseed"));i&&i.length%16===0||g.throwArgumentError("invalid encseed","json",e);for(var o=(0,c.arrayify)((0,d.n)(t,t,2e3,32,"sha256")).slice(0,16),a=i.slice(0,16),s=i.slice(16),p=new(u().ModeOfOperation.cbc)(o,a),m=u().padding.pkcs7.strip((0,c.arrayify)(p.decrypt(s))),y="",w=0;ws[r]||console.log.apply(console,t)}},{key:"debug",value:function(){for(var t=arguments.length,r=new Array(t),n=0;n>4],r+=h[15&t[o]];i.push(e+"=Uint8Array(0x"+r+")")}else i.push(e+"="+JSON.stringify(t))}catch(l){i.push(e+"="+JSON.stringify(n[e].toString()))}})),i.push("code=".concat(r)),i.push("version=".concat(this.version));var o=t,s="";switch(r){case f.NUMERIC_FAULT:s="NUMERIC_FAULT";var u=t;switch(u){case"overflow":case"underflow":case"division-by-zero":s+="-"+u;break;case"negative-power":case"negative-width":s+="-unsupported";break;case"unbound-bitwise-result":s+="-unbound-result"}break;case f.CALL_EXCEPTION:case f.INSUFFICIENT_FUNDS:case f.MISSING_NEW:case f.NONCE_EXPIRED:case f.REPLACEMENT_UNDERPRICED:case f.TRANSACTION_REPLACED:case f.UNPREDICTABLE_GAS_LIMIT:s=r}s&&(t+=" [ See: https://links.ethers.org/v5-errors-"+s+" ]"),i.length&&(t+=" ("+i.join(", ")+")");var l=new Error(t);return l.reason=o,l.code=r,Object.keys(n).forEach((function(e){l[e]=n[e]})),l}},{key:"throwError",value:function(e,t,r){throw this.makeError(e,t,r)}},{key:"throwArgumentError",value:function(t,r,n){return this.throwError(t,e.errors.INVALID_ARGUMENT,{argument:r,value:n})}},{key:"assert",value:function(e,t,r,n){e||this.throwError(t,r,n)}},{key:"assertArgument",value:function(e,t,r,n){e||this.throwArgumentError(t,r,n)}},{key:"checkNormalize",value:function(t){null==t&&(t="platform missing String.prototype.normalize"),d&&this.throwError("platform missing String.prototype.normalize",e.errors.UNSUPPORTED_OPERATION,{operation:"String.prototype.normalize",form:d})}},{key:"checkSafeUint53",value:function(t,r){"number"===typeof t&&(null==r&&(r="value not safe"),(t<0||t>=9007199254740991)&&this.throwError(r,e.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"out-of-safe-range",value:t}),t%1&&this.throwError(r,e.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"non-integer",value:t}))}},{key:"checkArgumentCount",value:function(t,r,n){n=n?": "+n:"",tr&&this.throwError("too many arguments"+n,e.errors.UNEXPECTED_ARGUMENT,{count:t,expectedCount:r})}},{key:"checkNew",value:function(t,r){t!==Object&&null!=t||this.throwError("missing new",e.errors.MISSING_NEW,{name:r.name})}},{key:"checkAbstract",value:function(t,r){t===r?this.throwError("cannot instantiate abstract class "+JSON.stringify(r.name)+" directly; use a sub-class",e.errors.UNSUPPORTED_OPERATION,{name:t.name,operation:"new"}):t!==Object&&null!=t||this.throwError("missing new",e.errors.MISSING_NEW,{name:r.name})}}],[{key:"globalLogger",value:function(){return l||(l=new e("logger/5.6.0")),l}},{key:"setCensorship",value:function(t,r){if(!t&&r&&this.globalLogger().throwError("cannot permanently disable censorship",e.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"}),o){if(!t)return;this.globalLogger().throwError("error censorship permanent",e.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"})}a=!!t,o=!!r}},{key:"setLogLevel",value:function(t){var r=s[t.toLowerCase()];null!=r?u=r:e.globalLogger().warn("invalid log level - "+t)}},{key:"from",value:function(t){return new e(t)}}]),e}();p.errors=f,p.levels=c},4130:function(e,t,r){"use strict";r.d(t,{H:function(){return c}});var n=new(r(1755).Logger)("networks/5.6.2");function i(e){var t=function(t,r){null==r&&(r={});var n=[];if(t.InfuraProvider&&"-"!==r.infura)try{n.push(new t.InfuraProvider(e,r.infura))}catch(a){}if(t.EtherscanProvider&&"-"!==r.etherscan)try{n.push(new t.EtherscanProvider(e,r.etherscan))}catch(a){}if(t.AlchemyProvider&&"-"!==r.alchemy)try{n.push(new t.AlchemyProvider(e,r.alchemy))}catch(a){}if(t.PocketProvider&&"-"!==r.pocket){try{var i=new t.PocketProvider(e,r.pocket);i.network&&-1===["goerli","ropsten","rinkeby"].indexOf(i.network.name)&&n.push(i)}catch(a){}}if(t.CloudflareProvider&&"-"!==r.cloudflare)try{n.push(new t.CloudflareProvider(e))}catch(a){}if(t.AnkrProvider&&"-"!==r.ankr)try{n.push(new t.AnkrProvider(e,r.ankr))}catch(a){}if(0===n.length)return null;if(t.FallbackProvider){var o=1;return null!=r.quorum?o=r.quorum:"homestead"===e&&(o=2),new t.FallbackProvider(n,o)}return n[0]};return t.renetwork=function(e){return i(e)},t}function o(e,t){var r=function(r,n){return r.JsonRpcProvider?new r.JsonRpcProvider(e,t):null};return r.renetwork=function(t){return o(e,t)},r}var a={chainId:1,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"homestead",_defaultProvider:i("homestead")},s={chainId:3,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"ropsten",_defaultProvider:i("ropsten")},u={chainId:63,name:"classicMordor",_defaultProvider:o("https://www.ethercluster.com/mordor","classicMordor")},l={unspecified:{chainId:0,name:"unspecified"},homestead:a,mainnet:a,morden:{chainId:2,name:"morden"},ropsten:s,testnet:s,rinkeby:{chainId:4,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"rinkeby",_defaultProvider:i("rinkeby")},kovan:{chainId:42,name:"kovan",_defaultProvider:i("kovan")},goerli:{chainId:5,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"goerli",_defaultProvider:i("goerli")},kintsugi:{chainId:1337702,name:"kintsugi"},classic:{chainId:61,name:"classic",_defaultProvider:o("https://www.ethercluster.com/etc","classic")},classicMorden:{chainId:62,name:"classicMorden"},classicMordor:u,classicTestnet:u,classicKotti:{chainId:6,name:"classicKotti",_defaultProvider:o("https://www.ethercluster.com/kotti","classicKotti")},xdai:{chainId:100,name:"xdai"},matic:{chainId:137,name:"matic"},maticmum:{chainId:80001,name:"maticmum"},optimism:{chainId:10,name:"optimism"},"optimism-kovan":{chainId:69,name:"optimism-kovan"},"optimism-goerli":{chainId:420,name:"optimism-goerli"},arbitrum:{chainId:42161,name:"arbitrum"},"arbitrum-rinkeby":{chainId:421611,name:"arbitrum-rinkeby"},bnb:{chainId:56,name:"bnb"},bnbt:{chainId:97,name:"bnbt"}};function c(e){if(null==e)return null;if("number"===typeof e){for(var t in l){var r=l[t];if(r.chainId===e)return{name:r.name,chainId:r.chainId,ensAddress:r.ensAddress||null,_defaultProvider:r._defaultProvider||null}}return{chainId:e,name:"unknown"}}if("string"===typeof e){var i=l[e];return null==i?null:{name:i.name,chainId:i.chainId,ensAddress:i.ensAddress,_defaultProvider:i._defaultProvider||null}}var o=l[e.name];if(!o)return"number"!==typeof e.chainId&&n.throwArgumentError("invalid network chainId","network",e),e;0!==e.chainId&&e.chainId!==o.chainId&&n.throwArgumentError("network chainId mismatch","network",e);var a,s=e._defaultProvider||null;return null==s&&o._defaultProvider&&(s=(a=o._defaultProvider)&&"function"===typeof a.renetwork?o._defaultProvider.renetwork(e):o._defaultProvider),{name:e.name,chainId:o.chainId,ensAddress:e.ensAddress||o.ensAddress||null,_defaultProvider:s}}},3044:function(e,t,r){"use strict";r.d(t,{n:function(){return o}});var n=r(2917),i=r(9721);function o(e,t,r,o,a){var s;e=(0,n.arrayify)(e),t=(0,n.arrayify)(t);var u,l,c=1,f=new Uint8Array(o),d=new Uint8Array(t.length+4);d.set(t);for(var h=1;h<=c;h++){d[t.length]=h>>24&255,d[t.length+1]=h>>16&255,d[t.length+2]=h>>8&255,d[t.length+3]=255&h;var p=(0,n.arrayify)((0,i.Gy)(a,e,d));s||(s=p.length,l=new Uint8Array(s),u=o-((c=Math.ceil(o/s))-1)*s),l.set(p);for(var m=1;m1024||e%1||e!=e)&&o.throwArgumentError("invalid length","length",e);var t=new Uint8Array(e);return s.getRandomValues(t),(0,n.arrayify)(t)}s&&s.getRandomValues||(o.warn("WARNING: Missing strong random number source"),s={getRandomValues:function(e){return o.throwError("no secure random source avaialble",i.Logger.errors.UNSUPPORTED_OPERATION,{operation:"crypto.getRandomValues"})}})},3617:function(e,t,r){"use strict";function n(e){for(var t=(e=e.slice()).length-1;t>0;t--){var r=Math.floor(Math.random()*(t+1)),n=e[t];e[t]=e[r],e[r]=n}return e}r.d(t,{y:function(){return n}})},4228:function(e,t,r){"use strict";r.r(t),r.d(t,{decode:function(){return d},encode:function(){return l}});var n=r(2917),i=r(1755),o=new i.Logger("rlp/5.6.0");function a(e){for(var t=[];e;)t.unshift(255&e),e>>=8;return t}function s(e,t,r){for(var n=0,i=0;it+1+n&&o.throwError("child data too short",i.Logger.errors.BUFFER_OVERRUN,{})}return{consumed:1+n,result:a}}function f(e,t){if(0===e.length&&o.throwError("data too short",i.Logger.errors.BUFFER_OVERRUN,{}),e[t]>=248){var r=e[t]-247;t+1+r>e.length&&o.throwError("data short segment too short",i.Logger.errors.BUFFER_OVERRUN,{});var a=s(e,t+1,r);return t+1+r+a>e.length&&o.throwError("data long segment too short",i.Logger.errors.BUFFER_OVERRUN,{}),c(e,t,t+1+r,r+a)}if(e[t]>=192){var u=e[t]-192;return t+1+u>e.length&&o.throwError("data array too short",i.Logger.errors.BUFFER_OVERRUN,{}),c(e,t,t+1,u)}if(e[t]>=184){var l=e[t]-183;t+1+l>e.length&&o.throwError("data array too short",i.Logger.errors.BUFFER_OVERRUN,{});var f=s(e,t+1,l);return t+1+l+f>e.length&&o.throwError("data array too short",i.Logger.errors.BUFFER_OVERRUN,{}),{consumed:1+l+f,result:(0,n.hexlify)(e.slice(t+1+l,t+1+l+f))}}if(e[t]>=128){var d=e[t]-128;return t+1+d>e.length&&o.throwError("data too short",i.Logger.errors.BUFFER_OVERRUN,{}),{consumed:1+d,result:(0,n.hexlify)(e.slice(t+1,t+1+d))}}return{consumed:1,result:(0,n.hexlify)(e[t])}}function d(e){var t=(0,n.arrayify)(e),r=f(t,0);return r.consumed!==t.length&&o.throwArgumentError("invalid rlp data","data",e),r.result}},9752:function(e,t,r){"use strict";r.r(t),r.d(t,{SupportedAlgorithm:function(){return i.p},computeHmac:function(){return n.Gy},ripemd160:function(){return n.bP},sha256:function(){return n.JQ},sha512:function(){return n.o}});var n=r(9721),i=r(9149)},9721:function(e,t,r){"use strict";r.d(t,{Gy:function(){return d},bP:function(){return l},JQ:function(){return c},o:function(){return f}});var n=r(361),i=r.n(n),o=r(2917),a=r(9149),s=r(1755),u=new s.Logger("sha2/5.6.0");function l(e){return"0x"+i().ripemd160().update((0,o.arrayify)(e)).digest("hex")}function c(e){return"0x"+i().sha256().update((0,o.arrayify)(e)).digest("hex")}function f(e){return"0x"+i().sha512().update((0,o.arrayify)(e)).digest("hex")}function d(e,t,r){return a.p[e]||u.throwError("unsupported algorithm "+e,s.Logger.errors.UNSUPPORTED_OPERATION,{operation:"hmac",algorithm:e}),"0x"+i().hmac(i()[e],(0,o.arrayify)(t)).update((0,o.arrayify)(r)).digest("hex")}},9149:function(e,t,r){"use strict";var n;r.d(t,{p:function(){return n}}),function(e){e.sha256="sha256",e.sha512="sha512"}(n||(n={}))},3005:function(e,t,r){"use strict";r.d(t,{Et:function(){return Y},VW:function(){return J},LO:function(){return Q}});var n=r(9249),i=r(7371),o=r(5870),a=r.n(o),s=r(361),u=r.n(s);"undefined"!==typeof globalThis?globalThis:"undefined"!==typeof window?window:"undefined"!==typeof r.g?r.g:"undefined"!==typeof self&&self;function l(e,t,r){return r={path:t,exports:{},require:function(e,t){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}((void 0===t||null===t)&&r.path)}},e(r,r.exports),r.exports}var c=f;function f(e,t){if(!e)throw new Error(t||"Assertion failed")}f.equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)};var d=l((function(e,t){var r=t;function n(e){return 1===e.length?"0"+e:e}function i(e){for(var t="",r=0;r>8,a=255&i;o?r.push(o,a):r.push(a)}return r},r.zero2=n,r.toHex=i,r.encode=function(e,t){return"hex"===t?i(e):e}})),h=l((function(e,t){var r=t;r.assert=c,r.toArray=d.toArray,r.zero2=d.zero2,r.toHex=d.toHex,r.encode=d.encode,r.getNAF=function(e,t,r){var n=new Array(Math.max(e.bitLength(),r)+1);n.fill(0);for(var i=1<(i>>1)-1?(i>>1)-u:u,o.isubn(s)):s=0,n[a]=s,o.iushrn(1)}return n},r.getJSF=function(e,t){var r=[[],[]];e=e.clone(),t=t.clone();for(var n,i=0,o=0;e.cmpn(-i)>0||t.cmpn(-o)>0;){var a,s,u=e.andln(3)+i&3,l=t.andln(3)+o&3;3===u&&(u=-1),3===l&&(l=-1),a=0===(1&u)?0:3!==(n=e.andln(7)+i&7)&&5!==n||2!==l?u:-u,r[0].push(a),s=0===(1&l)?0:3!==(n=t.andln(7)+o&7)&&5!==n||2!==u?l:-l,r[1].push(s),2*i===a+1&&(i=1-i),2*o===s+1&&(o=1-o),e.iushrn(1),t.iushrn(1)}return r},r.cachedProperty=function(e,t,r){var n="_"+t;e.prototype[t]=function(){return void 0!==this[n]?this[n]:this[n]=r.call(this)}},r.parseBytes=function(e){return"string"===typeof e?r.toArray(e,"hex"):e},r.intFromLE=function(e){return new(a())(e,"hex","le")}})),p=h.getNAF,m=h.getJSF,y=h.assert;function v(e,t){this.type=e,this.p=new(a())(t.p,16),this.red=t.prime?a().red(t.prime):a().mont(this.p),this.zero=new(a())(0).toRed(this.red),this.one=new(a())(1).toRed(this.red),this.two=new(a())(2).toRed(this.red),this.n=t.n&&new(a())(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}var g=v;function b(e,t){this.curve=e,this.type=t,this.precomputed=null}v.prototype.point=function(){throw new Error("Not implemented")},v.prototype.validate=function(){throw new Error("Not implemented")},v.prototype._fixedNafMul=function(e,t){y(e.precomputed);var r=e._getDoubles(),n=p(t,1,this._bitLength),i=(1<=o;u--)a=(a<<1)+n[u];s.push(a)}for(var l=this.jpoint(null,null,null),c=this.jpoint(null,null,null),f=i;f>0;f--){for(o=0;o=0;s--){for(var u=0;s>=0&&0===o[s];s--)u++;if(s>=0&&u++,a=a.dblp(u),s<0)break;var l=o[s];y(0!==l),a="affine"===e.type?l>0?a.mixedAdd(i[l-1>>1]):a.mixedAdd(i[-l-1>>1].neg()):l>0?a.add(i[l-1>>1]):a.add(i[-l-1>>1].neg())}return"affine"===e.type?a.toP():a},v.prototype._wnafMulAdd=function(e,t,r,n,i){var o,a,s,u=this._wnafT1,l=this._wnafT2,c=this._wnafT3,f=0;for(o=0;o=1;o-=2){var h=o-1,y=o;if(1===u[h]&&1===u[y]){var v=[t[h],null,null,t[y]];0===t[h].y.cmp(t[y].y)?(v[1]=t[h].add(t[y]),v[2]=t[h].toJ().mixedAdd(t[y].neg())):0===t[h].y.cmp(t[y].y.redNeg())?(v[1]=t[h].toJ().mixedAdd(t[y]),v[2]=t[h].add(t[y].neg())):(v[1]=t[h].toJ().mixedAdd(t[y]),v[2]=t[h].toJ().mixedAdd(t[y].neg()));var g=[-3,-1,-5,-7,0,7,5,1,3],b=m(r[h],r[y]);for(f=Math.max(b[0].length,f),c[h]=new Array(f),c[y]=new Array(f),a=0;a=0;o--){for(var k=0;o>=0;){var E=!0;for(a=0;a=0&&k++,_=_.dblp(k),o<0)break;for(a=0;a0?s=l[a][A-1>>1]:A<0&&(s=l[a][-A-1>>1].neg()),_="affine"===s.type?_.mixedAdd(s):_.add(s))}}for(o=0;o=Math.ceil((e.bitLength()+1)/t.step)},b.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],n=this,i=0;i=0&&(o=t,s=r),n.negative&&(n=n.neg(),i=i.neg()),o.negative&&(o=o.neg(),s=s.neg()),[{a:n,b:i},{a:o,b:s}]},_.prototype._endoSplit=function(e){var t=this.endo.basis,r=t[0],n=t[1],i=n.b.mul(e).divRound(this.n),o=r.b.neg().mul(e).divRound(this.n),a=i.mul(r.a),s=o.mul(n.a),u=i.mul(r.b),l=o.mul(n.b);return{k1:e.sub(a).sub(s),k2:u.add(l).neg()}},_.prototype.pointFromX=function(e,t){(e=new(a())(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),n=r.redSqrt();if(0!==n.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var i=n.fromRed().isOdd();return(t&&!i||!t&&i)&&(n=n.redNeg()),this.point(e,n)},_.prototype.validate=function(e){if(e.inf)return!0;var t=e.x,r=e.y,n=this.a.redMul(t),i=t.redSqr().redMul(t).redIAdd(n).redIAdd(this.b);return 0===r.redSqr().redISub(i).cmpn(0)},_.prototype._endoWnafMulAdd=function(e,t,r){for(var n=this._endoWnafT1,i=this._endoWnafT2,o=0;o":""},k.prototype.isInfinity=function(){return this.inf},k.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(0===this.x.cmp(e.x))return this.curve.point(null,null);var t=this.y.redSub(e.y);0!==t.cmpn(0)&&(t=t.redMul(this.x.redSub(e.x).redInvm()));var r=t.redSqr().redISub(this.x).redISub(e.x),n=t.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,n)},k.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(0===e.cmpn(0))return this.curve.point(null,null);var t=this.curve.a,r=this.x.redSqr(),n=e.redInvm(),i=r.redAdd(r).redIAdd(r).redIAdd(t).redMul(n),o=i.redSqr().redISub(this.x.redAdd(this.x)),a=i.redMul(this.x.redSub(o)).redISub(this.y);return this.curve.point(o,a)},k.prototype.getX=function(){return this.x.fromRed()},k.prototype.getY=function(){return this.y.fromRed()},k.prototype.mul=function(e){return e=new(a())(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},k.prototype.mulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i):this.curve._wnafMulAdd(1,n,i,2)},k.prototype.jmulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i,!0):this.curve._wnafMulAdd(1,n,i,2,!0)},k.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||0===this.x.cmp(e.x)&&0===this.y.cmp(e.y))},k.prototype.neg=function(e){if(this.inf)return this;var t=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var r=this.precomputed,n=function(e){return e.neg()};t.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(n)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(n)}}}return t},k.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},w(E,g.BasePoint),_.prototype.jpoint=function(e,t,r){return new E(this,e,t,r)},E.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),t=e.redSqr(),r=this.x.redMul(t),n=this.y.redMul(t).redMul(e);return this.curve.point(r,n)},E.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},E.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.z.redSqr(),r=this.z.redSqr(),n=this.x.redMul(t),i=e.x.redMul(r),o=this.y.redMul(t.redMul(e.z)),a=e.y.redMul(r.redMul(this.z)),s=n.redSub(i),u=o.redSub(a);if(0===s.cmpn(0))return 0!==u.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var l=s.redSqr(),c=l.redMul(s),f=n.redMul(l),d=u.redSqr().redIAdd(c).redISub(f).redISub(f),h=u.redMul(f.redISub(d)).redISub(o.redMul(c)),p=this.z.redMul(e.z).redMul(s);return this.curve.jpoint(d,h,p)},E.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var t=this.z.redSqr(),r=this.x,n=e.x.redMul(t),i=this.y,o=e.y.redMul(t).redMul(this.z),a=r.redSub(n),s=i.redSub(o);if(0===a.cmpn(0))return 0!==s.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var u=a.redSqr(),l=u.redMul(a),c=r.redMul(u),f=s.redSqr().redIAdd(l).redISub(c).redISub(c),d=s.redMul(c.redISub(f)).redISub(i.redMul(l)),h=this.z.redMul(a);return this.curve.jpoint(f,d,h)},E.prototype.dblp=function(e){if(0===e)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var t;if(this.curve.zeroA||this.curve.threeA){var r=this;for(t=0;t=0)return!1;if(r.redIAdd(i),0===this.x.cmp(r))return!0}},E.prototype.inspect=function(){return this.isInfinity()?"":""},E.prototype.isInfinity=function(){return 0===this.z.cmpn(0)};var A=l((function(e,t){var r=t;r.base=g,r.short=S,r.mont=null,r.edwards=null})),j=l((function(e,t){var r,n=t,i=h.assert;function o(e){"short"===e.type?this.curve=new A.short(e):"edwards"===e.type?this.curve=new A.edwards(e):this.curve=new A.mont(e),this.g=this.curve.g,this.n=this.curve.n,this.hash=e.hash,i(this.g.validate(),"Invalid curve"),i(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function a(e,t){Object.defineProperty(n,e,{configurable:!0,enumerable:!0,get:function(){var r=new o(t);return Object.defineProperty(n,e,{configurable:!0,enumerable:!0,value:r}),r}})}n.PresetCurve=o,a("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:u().sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),a("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:u().sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),a("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:u().sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),a("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:u().sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),a("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:u().sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),a("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:u().sha256,gRed:!1,g:["9"]}),a("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:u().sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{r=null.crash()}catch(s){r=void 0}a("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:u().sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",r]})}));function M(e){if(!(this instanceof M))return new M(e);this.hash=e.hash,this.predResist=!!e.predResist,this.outLen=this.hash.outSize,this.minEntropy=e.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var t=d.toArray(e.entropy,e.entropyEnc||"hex"),r=d.toArray(e.nonce,e.nonceEnc||"hex"),n=d.toArray(e.pers,e.persEnc||"hex");c(t.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(t,r,n)}var T=M;M.prototype._init=function(e,t,r){var n=e.concat(t).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var i=0;i=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(r||[])),this._reseed=1},M.prototype.generate=function(e,t,r,n){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!==typeof t&&(n=r,r=t,t=null),r&&(r=d.toArray(r,n||"hex"),this._update(r));for(var i=[];i.length"};var R=h.assert;function I(e,t){if(e instanceof I)return e;this._importDER(e,t)||(R(e.r&&e.s,"Signature without r or s"),this.r=new(a())(e.r,16),this.s=new(a())(e.s,16),void 0===e.recoveryParam?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}var L=I;function N(){this.place=0}function D(e,t){var r=e[t.place++];if(!(128&r))return r;var n=15&r;if(0===n||n>4)return!1;for(var i=0,o=0,a=t.place;o>>=0;return!(i<=127)&&(t.place=a,i)}function F(e){for(var t=0,r=e.length-1;!e[t]&&!(128&e[t+1])&&t>>3);for(e.push(128|r);--r;)e.push(t>>>(r<<3)&255);e.push(t)}}I.prototype._importDER=function(e,t){e=h.toArray(e,t);var r=new N;if(48!==e[r.place++])return!1;var n=D(e,r);if(!1===n)return!1;if(n+r.place!==e.length)return!1;if(2!==e[r.place++])return!1;var i=D(e,r);if(!1===i)return!1;var o=e.slice(r.place,i+r.place);if(r.place+=i,2!==e[r.place++])return!1;var s=D(e,r);if(!1===s)return!1;if(e.length!==s+r.place)return!1;var u=e.slice(r.place,s+r.place);if(0===o[0]){if(!(128&o[1]))return!1;o=o.slice(1)}if(0===u[0]){if(!(128&u[1]))return!1;u=u.slice(1)}return this.r=new(a())(o),this.s=new(a())(u),this.recoveryParam=null,!0},I.prototype.toDER=function(e){var t=this.r.toArray(),r=this.s.toArray();for(128&t[0]&&(t=[0].concat(t)),128&r[0]&&(r=[0].concat(r)),t=F(t),r=F(r);!r[0]&&!(128&r[1]);)r=r.slice(1);var n=[2];U(n,t.length),(n=n.concat(t)).push(2),U(n,r.length);var i=n.concat(r),o=[48];return U(o,i.length),o=o.concat(i),h.encode(o,e)};var B=function(){throw new Error("unsupported")},G=h.assert;function V(e){if(!(this instanceof V))return new V(e);"string"===typeof e&&(G(Object.prototype.hasOwnProperty.call(j,e),"Unknown curve "+e),e=j[e]),e instanceof j.PresetCurve&&(e={curve:e}),this.curve=e.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=e.curve.g,this.g.precompute(e.curve.n.bitLength()+1),this.hash=e.hash||e.curve.hash}var z=V;V.prototype.keyPair=function(e){return new O(this,e)},V.prototype.keyFromPrivate=function(e,t){return O.fromPrivate(this,e,t)},V.prototype.keyFromPublic=function(e,t){return O.fromPublic(this,e,t)},V.prototype.genKeyPair=function(e){e||(e={});for(var t=new T({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||B(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),r=this.n.byteLength(),n=this.n.sub(new(a())(2));;){var i=new(a())(t.generate(r));if(!(i.cmp(n)>0))return i.iaddn(1),this.keyFromPrivate(i)}},V.prototype._truncateToN=function(e,t){var r=8*e.byteLength()-this.n.bitLength();return r>0&&(e=e.ushrn(r)),!t&&e.cmp(this.n)>=0?e.sub(this.n):e},V.prototype.sign=function(e,t,r,n){"object"===typeof r&&(n=r,r=null),n||(n={}),t=this.keyFromPrivate(t,r),e=this._truncateToN(new(a())(e,16));for(var i=this.n.byteLength(),o=t.getPrivate().toArray("be",i),s=e.toArray("be",i),u=new T({hash:this.hash,entropy:o,nonce:s,pers:n.pers,persEnc:n.persEnc||"utf8"}),l=this.n.sub(new(a())(1)),c=0;;c++){var f=n.k?n.k(c):new(a())(u.generate(this.n.byteLength()));if(!((f=this._truncateToN(f,!0)).cmpn(1)<=0||f.cmp(l)>=0)){var d=this.g.mul(f);if(!d.isInfinity()){var h=d.getX(),p=h.umod(this.n);if(0!==p.cmpn(0)){var m=f.invm(this.n).mul(p.mul(t.getPrivate()).iadd(e));if(0!==(m=m.umod(this.n)).cmpn(0)){var y=(d.getY().isOdd()?1:0)|(0!==h.cmp(p)?2:0);return n.canonical&&m.cmp(this.nh)>0&&(m=this.n.sub(m),y^=1),new L({r:p,s:m,recoveryParam:y})}}}}}},V.prototype.verify=function(e,t,r,n){e=this._truncateToN(new(a())(e,16)),r=this.keyFromPublic(r,n);var i=(t=new L(t,"hex")).r,o=t.s;if(i.cmpn(1)<0||i.cmp(this.n)>=0)return!1;if(o.cmpn(1)<0||o.cmp(this.n)>=0)return!1;var s,u=o.invm(this.n),l=u.mul(e).umod(this.n),c=u.mul(i).umod(this.n);return this.curve._maxwellTrick?!(s=this.g.jmulAdd(l,r.getPublic(),c)).isInfinity()&&s.eqXToP(i):!(s=this.g.mulAdd(l,r.getPublic(),c)).isInfinity()&&0===s.getX().umod(this.n).cmp(i)},V.prototype.recoverPubKey=function(e,t,r,n){G((3&r)===r,"The recovery param is more than two bits"),t=new L(t,n);var i=this.n,o=new(a())(e),s=t.r,u=t.s,l=1&r,c=r>>1;if(s.cmp(this.curve.p.umod(this.curve.n))>=0&&c)throw new Error("Unable to find sencond key candinate");s=c?this.curve.pointFromX(s.add(this.curve.n),l):this.curve.pointFromX(s,l);var f=t.r.invm(i),d=i.sub(o).mul(f).umod(i),h=u.mul(f).umod(i);return this.g.mulAdd(d,s,h)},V.prototype.getKeyRecoveryParam=function(e,t,r,n){if(null!==(t=new L(t,n)).recoveryParam)return t.recoveryParam;for(var i=0;i<4;i++){var o;try{o=this.recoverPubKey(e,t,i)}catch(e){continue}if(o.eq(r))return i}throw new Error("Unable to find valid recovery factor")};var q=l((function(e,t){var r=t;r.version="6.5.4",r.utils=h,r.rand=function(){throw new Error("unsupported")},r.curve=A,r.curves=j,r.ec=z,r.eddsa=null})).ec,H=r(2917),Z=r(6574),W=new(r(1755).Logger)("signing-key/5.6.0"),K=null;function X(){return K||(K=new q("secp256k1")),K}var Y=function(){function e(t){(0,n.Z)(this,e),(0,Z.defineReadOnly)(this,"curve","secp256k1"),(0,Z.defineReadOnly)(this,"privateKey",(0,H.hexlify)(t));var r=X().keyFromPrivate((0,H.arrayify)(this.privateKey));(0,Z.defineReadOnly)(this,"publicKey","0x"+r.getPublic(!1,"hex")),(0,Z.defineReadOnly)(this,"compressedPublicKey","0x"+r.getPublic(!0,"hex")),(0,Z.defineReadOnly)(this,"_isSigningKey",!0)}return(0,i.Z)(e,[{key:"_addPoint",value:function(e){var t=X().keyFromPublic((0,H.arrayify)(this.publicKey)),r=X().keyFromPublic((0,H.arrayify)(e));return"0x"+t.pub.add(r.pub).encodeCompressed("hex")}},{key:"signDigest",value:function(e){var t=X().keyFromPrivate((0,H.arrayify)(this.privateKey)),r=(0,H.arrayify)(e);32!==r.length&&W.throwArgumentError("bad digest length","digest",e);var n=t.sign(r,{canonical:!0});return(0,H.splitSignature)({recoveryParam:n.recoveryParam,r:(0,H.hexZeroPad)("0x"+n.r.toString(16),32),s:(0,H.hexZeroPad)("0x"+n.s.toString(16),32)})}},{key:"computeSharedSecret",value:function(e){var t=X().keyFromPrivate((0,H.arrayify)(this.privateKey)),r=X().keyFromPublic((0,H.arrayify)(J(e)));return(0,H.hexZeroPad)("0x"+t.derive(r.getPublic()).toString(16),32)}}],[{key:"isSigningKey",value:function(e){return!(!e||!e._isSigningKey)}}]),e}();function Q(e,t){var r=(0,H.splitSignature)(t),n={r:(0,H.arrayify)(r.r),s:(0,H.arrayify)(r.s)};return"0x"+X().recoverPubKey((0,H.arrayify)(e),n,r.recoveryParam).encode("hex",!1)}function J(e,t){var r=(0,H.arrayify)(e);if(32===r.length){var n=new Y(r);return t?"0x"+X().keyFromPrivate(r).getPublic(!0,"hex"):n.publicKey}return 33===r.length?t?(0,H.hexlify)(r):"0x"+X().keyFromPublic(r).getPublic(!1,"hex"):65===r.length?t?"0x"+X().keyFromPublic(r).getPublic(!0,"hex"):(0,H.hexlify)(r):W.throwArgumentError("invalid public or private key","key","[REDACTED]")}},6724:function(e,t,r){"use strict";r.r(t),r.d(t,{keccak256:function(){return m},pack:function(){return p},sha256:function(){return y}});var n=r(8738),i=r(2917),o=r(6220),a=r(9721),s=r(2981),u=r(1755),l=new RegExp("^bytes([0-9]+)$"),c=new RegExp("^(u?int)([0-9]*)$"),f=new RegExp("^(.*)\\[([0-9]*)\\]$"),d=new u.Logger("solidity/5.6.0");function h(e,t,r){switch(e){case"address":return r?(0,i.zeroPad)(t,32):(0,i.arrayify)(t);case"string":return(0,s.Y0)(t);case"bytes":return(0,i.arrayify)(t);case"bool":return t=t?"0x01":"0x00",r?(0,i.zeroPad)(t,32):(0,i.arrayify)(t)}var o=e.match(c);if(o){var a=parseInt(o[2]||"256");return(o[2]&&String(a)!==o[2]||a%8!==0||0===a||a>256)&&d.throwArgumentError("invalid number type","type",e),r&&(a=256),t=n.O$.from(t).toTwos(a),(0,i.zeroPad)(t,a/8)}if(o=e.match(l)){var u=parseInt(o[1]);return(String(u)!==o[1]||0===u||u>32)&&d.throwArgumentError("invalid bytes type","type",e),(0,i.arrayify)(t).byteLength!==u&&d.throwArgumentError("invalid value for ".concat(e),"value",t),r?(0,i.arrayify)((t+"0000000000000000000000000000000000000000000000000000000000000000").substring(0,66)):t}if((o=e.match(f))&&Array.isArray(t)){var p=o[1];parseInt(o[2]||String(t.length))!=t.length&&d.throwArgumentError("invalid array length for ".concat(e),"value",t);var m=[];return t.forEach((function(e){m.push(h(p,e,!0))})),(0,i.concat)(m)}return d.throwArgumentError("invalid type","type",e)}function p(e,t){e.length!=t.length&&d.throwArgumentError("wrong number of values; expected ${ types.length }","values",t);var r=[];return e.forEach((function(e,n){r.push(h(e,t[n]))})),(0,i.hexlify)((0,i.concat)(r))}function m(e,t){return(0,o.keccak256)(p(e,t))}function y(e,t){return(0,a.JQ)(p(e,t))}},3280:function(e,t,r){"use strict";r.d(t,{Ll:function(){return p}});var n=r(2981);function i(e,t){t||(t=function(e){return[parseInt(e,16)]});var r=0,n={};return e.split(",").forEach((function(e){var i=e.split(":");r+=parseInt(i[0],16),n[r]=t(i[1])})),n}function o(e){var t=0;return e.split(",").map((function(e){var r=e.split("-");return 1===r.length?r[1]="0":""===r[1]&&(r[1]="1"),{l:t+parseInt(r[0],16),h:t=parseInt(r[1],16)}}))}function a(e,t){for(var r=0,n=0;n=(r+=i.l)&&e<=r+i.h&&(e-r)%(i.d||1)===0){if(i.e&&-1!==i.e.indexOf(e-r))continue;return i}}return null}var s=o("221,13-1b,5f-,40-10,51-f,11-3,3-3,2-2,2-4,8,2,15,2d,28-8,88,48,27-,3-5,11-20,27-,8,28,3-5,12,18,b-a,1c-4,6-16,2-d,2-2,2,1b-4,17-9,8f-,10,f,1f-2,1c-34,33-14e,4,36-,13-,6-2,1a-f,4,9-,3-,17,8,2-2,5-,2,8-,3-,4-8,2-3,3,6-,16-6,2-,7-3,3-,17,8,3,3,3-,2,6-3,3-,4-a,5,2-6,10-b,4,8,2,4,17,8,3,6-,b,4,4-,2-e,2-4,b-10,4,9-,3-,17,8,3-,5-,9-2,3-,4-7,3-3,3,4-3,c-10,3,7-2,4,5-2,3,2,3-2,3-2,4-2,9,4-3,6-2,4,5-8,2-e,d-d,4,9,4,18,b,6-3,8,4,5-6,3-8,3-3,b-11,3,9,4,18,b,6-3,8,4,5-6,3-6,2,3-3,b-11,3,9,4,18,11-3,7-,4,5-8,2-7,3-3,b-11,3,13-2,19,a,2-,8-2,2-3,7,2,9-11,4-b,3b-3,1e-24,3,2-,3,2-,2-5,5,8,4,2,2-,3,e,4-,6,2,7-,b-,3-21,49,23-5,1c-3,9,25,10-,2-2f,23,6,3,8-2,5-5,1b-45,27-9,2a-,2-3,5b-4,45-4,53-5,8,40,2,5-,8,2,5-,28,2,5-,20,2,5-,8,2,5-,8,8,18,20,2,5-,8,28,14-5,1d-22,56-b,277-8,1e-2,52-e,e,8-a,18-8,15-b,e,4,3-b,5e-2,b-15,10,b-5,59-7,2b-555,9d-3,5b-5,17-,7-,27-,7-,9,2,2,2,20-,36,10,f-,7,14-,4,a,54-3,2-6,6-5,9-,1c-10,13-1d,1c-14,3c-,10-6,32-b,240-30,28-18,c-14,a0,115-,3,66-,b-76,5,5-,1d,24,2,5-2,2,8-,35-2,19,f-10,1d-3,311-37f,1b,5a-b,d7-19,d-3,41,57-,68-4,29-3,5f,29-37,2e-2,25-c,2c-2,4e-3,30,78-3,64-,20,19b7-49,51a7-59,48e-2,38-738,2ba5-5b,222f-,3c-94,8-b,6-4,1b,6,2,3,3,6d-20,16e-f,41-,37-7,2e-2,11-f,5-b,18-,b,14,5-3,6,88-,2,bf-2,7-,7-,7-,4-2,8,8-9,8-2ff,20,5-b,1c-b4,27-,27-cbb1,f7-9,28-2,b5-221,56,48,3-,2-,3-,5,d,2,5,3,42,5-,9,8,1d,5,6,2-2,8,153-3,123-3,33-27fd,a6da-5128,21f-5df,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3,2-1d,61-ff7d"),u="ad,34f,1806,180b,180c,180d,200b,200c,200d,2060,feff".split(",").map((function(e){return parseInt(e,16)})),l=[{h:25,s:32,l:65},{h:30,s:32,e:[23],l:127},{h:54,s:1,e:[48],l:64,d:2},{h:14,s:1,l:57,d:2},{h:44,s:1,l:17,d:2},{h:10,s:1,e:[2,6,8],l:61,d:2},{h:16,s:1,l:68,d:2},{h:84,s:1,e:[18,24,66],l:19,d:2},{h:26,s:32,e:[17],l:435},{h:22,s:1,l:71,d:2},{h:15,s:80,l:40},{h:31,s:32,l:16},{h:32,s:1,l:80,d:2},{h:52,s:1,l:42,d:2},{h:12,s:1,l:55,d:2},{h:40,s:1,e:[38],l:15,d:2},{h:14,s:1,l:48,d:2},{h:37,s:48,l:49},{h:148,s:1,l:6351,d:2},{h:88,s:1,l:160,d:2},{h:15,s:16,l:704},{h:25,s:26,l:854},{h:25,s:32,l:55915},{h:37,s:40,l:1247},{h:25,s:-119711,l:53248},{h:25,s:-119763,l:52},{h:25,s:-119815,l:52},{h:25,s:-119867,e:[1,4,5,7,8,11,12,17],l:52},{h:25,s:-119919,l:52},{h:24,s:-119971,e:[2,7,8,17],l:52},{h:24,s:-120023,e:[2,7,13,15,16,17],l:52},{h:25,s:-120075,l:52},{h:25,s:-120127,l:52},{h:25,s:-120179,l:52},{h:25,s:-120231,l:52},{h:25,s:-120283,l:52},{h:25,s:-120335,l:52},{h:24,s:-119543,e:[17],l:56},{h:24,s:-119601,e:[17],l:58},{h:24,s:-119659,e:[17],l:58},{h:24,s:-119717,e:[17],l:58},{h:24,s:-119775,e:[17],l:58}],c=i("b5:3bc,c3:ff,7:73,2:253,5:254,3:256,1:257,5:259,1:25b,3:260,1:263,2:269,1:268,5:26f,1:272,2:275,7:280,3:283,5:288,3:28a,1:28b,5:292,3f:195,1:1bf,29:19e,125:3b9,8b:3b2,1:3b8,1:3c5,3:3c6,1:3c0,1a:3ba,1:3c1,1:3c3,2:3b8,1:3b5,1bc9:3b9,1c:1f76,1:1f77,f:1f7a,1:1f7b,d:1f78,1:1f79,1:1f7c,1:1f7d,107:63,5:25b,4:68,1:68,1:68,3:69,1:69,1:6c,3:6e,4:70,1:71,1:72,1:72,1:72,7:7a,2:3c9,2:7a,2:6b,1:e5,1:62,1:63,3:65,1:66,2:6d,b:3b3,1:3c0,6:64,1b574:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3"),f=i("179:1,2:1,2:1,5:1,2:1,a:4f,a:1,8:1,2:1,2:1,3:1,5:1,3:1,4:1,2:1,3:1,4:1,8:2,1:1,2:2,1:1,2:2,27:2,195:26,2:25,1:25,1:25,2:40,2:3f,1:3f,33:1,11:-6,1:-9,1ac7:-3a,6d:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,b:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,c:-8,2:-8,2:-8,2:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,49:-8,1:-8,1:-4a,1:-4a,d:-56,1:-56,1:-56,1:-56,d:-8,1:-8,f:-8,1:-8,3:-7"),d=i("df:00730073,51:00690307,19:02BC006E,a7:006A030C,18a:002003B9,16:03B903080301,20:03C503080301,1d7:05650582,190f:00680331,1:00740308,1:0077030A,1:0079030A,1:006102BE,b6:03C50313,2:03C503130300,2:03C503130301,2:03C503130342,2a:1F0003B9,1:1F0103B9,1:1F0203B9,1:1F0303B9,1:1F0403B9,1:1F0503B9,1:1F0603B9,1:1F0703B9,1:1F0003B9,1:1F0103B9,1:1F0203B9,1:1F0303B9,1:1F0403B9,1:1F0503B9,1:1F0603B9,1:1F0703B9,1:1F2003B9,1:1F2103B9,1:1F2203B9,1:1F2303B9,1:1F2403B9,1:1F2503B9,1:1F2603B9,1:1F2703B9,1:1F2003B9,1:1F2103B9,1:1F2203B9,1:1F2303B9,1:1F2403B9,1:1F2503B9,1:1F2603B9,1:1F2703B9,1:1F6003B9,1:1F6103B9,1:1F6203B9,1:1F6303B9,1:1F6403B9,1:1F6503B9,1:1F6603B9,1:1F6703B9,1:1F6003B9,1:1F6103B9,1:1F6203B9,1:1F6303B9,1:1F6403B9,1:1F6503B9,1:1F6603B9,1:1F6703B9,3:1F7003B9,1:03B103B9,1:03AC03B9,2:03B10342,1:03B1034203B9,5:03B103B9,6:1F7403B9,1:03B703B9,1:03AE03B9,2:03B70342,1:03B7034203B9,5:03B703B9,6:03B903080300,1:03B903080301,3:03B90342,1:03B903080342,b:03C503080300,1:03C503080301,1:03C10313,2:03C50342,1:03C503080342,b:1F7C03B9,1:03C903B9,1:03CE03B9,2:03C90342,1:03C9034203B9,5:03C903B9,ac:00720073,5b:00B00063,6:00B00066,d:006E006F,a:0073006D,1:00740065006C,1:0074006D,124f:006800700061,2:00610075,2:006F0076,b:00700061,1:006E0061,1:03BC0061,1:006D0061,1:006B0061,1:006B0062,1:006D0062,1:00670062,3:00700066,1:006E0066,1:03BC0066,4:0068007A,1:006B0068007A,1:006D0068007A,1:00670068007A,1:00740068007A,15:00700061,1:006B00700061,1:006D00700061,1:006700700061,8:00700076,1:006E0076,1:03BC0076,1:006D0076,1:006B0076,1:006D0076,1:00700077,1:006E0077,1:03BC0077,1:006D0077,1:006B0077,1:006D0077,1:006B03C9,1:006D03C9,2:00620071,3:00632215006B0067,1:0063006F002E,1:00640062,1:00670079,2:00680070,2:006B006B,1:006B006D,9:00700068,2:00700070006D,1:00700072,2:00730076,1:00770062,c723:00660066,1:00660069,1:0066006C,1:006600660069,1:00660066006C,1:00730074,1:00730074,d:05740576,1:05740565,1:0574056B,1:057E0576,1:0574056D",(function(e){if(e.length%4!==0)throw new Error("bad data");for(var t=[],r=0;r=0)return[];if(e>=65024&&e<=65039)return[];var t=function(e){var t=a(e,l);if(t)return[e+t.s];var r=c[e];if(r)return r;var n=f[e];return n?[e+n[0]]:d[e]||null}(e);return t||[e]})),r=t.reduce((function(e,t){return t.forEach((function(t){e.push(t)})),e}),[]),(r=(0,n.XL)((0,n.uu)(r),n.Uj.NFKC)).forEach((function(e){if(a(e,h))throw new Error("STRINGPREP_CONTAINS_PROHIBITED")})),r.forEach((function(e){if(a(e,s))throw new Error("STRINGPREP_CONTAINS_UNASSIGNED")}));var i=(0,n.uu)(r);if("-"===i.substring(0,1)||"--"===i.substring(2,4)||"-"===i.substring(i.length-1))throw new Error("invalid hyphen");if(i.length>63)throw new Error("too long");return i}},3288:function(e,t,r){"use strict";r.r(t),r.d(t,{UnicodeNormalizationForm:function(){return o.Uj},Utf8ErrorFuncs:function(){return o.te},Utf8ErrorReason:function(){return o.Uw},_toEscapedUtf8String:function(){return o.U$},formatBytes32String:function(){return a},nameprep:function(){return u.Ll},parseBytes32String:function(){return s},toUtf8Bytes:function(){return o.Y0},toUtf8CodePoints:function(){return o.XL},toUtf8String:function(){return o.ZN}});var n=r(6926),i=r(2917),o=r(2981);function a(e){var t=(0,o.Y0)(e);if(t.length>31)throw new Error("bytes32 string must be less than 32 bytes");return(0,i.hexlify)((0,i.concat)([t,n.R]).slice(0,32))}function s(e){var t=(0,i.arrayify)(e);if(32!==t.length)throw new Error("invalid bytes32 - not 32 bytes long");if(0!==t[31])throw new Error("invalid bytes32 string - no null terminator");for(var r=31;0===t[r-1];)r--;return(0,o.ZN)(t.slice(0,r))}var u=r(3280)},2981:function(e,t,r){"use strict";r.d(t,{Uj:function(){return n},te:function(){return u},Uw:function(){return i},U$:function(){return d},uu:function(){return h},Y0:function(){return c},XL:function(){return m},ZN:function(){return p}});var n,i,o=r(2917),a=new(r(1755).Logger)("strings/5.6.0");function s(e,t,r,n,o){if(e===i.BAD_PREFIX||e===i.UNEXPECTED_CONTINUE){for(var a=0,s=t+1;s>6===2;s++)a++;return a}return e===i.OVERRUN?r.length-t-1:0}!function(e){e.current="",e.NFC="NFC",e.NFD="NFD",e.NFKC="NFKC",e.NFKD="NFKD"}(n||(n={})),function(e){e.UNEXPECTED_CONTINUE="unexpected continuation byte",e.BAD_PREFIX="bad codepoint prefix",e.OVERRUN="string overrun",e.MISSING_CONTINUE="missing continuation byte",e.OUT_OF_RANGE="out of UTF-8 range",e.UTF16_SURROGATE="UTF-16 surrogate",e.OVERLONG="overlong representation"}(i||(i={}));var u=Object.freeze({error:function(e,t,r,n,i){return a.throwArgumentError("invalid codepoint at offset ".concat(t,"; ").concat(e),"bytes",r)},ignore:s,replace:function(e,t,r,n,o){return e===i.OVERLONG?(n.push(o),0):(n.push(65533),s(e,t,r))}});function l(e,t){null==t&&(t=u.error),e=(0,o.arrayify)(e);for(var r=[],n=0;n>7!==0){var s=null,l=null;if(192===(224&a))s=1,l=127;else if(224===(240&a))s=2,l=2047;else{if(240!==(248&a)){n+=t(128===(192&a)?i.UNEXPECTED_CONTINUE:i.BAD_PREFIX,n-1,e,r);continue}s=3,l=65535}if(n-1+s>=e.length)n+=t(i.OVERRUN,n-1,e,r);else{for(var c=a&(1<<8-s-1)-1,f=0;f1114111?n+=t(i.OUT_OF_RANGE,n-1-s,e,r,c):c>=55296&&c<=57343?n+=t(i.UTF16_SURROGATE,n-1-s,e,r,c):c<=l?n+=t(i.OVERLONG,n-1-s,e,r,c):r.push(c))}}else r.push(a)}return r}function c(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:n.current;t!=n.current&&(a.checkNormalize(),e=e.normalize(t));for(var r=[],i=0;i>6|192),r.push(63&s|128);else if(55296==(64512&s)){i++;var u=e.charCodeAt(i);if(i>=e.length||56320!==(64512&u))throw new Error("invalid utf-8 string");var l=65536+((1023&s)<<10)+(1023&u);r.push(l>>18|240),r.push(l>>12&63|128),r.push(l>>6&63|128),r.push(63&l|128)}else r.push(s>>12|224),r.push(s>>6&63|128),r.push(63&s|128)}return(0,o.arrayify)(r)}function f(e){var t="0000"+e.toString(16);return"\\u"+t.substring(t.length-4)}function d(e,t){return'"'+l(e,t).map((function(e){if(e<256){switch(e){case 8:return"\\b";case 9:return"\\t";case 10:return"\\n";case 13:return"\\r";case 34:return'\\"';case 92:return"\\\\"}if(e>=32&&e<127)return String.fromCharCode(e)}return e<=65535?f(e):f(55296+((e-=65536)>>10&1023))+f(56320+(1023&e))})).join("")+'"'}function h(e){return e.map((function(e){return e<=65535?String.fromCharCode(e):(e-=65536,String.fromCharCode(55296+(e>>10&1023),56320+(1023&e)))})).join("")}function p(e,t){return h(l(e,t))}function m(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:n.current;return l(c(e,t))}},2563:function(e,t,r){"use strict";r.r(t),r.d(t,{TransactionTypes:function(){return n},accessListify:function(){return _},computeAddress:function(){return g},parse:function(){return M},recoverAddress:function(){return b},serialize:function(){return A}});var n,i=r(3652),o=r(8738),a=r(2917),s=r(2742),u=r(6220),l=r(6574),c=r(4228),f=r(3005),d=r(1755),h=new d.Logger("transactions/5.6.0");function p(e){return"0x"===e?null:(0,i.getAddress)(e)}function m(e){return"0x"===e?s._Y:o.O$.from(e)}!function(e){e[e.legacy=0]="legacy",e[e.eip2930=1]="eip2930",e[e.eip1559=2]="eip1559"}(n||(n={}));var y=[{name:"nonce",maxLength:32,numeric:!0},{name:"gasPrice",maxLength:32,numeric:!0},{name:"gasLimit",maxLength:32,numeric:!0},{name:"to",length:20},{name:"value",maxLength:32,numeric:!0},{name:"data"}],v={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,type:!0,value:!0};function g(e){var t=(0,f.VW)(e);return(0,i.getAddress)((0,a.hexDataSlice)((0,u.keccak256)((0,a.hexDataSlice)(t,1)),12))}function b(e,t){return g((0,f.LO)((0,a.arrayify)(e),t))}function w(e,t){var r=(0,a.stripZeros)(o.O$.from(e).toHexString());return r.length>32&&h.throwArgumentError("invalid length for "+t,"transaction:"+t,e),r}function x(e,t){return{address:(0,i.getAddress)(e),storageKeys:(t||[]).map((function(t,r){return 32!==(0,a.hexDataLength)(t)&&h.throwArgumentError("invalid access list storageKey","accessList[".concat(e,":").concat(r,"]"),t),t.toLowerCase()}))}}function _(e){if(Array.isArray(e))return e.map((function(e,t){return Array.isArray(e)?(e.length>2&&h.throwArgumentError("access list expected to be [ address, storageKeys[] ]","value[".concat(t,"]"),e),x(e[0],e[1])):x(e.address,e.storageKeys)}));var t=Object.keys(e).map((function(t){var r=e[t].reduce((function(e,t){return e[t]=!0,e}),{});return x(t,Object.keys(r).sort())}));return t.sort((function(e,t){return e.address.localeCompare(t.address)})),t}function S(e){return _(e).map((function(e){return[e.address,e.storageKeys]}))}function k(e,t){if(null!=e.gasPrice){var r=o.O$.from(e.gasPrice),n=o.O$.from(e.maxFeePerGas||0);r.eq(n)||h.throwArgumentError("mismatch EIP-1559 gasPrice != maxFeePerGas","tx",{gasPrice:r,maxFeePerGas:n})}var s=[w(e.chainId||0,"chainId"),w(e.nonce||0,"nonce"),w(e.maxPriorityFeePerGas||0,"maxPriorityFeePerGas"),w(e.maxFeePerGas||0,"maxFeePerGas"),w(e.gasLimit||0,"gasLimit"),null!=e.to?(0,i.getAddress)(e.to):"0x",w(e.value||0,"value"),e.data||"0x",S(e.accessList||[])];if(t){var u=(0,a.splitSignature)(t);s.push(w(u.recoveryParam,"recoveryParam")),s.push((0,a.stripZeros)(u.r)),s.push((0,a.stripZeros)(u.s))}return(0,a.hexConcat)(["0x02",c.encode(s)])}function E(e,t){var r=[w(e.chainId||0,"chainId"),w(e.nonce||0,"nonce"),w(e.gasPrice||0,"gasPrice"),w(e.gasLimit||0,"gasLimit"),null!=e.to?(0,i.getAddress)(e.to):"0x",w(e.value||0,"value"),e.data||"0x",S(e.accessList||[])];if(t){var n=(0,a.splitSignature)(t);r.push(w(n.recoveryParam,"recoveryParam")),r.push((0,a.stripZeros)(n.r)),r.push((0,a.stripZeros)(n.s))}return(0,a.hexConcat)(["0x01",c.encode(r)])}function A(e,t){if(null==e.type||0===e.type)return null!=e.accessList&&h.throwArgumentError("untyped transactions do not support accessList; include type: 1","transaction",e),function(e,t){(0,l.checkProperties)(e,v);var r=[];y.forEach((function(t){var n=e[t.name]||[],i={};t.numeric&&(i.hexPad="left"),n=(0,a.arrayify)((0,a.hexlify)(n,i)),t.length&&n.length!==t.length&&n.length>0&&h.throwArgumentError("invalid length for "+t.name,"transaction:"+t.name,n),t.maxLength&&(n=(0,a.stripZeros)(n)).length>t.maxLength&&h.throwArgumentError("invalid length for "+t.name,"transaction:"+t.name,n),r.push((0,a.hexlify)(n))}));var n=0;if(null!=e.chainId?"number"!==typeof(n=e.chainId)&&h.throwArgumentError("invalid transaction.chainId","transaction",e):t&&!(0,a.isBytesLike)(t)&&t.v>28&&(n=Math.floor((t.v-35)/2)),0!==n&&(r.push((0,a.hexlify)(n)),r.push("0x"),r.push("0x")),!t)return c.encode(r);var i=(0,a.splitSignature)(t),o=27+i.recoveryParam;return 0!==n?(r.pop(),r.pop(),r.pop(),o+=2*n+8,i.v>28&&i.v!==o&&h.throwArgumentError("transaction.chainId/signature.v mismatch","signature",t)):i.v!==o&&h.throwArgumentError("transaction.chainId/signature.v mismatch","signature",t),r.push((0,a.hexlify)(o)),r.push((0,a.stripZeros)((0,a.arrayify)(i.r))),r.push((0,a.stripZeros)((0,a.arrayify)(i.s))),c.encode(r)}(e,t);switch(e.type){case 1:return E(e,t);case 2:return k(e,t)}return h.throwError("unsupported transaction type: ".concat(e.type),d.Logger.errors.UNSUPPORTED_OPERATION,{operation:"serializeTransaction",transactionType:e.type})}function j(e,t,r){try{var n=m(t[0]).toNumber();if(0!==n&&1!==n)throw new Error("bad recid");e.v=n}catch(o){h.throwArgumentError("invalid v for transaction type: 1","v",t[0])}e.r=(0,a.hexZeroPad)(t[1],32),e.s=(0,a.hexZeroPad)(t[2],32);try{var i=(0,u.keccak256)(r(e));e.from=b(i,{r:e.r,s:e.s,recoveryParam:e.v})}catch(o){console.log(o)}}function M(e){var t=(0,a.arrayify)(e);if(t[0]>127)return function(e){var t=c.decode(e);9!==t.length&&6!==t.length&&h.throwArgumentError("invalid raw transaction","rawTransaction",e);var r={nonce:m(t[0]).toNumber(),gasPrice:m(t[1]),gasLimit:m(t[2]),to:p(t[3]),value:m(t[4]),data:t[5],chainId:0};if(6===t.length)return r;try{r.v=o.O$.from(t[6]).toNumber()}catch(l){return console.log(l),r}if(r.r=(0,a.hexZeroPad)(t[7],32),r.s=(0,a.hexZeroPad)(t[8],32),o.O$.from(r.r).isZero()&&o.O$.from(r.s).isZero())r.chainId=r.v,r.v=0;else{r.chainId=Math.floor((r.v-35)/2),r.chainId<0&&(r.chainId=0);var n=r.v-27,i=t.slice(0,6);0!==r.chainId&&(i.push((0,a.hexlify)(r.chainId)),i.push("0x"),i.push("0x"),n-=2*r.chainId+8);var s=(0,u.keccak256)(c.encode(i));try{r.from=b(s,{r:(0,a.hexlify)(r.r),s:(0,a.hexlify)(r.s),recoveryParam:n})}catch(l){console.log(l)}r.hash=(0,u.keccak256)(e)}return r.type=null,r}(t);switch(t[0]){case 1:return function(e){var t=c.decode(e.slice(1));8!==t.length&&11!==t.length&&h.throwArgumentError("invalid component count for transaction type: 1","payload",(0,a.hexlify)(e));var r={type:1,chainId:m(t[0]).toNumber(),nonce:m(t[1]).toNumber(),gasPrice:m(t[2]),gasLimit:m(t[3]),to:p(t[4]),value:m(t[5]),data:t[6],accessList:_(t[7])};return 8===t.length||(r.hash=(0,u.keccak256)(e),j(r,t.slice(8),E)),r}(t);case 2:return function(e){var t=c.decode(e.slice(1));9!==t.length&&12!==t.length&&h.throwArgumentError("invalid component count for transaction type: 2","payload",(0,a.hexlify)(e));var r=m(t[2]),n=m(t[3]),i={type:2,chainId:m(t[0]).toNumber(),nonce:m(t[1]).toNumber(),maxPriorityFeePerGas:r,maxFeePerGas:n,gasPrice:null,gasLimit:m(t[4]),to:p(t[5]),value:m(t[6]),data:t[7],accessList:_(t[8])};return 9===t.length||(i.hash=(0,u.keccak256)(e),j(i,t.slice(9),k)),i}(t)}return h.throwError("unsupported transaction type: ".concat(t[0]),d.Logger.errors.UNSUPPORTED_OPERATION,{operation:"parseTransaction",transactionType:t[0]})}},8059:function(e,t,r){"use strict";r.r(t),r.d(t,{commify:function(){return a},formatEther:function(){return l},formatUnits:function(){return s},parseEther:function(){return c},parseUnits:function(){return u}});var n=r(5494),i=new(r(1755).Logger)("units/5.6.0"),o=["wei","kwei","mwei","gwei","szabo","finney","ether"];function a(e){var t=String(e).split(".");(t.length>2||!t[0].match(/^-?[0-9]*$/)||t[1]&&!t[1].match(/^[0-9]*$/)||"."===e||"-."===e)&&i.throwArgumentError("invalid value","value",e);var r=t[0],n="";for("-"===r.substring(0,1)&&(n="-",r=r.substring(1));"0"===r.substring(0,1);)r=r.substring(1);""===r&&(r="0");var o="";for(2===t.length&&(o="."+(t[1]||"0"));o.length>2&&"0"===o[o.length-1];)o=o.substring(0,o.length-1);for(var a=[];r.length;){if(r.length<=3){a.unshift(r);break}var s=r.length-3;a.unshift(r.substring(s)),r=r.substring(0,s)}return n+a.join(",")+o}function s(e,t){if("string"===typeof t){var r=o.indexOf(t);-1!==r&&(t=3*r)}return(0,n.S5)(e,null!=t?t:18)}function u(e,t){if("string"!==typeof e&&i.throwArgumentError("value must be a string","value",e),"string"===typeof t){var r=o.indexOf(t);-1!==r&&(t=3*r)}return(0,n.Ox)(e,null!=t?t:18)}function l(e){return s(e,18)}function c(e){return u(e,18)}},4754:function(e,t,r){"use strict";r.r(t),r.d(t,{Wallet:function(){return j},verifyMessage:function(){return M},verifyTypedData:function(){return T}});var n=r(9249),i=r(7371),o=r(753),a=r(5754),s=r(6906),u=r(7162),l=r.n(u),c=r(3652),f=r(2116),d=r(3660),h=r(2917),p=r(1763),m=r(3621),y=r(9400),v=r(6220),g=r(6574),b=r(8087),w=r(3005),x=r(4101),_=r(3065),S=r(2563),k=r(1755),E=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(t){o(t)}}function s(e){try{u(n.throw(e))}catch(t){o(t)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))},A=new k.Logger("wallet/5.6.0");var j=function(e){(0,a.Z)(r,e);var t=(0,s.Z)(r);function r(e,i){var a,s;if((0,n.Z)(this,r),A.checkNew(this instanceof r?this.constructor:void 0,r),a=t.call(this),null!=(s=e)&&(0,h.isHexString)(s.privateKey,32)&&null!=s.address){var u=new w.Et(e.privateKey);if((0,g.defineReadOnly)((0,o.Z)(a),"_signingKey",(function(){return u})),(0,g.defineReadOnly)((0,o.Z)(a),"address",(0,S.computeAddress)(a.publicKey)),a.address!==(0,c.getAddress)(e.address)&&A.throwArgumentError("privateKey/address mismatch","privateKey","[REDACTED]"),function(e){var t=e.mnemonic;return t&&t.phrase}(e)){var l=e.mnemonic;(0,g.defineReadOnly)((0,o.Z)(a),"_mnemonic",(function(){return{phrase:l.phrase,path:l.path||y.defaultPath,locale:l.locale||"en"}}));var d=a.mnemonic,p=y.HDNode.fromMnemonic(d.phrase,null,d.locale).derivePath(d.path);(0,S.computeAddress)(p.privateKey)!==a.address&&A.throwArgumentError("mnemonic/address mismatch","privateKey","[REDACTED]")}else(0,g.defineReadOnly)((0,o.Z)(a),"_mnemonic",(function(){return null}))}else{if(w.Et.isSigningKey(e))"secp256k1"!==e.curve&&A.throwArgumentError("unsupported curve; must be secp256k1","privateKey","[REDACTED]"),(0,g.defineReadOnly)((0,o.Z)(a),"_signingKey",(function(){return e}));else{"string"===typeof e&&e.match(/^[0-9a-f]*$/i)&&64===e.length&&(e="0x"+e);var m=new w.Et(e);(0,g.defineReadOnly)((0,o.Z)(a),"_signingKey",(function(){return m}))}(0,g.defineReadOnly)((0,o.Z)(a),"_mnemonic",(function(){return null})),(0,g.defineReadOnly)((0,o.Z)(a),"address",(0,S.computeAddress)(a.publicKey))}return i&&!f.zt.isProvider(i)&&A.throwArgumentError("invalid provider","provider",i),(0,g.defineReadOnly)((0,o.Z)(a),"provider",i||null),a}return(0,i.Z)(r,[{key:"mnemonic",get:function(){return this._mnemonic()}},{key:"privateKey",get:function(){return this._signingKey().privateKey}},{key:"publicKey",get:function(){return this._signingKey().publicKey}},{key:"getAddress",value:function(){return Promise.resolve(this.address)}},{key:"connect",value:function(e){return new r(this,e)}},{key:"signTransaction",value:function(e){var t=this;return(0,g.resolveProperties)(e).then((function(r){null!=r.from&&((0,c.getAddress)(r.from)!==t.address&&A.throwArgumentError("transaction from address mismatch","transaction.from",e.from),delete r.from);var n=t._signingKey().signDigest((0,v.keccak256)((0,S.serialize)(r)));return(0,S.serialize)(r,n)}))}},{key:"signMessage",value:function(e){return E(this,void 0,void 0,l().mark((function t(){return l().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.abrupt("return",(0,h.joinSignature)(this._signingKey().signDigest((0,p.r)(e))));case 1:case"end":return t.stop()}}),t,this)})))}},{key:"_signTypedData",value:function(e,t,r){return E(this,void 0,void 0,l().mark((function n(){var i,o=this;return l().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,m.E.resolveNames(e,t,r,(function(e){return null==o.provider&&A.throwError("cannot resolve ENS names without a provider",k.Logger.errors.UNSUPPORTED_OPERATION,{operation:"resolveName",value:e}),o.provider.resolveName(e)}));case 2:return i=n.sent,n.abrupt("return",(0,h.joinSignature)(this._signingKey().signDigest(m.E.hash(i.domain,t,i.value))));case 4:case"end":return n.stop()}}),n,this)})))}},{key:"encrypt",value:function(e,t,r){if("function"!==typeof t||r||(r=t,t={}),r&&"function"!==typeof r)throw new Error("invalid callback");return t||(t={}),(0,_.HI)(this,e,t,r)}}],[{key:"createRandom",value:function(e){var t=(0,b.O)(16);e||(e={}),e.extraEntropy&&(t=(0,h.arrayify)((0,h.hexDataSlice)((0,v.keccak256)((0,h.concat)([t,e.extraEntropy])),0,16)));var n=(0,y.entropyToMnemonic)(t,e.locale);return r.fromMnemonic(n,e.path,e.locale)}},{key:"fromEncryptedJson",value:function(e,t,n){return(0,x.decryptJsonWallet)(e,t,n).then((function(e){return new r(e)}))}},{key:"fromEncryptedJsonSync",value:function(e,t){return new r((0,x.decryptJsonWalletSync)(e,t))}},{key:"fromMnemonic",value:function(e,t,n){return t||(t=y.defaultPath),new r(y.HDNode.fromMnemonic(e,null,n).derivePath(t))}}]),r}(d.Signer);function M(e,t){return(0,S.recoverAddress)((0,p.r)(e),t)}function T(e,t,r,n){return(0,S.recoverAddress)(m.E.hash(e,t,r),n)}},9480:function(e,t,r){"use strict";r.r(t),r.d(t,{_fetchData:function(){return y},fetchJson:function(){return v},poll:function(){return g}});var n=r(7162),i=r.n(n),o=r(9911),a=r(2917),s=r(6574),u=r(2981),l=r(1755),c=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(t){o(t)}}function s(e){try{u(n.throw(e))}catch(t){o(t)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};function f(e,t){return c(this,void 0,void 0,i().mark((function r(){var n,o,s,u;return i().wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return null==t&&(t={}),n={method:t.method||"GET",headers:t.headers||{},body:t.body||void 0},!0!==t.skipFetchSetup&&(n.mode="cors",n.cache="no-cache",n.credentials="same-origin",n.redirect="follow",n.referrer="client"),r.next=6,fetch(e,n);case 6:return o=r.sent,r.next=9,o.arrayBuffer();case 9:return s=r.sent,u={},o.headers.forEach?o.headers.forEach((function(e,t){u[t.toLowerCase()]=e})):o.headers.keys().forEach((function(e){u[e.toLowerCase()]=o.headers.get(e)})),r.abrupt("return",{headers:u,statusCode:o.status,statusMessage:o.statusText,body:(0,a.arrayify)(new Uint8Array(s))});case 13:case"end":return r.stop()}}),r)})))}var d=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(t){o(t)}}function s(e){try{u(n.throw(e))}catch(t){o(t)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))},h=new l.Logger("web/5.6.0");function p(e){return new Promise((function(t){setTimeout(t,e)}))}function m(e,t){if(null==e)return null;if("string"===typeof e)return e;if((0,a.isBytesLike)(e)){if(t&&("text"===t.split("/")[0]||"application/json"===t.split(";")[0].trim()))try{return(0,u.ZN)(e)}catch(r){}return(0,a.hexlify)(e)}return e}function y(e,t,r){var n="object"===typeof e&&null!=e.throttleLimit?e.throttleLimit:12;h.assertArgument(n>0&&n%1===0,"invalid connection throttle limit","connection.throttleLimit",n);var a="object"===typeof e?e.throttleCallback:null,s="object"===typeof e&&"number"===typeof e.throttleSlotInterval?e.throttleSlotInterval:100;h.assertArgument(s>0&&s%1===0,"invalid connection throttle slot interval","connection.throttleSlotInterval",s);var c="object"===typeof e&&!!e.errorPassThrough,y={},v=null,g={method:"GET"},b=!1,w=12e4;if("string"===typeof e)v=e;else if("object"===typeof e){if(null!=e&&null!=e.url||h.throwArgumentError("missing URL","connection.url",e),v=e.url,"number"===typeof e.timeout&&e.timeout>0&&(w=e.timeout),e.headers)for(var x in e.headers)y[x.toLowerCase()]={key:x,value:String(e.headers[x])},["if-none-match","if-modified-since"].indexOf(x.toLowerCase())>=0&&(b=!0);if(g.allowGzip=!!e.allowGzip,null!=e.user&&null!=e.password){"https:"!==v.substring(0,6)&&!0!==e.allowInsecureAuthentication&&h.throwError("basic authentication requires a secure https url",l.Logger.errors.INVALID_ARGUMENT,{argument:"url",url:v,user:e.user,password:"[REDACTED]"});var _=e.user+":"+e.password;y.authorization={key:"Authorization",value:"Basic "+(0,o.c)((0,u.Y0)(_))}}null!=e.skipFetchSetup&&(g.skipFetchSetup=!!e.skipFetchSetup)}var S=new RegExp("^data:([a-z0-9-]+/[a-z0-9-]+);base64,(.*)$","i"),k=v?v.match(S):null;if(k)try{var E={statusCode:200,statusMessage:"OK",headers:{"content-type":k[1]},body:(0,o.J)(k[2])},A=E.body;return r&&(A=r(E.body,E)),Promise.resolve(A)}catch(P){h.throwError("processing response error",l.Logger.errors.SERVER_ERROR,{body:m(k[1],k[2]),error:P,requestBody:null,requestMethod:"GET",url:v})}t&&(g.method="POST",g.body=t,null==y["content-type"]&&(y["content-type"]={key:"Content-Type",value:"application/octet-stream"}),null==y["content-length"]&&(y["content-length"]={key:"Content-Length",value:String(t.length)}));var j={};Object.keys(y).forEach((function(e){var t=y[e];j[t.key]=t.value})),g.headers=j;var M=function(){var e=null;return{promise:new Promise((function(t,r){w&&(e=setTimeout((function(){null!=e&&(e=null,r(h.makeError("timeout",l.Logger.errors.TIMEOUT,{requestBody:m(g.body,j["content-type"]),requestMethod:g.method,timeout:w,url:v})))}),w))})),cancel:function(){null!=e&&(clearTimeout(e),e=null)}}}(),T=function(){return d(this,void 0,void 0,i().mark((function e(){var t,o,u,d,y,w,x,_,S,k;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t=0;case 1:if(!(t=300)&&(M.cancel(),h.throwError("bad response",l.Logger.errors.SERVER_ERROR,{status:o.statusCode,headers:o.headers,body:m(x,o.headers?o.headers["content-type"]:null),requestBody:m(g.body,j["content-type"]),requestMethod:g.method,url:v})),!r){e.next=60;break}return e.prev=37,e.next=40,r(x,o);case 40:return _=e.sent,M.cancel(),e.abrupt("return",_);case 45:if(e.prev=45,e.t1=e.catch(37),!(e.t1.throttleRetry&&ts)return void(a()&&n(new Error("retry limit reached")));var l=t.interval*parseInt(String(Math.random()*Math.pow(2,u)));lt.ceiling&&(l=t.ceiling),setTimeout(i,l)}return null}),(function(e){a()&&n(e)}))}()}))}},6985:function(e,t,r){"use strict";r.r(t),r.d(t,{Wordlist:function(){return n.D},logger:function(){return n.k},wordlists:function(){return i.E}});var n=r(8724),i=r(2687)},8724:function(e,t,r){"use strict";r.d(t,{D:function(){return l},k:function(){return u}});var n=r(9249),i=r(7371),o=r(1235),a=r(6574),s=r(1755),u=new s.Logger("wordlists/5.6.0"),l=function(){function e(t){(0,n.Z)(this,e),u.checkAbstract(this instanceof e?this.constructor:void 0,e),(0,a.defineReadOnly)(this,"locale",t)}return(0,i.Z)(e,[{key:"split",value:function(e){return e.toLowerCase().split(/ +/g)}},{key:"join",value:function(e){return e.join(" ")}}],[{key:"check",value:function(e){for(var t=[],r=0;r<2048;r++){var n=e.getWord(r);if(r!==e.getWordIndex(n))return"0x";t.push(n)}return(0,o.id)(t.join("\n")+"\n")}},{key:"register",value:function(e,t){t||(t=e.locale)}}]),e}()},2687:function(e,t,r){"use strict";r.d(t,{E:function(){return f}});var n=r(9249),i=r(7371),o=r(5754),a=r(6906),s=r(8724),u=null;function l(e){if(null==u&&(u="AbandonAbilityAbleAboutAboveAbsentAbsorbAbstractAbsurdAbuseAccessAccidentAccountAccuseAchieveAcidAcousticAcquireAcrossActActionActorActressActualAdaptAddAddictAddressAdjustAdmitAdultAdvanceAdviceAerobicAffairAffordAfraidAgainAgeAgentAgreeAheadAimAirAirportAisleAlarmAlbumAlcoholAlertAlienAllAlleyAllowAlmostAloneAlphaAlreadyAlsoAlterAlwaysAmateurAmazingAmongAmountAmusedAnalystAnchorAncientAngerAngleAngryAnimalAnkleAnnounceAnnualAnotherAnswerAntennaAntiqueAnxietyAnyApartApologyAppearAppleApproveAprilArchArcticAreaArenaArgueArmArmedArmorArmyAroundArrangeArrestArriveArrowArtArtefactArtistArtworkAskAspectAssaultAssetAssistAssumeAsthmaAthleteAtomAttackAttendAttitudeAttractAuctionAuditAugustAuntAuthorAutoAutumnAverageAvocadoAvoidAwakeAwareAwayAwesomeAwfulAwkwardAxisBabyBachelorBaconBadgeBagBalanceBalconyBallBambooBananaBannerBarBarelyBargainBarrelBaseBasicBasketBattleBeachBeanBeautyBecauseBecomeBeefBeforeBeginBehaveBehindBelieveBelowBeltBenchBenefitBestBetrayBetterBetweenBeyondBicycleBidBikeBindBiologyBirdBirthBitterBlackBladeBlameBlanketBlastBleakBlessBlindBloodBlossomBlouseBlueBlurBlushBoardBoatBodyBoilBombBoneBonusBookBoostBorderBoringBorrowBossBottomBounceBoxBoyBracketBrainBrandBrassBraveBreadBreezeBrickBridgeBriefBrightBringBriskBroccoliBrokenBronzeBroomBrotherBrownBrushBubbleBuddyBudgetBuffaloBuildBulbBulkBulletBundleBunkerBurdenBurgerBurstBusBusinessBusyButterBuyerBuzzCabbageCabinCableCactusCageCakeCallCalmCameraCampCanCanalCancelCandyCannonCanoeCanvasCanyonCapableCapitalCaptainCarCarbonCardCargoCarpetCarryCartCaseCashCasinoCastleCasualCatCatalogCatchCategoryCattleCaughtCauseCautionCaveCeilingCeleryCementCensusCenturyCerealCertainChairChalkChampionChangeChaosChapterChargeChaseChatCheapCheckCheeseChefCherryChestChickenChiefChildChimneyChoiceChooseChronicChuckleChunkChurnCigarCinnamonCircleCitizenCityCivilClaimClapClarifyClawClayCleanClerkCleverClickClientCliffClimbClinicClipClockClogCloseClothCloudClownClubClumpClusterClutchCoachCoastCoconutCodeCoffeeCoilCoinCollectColorColumnCombineComeComfortComicCommonCompanyConcertConductConfirmCongressConnectConsiderControlConvinceCookCoolCopperCopyCoralCoreCornCorrectCostCottonCouchCountryCoupleCourseCousinCoverCoyoteCrackCradleCraftCramCraneCrashCraterCrawlCrazyCreamCreditCreekCrewCricketCrimeCrispCriticCropCrossCrouchCrowdCrucialCruelCruiseCrumbleCrunchCrushCryCrystalCubeCultureCupCupboardCuriousCurrentCurtainCurveCushionCustomCuteCycleDadDamageDampDanceDangerDaringDashDaughterDawnDayDealDebateDebrisDecadeDecemberDecideDeclineDecorateDecreaseDeerDefenseDefineDefyDegreeDelayDeliverDemandDemiseDenialDentistDenyDepartDependDepositDepthDeputyDeriveDescribeDesertDesignDeskDespairDestroyDetailDetectDevelopDeviceDevoteDiagramDialDiamondDiaryDiceDieselDietDifferDigitalDignityDilemmaDinnerDinosaurDirectDirtDisagreeDiscoverDiseaseDishDismissDisorderDisplayDistanceDivertDivideDivorceDizzyDoctorDocumentDogDollDolphinDomainDonateDonkeyDonorDoorDoseDoubleDoveDraftDragonDramaDrasticDrawDreamDressDriftDrillDrinkDripDriveDropDrumDryDuckDumbDuneDuringDustDutchDutyDwarfDynamicEagerEagleEarlyEarnEarthEasilyEastEasyEchoEcologyEconomyEdgeEditEducateEffortEggEightEitherElbowElderElectricElegantElementElephantElevatorEliteElseEmbarkEmbodyEmbraceEmergeEmotionEmployEmpowerEmptyEnableEnactEndEndlessEndorseEnemyEnergyEnforceEngageEngineEnhanceEnjoyEnlistEnoughEnrichEnrollEnsureEnterEntireEntryEnvelopeEpisodeEqualEquipEraEraseErodeErosionErrorEruptEscapeEssayEssenceEstateEternalEthicsEvidenceEvilEvokeEvolveExactExampleExcessExchangeExciteExcludeExcuseExecuteExerciseExhaustExhibitExileExistExitExoticExpandExpectExpireExplainExposeExpressExtendExtraEyeEyebrowFabricFaceFacultyFadeFaintFaithFallFalseFameFamilyFamousFanFancyFantasyFarmFashionFatFatalFatherFatigueFaultFavoriteFeatureFebruaryFederalFeeFeedFeelFemaleFenceFestivalFetchFeverFewFiberFictionFieldFigureFileFilmFilterFinalFindFineFingerFinishFireFirmFirstFiscalFishFitFitnessFixFlagFlameFlashFlatFlavorFleeFlightFlipFloatFlockFloorFlowerFluidFlushFlyFoamFocusFogFoilFoldFollowFoodFootForceForestForgetForkFortuneForumForwardFossilFosterFoundFoxFragileFrameFrequentFreshFriendFringeFrogFrontFrostFrownFrozenFruitFuelFunFunnyFurnaceFuryFutureGadgetGainGalaxyGalleryGameGapGarageGarbageGardenGarlicGarmentGasGaspGateGatherGaugeGazeGeneralGeniusGenreGentleGenuineGestureGhostGiantGiftGiggleGingerGiraffeGirlGiveGladGlanceGlareGlassGlideGlimpseGlobeGloomGloryGloveGlowGlueGoatGoddessGoldGoodGooseGorillaGospelGossipGovernGownGrabGraceGrainGrantGrapeGrassGravityGreatGreenGridGriefGritGroceryGroupGrowGruntGuardGuessGuideGuiltGuitarGunGymHabitHairHalfHammerHamsterHandHappyHarborHardHarshHarvestHatHaveHawkHazardHeadHealthHeartHeavyHedgehogHeightHelloHelmetHelpHenHeroHiddenHighHillHintHipHireHistoryHobbyHockeyHoldHoleHolidayHollowHomeHoneyHoodHopeHornHorrorHorseHospitalHostHotelHourHoverHubHugeHumanHumbleHumorHundredHungryHuntHurdleHurryHurtHusbandHybridIceIconIdeaIdentifyIdleIgnoreIllIllegalIllnessImageImitateImmenseImmuneImpactImposeImproveImpulseInchIncludeIncomeIncreaseIndexIndicateIndoorIndustryInfantInflictInformInhaleInheritInitialInjectInjuryInmateInnerInnocentInputInquiryInsaneInsectInsideInspireInstallIntactInterestIntoInvestInviteInvolveIronIslandIsolateIssueItemIvoryJacketJaguarJarJazzJealousJeansJellyJewelJobJoinJokeJourneyJoyJudgeJuiceJumpJungleJuniorJunkJustKangarooKeenKeepKetchupKeyKickKidKidneyKindKingdomKissKitKitchenKiteKittenKiwiKneeKnifeKnockKnowLabLabelLaborLadderLadyLakeLampLanguageLaptopLargeLaterLatinLaughLaundryLavaLawLawnLawsuitLayerLazyLeaderLeafLearnLeaveLectureLeftLegLegalLegendLeisureLemonLendLengthLensLeopardLessonLetterLevelLiarLibertyLibraryLicenseLifeLiftLightLikeLimbLimitLinkLionLiquidListLittleLiveLizardLoadLoanLobsterLocalLockLogicLonelyLongLoopLotteryLoudLoungeLoveLoyalLuckyLuggageLumberLunarLunchLuxuryLyricsMachineMadMagicMagnetMaidMailMainMajorMakeMammalManManageMandateMangoMansionManualMapleMarbleMarchMarginMarineMarketMarriageMaskMassMasterMatchMaterialMathMatrixMatterMaximumMazeMeadowMeanMeasureMeatMechanicMedalMediaMelodyMeltMemberMemoryMentionMenuMercyMergeMeritMerryMeshMessageMetalMethodMiddleMidnightMilkMillionMimicMindMinimumMinorMinuteMiracleMirrorMiseryMissMistakeMixMixedMixtureMobileModelModifyMomMomentMonitorMonkeyMonsterMonthMoonMoralMoreMorningMosquitoMotherMotionMotorMountainMouseMoveMovieMuchMuffinMuleMultiplyMuscleMuseumMushroomMusicMustMutualMyselfMysteryMythNaiveNameNapkinNarrowNastyNationNatureNearNeckNeedNegativeNeglectNeitherNephewNerveNestNetNetworkNeutralNeverNewsNextNiceNightNobleNoiseNomineeNoodleNormalNorthNoseNotableNoteNothingNoticeNovelNowNuclearNumberNurseNutOakObeyObjectObligeObscureObserveObtainObviousOccurOceanOctoberOdorOffOfferOfficeOftenOilOkayOldOliveOlympicOmitOnceOneOnionOnlineOnlyOpenOperaOpinionOpposeOptionOrangeOrbitOrchardOrderOrdinaryOrganOrientOriginalOrphanOstrichOtherOutdoorOuterOutputOutsideOvalOvenOverOwnOwnerOxygenOysterOzonePactPaddlePagePairPalacePalmPandaPanelPanicPantherPaperParadeParentParkParrotPartyPassPatchPathPatientPatrolPatternPausePavePaymentPeacePeanutPearPeasantPelicanPenPenaltyPencilPeoplePepperPerfectPermitPersonPetPhonePhotoPhrasePhysicalPianoPicnicPicturePiecePigPigeonPillPilotPinkPioneerPipePistolPitchPizzaPlacePlanetPlasticPlatePlayPleasePledgePluckPlugPlungePoemPoetPointPolarPolePolicePondPonyPoolPopularPortionPositionPossiblePostPotatoPotteryPovertyPowderPowerPracticePraisePredictPreferPreparePresentPrettyPreventPricePridePrimaryPrintPriorityPrisonPrivatePrizeProblemProcessProduceProfitProgramProjectPromoteProofPropertyProsperProtectProudProvidePublicPuddingPullPulpPulsePumpkinPunchPupilPuppyPurchasePurityPurposePursePushPutPuzzlePyramidQualityQuantumQuarterQuestionQuickQuitQuizQuoteRabbitRaccoonRaceRackRadarRadioRailRainRaiseRallyRampRanchRandomRangeRapidRareRateRatherRavenRawRazorReadyRealReasonRebelRebuildRecallReceiveRecipeRecordRecycleReduceReflectReformRefuseRegionRegretRegularRejectRelaxReleaseReliefRelyRemainRememberRemindRemoveRenderRenewRentReopenRepairRepeatReplaceReportRequireRescueResembleResistResourceResponseResultRetireRetreatReturnReunionRevealReviewRewardRhythmRibRibbonRiceRichRideRidgeRifleRightRigidRingRiotRippleRiskRitualRivalRiverRoadRoastRobotRobustRocketRomanceRoofRookieRoomRoseRotateRoughRoundRouteRoyalRubberRudeRugRuleRunRunwayRuralSadSaddleSadnessSafeSailSaladSalmonSalonSaltSaluteSameSampleSandSatisfySatoshiSauceSausageSaveSayScaleScanScareScatterSceneSchemeSchoolScienceScissorsScorpionScoutScrapScreenScriptScrubSeaSearchSeasonSeatSecondSecretSectionSecuritySeedSeekSegmentSelectSellSeminarSeniorSenseSentenceSeriesServiceSessionSettleSetupSevenShadowShaftShallowShareShedShellSheriffShieldShiftShineShipShiverShockShoeShootShopShortShoulderShoveShrimpShrugShuffleShySiblingSickSideSiegeSightSignSilentSilkSillySilverSimilarSimpleSinceSingSirenSisterSituateSixSizeSkateSketchSkiSkillSkinSkirtSkullSlabSlamSleepSlenderSliceSlideSlightSlimSloganSlotSlowSlushSmallSmartSmileSmokeSmoothSnackSnakeSnapSniffSnowSoapSoccerSocialSockSodaSoftSolarSoldierSolidSolutionSolveSomeoneSongSoonSorrySortSoulSoundSoupSourceSouthSpaceSpareSpatialSpawnSpeakSpecialSpeedSpellSpendSphereSpiceSpiderSpikeSpinSpiritSplitSpoilSponsorSpoonSportSpotSpraySpreadSpringSpySquareSqueezeSquirrelStableStadiumStaffStageStairsStampStandStartStateStaySteakSteelStemStepStereoStickStillStingStockStomachStoneStoolStoryStoveStrategyStreetStrikeStrongStruggleStudentStuffStumbleStyleSubjectSubmitSubwaySuccessSuchSuddenSufferSugarSuggestSuitSummerSunSunnySunsetSuperSupplySupremeSureSurfaceSurgeSurpriseSurroundSurveySuspectSustainSwallowSwampSwapSwarmSwearSweetSwiftSwimSwingSwitchSwordSymbolSymptomSyrupSystemTableTackleTagTailTalentTalkTankTapeTargetTaskTasteTattooTaxiTeachTeamTellTenTenantTennisTentTermTestTextThankThatThemeThenTheoryThereTheyThingThisThoughtThreeThriveThrowThumbThunderTicketTideTigerTiltTimberTimeTinyTipTiredTissueTitleToastTobaccoTodayToddlerToeTogetherToiletTokenTomatoTomorrowToneTongueTonightToolToothTopTopicToppleTorchTornadoTortoiseTossTotalTouristTowardTowerTownToyTrackTradeTrafficTragicTrainTransferTrapTrashTravelTrayTreatTreeTrendTrialTribeTrickTriggerTrimTripTrophyTroubleTruckTrueTrulyTrumpetTrustTruthTryTubeTuitionTumbleTunaTunnelTurkeyTurnTurtleTwelveTwentyTwiceTwinTwistTwoTypeTypicalUglyUmbrellaUnableUnawareUncleUncoverUnderUndoUnfairUnfoldUnhappyUniformUniqueUnitUniverseUnknownUnlockUntilUnusualUnveilUpdateUpgradeUpholdUponUpperUpsetUrbanUrgeUsageUseUsedUsefulUselessUsualUtilityVacantVacuumVagueValidValleyValveVanVanishVaporVariousVastVaultVehicleVelvetVendorVentureVenueVerbVerifyVersionVeryVesselVeteranViableVibrantViciousVictoryVideoViewVillageVintageViolinVirtualVirusVisaVisitVisualVitalVividVocalVoiceVoidVolcanoVolumeVoteVoyageWageWagonWaitWalkWallWalnutWantWarfareWarmWarriorWashWaspWasteWaterWaveWayWealthWeaponWearWeaselWeatherWebWeddingWeekendWeirdWelcomeWestWetWhaleWhatWheatWheelWhenWhereWhipWhisperWideWidthWifeWildWillWinWindowWineWingWinkWinnerWinterWireWisdomWiseWishWitnessWolfWomanWonderWoodWoolWordWorkWorldWorryWorthWrapWreckWrestleWristWriteWrongYardYearYellowYouYoungYouthZebraZeroZoneZoo".replace(/([A-Z])/g," $1").toLowerCase().substring(1).split(" "),"0x3c8acc1e7b08d8e76f9fda015ef48dc8c710a73cb7e0f77b2c18a9b5a7adde60"!==s.D.check(e)))throw u=null,new Error("BIP39 Wordlist for en (English) FAILED")}var c=new(function(e){(0,o.Z)(r,e);var t=(0,a.Z)(r);function r(){return(0,n.Z)(this,r),t.call(this,"en")}return(0,i.Z)(r,[{key:"getWord",value:function(e){return l(this),u[e]}},{key:"getWordIndex",value:function(e){return l(this),u.indexOf(e)}}]),r}(s.D));s.D.register(c);var f={en:c}},2615:function(e){"use strict";!function(t){function r(e){return parseInt(e)===e}function n(e){if(!r(e.length))return!1;for(var t=0;t255)return!1;return!0}function i(e,t){if(e.buffer&&ArrayBuffer.isView(e)&&"Uint8Array"===e.name)return t&&(e=e.slice?e.slice():Array.prototype.slice.call(e)),e;if(Array.isArray(e)){if(!n(e))throw new Error("Array contains invalid value: "+e);return new Uint8Array(e)}if(r(e.length)&&n(e))return new Uint8Array(e);throw new Error("unsupported array-like object")}function o(e){return new Uint8Array(e)}function a(e,t,r,n,i){null==n&&null==i||(e=e.slice?e.slice(n,i):Array.prototype.slice.call(e,n,i)),t.set(e,r)}var s={toBytes:function(e){var t=[],r=0;for(e=encodeURI(e);r191&&n<224?(t.push(String.fromCharCode((31&n)<<6|63&e[r+1])),r+=2):(t.push(String.fromCharCode((15&n)<<12|(63&e[r+1])<<6|63&e[r+2])),r+=3)}return t.join("")}},u=function(){var e="0123456789abcdef";return{toBytes:function(e){for(var t=[],r=0;r>4]+e[15&i])}return r.join("")}}}(),l={16:10,24:12,32:14},c=[1,2,4,8,16,32,64,128,27,54,108,216,171,77,154,47,94,188,99,198,151,53,106,212,179,125,250,239,197,145],f=[99,124,119,123,242,107,111,197,48,1,103,43,254,215,171,118,202,130,201,125,250,89,71,240,173,212,162,175,156,164,114,192,183,253,147,38,54,63,247,204,52,165,229,241,113,216,49,21,4,199,35,195,24,150,5,154,7,18,128,226,235,39,178,117,9,131,44,26,27,110,90,160,82,59,214,179,41,227,47,132,83,209,0,237,32,252,177,91,106,203,190,57,74,76,88,207,208,239,170,251,67,77,51,133,69,249,2,127,80,60,159,168,81,163,64,143,146,157,56,245,188,182,218,33,16,255,243,210,205,12,19,236,95,151,68,23,196,167,126,61,100,93,25,115,96,129,79,220,34,42,144,136,70,238,184,20,222,94,11,219,224,50,58,10,73,6,36,92,194,211,172,98,145,149,228,121,231,200,55,109,141,213,78,169,108,86,244,234,101,122,174,8,186,120,37,46,28,166,180,198,232,221,116,31,75,189,139,138,112,62,181,102,72,3,246,14,97,53,87,185,134,193,29,158,225,248,152,17,105,217,142,148,155,30,135,233,206,85,40,223,140,161,137,13,191,230,66,104,65,153,45,15,176,84,187,22],d=[82,9,106,213,48,54,165,56,191,64,163,158,129,243,215,251,124,227,57,130,155,47,255,135,52,142,67,68,196,222,233,203,84,123,148,50,166,194,35,61,238,76,149,11,66,250,195,78,8,46,161,102,40,217,36,178,118,91,162,73,109,139,209,37,114,248,246,100,134,104,152,22,212,164,92,204,93,101,182,146,108,112,72,80,253,237,185,218,94,21,70,87,167,141,157,132,144,216,171,0,140,188,211,10,247,228,88,5,184,179,69,6,208,44,30,143,202,63,15,2,193,175,189,3,1,19,138,107,58,145,17,65,79,103,220,234,151,242,207,206,240,180,230,115,150,172,116,34,231,173,53,133,226,249,55,232,28,117,223,110,71,241,26,113,29,41,197,137,111,183,98,14,170,24,190,27,252,86,62,75,198,210,121,32,154,219,192,254,120,205,90,244,31,221,168,51,136,7,199,49,177,18,16,89,39,128,236,95,96,81,127,169,25,181,74,13,45,229,122,159,147,201,156,239,160,224,59,77,174,42,245,176,200,235,187,60,131,83,153,97,23,43,4,126,186,119,214,38,225,105,20,99,85,33,12,125],h=[3328402341,4168907908,4000806809,4135287693,4294111757,3597364157,3731845041,2445657428,1613770832,33620227,3462883241,1445669757,3892248089,3050821474,1303096294,3967186586,2412431941,528646813,2311702848,4202528135,4026202645,2992200171,2387036105,4226871307,1101901292,3017069671,1604494077,1169141738,597466303,1403299063,3832705686,2613100635,1974974402,3791519004,1033081774,1277568618,1815492186,2118074177,4126668546,2211236943,1748251740,1369810420,3521504564,4193382664,3799085459,2883115123,1647391059,706024767,134480908,2512897874,1176707941,2646852446,806885416,932615841,168101135,798661301,235341577,605164086,461406363,3756188221,3454790438,1311188841,2142417613,3933566367,302582043,495158174,1479289972,874125870,907746093,3698224818,3025820398,1537253627,2756858614,1983593293,3084310113,2108928974,1378429307,3722699582,1580150641,327451799,2790478837,3117535592,0,3253595436,1075847264,3825007647,2041688520,3059440621,3563743934,2378943302,1740553945,1916352843,2487896798,2555137236,2958579944,2244988746,3151024235,3320835882,1336584933,3992714006,2252555205,2588757463,1714631509,293963156,2319795663,3925473552,67240454,4269768577,2689618160,2017213508,631218106,1269344483,2723238387,1571005438,2151694528,93294474,1066570413,563977660,1882732616,4059428100,1673313503,2008463041,2950355573,1109467491,537923632,3858759450,4260623118,3218264685,2177748300,403442708,638784309,3287084079,3193921505,899127202,2286175436,773265209,2479146071,1437050866,4236148354,2050833735,3362022572,3126681063,840505643,3866325909,3227541664,427917720,2655997905,2749160575,1143087718,1412049534,999329963,193497219,2353415882,3354324521,1807268051,672404540,2816401017,3160301282,369822493,2916866934,3688947771,1681011286,1949973070,336202270,2454276571,201721354,1210328172,3093060836,2680341085,3184776046,1135389935,3294782118,965841320,831886756,3554993207,4068047243,3588745010,2345191491,1849112409,3664604599,26054028,2983581028,2622377682,1235855840,3630984372,2891339514,4092916743,3488279077,3395642799,4101667470,1202630377,268961816,1874508501,4034427016,1243948399,1546530418,941366308,1470539505,1941222599,2546386513,3421038627,2715671932,3899946140,1042226977,2521517021,1639824860,227249030,260737669,3765465232,2084453954,1907733956,3429263018,2420656344,100860677,4160157185,470683154,3261161891,1781871967,2924959737,1773779408,394692241,2579611992,974986535,664706745,3655459128,3958962195,731420851,571543859,3530123707,2849626480,126783113,865375399,765172662,1008606754,361203602,3387549984,2278477385,2857719295,1344809080,2782912378,59542671,1503764984,160008576,437062935,1707065306,3622233649,2218934982,3496503480,2185314755,697932208,1512910199,504303377,2075177163,2824099068,1841019862,739644986],p=[2781242211,2230877308,2582542199,2381740923,234877682,3184946027,2984144751,1418839493,1348481072,50462977,2848876391,2102799147,434634494,1656084439,3863849899,2599188086,1167051466,2636087938,1082771913,2281340285,368048890,3954334041,3381544775,201060592,3963727277,1739838676,4250903202,3930435503,3206782108,4149453988,2531553906,1536934080,3262494647,484572669,2923271059,1783375398,1517041206,1098792767,49674231,1334037708,1550332980,4098991525,886171109,150598129,2481090929,1940642008,1398944049,1059722517,201851908,1385547719,1699095331,1587397571,674240536,2704774806,252314885,3039795866,151914247,908333586,2602270848,1038082786,651029483,1766729511,3447698098,2682942837,454166793,2652734339,1951935532,775166490,758520603,3000790638,4004797018,4217086112,4137964114,1299594043,1639438038,3464344499,2068982057,1054729187,1901997871,2534638724,4121318227,1757008337,0,750906861,1614815264,535035132,3363418545,3988151131,3201591914,1183697867,3647454910,1265776953,3734260298,3566750796,3903871064,1250283471,1807470800,717615087,3847203498,384695291,3313910595,3617213773,1432761139,2484176261,3481945413,283769337,100925954,2180939647,4037038160,1148730428,3123027871,3813386408,4087501137,4267549603,3229630528,2315620239,2906624658,3156319645,1215313976,82966005,3747855548,3245848246,1974459098,1665278241,807407632,451280895,251524083,1841287890,1283575245,337120268,891687699,801369324,3787349855,2721421207,3431482436,959321879,1469301956,4065699751,2197585534,1199193405,2898814052,3887750493,724703513,2514908019,2696962144,2551808385,3516813135,2141445340,1715741218,2119445034,2872807568,2198571144,3398190662,700968686,3547052216,1009259540,2041044702,3803995742,487983883,1991105499,1004265696,1449407026,1316239930,504629770,3683797321,168560134,1816667172,3837287516,1570751170,1857934291,4014189740,2797888098,2822345105,2754712981,936633572,2347923833,852879335,1133234376,1500395319,3084545389,2348912013,1689376213,3533459022,3762923945,3034082412,4205598294,133428468,634383082,2949277029,2398386810,3913789102,403703816,3580869306,2297460856,1867130149,1918643758,607656988,4049053350,3346248884,1368901318,600565992,2090982877,2632479860,557719327,3717614411,3697393085,2249034635,2232388234,2430627952,1115438654,3295786421,2865522278,3633334344,84280067,33027830,303828494,2747425121,1600795957,4188952407,3496589753,2434238086,1486471617,658119965,3106381470,953803233,334231800,3005978776,857870609,3151128937,1890179545,2298973838,2805175444,3056442267,574365214,2450884487,550103529,1233637070,4289353045,2018519080,2057691103,2399374476,4166623649,2148108681,387583245,3664101311,836232934,3330556482,3100665960,3280093505,2955516313,2002398509,287182607,3413881008,4238890068,3597515707,975967766],m=[1671808611,2089089148,2006576759,2072901243,4061003762,1807603307,1873927791,3310653893,810573872,16974337,1739181671,729634347,4263110654,3613570519,2883997099,1989864566,3393556426,2191335298,3376449993,2106063485,4195741690,1508618841,1204391495,4027317232,2917941677,3563566036,2734514082,2951366063,2629772188,2767672228,1922491506,3227229120,3082974647,4246528509,2477669779,644500518,911895606,1061256767,4144166391,3427763148,878471220,2784252325,3845444069,4043897329,1905517169,3631459288,827548209,356461077,67897348,3344078279,593839651,3277757891,405286936,2527147926,84871685,2595565466,118033927,305538066,2157648768,3795705826,3945188843,661212711,2999812018,1973414517,152769033,2208177539,745822252,439235610,455947803,1857215598,1525593178,2700827552,1391895634,994932283,3596728278,3016654259,695947817,3812548067,795958831,2224493444,1408607827,3513301457,0,3979133421,543178784,4229948412,2982705585,1542305371,1790891114,3410398667,3201918910,961245753,1256100938,1289001036,1491644504,3477767631,3496721360,4012557807,2867154858,4212583931,1137018435,1305975373,861234739,2241073541,1171229253,4178635257,33948674,2139225727,1357946960,1011120188,2679776671,2833468328,1374921297,2751356323,1086357568,2408187279,2460827538,2646352285,944271416,4110742005,3168756668,3066132406,3665145818,560153121,271589392,4279952895,4077846003,3530407890,3444343245,202643468,322250259,3962553324,1608629855,2543990167,1154254916,389623319,3294073796,2817676711,2122513534,1028094525,1689045092,1575467613,422261273,1939203699,1621147744,2174228865,1339137615,3699352540,577127458,712922154,2427141008,2290289544,1187679302,3995715566,3100863416,339486740,3732514782,1591917662,186455563,3681988059,3762019296,844522546,978220090,169743370,1239126601,101321734,611076132,1558493276,3260915650,3547250131,2901361580,1655096418,2443721105,2510565781,3828863972,2039214713,3878868455,3359869896,928607799,1840765549,2374762893,3580146133,1322425422,2850048425,1823791212,1459268694,4094161908,3928346602,1706019429,2056189050,2934523822,135794696,3134549946,2022240376,628050469,779246638,472135708,2800834470,3032970164,3327236038,3894660072,3715932637,1956440180,522272287,1272813131,3185336765,2340818315,2323976074,1888542832,1044544574,3049550261,1722469478,1222152264,50660867,4127324150,236067854,1638122081,895445557,1475980887,3117443513,2257655686,3243809217,489110045,2662934430,3778599393,4162055160,2561878936,288563729,1773916777,3648039385,2391345038,2493985684,2612407707,505560094,2274497927,3911240169,3460925390,1442818645,678973480,3749357023,2358182796,2717407649,2306869641,219617805,3218761151,3862026214,1120306242,1756942440,1103331905,2578459033,762796589,252780047,2966125488,1425844308,3151392187,372911126],y=[1667474886,2088535288,2004326894,2071694838,4075949567,1802223062,1869591006,3318043793,808472672,16843522,1734846926,724270422,4278065639,3621216949,2880169549,1987484396,3402253711,2189597983,3385409673,2105378810,4210693615,1499065266,1195886990,4042263547,2913856577,3570689971,2728590687,2947541573,2627518243,2762274643,1920112356,3233831835,3082273397,4261223649,2475929149,640051788,909531756,1061110142,4160160501,3435941763,875846760,2779116625,3857003729,4059105529,1903268834,3638064043,825316194,353713962,67374088,3351728789,589522246,3284360861,404236336,2526454071,84217610,2593830191,117901582,303183396,2155911963,3806477791,3958056653,656894286,2998062463,1970642922,151591698,2206440989,741110872,437923380,454765878,1852748508,1515908788,2694904667,1381168804,993742198,3604373943,3014905469,690584402,3823320797,791638366,2223281939,1398011302,3520161977,0,3991743681,538992704,4244381667,2981218425,1532751286,1785380564,3419096717,3200178535,960056178,1246420628,1280103576,1482221744,3486468741,3503319995,4025428677,2863326543,4227536621,1128514950,1296947098,859002214,2240123921,1162203018,4193849577,33687044,2139062782,1347481760,1010582648,2678045221,2829640523,1364325282,2745433693,1077985408,2408548869,2459086143,2644360225,943212656,4126475505,3166494563,3065430391,3671750063,555836226,269496352,4294908645,4092792573,3537006015,3452783745,202118168,320025894,3974901699,1600119230,2543297077,1145359496,387397934,3301201811,2812801621,2122220284,1027426170,1684319432,1566435258,421079858,1936954854,1616945344,2172753945,1330631070,3705438115,572679748,707427924,2425400123,2290647819,1179044492,4008585671,3099120491,336870440,3739122087,1583276732,185277718,3688593069,3772791771,842159716,976899700,168435220,1229577106,101059084,606366792,1549591736,3267517855,3553849021,2897014595,1650632388,2442242105,2509612081,3840161747,2038008818,3890688725,3368567691,926374254,1835907034,2374863873,3587531953,1313788572,2846482505,1819063512,1448540844,4109633523,3941213647,1701162954,2054852340,2930698567,134748176,3132806511,2021165296,623210314,774795868,471606328,2795958615,3031746419,3334885783,3907527627,3722280097,1953799400,522133822,1263263126,3183336545,2341176845,2324333839,1886425312,1044267644,3048588401,1718004428,1212733584,50529542,4143317495,235803164,1633788866,892690282,1465383342,3115962473,2256965911,3250673817,488449850,2661202215,3789633753,4177007595,2560144171,286339874,1768537042,3654906025,2391705863,2492770099,2610673197,505291324,2273808917,3924369609,3469625735,1431699370,673740880,3755965093,2358021891,2711746649,2307489801,218961690,3217021541,3873845719,1111672452,1751693520,1094828930,2576986153,757954394,252645662,2964376443,1414855848,3149649517,370555436],v=[1374988112,2118214995,437757123,975658646,1001089995,530400753,2902087851,1273168787,540080725,2910219766,2295101073,4110568485,1340463100,3307916247,641025152,3043140495,3736164937,632953703,1172967064,1576976609,3274667266,2169303058,2370213795,1809054150,59727847,361929877,3211623147,2505202138,3569255213,1484005843,1239443753,2395588676,1975683434,4102977912,2572697195,666464733,3202437046,4035489047,3374361702,2110667444,1675577880,3843699074,2538681184,1649639237,2976151520,3144396420,4269907996,4178062228,1883793496,2403728665,2497604743,1383856311,2876494627,1917518562,3810496343,1716890410,3001755655,800440835,2261089178,3543599269,807962610,599762354,33778362,3977675356,2328828971,2809771154,4077384432,1315562145,1708848333,101039829,3509871135,3299278474,875451293,2733856160,92987698,2767645557,193195065,1080094634,1584504582,3178106961,1042385657,2531067453,3711829422,1306967366,2438237621,1908694277,67556463,1615861247,429456164,3602770327,2302690252,1742315127,2968011453,126454664,3877198648,2043211483,2709260871,2084704233,4169408201,0,159417987,841739592,504459436,1817866830,4245618683,260388950,1034867998,908933415,168810852,1750902305,2606453969,607530554,202008497,2472011535,3035535058,463180190,2160117071,1641816226,1517767529,470948374,3801332234,3231722213,1008918595,303765277,235474187,4069246893,766945465,337553864,1475418501,2943682380,4003061179,2743034109,4144047775,1551037884,1147550661,1543208500,2336434550,3408119516,3069049960,3102011747,3610369226,1113818384,328671808,2227573024,2236228733,3535486456,2935566865,3341394285,496906059,3702665459,226906860,2009195472,733156972,2842737049,294930682,1206477858,2835123396,2700099354,1451044056,573804783,2269728455,3644379585,2362090238,2564033334,2801107407,2776292904,3669462566,1068351396,742039012,1350078989,1784663195,1417561698,4136440770,2430122216,775550814,2193862645,2673705150,1775276924,1876241833,3475313331,3366754619,270040487,3902563182,3678124923,3441850377,1851332852,3969562369,2203032232,3868552805,2868897406,566021896,4011190502,3135740889,1248802510,3936291284,699432150,832877231,708780849,3332740144,899835584,1951317047,4236429990,3767586992,866637845,4043610186,1106041591,2144161806,395441711,1984812685,1139781709,3433712980,3835036895,2664543715,1282050075,3240894392,1181045119,2640243204,25965917,4203181171,4211818798,3009879386,2463879762,3910161971,1842759443,2597806476,933301370,1509430414,3943906441,3467192302,3076639029,3776767469,2051518780,2631065433,1441952575,404016761,1942435775,1408749034,1610459739,3745345300,2017778566,3400528769,3110650942,941896748,3265478751,371049330,3168937228,675039627,4279080257,967311729,135050206,3635733660,1683407248,2076935265,3576870512,1215061108,3501741890],g=[1347548327,1400783205,3273267108,2520393566,3409685355,4045380933,2880240216,2471224067,1428173050,4138563181,2441661558,636813900,4233094615,3620022987,2149987652,2411029155,1239331162,1730525723,2554718734,3781033664,46346101,310463728,2743944855,3328955385,3875770207,2501218972,3955191162,3667219033,768917123,3545789473,692707433,1150208456,1786102409,2029293177,1805211710,3710368113,3065962831,401639597,1724457132,3028143674,409198410,2196052529,1620529459,1164071807,3769721975,2226875310,486441376,2499348523,1483753576,428819965,2274680428,3075636216,598438867,3799141122,1474502543,711349675,129166120,53458370,2592523643,2782082824,4063242375,2988687269,3120694122,1559041666,730517276,2460449204,4042459122,2706270690,3446004468,3573941694,533804130,2328143614,2637442643,2695033685,839224033,1973745387,957055980,2856345839,106852767,1371368976,4181598602,1033297158,2933734917,1179510461,3046200461,91341917,1862534868,4284502037,605657339,2547432937,3431546947,2003294622,3182487618,2282195339,954669403,3682191598,1201765386,3917234703,3388507166,0,2198438022,1211247597,2887651696,1315723890,4227665663,1443857720,507358933,657861945,1678381017,560487590,3516619604,975451694,2970356327,261314535,3535072918,2652609425,1333838021,2724322336,1767536459,370938394,182621114,3854606378,1128014560,487725847,185469197,2918353863,3106780840,3356761769,2237133081,1286567175,3152976349,4255350624,2683765030,3160175349,3309594171,878443390,1988838185,3704300486,1756818940,1673061617,3403100636,272786309,1075025698,545572369,2105887268,4174560061,296679730,1841768865,1260232239,4091327024,3960309330,3497509347,1814803222,2578018489,4195456072,575138148,3299409036,446754879,3629546796,4011996048,3347532110,3252238545,4270639778,915985419,3483825537,681933534,651868046,2755636671,3828103837,223377554,2607439820,1649704518,3270937875,3901806776,1580087799,4118987695,3198115200,2087309459,2842678573,3016697106,1003007129,2802849917,1860738147,2077965243,164439672,4100872472,32283319,2827177882,1709610350,2125135846,136428751,3874428392,3652904859,3460984630,3572145929,3593056380,2939266226,824852259,818324884,3224740454,930369212,2801566410,2967507152,355706840,1257309336,4148292826,243256656,790073846,2373340630,1296297904,1422699085,3756299780,3818836405,457992840,3099667487,2135319889,77422314,1560382517,1945798516,788204353,1521706781,1385356242,870912086,325965383,2358957921,2050466060,2388260884,2313884476,4006521127,901210569,3990953189,1014646705,1503449823,1062597235,2031621326,3212035895,3931371469,1533017514,350174575,2256028891,2177544179,1052338372,741876788,1606591296,1914052035,213705253,2334669897,1107234197,1899603969,3725069491,2631447780,2422494913,1635502980,1893020342,1950903388,1120974935],b=[2807058932,1699970625,2764249623,1586903591,1808481195,1173430173,1487645946,59984867,4199882800,1844882806,1989249228,1277555970,3623636965,3419915562,1149249077,2744104290,1514790577,459744698,244860394,3235995134,1963115311,4027744588,2544078150,4190530515,1608975247,2627016082,2062270317,1507497298,2200818878,567498868,1764313568,3359936201,2305455554,2037970062,1047239e3,1910319033,1337376481,2904027272,2892417312,984907214,1243112415,830661914,861968209,2135253587,2011214180,2927934315,2686254721,731183368,1750626376,4246310725,1820824798,4172763771,3542330227,48394827,2404901663,2871682645,671593195,3254988725,2073724613,145085239,2280796200,2779915199,1790575107,2187128086,472615631,3029510009,4075877127,3802222185,4107101658,3201631749,1646252340,4270507174,1402811438,1436590835,3778151818,3950355702,3963161475,4020912224,2667994737,273792366,2331590177,104699613,95345982,3175501286,2377486676,1560637892,3564045318,369057872,4213447064,3919042237,1137477952,2658625497,1119727848,2340947849,1530455833,4007360968,172466556,266959938,516552836,0,2256734592,3980931627,1890328081,1917742170,4294704398,945164165,3575528878,958871085,3647212047,2787207260,1423022939,775562294,1739656202,3876557655,2530391278,2443058075,3310321856,547512796,1265195639,437656594,3121275539,719700128,3762502690,387781147,218828297,3350065803,2830708150,2848461854,428169201,122466165,3720081049,1627235199,648017665,4122762354,1002783846,2117360635,695634755,3336358691,4234721005,4049844452,3704280881,2232435299,574624663,287343814,612205898,1039717051,840019705,2708326185,793451934,821288114,1391201670,3822090177,376187827,3113855344,1224348052,1679968233,2361698556,1058709744,752375421,2431590963,1321699145,3519142200,2734591178,188127444,2177869557,3727205754,2384911031,3215212461,2648976442,2450346104,3432737375,1180849278,331544205,3102249176,4150144569,2952102595,2159976285,2474404304,766078933,313773861,2570832044,2108100632,1668212892,3145456443,2013908262,418672217,3070356634,2594734927,1852171925,3867060991,3473416636,3907448597,2614737639,919489135,164948639,2094410160,2997825956,590424639,2486224549,1723872674,3157750862,3399941250,3501252752,3625268135,2555048196,3673637356,1343127501,4130281361,3599595085,2957853679,1297403050,81781910,3051593425,2283490410,532201772,1367295589,3926170974,895287692,1953757831,1093597963,492483431,3528626907,1446242576,1192455638,1636604631,209336225,344873464,1015671571,669961897,3375740769,3857572124,2973530695,3747192018,1933530610,3464042516,935293895,3454686199,2858115069,1863638845,3683022916,4085369519,3292445032,875313188,1080017571,3279033885,621591778,1233856572,2504130317,24197544,3017672716,3835484340,3247465558,2220981195,3060847922,1551124588,1463996600],w=[4104605777,1097159550,396673818,660510266,2875968315,2638606623,4200115116,3808662347,821712160,1986918061,3430322568,38544885,3856137295,718002117,893681702,1654886325,2975484382,3122358053,3926825029,4274053469,796197571,1290801793,1184342925,3556361835,2405426947,2459735317,1836772287,1381620373,3196267988,1948373848,3764988233,3385345166,3263785589,2390325492,1480485785,3111247143,3780097726,2293045232,548169417,3459953789,3746175075,439452389,1362321559,1400849762,1685577905,1806599355,2174754046,137073913,1214797936,1174215055,3731654548,2079897426,1943217067,1258480242,529487843,1437280870,3945269170,3049390895,3313212038,923313619,679998e3,3215307299,57326082,377642221,3474729866,2041877159,133361907,1776460110,3673476453,96392454,878845905,2801699524,777231668,4082475170,2330014213,4142626212,2213296395,1626319424,1906247262,1846563261,562755902,3708173718,1040559837,3871163981,1418573201,3294430577,114585348,1343618912,2566595609,3186202582,1078185097,3651041127,3896688048,2307622919,425408743,3371096953,2081048481,1108339068,2216610296,0,2156299017,736970802,292596766,1517440620,251657213,2235061775,2933202493,758720310,265905162,1554391400,1532285339,908999204,174567692,1474760595,4002861748,2610011675,3234156416,3693126241,2001430874,303699484,2478443234,2687165888,585122620,454499602,151849742,2345119218,3064510765,514443284,4044981591,1963412655,2581445614,2137062819,19308535,1928707164,1715193156,4219352155,1126790795,600235211,3992742070,3841024952,836553431,1669664834,2535604243,3323011204,1243905413,3141400786,4180808110,698445255,2653899549,2989552604,2253581325,3252932727,3004591147,1891211689,2487810577,3915653703,4237083816,4030667424,2100090966,865136418,1229899655,953270745,3399679628,3557504664,4118925222,2061379749,3079546586,2915017791,983426092,2022837584,1607244650,2118541908,2366882550,3635996816,972512814,3283088770,1568718495,3499326569,3576539503,621982671,2895723464,410887952,2623762152,1002142683,645401037,1494807662,2595684844,1335535747,2507040230,4293295786,3167684641,367585007,3885750714,1865862730,2668221674,2960971305,2763173681,1059270954,2777952454,2724642869,1320957812,2194319100,2429595872,2815956275,77089521,3973773121,3444575871,2448830231,1305906550,4021308739,2857194700,2516901860,3518358430,1787304780,740276417,1699839814,1592394909,2352307457,2272556026,188821243,1729977011,3687994002,274084841,3594982253,3613494426,2701949495,4162096729,322734571,2837966542,1640576439,484830689,1202797690,3537852828,4067639125,349075736,3342319475,4157467219,4255800159,1030690015,1155237496,2951971274,1757691577,607398968,2738905026,499347990,3794078908,1011452712,227885567,2818666809,213114376,3034881240,1455525988,3414450555,850817237,1817998408,3092726480],x=[0,235474187,470948374,303765277,941896748,908933415,607530554,708780849,1883793496,2118214995,1817866830,1649639237,1215061108,1181045119,1417561698,1517767529,3767586992,4003061179,4236429990,4069246893,3635733660,3602770327,3299278474,3400528769,2430122216,2664543715,2362090238,2193862645,2835123396,2801107407,3035535058,3135740889,3678124923,3576870512,3341394285,3374361702,3810496343,3977675356,4279080257,4043610186,2876494627,2776292904,3076639029,3110650942,2472011535,2640243204,2403728665,2169303058,1001089995,899835584,666464733,699432150,59727847,226906860,530400753,294930682,1273168787,1172967064,1475418501,1509430414,1942435775,2110667444,1876241833,1641816226,2910219766,2743034109,2976151520,3211623147,2505202138,2606453969,2302690252,2269728455,3711829422,3543599269,3240894392,3475313331,3843699074,3943906441,4178062228,4144047775,1306967366,1139781709,1374988112,1610459739,1975683434,2076935265,1775276924,1742315127,1034867998,866637845,566021896,800440835,92987698,193195065,429456164,395441711,1984812685,2017778566,1784663195,1683407248,1315562145,1080094634,1383856311,1551037884,101039829,135050206,437757123,337553864,1042385657,807962610,573804783,742039012,2531067453,2564033334,2328828971,2227573024,2935566865,2700099354,3001755655,3168937228,3868552805,3902563182,4203181171,4102977912,3736164937,3501741890,3265478751,3433712980,1106041591,1340463100,1576976609,1408749034,2043211483,2009195472,1708848333,1809054150,832877231,1068351396,766945465,599762354,159417987,126454664,361929877,463180190,2709260871,2943682380,3178106961,3009879386,2572697195,2538681184,2236228733,2336434550,3509871135,3745345300,3441850377,3274667266,3910161971,3877198648,4110568485,4211818798,2597806476,2497604743,2261089178,2295101073,2733856160,2902087851,3202437046,2968011453,3936291284,3835036895,4136440770,4169408201,3535486456,3702665459,3467192302,3231722213,2051518780,1951317047,1716890410,1750902305,1113818384,1282050075,1584504582,1350078989,168810852,67556463,371049330,404016761,841739592,1008918595,775550814,540080725,3969562369,3801332234,4035489047,4269907996,3569255213,3669462566,3366754619,3332740144,2631065433,2463879762,2160117071,2395588676,2767645557,2868897406,3102011747,3069049960,202008497,33778362,270040487,504459436,875451293,975658646,675039627,641025152,2084704233,1917518562,1615861247,1851332852,1147550661,1248802510,1484005843,1451044056,933301370,967311729,733156972,632953703,260388950,25965917,328671808,496906059,1206477858,1239443753,1543208500,1441952575,2144161806,1908694277,1675577880,1842759443,3610369226,3644379585,3408119516,3307916247,4011190502,3776767469,4077384432,4245618683,2809771154,2842737049,3144396420,3043140495,2673705150,2438237621,2203032232,2370213795],_=[0,185469197,370938394,487725847,741876788,657861945,975451694,824852259,1483753576,1400783205,1315723890,1164071807,1950903388,2135319889,1649704518,1767536459,2967507152,3152976349,2801566410,2918353863,2631447780,2547432937,2328143614,2177544179,3901806776,3818836405,4270639778,4118987695,3299409036,3483825537,3535072918,3652904859,2077965243,1893020342,1841768865,1724457132,1474502543,1559041666,1107234197,1257309336,598438867,681933534,901210569,1052338372,261314535,77422314,428819965,310463728,3409685355,3224740454,3710368113,3593056380,3875770207,3960309330,4045380933,4195456072,2471224067,2554718734,2237133081,2388260884,3212035895,3028143674,2842678573,2724322336,4138563181,4255350624,3769721975,3955191162,3667219033,3516619604,3431546947,3347532110,2933734917,2782082824,3099667487,3016697106,2196052529,2313884476,2499348523,2683765030,1179510461,1296297904,1347548327,1533017514,1786102409,1635502980,2087309459,2003294622,507358933,355706840,136428751,53458370,839224033,957055980,605657339,790073846,2373340630,2256028891,2607439820,2422494913,2706270690,2856345839,3075636216,3160175349,3573941694,3725069491,3273267108,3356761769,4181598602,4063242375,4011996048,3828103837,1033297158,915985419,730517276,545572369,296679730,446754879,129166120,213705253,1709610350,1860738147,1945798516,2029293177,1239331162,1120974935,1606591296,1422699085,4148292826,4233094615,3781033664,3931371469,3682191598,3497509347,3446004468,3328955385,2939266226,2755636671,3106780840,2988687269,2198438022,2282195339,2501218972,2652609425,1201765386,1286567175,1371368976,1521706781,1805211710,1620529459,2105887268,1988838185,533804130,350174575,164439672,46346101,870912086,954669403,636813900,788204353,2358957921,2274680428,2592523643,2441661558,2695033685,2880240216,3065962831,3182487618,3572145929,3756299780,3270937875,3388507166,4174560061,4091327024,4006521127,3854606378,1014646705,930369212,711349675,560487590,272786309,457992840,106852767,223377554,1678381017,1862534868,1914052035,2031621326,1211247597,1128014560,1580087799,1428173050,32283319,182621114,401639597,486441376,768917123,651868046,1003007129,818324884,1503449823,1385356242,1333838021,1150208456,1973745387,2125135846,1673061617,1756818940,2970356327,3120694122,2802849917,2887651696,2637442643,2520393566,2334669897,2149987652,3917234703,3799141122,4284502037,4100872472,3309594171,3460984630,3545789473,3629546796,2050466060,1899603969,1814803222,1730525723,1443857720,1560382517,1075025698,1260232239,575138148,692707433,878443390,1062597235,243256656,91341917,409198410,325965383,3403100636,3252238545,3704300486,3620022987,3874428392,3990953189,4042459122,4227665663,2460449204,2578018489,2226875310,2411029155,3198115200,3046200461,2827177882,2743944855],S=[0,218828297,437656594,387781147,875313188,958871085,775562294,590424639,1750626376,1699970625,1917742170,2135253587,1551124588,1367295589,1180849278,1265195639,3501252752,3720081049,3399941250,3350065803,3835484340,3919042237,4270507174,4085369519,3102249176,3051593425,2734591178,2952102595,2361698556,2177869557,2530391278,2614737639,3145456443,3060847922,2708326185,2892417312,2404901663,2187128086,2504130317,2555048196,3542330227,3727205754,3375740769,3292445032,3876557655,3926170974,4246310725,4027744588,1808481195,1723872674,1910319033,2094410160,1608975247,1391201670,1173430173,1224348052,59984867,244860394,428169201,344873464,935293895,984907214,766078933,547512796,1844882806,1627235199,2011214180,2062270317,1507497298,1423022939,1137477952,1321699145,95345982,145085239,532201772,313773861,830661914,1015671571,731183368,648017665,3175501286,2957853679,2807058932,2858115069,2305455554,2220981195,2474404304,2658625497,3575528878,3625268135,3473416636,3254988725,3778151818,3963161475,4213447064,4130281361,3599595085,3683022916,3432737375,3247465558,3802222185,4020912224,4172763771,4122762354,3201631749,3017672716,2764249623,2848461854,2331590177,2280796200,2431590963,2648976442,104699613,188127444,472615631,287343814,840019705,1058709744,671593195,621591778,1852171925,1668212892,1953757831,2037970062,1514790577,1463996600,1080017571,1297403050,3673637356,3623636965,3235995134,3454686199,4007360968,3822090177,4107101658,4190530515,2997825956,3215212461,2830708150,2779915199,2256734592,2340947849,2627016082,2443058075,172466556,122466165,273792366,492483431,1047239e3,861968209,612205898,695634755,1646252340,1863638845,2013908262,1963115311,1446242576,1530455833,1277555970,1093597963,1636604631,1820824798,2073724613,1989249228,1436590835,1487645946,1337376481,1119727848,164948639,81781910,331544205,516552836,1039717051,821288114,669961897,719700128,2973530695,3157750862,2871682645,2787207260,2232435299,2283490410,2667994737,2450346104,3647212047,3564045318,3279033885,3464042516,3980931627,3762502690,4150144569,4199882800,3070356634,3121275539,2904027272,2686254721,2200818878,2384911031,2570832044,2486224549,3747192018,3528626907,3310321856,3359936201,3950355702,3867060991,4049844452,4234721005,1739656202,1790575107,2108100632,1890328081,1402811438,1586903591,1233856572,1149249077,266959938,48394827,369057872,418672217,1002783846,919489135,567498868,752375421,209336225,24197544,376187827,459744698,945164165,895287692,574624663,793451934,1679968233,1764313568,2117360635,1933530610,1343127501,1560637892,1243112415,1192455638,3704280881,3519142200,3336358691,3419915562,3907448597,3857572124,4075877127,4294704398,3029510009,3113855344,2927934315,2744104290,2159976285,2377486676,2594734927,2544078150],k=[0,151849742,303699484,454499602,607398968,758720310,908999204,1059270954,1214797936,1097159550,1517440620,1400849762,1817998408,1699839814,2118541908,2001430874,2429595872,2581445614,2194319100,2345119218,3034881240,3186202582,2801699524,2951971274,3635996816,3518358430,3399679628,3283088770,4237083816,4118925222,4002861748,3885750714,1002142683,850817237,698445255,548169417,529487843,377642221,227885567,77089521,1943217067,2061379749,1640576439,1757691577,1474760595,1592394909,1174215055,1290801793,2875968315,2724642869,3111247143,2960971305,2405426947,2253581325,2638606623,2487810577,3808662347,3926825029,4044981591,4162096729,3342319475,3459953789,3576539503,3693126241,1986918061,2137062819,1685577905,1836772287,1381620373,1532285339,1078185097,1229899655,1040559837,923313619,740276417,621982671,439452389,322734571,137073913,19308535,3871163981,4021308739,4104605777,4255800159,3263785589,3414450555,3499326569,3651041127,2933202493,2815956275,3167684641,3049390895,2330014213,2213296395,2566595609,2448830231,1305906550,1155237496,1607244650,1455525988,1776460110,1626319424,2079897426,1928707164,96392454,213114376,396673818,514443284,562755902,679998e3,865136418,983426092,3708173718,3557504664,3474729866,3323011204,4180808110,4030667424,3945269170,3794078908,2507040230,2623762152,2272556026,2390325492,2975484382,3092726480,2738905026,2857194700,3973773121,3856137295,4274053469,4157467219,3371096953,3252932727,3673476453,3556361835,2763173681,2915017791,3064510765,3215307299,2156299017,2307622919,2459735317,2610011675,2081048481,1963412655,1846563261,1729977011,1480485785,1362321559,1243905413,1126790795,878845905,1030690015,645401037,796197571,274084841,425408743,38544885,188821243,3613494426,3731654548,3313212038,3430322568,4082475170,4200115116,3780097726,3896688048,2668221674,2516901860,2366882550,2216610296,3141400786,2989552604,2837966542,2687165888,1202797690,1320957812,1437280870,1554391400,1669664834,1787304780,1906247262,2022837584,265905162,114585348,499347990,349075736,736970802,585122620,972512814,821712160,2595684844,2478443234,2293045232,2174754046,3196267988,3079546586,2895723464,2777952454,3537852828,3687994002,3234156416,3385345166,4142626212,4293295786,3841024952,3992742070,174567692,57326082,410887952,292596766,777231668,660510266,1011452712,893681702,1108339068,1258480242,1343618912,1494807662,1715193156,1865862730,1948373848,2100090966,2701949495,2818666809,3004591147,3122358053,2235061775,2352307457,2535604243,2653899549,3915653703,3764988233,4219352155,4067639125,3444575871,3294430577,3746175075,3594982253,836553431,953270745,600235211,718002117,367585007,484830689,133361907,251657213,2041877159,1891211689,1806599355,1654886325,1568718495,1418573201,1335535747,1184342925];function E(e){for(var t=[],r=0;r>2,this._Ke[r][t%4]=o[t],this._Kd[e-r][t%4]=o[t];for(var a,s=0,u=i;u>16&255]<<24^f[a>>8&255]<<16^f[255&a]<<8^f[a>>24&255]^c[s]<<24,s+=1,8!=i)for(t=1;t>8&255]<<8^f[a>>16&255]<<16^f[a>>24&255]<<24;for(t=i/2+1;t>2,h=u%4,this._Ke[d][h]=o[t],this._Kd[e-d][h]=o[t++],u++}for(var d=1;d>24&255]^_[a>>16&255]^S[a>>8&255]^k[255&a]},A.prototype.encrypt=function(e){if(16!=e.length)throw new Error("invalid plaintext size (must be 16 bytes)");for(var t=this._Ke.length-1,r=[0,0,0,0],n=E(e),i=0;i<4;i++)n[i]^=this._Ke[0][i];for(var a=1;a>24&255]^p[n[(i+1)%4]>>16&255]^m[n[(i+2)%4]>>8&255]^y[255&n[(i+3)%4]]^this._Ke[a][i];n=r.slice()}var s,u=o(16);for(i=0;i<4;i++)s=this._Ke[t][i],u[4*i]=255&(f[n[i]>>24&255]^s>>24),u[4*i+1]=255&(f[n[(i+1)%4]>>16&255]^s>>16),u[4*i+2]=255&(f[n[(i+2)%4]>>8&255]^s>>8),u[4*i+3]=255&(f[255&n[(i+3)%4]]^s);return u},A.prototype.decrypt=function(e){if(16!=e.length)throw new Error("invalid ciphertext size (must be 16 bytes)");for(var t=this._Kd.length-1,r=[0,0,0,0],n=E(e),i=0;i<4;i++)n[i]^=this._Kd[0][i];for(var a=1;a>24&255]^g[n[(i+3)%4]>>16&255]^b[n[(i+2)%4]>>8&255]^w[255&n[(i+1)%4]]^this._Kd[a][i];n=r.slice()}var s,u=o(16);for(i=0;i<4;i++)s=this._Kd[t][i],u[4*i]=255&(d[n[i]>>24&255]^s>>24),u[4*i+1]=255&(d[n[(i+3)%4]>>16&255]^s>>16),u[4*i+2]=255&(d[n[(i+2)%4]>>8&255]^s>>8),u[4*i+3]=255&(d[255&n[(i+1)%4]]^s);return u};var j=function e(t){if(!(this instanceof e))throw Error("AES must be instanitated with `new`");this.description="Electronic Code Block",this.name="ecb",this._aes=new A(t)};j.prototype.encrypt=function(e){if((e=i(e)).length%16!==0)throw new Error("invalid plaintext size (must be multiple of 16 bytes)");for(var t=o(e.length),r=o(16),n=0;n=0;--t)this._counter[t]=e%256,e>>=8},C.prototype.setBytes=function(e){if(16!=(e=i(e,!0)).length)throw new Error("invalid counter bytes size (must be 16 bytes)");this._counter=e},C.prototype.increment=function(){for(var e=15;e>=0;e--){if(255!==this._counter[e]){this._counter[e]++;break}this._counter[e]=0}};var O=function e(t,r){if(!(this instanceof e))throw Error("AES must be instanitated with `new`");this.description="Counter",this.name="ctr",r instanceof C||(r=new C(r)),this._counter=r,this._remainingCounter=null,this._remainingCounterIndex=16,this._aes=new A(t)};O.prototype.encrypt=function(e){for(var t=i(e,!0),r=0;r16)throw new Error("PKCS#7 padding byte out of range");for(var r=e.length-t,n=0;n>25;return(33554431&e)<<5^996825010&-(t>>0&1)^642813549&-(t>>1&1)^513874426&-(t>>2&1)^1027748829&-(t>>3&1)^705979059&-(t>>4&1)}function a(e){for(var t=1,r=0;r126)return"Invalid prefix ("+e+")";t=o(t)^n>>5}for(t=o(t),r=0;rt)return"Exceeds length limit";var n=e.toLowerCase(),i=e.toUpperCase();if(e!==n&&e!==i)return"Mixed-case string "+e;var s=(e=n).lastIndexOf("1");if(-1===s)return"No separator character for "+e;if(0===s)return"Missing prefix for "+e;var u=e.slice(0,s),l=e.slice(s+1);if(l.length<6)return"Data too short";var c=a(u);if("string"===typeof c)return c;for(var f=[],d=0;d=l.length||f.push(p)}return 1!==c?"Invalid checksum for "+e:{prefix:u,words:f}}function u(e,t,r,n){for(var i=0,o=0,a=(1<=r;)o-=r,s.push(i>>o&a);if(n)o>0&&s.push(i<=t)return"Excess padding";if(i<n)throw new TypeError("Exceeds length limit");var i=a(e=e.toLowerCase());if("string"===typeof i)throw new Error(i);for(var s=e+"1",u=0;u>5!==0)throw new Error("Non 5-bit word");i=o(i)^l,s+=t.charAt(l)}for(u=0;u<6;++u)i=o(i);for(i^=1,u=0;u<6;++u){s+=t.charAt(i>>5*(5-u)&31)}return s},toWordsUnsafe:function(e){var t=u(e,8,5,!0);if(Array.isArray(t))return t},toWords:function(e){var t=u(e,8,5,!0);if(Array.isArray(t))return t;throw new Error(t)},fromWordsUnsafe:function(e){var t=u(e,5,8,!1);if(Array.isArray(t))return t},fromWords:function(e){var t=u(e,5,8,!1);if(Array.isArray(t))return t;throw new Error(t)}}},5870:function(e,t,r){!function(e,t){"use strict";function n(e,t){if(!e)throw new Error(t||"Assertion failed")}function i(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function o(e,t,r){if(o.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var a;"object"===typeof e?e.exports=o:t.BN=o,o.BN=o,o.wordSize=26;try{a="undefined"!==typeof window&&"undefined"!==typeof window.Buffer?window.Buffer:r(3196).Buffer}catch(E){}function s(e,t){var r=e.charCodeAt(t);return r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function u(e,t,r){var n=s(e,r);return r-1>=t&&(n|=s(e,r-1)<<4),n}function l(e,t,r,n){for(var i=0,o=Math.min(e.length,r),a=t;a=49?s-49+10:s>=17?s-17+10:s}return i}o.isBN=function(e){return e instanceof o||null!==e&&"object"===typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"===typeof e)return this._initNumber(e,t,r);if("object"===typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(i++,this.negative=1),i=0;i-=3)a=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(i=0,o=0;i>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)i=u(e,t,n)<=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;else for(n=(e.length-t)%2===0?t+1:t;n=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,s=Math.min(o,o-a)+r,u=0,c=r;c1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var c=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],f=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],d=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function h(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var l=1;l>>26,f=67108863&u,d=Math.min(l,t.length-1),h=Math.max(0,l-e.length+1);h<=d;h++){var p=l-h|0;c+=(a=(i=0|e.words[p])*(o=0|t.words[h])+f)/67108864|0,f=67108863&a}r.words[l]=0|f,u=0|c}return 0!==u?r.words[l]=0|u:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,o=0,a=0;a>>24-i&16777215)||a!==this.length-1?c[6-u.length]+u+r:u+r,(i+=2)>=26&&(i-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var l=f[e],h=d[e];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(h).toString(e);r=(p=p.idivn(h)).isZero()?m+r:c[l-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return n("undefined"!==typeof a),this.toArrayLike(a,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var i=this.byteLength(),o=r||Math.max(1,i);n(i<=o,"byte array longer than desired length"),n(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===t,l=new e(o),c=this.clone();if(u){for(s=0;!c.isZero();s++)a=c.andln(255),c.iushrn(8),l[s]=a;for(;s=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0===(8191&t)&&(r+=13,t>>>=13),0===(127&t)&&(r+=7,t>>>=7),0===(15&t)&&(r+=4,t>>>=4),0===(3&t)&&(r+=2,t>>>=2),0===(1&t)&&r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){n("number"===typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i0&&(this.words[i]=~this.words[i]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){n("number"===typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a>26,this.words[a]=67108863&t;for(;0!==o&&a>26,this.words[a]=67108863&t;if(0===o&&a>>13,h=0|a[1],p=8191&h,m=h>>>13,y=0|a[2],v=8191&y,g=y>>>13,b=0|a[3],w=8191&b,x=b>>>13,_=0|a[4],S=8191&_,k=_>>>13,E=0|a[5],A=8191&E,j=E>>>13,M=0|a[6],T=8191&M,P=M>>>13,C=0|a[7],O=8191&C,R=C>>>13,I=0|a[8],L=8191&I,N=I>>>13,D=0|a[9],F=8191&D,U=D>>>13,B=0|s[0],G=8191&B,V=B>>>13,z=0|s[1],q=8191&z,H=z>>>13,Z=0|s[2],W=8191&Z,K=Z>>>13,X=0|s[3],Y=8191&X,Q=X>>>13,J=0|s[4],$=8191&J,ee=J>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],oe=8191&ie,ae=ie>>>13,se=0|s[7],ue=8191&se,le=se>>>13,ce=0|s[8],fe=8191&ce,de=ce>>>13,he=0|s[9],pe=8191&he,me=he>>>13;r.negative=e.negative^t.negative,r.length=19;var ye=(l+(n=Math.imul(f,G))|0)+((8191&(i=(i=Math.imul(f,V))+Math.imul(d,G)|0))<<13)|0;l=((o=Math.imul(d,V))+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(p,G),i=(i=Math.imul(p,V))+Math.imul(m,G)|0,o=Math.imul(m,V);var ve=(l+(n=n+Math.imul(f,q)|0)|0)+((8191&(i=(i=i+Math.imul(f,H)|0)+Math.imul(d,q)|0))<<13)|0;l=((o=o+Math.imul(d,H)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(v,G),i=(i=Math.imul(v,V))+Math.imul(g,G)|0,o=Math.imul(g,V),n=n+Math.imul(p,q)|0,i=(i=i+Math.imul(p,H)|0)+Math.imul(m,q)|0,o=o+Math.imul(m,H)|0;var ge=(l+(n=n+Math.imul(f,W)|0)|0)+((8191&(i=(i=i+Math.imul(f,K)|0)+Math.imul(d,W)|0))<<13)|0;l=((o=o+Math.imul(d,K)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(w,G),i=(i=Math.imul(w,V))+Math.imul(x,G)|0,o=Math.imul(x,V),n=n+Math.imul(v,q)|0,i=(i=i+Math.imul(v,H)|0)+Math.imul(g,q)|0,o=o+Math.imul(g,H)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,K)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,K)|0;var be=(l+(n=n+Math.imul(f,Y)|0)|0)+((8191&(i=(i=i+Math.imul(f,Q)|0)+Math.imul(d,Y)|0))<<13)|0;l=((o=o+Math.imul(d,Q)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(S,G),i=(i=Math.imul(S,V))+Math.imul(k,G)|0,o=Math.imul(k,V),n=n+Math.imul(w,q)|0,i=(i=i+Math.imul(w,H)|0)+Math.imul(x,q)|0,o=o+Math.imul(x,H)|0,n=n+Math.imul(v,W)|0,i=(i=i+Math.imul(v,K)|0)+Math.imul(g,W)|0,o=o+Math.imul(g,K)|0,n=n+Math.imul(p,Y)|0,i=(i=i+Math.imul(p,Q)|0)+Math.imul(m,Y)|0,o=o+Math.imul(m,Q)|0;var we=(l+(n=n+Math.imul(f,$)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(d,$)|0))<<13)|0;l=((o=o+Math.imul(d,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(A,G),i=(i=Math.imul(A,V))+Math.imul(j,G)|0,o=Math.imul(j,V),n=n+Math.imul(S,q)|0,i=(i=i+Math.imul(S,H)|0)+Math.imul(k,q)|0,o=o+Math.imul(k,H)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,K)|0)+Math.imul(x,W)|0,o=o+Math.imul(x,K)|0,n=n+Math.imul(v,Y)|0,i=(i=i+Math.imul(v,Q)|0)+Math.imul(g,Y)|0,o=o+Math.imul(g,Q)|0,n=n+Math.imul(p,$)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,ee)|0;var xe=(l+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(d,re)|0))<<13)|0;l=((o=o+Math.imul(d,ne)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(T,G),i=(i=Math.imul(T,V))+Math.imul(P,G)|0,o=Math.imul(P,V),n=n+Math.imul(A,q)|0,i=(i=i+Math.imul(A,H)|0)+Math.imul(j,q)|0,o=o+Math.imul(j,H)|0,n=n+Math.imul(S,W)|0,i=(i=i+Math.imul(S,K)|0)+Math.imul(k,W)|0,o=o+Math.imul(k,K)|0,n=n+Math.imul(w,Y)|0,i=(i=i+Math.imul(w,Q)|0)+Math.imul(x,Y)|0,o=o+Math.imul(x,Q)|0,n=n+Math.imul(v,$)|0,i=(i=i+Math.imul(v,ee)|0)+Math.imul(g,$)|0,o=o+Math.imul(g,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0;var _e=(l+(n=n+Math.imul(f,oe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ae)|0)+Math.imul(d,oe)|0))<<13)|0;l=((o=o+Math.imul(d,ae)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(O,G),i=(i=Math.imul(O,V))+Math.imul(R,G)|0,o=Math.imul(R,V),n=n+Math.imul(T,q)|0,i=(i=i+Math.imul(T,H)|0)+Math.imul(P,q)|0,o=o+Math.imul(P,H)|0,n=n+Math.imul(A,W)|0,i=(i=i+Math.imul(A,K)|0)+Math.imul(j,W)|0,o=o+Math.imul(j,K)|0,n=n+Math.imul(S,Y)|0,i=(i=i+Math.imul(S,Q)|0)+Math.imul(k,Y)|0,o=o+Math.imul(k,Q)|0,n=n+Math.imul(w,$)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(x,$)|0,o=o+Math.imul(x,ee)|0,n=n+Math.imul(v,re)|0,i=(i=i+Math.imul(v,ne)|0)+Math.imul(g,re)|0,o=o+Math.imul(g,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0;var Se=(l+(n=n+Math.imul(f,ue)|0)|0)+((8191&(i=(i=i+Math.imul(f,le)|0)+Math.imul(d,ue)|0))<<13)|0;l=((o=o+Math.imul(d,le)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(L,G),i=(i=Math.imul(L,V))+Math.imul(N,G)|0,o=Math.imul(N,V),n=n+Math.imul(O,q)|0,i=(i=i+Math.imul(O,H)|0)+Math.imul(R,q)|0,o=o+Math.imul(R,H)|0,n=n+Math.imul(T,W)|0,i=(i=i+Math.imul(T,K)|0)+Math.imul(P,W)|0,o=o+Math.imul(P,K)|0,n=n+Math.imul(A,Y)|0,i=(i=i+Math.imul(A,Q)|0)+Math.imul(j,Y)|0,o=o+Math.imul(j,Q)|0,n=n+Math.imul(S,$)|0,i=(i=i+Math.imul(S,ee)|0)+Math.imul(k,$)|0,o=o+Math.imul(k,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(x,re)|0,o=o+Math.imul(x,ne)|0,n=n+Math.imul(v,oe)|0,i=(i=i+Math.imul(v,ae)|0)+Math.imul(g,oe)|0,o=o+Math.imul(g,ae)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,le)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,le)|0;var ke=(l+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,de)|0)+Math.imul(d,fe)|0))<<13)|0;l=((o=o+Math.imul(d,de)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(F,G),i=(i=Math.imul(F,V))+Math.imul(U,G)|0,o=Math.imul(U,V),n=n+Math.imul(L,q)|0,i=(i=i+Math.imul(L,H)|0)+Math.imul(N,q)|0,o=o+Math.imul(N,H)|0,n=n+Math.imul(O,W)|0,i=(i=i+Math.imul(O,K)|0)+Math.imul(R,W)|0,o=o+Math.imul(R,K)|0,n=n+Math.imul(T,Y)|0,i=(i=i+Math.imul(T,Q)|0)+Math.imul(P,Y)|0,o=o+Math.imul(P,Q)|0,n=n+Math.imul(A,$)|0,i=(i=i+Math.imul(A,ee)|0)+Math.imul(j,$)|0,o=o+Math.imul(j,ee)|0,n=n+Math.imul(S,re)|0,i=(i=i+Math.imul(S,ne)|0)+Math.imul(k,re)|0,o=o+Math.imul(k,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(x,oe)|0,o=o+Math.imul(x,ae)|0,n=n+Math.imul(v,ue)|0,i=(i=i+Math.imul(v,le)|0)+Math.imul(g,ue)|0,o=o+Math.imul(g,le)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,de)|0)+Math.imul(m,fe)|0,o=o+Math.imul(m,de)|0;var Ee=(l+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,me)|0)+Math.imul(d,pe)|0))<<13)|0;l=((o=o+Math.imul(d,me)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,q),i=(i=Math.imul(F,H))+Math.imul(U,q)|0,o=Math.imul(U,H),n=n+Math.imul(L,W)|0,i=(i=i+Math.imul(L,K)|0)+Math.imul(N,W)|0,o=o+Math.imul(N,K)|0,n=n+Math.imul(O,Y)|0,i=(i=i+Math.imul(O,Q)|0)+Math.imul(R,Y)|0,o=o+Math.imul(R,Q)|0,n=n+Math.imul(T,$)|0,i=(i=i+Math.imul(T,ee)|0)+Math.imul(P,$)|0,o=o+Math.imul(P,ee)|0,n=n+Math.imul(A,re)|0,i=(i=i+Math.imul(A,ne)|0)+Math.imul(j,re)|0,o=o+Math.imul(j,ne)|0,n=n+Math.imul(S,oe)|0,i=(i=i+Math.imul(S,ae)|0)+Math.imul(k,oe)|0,o=o+Math.imul(k,ae)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,le)|0)+Math.imul(x,ue)|0,o=o+Math.imul(x,le)|0,n=n+Math.imul(v,fe)|0,i=(i=i+Math.imul(v,de)|0)+Math.imul(g,fe)|0,o=o+Math.imul(g,de)|0;var Ae=(l+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,me)|0)+Math.imul(m,pe)|0))<<13)|0;l=((o=o+Math.imul(m,me)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(F,W),i=(i=Math.imul(F,K))+Math.imul(U,W)|0,o=Math.imul(U,K),n=n+Math.imul(L,Y)|0,i=(i=i+Math.imul(L,Q)|0)+Math.imul(N,Y)|0,o=o+Math.imul(N,Q)|0,n=n+Math.imul(O,$)|0,i=(i=i+Math.imul(O,ee)|0)+Math.imul(R,$)|0,o=o+Math.imul(R,ee)|0,n=n+Math.imul(T,re)|0,i=(i=i+Math.imul(T,ne)|0)+Math.imul(P,re)|0,o=o+Math.imul(P,ne)|0,n=n+Math.imul(A,oe)|0,i=(i=i+Math.imul(A,ae)|0)+Math.imul(j,oe)|0,o=o+Math.imul(j,ae)|0,n=n+Math.imul(S,ue)|0,i=(i=i+Math.imul(S,le)|0)+Math.imul(k,ue)|0,o=o+Math.imul(k,le)|0,n=n+Math.imul(w,fe)|0,i=(i=i+Math.imul(w,de)|0)+Math.imul(x,fe)|0,o=o+Math.imul(x,de)|0;var je=(l+(n=n+Math.imul(v,pe)|0)|0)+((8191&(i=(i=i+Math.imul(v,me)|0)+Math.imul(g,pe)|0))<<13)|0;l=((o=o+Math.imul(g,me)|0)+(i>>>13)|0)+(je>>>26)|0,je&=67108863,n=Math.imul(F,Y),i=(i=Math.imul(F,Q))+Math.imul(U,Y)|0,o=Math.imul(U,Q),n=n+Math.imul(L,$)|0,i=(i=i+Math.imul(L,ee)|0)+Math.imul(N,$)|0,o=o+Math.imul(N,ee)|0,n=n+Math.imul(O,re)|0,i=(i=i+Math.imul(O,ne)|0)+Math.imul(R,re)|0,o=o+Math.imul(R,ne)|0,n=n+Math.imul(T,oe)|0,i=(i=i+Math.imul(T,ae)|0)+Math.imul(P,oe)|0,o=o+Math.imul(P,ae)|0,n=n+Math.imul(A,ue)|0,i=(i=i+Math.imul(A,le)|0)+Math.imul(j,ue)|0,o=o+Math.imul(j,le)|0,n=n+Math.imul(S,fe)|0,i=(i=i+Math.imul(S,de)|0)+Math.imul(k,fe)|0,o=o+Math.imul(k,de)|0;var Me=(l+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,me)|0)+Math.imul(x,pe)|0))<<13)|0;l=((o=o+Math.imul(x,me)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,$),i=(i=Math.imul(F,ee))+Math.imul(U,$)|0,o=Math.imul(U,ee),n=n+Math.imul(L,re)|0,i=(i=i+Math.imul(L,ne)|0)+Math.imul(N,re)|0,o=o+Math.imul(N,ne)|0,n=n+Math.imul(O,oe)|0,i=(i=i+Math.imul(O,ae)|0)+Math.imul(R,oe)|0,o=o+Math.imul(R,ae)|0,n=n+Math.imul(T,ue)|0,i=(i=i+Math.imul(T,le)|0)+Math.imul(P,ue)|0,o=o+Math.imul(P,le)|0,n=n+Math.imul(A,fe)|0,i=(i=i+Math.imul(A,de)|0)+Math.imul(j,fe)|0,o=o+Math.imul(j,de)|0;var Te=(l+(n=n+Math.imul(S,pe)|0)|0)+((8191&(i=(i=i+Math.imul(S,me)|0)+Math.imul(k,pe)|0))<<13)|0;l=((o=o+Math.imul(k,me)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,re),i=(i=Math.imul(F,ne))+Math.imul(U,re)|0,o=Math.imul(U,ne),n=n+Math.imul(L,oe)|0,i=(i=i+Math.imul(L,ae)|0)+Math.imul(N,oe)|0,o=o+Math.imul(N,ae)|0,n=n+Math.imul(O,ue)|0,i=(i=i+Math.imul(O,le)|0)+Math.imul(R,ue)|0,o=o+Math.imul(R,le)|0,n=n+Math.imul(T,fe)|0,i=(i=i+Math.imul(T,de)|0)+Math.imul(P,fe)|0,o=o+Math.imul(P,de)|0;var Pe=(l+(n=n+Math.imul(A,pe)|0)|0)+((8191&(i=(i=i+Math.imul(A,me)|0)+Math.imul(j,pe)|0))<<13)|0;l=((o=o+Math.imul(j,me)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,oe),i=(i=Math.imul(F,ae))+Math.imul(U,oe)|0,o=Math.imul(U,ae),n=n+Math.imul(L,ue)|0,i=(i=i+Math.imul(L,le)|0)+Math.imul(N,ue)|0,o=o+Math.imul(N,le)|0,n=n+Math.imul(O,fe)|0,i=(i=i+Math.imul(O,de)|0)+Math.imul(R,fe)|0,o=o+Math.imul(R,de)|0;var Ce=(l+(n=n+Math.imul(T,pe)|0)|0)+((8191&(i=(i=i+Math.imul(T,me)|0)+Math.imul(P,pe)|0))<<13)|0;l=((o=o+Math.imul(P,me)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,n=Math.imul(F,ue),i=(i=Math.imul(F,le))+Math.imul(U,ue)|0,o=Math.imul(U,le),n=n+Math.imul(L,fe)|0,i=(i=i+Math.imul(L,de)|0)+Math.imul(N,fe)|0,o=o+Math.imul(N,de)|0;var Oe=(l+(n=n+Math.imul(O,pe)|0)|0)+((8191&(i=(i=i+Math.imul(O,me)|0)+Math.imul(R,pe)|0))<<13)|0;l=((o=o+Math.imul(R,me)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,fe),i=(i=Math.imul(F,de))+Math.imul(U,fe)|0,o=Math.imul(U,de);var Re=(l+(n=n+Math.imul(L,pe)|0)|0)+((8191&(i=(i=i+Math.imul(L,me)|0)+Math.imul(N,pe)|0))<<13)|0;l=((o=o+Math.imul(N,me)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863;var Ie=(l+(n=Math.imul(F,pe))|0)+((8191&(i=(i=Math.imul(F,me))+Math.imul(U,pe)|0))<<13)|0;return l=((o=Math.imul(U,me))+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,u[0]=ye,u[1]=ve,u[2]=ge,u[3]=be,u[4]=we,u[5]=xe,u[6]=_e,u[7]=Se,u[8]=ke,u[9]=Ee,u[10]=Ae,u[11]=je,u[12]=Me,u[13]=Te,u[14]=Pe,u[15]=Ce,u[16]=Oe,u[17]=Re,u[18]=Ie,0!==l&&(u[19]=l,r.length++),r};function m(e,t,r){return(new y).mulp(e,t,r)}function y(e,t){this.x=e,this.y=t}Math.imul||(p=h),o.prototype.mulTo=function(e,t){var r,n=this.length+e.length;return r=10===this.length&&10===e.length?p(this,e,t):n<63?h(this,e,t):n<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r.strip()}(this,e,t):m(this,e,t),r},y.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,n=0;n>=1;return n},y.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a>>=1)i++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a>=26,t+=i/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>i}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n=0);var t,r=e%26,i=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t=0),i=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,l=0;l=0&&(0!==c||l>=i);l--){var f=0|this.words[l];this.words[l]=c<<26-o|f>>>o,c=f&s}return u&&0!==c&&(u.words[u.length++]=c),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){n("number"===typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var i=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(n("number"===typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(u/67108864|0),this.words[i+r]=67108863&o}for(;i>26,this.words[i+r]=67108863&o;if(0===s)return this.strip();for(n(-1===s),s=0,i=0;i>26,this.words[i]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,a=0|i.words[i.length-1];0!==(r=26-this._countBits(a))&&(i=i.ushln(r),n.iushln(r),a=0|i.words[i.length-1]);var s,u=n.length-i.length;if("mod"!==t){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var l=0;l=0;f--){var d=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(d=Math.min(d/a|0,67108863),n._ishlnsubmul(i,d,f);0!==n.negative;)d--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=d)}return s&&s.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},o.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(i=s.div.neg()),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(e)),{div:i,mod:a}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(i=s.div.neg()),{div:i,mod:s.mod}):0!==(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(e)),{div:s.div,mod:a}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var i,a,s},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,i=this.length-1;i>=0;i--)r=(t*r+(0|this.words[i]))%e;return r},o.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var i=(0|this.words[r])+67108864*t;this.words[r]=i/e|0,t=i%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),a=new o(0),s=new o(0),u=new o(1),l=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++l;for(var c=r.clone(),f=t.clone();!t.isZero();){for(var d=0,h=1;0===(t.words[0]&h)&&d<26;++d,h<<=1);if(d>0)for(t.iushrn(d);d-- >0;)(i.isOdd()||a.isOdd())&&(i.iadd(c),a.isub(f)),i.iushrn(1),a.iushrn(1);for(var p=0,m=1;0===(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(c),u.isub(f)),s.iushrn(1),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(s),a.isub(u)):(r.isub(t),s.isub(i),u.isub(a))}return{a:s,b:u,gcd:r.iushln(l)}},o.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,a=new o(1),s=new o(0),u=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var l=0,c=1;0===(t.words[0]&c)&&l<26;++l,c<<=1);if(l>0)for(t.iushrn(l);l-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var f=0,d=1;0===(r.words[0]&d)&&f<26;++f,d<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(s)):(r.isub(t),s.isub(a))}return(i=0===t.cmpn(1)?a:s).cmpn(0)<0&&i.iadd(e),i},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0===(1&this.words[0])},o.prototype.isOdd=function(){return 1===(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){n("number"===typeof e);var t=e%26,r=(e-t)/26,i=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:ie.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){ni&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new S(e)},o.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var v={k256:null,p224:null,p192:null,p25519:null};function g(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function b(){g.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){g.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function x(){g.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function _(){g.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function S(e){if("string"===typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function k(e){S.call(this,e),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}g.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},g.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},g.prototype.split=function(e,t){e.iushrn(this.n,0,t)},g.prototype.imulK=function(e){return e.imul(this.k)},i(b,g),b.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),i=0;i>>22,o=a}o>>>=22,e.words[i-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},b.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(v[e])return v[e];var t;if("k256"===e)t=new b;else if("p224"===e)t=new w;else if("p192"===e)t=new x;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new _}return v[e]=t,t},S.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},S.prototype._verify2=function(e,t){n(0===(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},S.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},S.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},S.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},S.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},S.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},S.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},S.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},S.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},S.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},S.prototype.isqr=function(e){return this.imul(e,e.clone())},S.prototype.sqr=function(e){return this.mul(e,e)},S.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2===1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),a=0;!i.isZero()&&0===i.andln(1);)a++,i.iushrn(1);n(!i.isZero());var s=new o(1).toRed(this),u=s.redNeg(),l=this.m.subn(1).iushrn(1),c=this.m.bitLength();for(c=new o(2*c*c).toRed(this);0!==this.pow(c,l).cmp(u);)c.redIAdd(u);for(var f=this.pow(c,i),d=this.pow(e,i.addn(1).iushrn(1)),h=this.pow(e,i),p=a;0!==h.cmp(s);){for(var m=h,y=0;0!==m.cmp(s);y++)m=m.redSqr();n(y=0;n--){for(var l=t.words[n],c=u-1;c>=0;c--){var f=l>>c&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==a?(a<<=1,a|=f,(4===++s||0===n&&0===c)&&(i=this.mul(i,r[a]),s=0,a=0)):s=0}u=26}return i},S.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},S.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new k(e)},i(k,S),k.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},k.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},k.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},k.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},k.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},5667:function(e,t){var r;!function(){"use strict";var n={}.hasOwnProperty;function i(){for(var e=[],t=0;t=this._delta8){var r=(e=this.pending).length%this._delta8;this.pending=e.slice(e.length-r,e.length),0===this.pending.length&&(this.pending=null),e=n.join32(e,0,e.length-r,this.endian);for(var i=0;i>>24&255,n[i++]=e>>>16&255,n[i++]=e>>>8&255,n[i++]=255&e}else for(n[i++]=255&e,n[i++]=e>>>8&255,n[i++]=e>>>16&255,n[i++]=e>>>24&255,n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=0,o=8;othis.blockSize&&(e=(new this.Hash).update(e).digest()),i(e.length<=this.blockSize);for(var t=e.length;t>>3},t.g1_256=function(e){return n(e,17)^n(e,19)^e>>>10}},9339:function(e,t,r){"use strict";var n=r(1185),i=r(8685);function o(e,t){return 55296===(64512&e.charCodeAt(t))&&(!(t<0||t+1>=e.length)&&56320===(64512&e.charCodeAt(t+1)))}function a(e){return(e>>>24|e>>>8&65280|e<<8&16711680|(255&e)<<24)>>>0}function s(e){return 1===e.length?"0"+e:e}function u(e){return 7===e.length?"0"+e:6===e.length?"00"+e:5===e.length?"000"+e:4===e.length?"0000"+e:3===e.length?"00000"+e:2===e.length?"000000"+e:1===e.length?"0000000"+e:e}t.inherits=i,t.toArray=function(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if("string"===typeof e)if(t){if("hex"===t)for((e=e.replace(/[^a-z0-9]+/gi,"")).length%2!==0&&(e="0"+e),i=0;i>6|192,r[n++]=63&a|128):o(e,i)?(a=65536+((1023&a)<<10)+(1023&e.charCodeAt(++i)),r[n++]=a>>18|240,r[n++]=a>>12&63|128,r[n++]=a>>6&63|128,r[n++]=63&a|128):(r[n++]=a>>12|224,r[n++]=a>>6&63|128,r[n++]=63&a|128)}else for(i=0;i>>0}return a},t.split32=function(e,t){for(var r=new Array(4*e.length),n=0,i=0;n>>24,r[i+1]=o>>>16&255,r[i+2]=o>>>8&255,r[i+3]=255&o):(r[i+3]=o>>>24,r[i+2]=o>>>16&255,r[i+1]=o>>>8&255,r[i]=255&o)}return r},t.rotr32=function(e,t){return e>>>t|e<<32-t},t.rotl32=function(e,t){return e<>>32-t},t.sum32=function(e,t){return e+t>>>0},t.sum32_3=function(e,t,r){return e+t+r>>>0},t.sum32_4=function(e,t,r,n){return e+t+r+n>>>0},t.sum32_5=function(e,t,r,n,i){return e+t+r+n+i>>>0},t.sum64=function(e,t,r,n){var i=e[t],o=n+e[t+1]>>>0,a=(o>>0,e[t+1]=o},t.sum64_hi=function(e,t,r,n){return(t+n>>>0>>0},t.sum64_lo=function(e,t,r,n){return t+n>>>0},t.sum64_4_hi=function(e,t,r,n,i,o,a,s){var u=0,l=t;return u+=(l=l+n>>>0)>>0)>>0)>>0},t.sum64_4_lo=function(e,t,r,n,i,o,a,s){return t+n+o+s>>>0},t.sum64_5_hi=function(e,t,r,n,i,o,a,s,u,l){var c=0,f=t;return c+=(f=f+n>>>0)>>0)>>0)>>0)>>0},t.sum64_5_lo=function(e,t,r,n,i,o,a,s,u,l){return t+n+o+s+l>>>0},t.rotr64_hi=function(e,t,r){return(t<<32-r|e>>>r)>>>0},t.rotr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0},t.shr64_hi=function(e,t,r){return e>>>r},t.shr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0}},8685:function(e){"function"===typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}},7509:function(e,t,r){var n;!function(){"use strict";var i="input is invalid type",o="object"===typeof window,a=o?window:{};a.JS_SHA3_NO_WINDOW&&(o=!1);var s=!o&&"object"===typeof self;!a.JS_SHA3_NO_NODE_JS&&"object"===typeof process&&process.versions&&process.versions.node?a=r.g:s&&(a=self);var u=!a.JS_SHA3_NO_COMMON_JS&&e.exports,l=r.amdO,c=!a.JS_SHA3_NO_ARRAY_BUFFER&&"undefined"!==typeof ArrayBuffer,f="0123456789abcdef".split(""),d=[4,1024,262144,67108864],h=[0,8,16,24],p=[1,0,32898,0,32906,2147483648,2147516416,2147483648,32907,0,2147483649,0,2147516545,2147483648,32777,2147483648,138,0,136,0,2147516425,0,2147483658,0,2147516555,0,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,2147483648,32778,0,2147483658,2147483648,2147516545,2147483648,32896,2147483648,2147483649,0,2147516424,2147483648],m=[224,256,384,512],y=[128,256],v=["hex","buffer","arrayBuffer","array","digest"],g={128:168,256:136};!a.JS_SHA3_NO_NODE_JS&&Array.isArray||(Array.isArray=function(e){return"[object Array]"===Object.prototype.toString.call(e)}),!c||!a.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW&&ArrayBuffer.isView||(ArrayBuffer.isView=function(e){return"object"===typeof e&&e.buffer&&e.buffer.constructor===ArrayBuffer});for(var b=function(e,t,r){return function(n){return new I(e,t,e).update(n)[r]()}},w=function(e,t,r){return function(n,i){return new I(e,t,i).update(n)[r]()}},x=function(e,t,r){return function(t,n,i,o){return A["cshake"+e].update(t,n,i,o)[r]()}},_=function(e,t,r){return function(t,n,i,o){return A["kmac"+e].update(t,n,i,o)[r]()}},S=function(e,t,r,n){for(var i=0;i>5,this.byteCount=this.blockCount<<2,this.outputBlocks=r>>5,this.extraBytes=(31&r)>>3;for(var n=0;n<50;++n)this.s[n]=0}function L(e,t,r){I.call(this,e,t,r)}I.prototype.update=function(e){if(this.finalized)throw new Error("finalize already called");var t,r=typeof e;if("string"!==r){if("object"!==r)throw new Error(i);if(null===e)throw new Error(i);if(c&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!Array.isArray(e)&&(!c||!ArrayBuffer.isView(e)))throw new Error(i);t=!0}for(var n,o,a=this.blocks,s=this.byteCount,u=e.length,l=this.blockCount,f=0,d=this.s;f>2]|=e[f]<>2]|=o<>2]|=(192|o>>6)<>2]|=(128|63&o)<=57344?(a[n>>2]|=(224|o>>12)<>2]|=(128|o>>6&63)<>2]|=(128|63&o)<>2]|=(240|o>>18)<>2]|=(128|o>>12&63)<>2]|=(128|o>>6&63)<>2]|=(128|63&o)<=s){for(this.start=n-s,this.block=a[l],n=0;n>=8);r>0;)i.unshift(r),r=255&(e>>=8),++n;return t?i.push(n):i.unshift(n),this.update(i),i.length},I.prototype.encodeString=function(e){var t,r=typeof e;if("string"!==r){if("object"!==r)throw new Error(i);if(null===e)throw new Error(i);if(c&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!Array.isArray(e)&&(!c||!ArrayBuffer.isView(e)))throw new Error(i);t=!0}var n=0,o=e.length;if(t)n=o;else for(var a=0;a=57344?n+=3:(s=65536+((1023&s)<<10|1023&e.charCodeAt(++a)),n+=4)}return n+=this.encode(8*n),this.update(e),n},I.prototype.bytepad=function(e,t){for(var r=this.encode(t),n=0;n>2]|=this.padding[3&t],this.lastByteIndex===this.byteCount)for(e[0]=e[r],t=1;t>4&15]+f[15&e]+f[e>>12&15]+f[e>>8&15]+f[e>>20&15]+f[e>>16&15]+f[e>>28&15]+f[e>>24&15];a%t===0&&(N(r),o=0)}return i&&(e=r[o],s+=f[e>>4&15]+f[15&e],i>1&&(s+=f[e>>12&15]+f[e>>8&15]),i>2&&(s+=f[e>>20&15]+f[e>>16&15])),s},I.prototype.arrayBuffer=function(){this.finalize();var e,t=this.blockCount,r=this.s,n=this.outputBlocks,i=this.extraBytes,o=0,a=0,s=this.outputBits>>3;e=i?new ArrayBuffer(n+1<<2):new ArrayBuffer(s);for(var u=new Uint32Array(e);a>8&255,u[e+2]=t>>16&255,u[e+3]=t>>24&255;s%r===0&&N(n)}return o&&(e=s<<2,t=n[a],u[e]=255&t,o>1&&(u[e+1]=t>>8&255),o>2&&(u[e+2]=t>>16&255)),u},L.prototype=new I,L.prototype.finalize=function(){return this.encode(this.outputBits,!0),I.prototype.finalize.call(this)};var N=function(e){var t,r,n,i,o,a,s,u,l,c,f,d,h,m,y,v,g,b,w,x,_,S,k,E,A,j,M,T,P,C,O,R,I,L,N,D,F,U,B,G,V,z,q,H,Z,W,K,X,Y,Q,J,$,ee,te,re,ne,ie,oe,ae,se,ue,le,ce;for(n=0;n<48;n+=2)i=e[0]^e[10]^e[20]^e[30]^e[40],o=e[1]^e[11]^e[21]^e[31]^e[41],a=e[2]^e[12]^e[22]^e[32]^e[42],s=e[3]^e[13]^e[23]^e[33]^e[43],u=e[4]^e[14]^e[24]^e[34]^e[44],l=e[5]^e[15]^e[25]^e[35]^e[45],c=e[6]^e[16]^e[26]^e[36]^e[46],f=e[7]^e[17]^e[27]^e[37]^e[47],t=(d=e[8]^e[18]^e[28]^e[38]^e[48])^(a<<1|s>>>31),r=(h=e[9]^e[19]^e[29]^e[39]^e[49])^(s<<1|a>>>31),e[0]^=t,e[1]^=r,e[10]^=t,e[11]^=r,e[20]^=t,e[21]^=r,e[30]^=t,e[31]^=r,e[40]^=t,e[41]^=r,t=i^(u<<1|l>>>31),r=o^(l<<1|u>>>31),e[2]^=t,e[3]^=r,e[12]^=t,e[13]^=r,e[22]^=t,e[23]^=r,e[32]^=t,e[33]^=r,e[42]^=t,e[43]^=r,t=a^(c<<1|f>>>31),r=s^(f<<1|c>>>31),e[4]^=t,e[5]^=r,e[14]^=t,e[15]^=r,e[24]^=t,e[25]^=r,e[34]^=t,e[35]^=r,e[44]^=t,e[45]^=r,t=u^(d<<1|h>>>31),r=l^(h<<1|d>>>31),e[6]^=t,e[7]^=r,e[16]^=t,e[17]^=r,e[26]^=t,e[27]^=r,e[36]^=t,e[37]^=r,e[46]^=t,e[47]^=r,t=c^(i<<1|o>>>31),r=f^(o<<1|i>>>31),e[8]^=t,e[9]^=r,e[18]^=t,e[19]^=r,e[28]^=t,e[29]^=r,e[38]^=t,e[39]^=r,e[48]^=t,e[49]^=r,m=e[0],y=e[1],W=e[11]<<4|e[10]>>>28,K=e[10]<<4|e[11]>>>28,T=e[20]<<3|e[21]>>>29,P=e[21]<<3|e[20]>>>29,se=e[31]<<9|e[30]>>>23,ue=e[30]<<9|e[31]>>>23,z=e[40]<<18|e[41]>>>14,q=e[41]<<18|e[40]>>>14,L=e[2]<<1|e[3]>>>31,N=e[3]<<1|e[2]>>>31,v=e[13]<<12|e[12]>>>20,g=e[12]<<12|e[13]>>>20,X=e[22]<<10|e[23]>>>22,Y=e[23]<<10|e[22]>>>22,C=e[33]<<13|e[32]>>>19,O=e[32]<<13|e[33]>>>19,le=e[42]<<2|e[43]>>>30,ce=e[43]<<2|e[42]>>>30,te=e[5]<<30|e[4]>>>2,re=e[4]<<30|e[5]>>>2,D=e[14]<<6|e[15]>>>26,F=e[15]<<6|e[14]>>>26,b=e[25]<<11|e[24]>>>21,w=e[24]<<11|e[25]>>>21,Q=e[34]<<15|e[35]>>>17,J=e[35]<<15|e[34]>>>17,R=e[45]<<29|e[44]>>>3,I=e[44]<<29|e[45]>>>3,E=e[6]<<28|e[7]>>>4,A=e[7]<<28|e[6]>>>4,ne=e[17]<<23|e[16]>>>9,ie=e[16]<<23|e[17]>>>9,U=e[26]<<25|e[27]>>>7,B=e[27]<<25|e[26]>>>7,x=e[36]<<21|e[37]>>>11,_=e[37]<<21|e[36]>>>11,$=e[47]<<24|e[46]>>>8,ee=e[46]<<24|e[47]>>>8,H=e[8]<<27|e[9]>>>5,Z=e[9]<<27|e[8]>>>5,j=e[18]<<20|e[19]>>>12,M=e[19]<<20|e[18]>>>12,oe=e[29]<<7|e[28]>>>25,ae=e[28]<<7|e[29]>>>25,G=e[38]<<8|e[39]>>>24,V=e[39]<<8|e[38]>>>24,S=e[48]<<14|e[49]>>>18,k=e[49]<<14|e[48]>>>18,e[0]=m^~v&b,e[1]=y^~g&w,e[10]=E^~j&T,e[11]=A^~M&P,e[20]=L^~D&U,e[21]=N^~F&B,e[30]=H^~W&X,e[31]=Z^~K&Y,e[40]=te^~ne&oe,e[41]=re^~ie&ae,e[2]=v^~b&x,e[3]=g^~w&_,e[12]=j^~T&C,e[13]=M^~P&O,e[22]=D^~U&G,e[23]=F^~B&V,e[32]=W^~X&Q,e[33]=K^~Y&J,e[42]=ne^~oe&se,e[43]=ie^~ae&ue,e[4]=b^~x&S,e[5]=w^~_&k,e[14]=T^~C&R,e[15]=P^~O&I,e[24]=U^~G&z,e[25]=B^~V&q,e[34]=X^~Q&$,e[35]=Y^~J&ee,e[44]=oe^~se&le,e[45]=ae^~ue&ce,e[6]=x^~S&m,e[7]=_^~k&y,e[16]=C^~R&E,e[17]=O^~I&A,e[26]=G^~z&L,e[27]=V^~q&N,e[36]=Q^~$&H,e[37]=J^~ee&Z,e[46]=se^~le&te,e[47]=ue^~ce&re,e[8]=S^~m&v,e[9]=k^~y&g,e[18]=R^~E&j,e[19]=I^~A&M,e[28]=z^~L&D,e[29]=q^~N&F,e[38]=$^~H&W,e[39]=ee^~Z&K,e[48]=le^~te&ne,e[49]=ce^~re&ie,e[0]^=p[n],e[1]^=p[n+1]};if(u)e.exports=A;else{for(M=0;M>16&255,u[c++]=t>>8&255,u[c++]=255&t;return 2===s&&(t=i[e.charCodeAt(r)]<<2|i[e.charCodeAt(r+1)]>>4,u[c++]=255&t),1===s&&(t=i[e.charCodeAt(r)]<<10|i[e.charCodeAt(r+1)]<<4|i[e.charCodeAt(r+2)]>>2,u[c++]=t>>8&255,u[c++]=255&t),u},r.fromByteArray=function(e){for(var t,r=e.length,i=r%3,o=[],a=0,s=r-i;a>2]+n[t<<4&63]+"==")):2==i&&(t=(e[r-2]<<8)+e[r-1],o.push(n[t>>10]+n[t>>4&63]+n[t<<2&63]+"=")),o.join("")};for(var n=[],i=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,u=a.length;s>18&63]+n[o>>12&63]+n[o>>6&63]+n[63&o]);return a.join("")}i["-".charCodeAt(0)]=62,i["_".charCodeAt(0)]=63},{}],2:[function(e,t,r){},{}],3:[function(e,t,r){arguments[4][2][0].apply(r,arguments)},{dup:2}],4:[function(e,t,r){(function(t){"use strict";var n=e("base64-js"),i=e("ieee754"),o="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;r.Buffer=t,r.SlowBuffer=function(e){return+e!=e&&(e=0),t.alloc(+e)},r.INSPECT_MAX_BYTES=50;var a=2147483647;function s(e){if(a>>1;case"base64":return I(e).length;default:if(o)return i?-1:R(e).length;r=(""+r).toLowerCase(),o=!0}}function p(e,t,r){var n=e[t];e[t]=e[r],e[r]=n}function m(e,r,n,i,o){if(0===e.length)return-1;if("string"==typeof n?(i=n,n=0):2147483647=e.length){if(o)return-1;n=e.length-1}else if(n<0){if(!o)return-1;n=0}if("string"==typeof r&&(r=t.from(r,i)),t.isBuffer(r))return 0===r.length?-1:y(e,r,n,i,o);if("number"==typeof r)return r&=255,"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,r,n):Uint8Array.prototype.lastIndexOf.call(e,r,n):y(e,[r],n,i,o);throw new TypeError("val must be string, number or Buffer")}function y(e,t,r,n,i){var o,a=1,s=e.length,u=t.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(e.length<2||t.length<2)return-1;s/=a=2,u/=2,r/=2}function l(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(i){var c=-1;for(o=r;o>8,i=r%256,o.push(i),o.push(n);return o}(t,e.length-r),e,r,n)}function w(e,t,r){return 0===t&&r===e.length?n.fromByteArray(e):n.fromByteArray(e.slice(t,r))}function x(e,t,r){r=Math.min(e.length,r);for(var n=[],i=t;i>>10&1023|55296),c=56320|1023&c),n.push(c),i+=f}return function(e){var t=e.length;if(t<=_)return String.fromCharCode.apply(String,e);for(var r="",n=0;nthis.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(t>>>=0))return"";for(e=e||"utf8";;)switch(e){case"hex":return E(this,t,r);case"utf8":case"utf-8":return x(this,t,r);case"ascii":return S(this,t,r);case"latin1":case"binary":return k(this,t,r);case"base64":return w(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return A(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}.apply(this,arguments)},t.prototype.equals=function(e){if(!t.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===t.compare(this,e)},t.prototype.inspect=function(){var e="",t=r.INSPECT_MAX_BYTES;return e=this.toString("hex",0,t).replace(/(.{2})/g,"$1 ").trim(),this.length>t&&(e+=" ... "),""},o&&(t.prototype[o]=t.prototype.inspect),t.prototype.compare=function(e,r,n,i,o){if(N(e,Uint8Array)&&(e=t.from(e,e.offset,e.byteLength)),!t.isBuffer(e))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===r&&(r=0),void 0===n&&(n=e?e.length:0),void 0===i&&(i=0),void 0===o&&(o=this.length),r<0||n>e.length||i<0||o>this.length)throw new RangeError("out of range index");if(o<=i&&n<=r)return 0;if(o<=i)return-1;if(n<=r)return 1;if(this===e)return 0;for(var a=(o>>>=0)-(i>>>=0),s=(n>>>=0)-(r>>>=0),u=Math.min(a,s),l=this.slice(i,o),c=e.slice(r,n),f=0;f>>=0,isFinite(r)?(r>>>=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}var i=this.length-t;if((void 0===r||ithis.length)throw new RangeError("Attempt to write outside buffer bounds");n=n||"utf8";for(var o,a,s,u,l,c,f=!1;;)switch(n){case"hex":return v(this,e,t,r);case"utf8":case"utf-8":return l=t,c=r,L(R(e,(u=this).length-l),u,l,c);case"ascii":case"latin1":case"binary":return g(this,e,t,r);case"base64":return o=this,a=t,s=r,L(I(e),o,a,s);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return b(this,e,t,r);default:if(f)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),f=!0}},t.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var _=4096;function S(e,t,r){var n="";r=Math.min(e.length,r);for(var i=t;ie.length)throw new RangeError("Index out of range")}function T(e,t,r,n){if(r+n>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function P(e,t,r,n,o){return t=+t,r>>>=0,o||T(e,0,r,4),i.write(e,t,r,n,23,4),r+4}function C(e,t,r,n,o){return t=+t,r>>>=0,o||T(e,0,r,8),i.write(e,t,r,n,52,8),r+8}t.prototype.slice=function(e,r){var n=this.length;(e=~~e)<0?(e+=n)<0&&(e=0):n>>=0,t>>>=0,r||j(e,t,this.length);for(var n=this[e],i=1,o=0;++o>>=0,t>>>=0,r||j(e,t,this.length);for(var n=this[e+--t],i=1;0>>=0,t||j(e,1,this.length),this[e]},t.prototype.readUInt16LE=function(e,t){return e>>>=0,t||j(e,2,this.length),this[e]|this[e+1]<<8},t.prototype.readUInt16BE=function(e,t){return e>>>=0,t||j(e,2,this.length),this[e]<<8|this[e+1]},t.prototype.readUInt32LE=function(e,t){return e>>>=0,t||j(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},t.prototype.readUInt32BE=function(e,t){return e>>>=0,t||j(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},t.prototype.readIntLE=function(e,t,r){e>>>=0,t>>>=0,r||j(e,t,this.length);for(var n=this[e],i=1,o=0;++o>>=0,t>>>=0,r||j(e,t,this.length);for(var n=t,i=1,o=this[e+--n];0>>=0,t||j(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},t.prototype.readInt16LE=function(e,t){e>>>=0,t||j(e,2,this.length);var r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},t.prototype.readInt16BE=function(e,t){e>>>=0,t||j(e,2,this.length);var r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},t.prototype.readInt32LE=function(e,t){return e>>>=0,t||j(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},t.prototype.readInt32BE=function(e,t){return e>>>=0,t||j(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},t.prototype.readFloatLE=function(e,t){return e>>>=0,t||j(e,4,this.length),i.read(this,e,!0,23,4)},t.prototype.readFloatBE=function(e,t){return e>>>=0,t||j(e,4,this.length),i.read(this,e,!1,23,4)},t.prototype.readDoubleLE=function(e,t){return e>>>=0,t||j(e,8,this.length),i.read(this,e,!0,52,8)},t.prototype.readDoubleBE=function(e,t){return e>>>=0,t||j(e,8,this.length),i.read(this,e,!1,52,8)},t.prototype.writeUIntLE=function(e,t,r,n){e=+e,t>>>=0,r>>>=0,n||M(this,e,t,r,Math.pow(2,8*r)-1,0);var i=1,o=0;for(this[t]=255&e;++o>>=0,r>>>=0,n||M(this,e,t,r,Math.pow(2,8*r)-1,0);var i=r-1,o=1;for(this[t+i]=255&e;0<=--i&&(o*=256);)this[t+i]=e/o&255;return t+r},t.prototype.writeUInt8=function(e,t,r){return e=+e,t>>>=0,r||M(this,e,t,1,255,0),this[t]=255&e,t+1},t.prototype.writeUInt16LE=function(e,t,r){return e=+e,t>>>=0,r||M(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},t.prototype.writeUInt16BE=function(e,t,r){return e=+e,t>>>=0,r||M(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},t.prototype.writeUInt32LE=function(e,t,r){return e=+e,t>>>=0,r||M(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},t.prototype.writeUInt32BE=function(e,t,r){return e=+e,t>>>=0,r||M(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},t.prototype.writeIntLE=function(e,t,r,n){if(e=+e,t>>>=0,!n){var i=Math.pow(2,8*r-1);M(this,e,t,r,i-1,-i)}var o=0,a=1,s=0;for(this[t]=255&e;++o>0)-s&255;return t+r},t.prototype.writeIntBE=function(e,t,r,n){if(e=+e,t>>>=0,!n){var i=Math.pow(2,8*r-1);M(this,e,t,r,i-1,-i)}var o=r-1,a=1,s=0;for(this[t+o]=255&e;0<=--o&&(a*=256);)e<0&&0===s&&0!==this[t+o+1]&&(s=1),this[t+o]=(e/a>>0)-s&255;return t+r},t.prototype.writeInt8=function(e,t,r){return e=+e,t>>>=0,r||M(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},t.prototype.writeInt16LE=function(e,t,r){return e=+e,t>>>=0,r||M(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},t.prototype.writeInt16BE=function(e,t,r){return e=+e,t>>>=0,r||M(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},t.prototype.writeInt32LE=function(e,t,r){return e=+e,t>>>=0,r||M(this,e,t,4,2147483647,-2147483648),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},t.prototype.writeInt32BE=function(e,t,r){return e=+e,t>>>=0,r||M(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},t.prototype.writeFloatLE=function(e,t,r){return P(this,e,t,!0,r)},t.prototype.writeFloatBE=function(e,t,r){return P(this,e,t,!1,r)},t.prototype.writeDoubleLE=function(e,t,r){return C(this,e,t,!0,r)},t.prototype.writeDoubleBE=function(e,t,r){return C(this,e,t,!1,r)},t.prototype.copy=function(e,r,n,i){if(!t.isBuffer(e))throw new TypeError("argument should be a Buffer");if(n=n||0,i||0===i||(i=this.length),r>=e.length&&(r=e.length),r=r||0,0=this.length)throw new RangeError("Index out of range");if(i<0)throw new RangeError("sourceEnd out of bounds");i>this.length&&(i=this.length),e.length-r>>=0,n=void 0===n?this.length:n>>>0,"number"==typeof(e=e||0))for(a=r;a>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;o.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return o}function I(e){return n.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(O,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function L(e,t,r,n){for(var i=0;i=t.length||i>=e.length);++i)t[i+r]=e[i];return i}function N(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}function D(e){return e!=e}var F=function(){for(var e="0123456789abcdef",t=new Array(256),r=0;r<16;++r)for(var n=16*r,i=0;i<16;++i)t[n+i]=e[r]+e[i];return t}()}).call(this,e("buffer").Buffer)},{"base64-js":1,buffer:4,ieee754:236}],5:[function(e,t,r){t.exports=function(e){if("function"!=typeof e)throw TypeError(String(e)+" is not a function");return e}},{}],6:[function(e,t,r){var n=e("../internals/is-object");t.exports=function(e){if(!n(e)&&null!==e)throw TypeError("Can't set "+String(e)+" as a prototype");return e}},{"../internals/is-object":74}],7:[function(e,t,r){var n=e("../internals/well-known-symbol"),i=e("../internals/object-create"),o=e("../internals/object-define-property"),a=n("unscopables"),s=Array.prototype;null==s[a]&&o.f(s,a,{configurable:!0,value:i(null)}),t.exports=function(e){s[a][e]=!0}},{"../internals/object-create":90,"../internals/object-define-property":92,"../internals/well-known-symbol":146}],8:[function(e,t,r){"use strict";var n=e("../internals/string-multibyte").charAt;t.exports=function(e,t,r){return t+(r?n(e,t).length:1)}},{"../internals/string-multibyte":123}],9:[function(e,t,r){t.exports=function(e,t,r){if(!(e instanceof t))throw TypeError("Incorrect "+(r?r+" ":"")+"invocation");return e}},{}],10:[function(e,t,r){var n=e("../internals/is-object");t.exports=function(e){if(!n(e))throw TypeError(String(e)+" is not an object");return e}},{"../internals/is-object":74}],11:[function(e,t,r){t.exports="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView},{}],12:[function(e,t,r){"use strict";function n(e){return u(e)&&l(P,c(e))}var i,o=e("../internals/array-buffer-native"),a=e("../internals/descriptors"),s=e("../internals/global"),u=e("../internals/is-object"),l=e("../internals/has"),c=e("../internals/classof"),f=e("../internals/create-non-enumerable-property"),d=e("../internals/redefine"),h=e("../internals/object-define-property").f,p=e("../internals/object-get-prototype-of"),m=e("../internals/object-set-prototype-of"),y=e("../internals/well-known-symbol"),v=e("../internals/uid"),g=s.Int8Array,b=g&&g.prototype,w=s.Uint8ClampedArray,x=w&&w.prototype,_=g&&p(g),S=b&&p(b),k=Object.prototype,E=k.isPrototypeOf,A=y("toStringTag"),j=v("TYPED_ARRAY_TAG"),M=o&&!!m&&"Opera"!==c(s.opera),T=!1,P={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8};for(i in P)s[i]||(M=!1);if((!M||"function"!=typeof _||_===Function.prototype)&&(_=function(){throw TypeError("Incorrect invocation")},M))for(i in P)s[i]&&m(s[i],_);if((!M||!S||S===k)&&(S=_.prototype,M))for(i in P)s[i]&&m(s[i].prototype,S);if(M&&p(x)!==S&&m(x,S),a&&!l(S,A))for(i in T=!0,h(S,A,{get:function(){return u(this)?this[j]:void 0}}),P)s[i]&&f(s[i],j,i);t.exports={NATIVE_ARRAY_BUFFER_VIEWS:M,TYPED_ARRAY_TAG:T&&j,aTypedArray:function(e){if(n(e))return e;throw TypeError("Target is not a typed array")},aTypedArrayConstructor:function(e){if(m){if(E.call(_,e))return e}else for(var t in P)if(l(P,i)){var r=s[t];if(r&&(e===r||E.call(r,e)))return e}throw TypeError("Target is not a typed array constructor")},exportTypedArrayMethod:function(e,t,r){if(a){if(r)for(var n in P){var i=s[n];i&&l(i.prototype,e)&&delete i.prototype[e]}S[e]&&!r||d(S,e,r?t:M&&b[e]||t)}},exportTypedArrayStaticMethod:function(e,t,r){var n,i;if(a){if(m){if(r)for(n in P)(i=s[n])&&l(i,e)&&delete i[e];if(_[e]&&!r)return;try{return d(_,e,r?t:M&&g[e]||t)}catch(e){}}for(n in P)!(i=s[n])||i[e]&&!r||d(i,e,t)}},isView:function(e){var t=c(e);return"DataView"===t||l(P,t)},isTypedArray:n,TypedArray:_,TypedArrayPrototype:S}},{"../internals/array-buffer-native":11,"../internals/classof":29,"../internals/create-non-enumerable-property":37,"../internals/descriptors":42,"../internals/global":59,"../internals/has":60,"../internals/is-object":74,"../internals/object-define-property":92,"../internals/object-get-prototype-of":97,"../internals/object-set-prototype-of":101,"../internals/redefine":108,"../internals/uid":143,"../internals/well-known-symbol":146}],13:[function(e,t,r){"use strict";function n(e){return[255&e]}function i(e){return[255&e,e>>8&255]}function o(e){return[255&e,e>>8&255,e>>16&255,e>>24&255]}function a(e){return e[3]<<24|e[2]<<16|e[1]<<8|e[0]}function s(e){return V(e,23,4)}function u(e){return V(e,52,8)}function l(e,t){A(e[I],t,{get:function(){return P(this)[t]}})}function c(e,t,r,n){var i=x(r),o=P(e);if(i+t>o.byteLength)throw G(L);var a=P(o.buffer).bytes,s=i+o.byteOffset,u=a.slice(s,s+t);return n?u:u.reverse()}function f(e,t,r,n,i,o){var a=x(r),s=P(e);if(a+t>s.byteLength)throw G(L);for(var u=P(s.buffer).bytes,l=a+s.byteOffset,c=n(+i),f=0;fW;)(q=Z[W++])in D||m(D,q,N[q]);H.constructor=D}k&&S(U)!==B&&k(U,B);var K=new F(new D(2)),X=U.setInt8;K.setInt8(0,2147483648),K.setInt8(1,2147483649),!K.getInt8(0)&&K.getInt8(1)||y(U,{setInt8:function(e,t){X.call(this,e,t<<24>>24)},setUint8:function(e,t){X.call(this,e,t<<24>>24)}},{unsafe:!0})}else D=function(e){g(this,D,O);var t=x(e);C(this,{bytes:j.call(new Array(t),0),byteLength:t}),h||(this.byteLength=t)},F=function(e,t,r){g(this,F,R),g(e,D,R);var n=P(e).byteLength,i=b(t);if(i<0||n>24},getUint8:function(e){return c(this,1,e)[0]},getInt16:function(e,t){var r=c(this,2,e,1>16},getUint16:function(e,t){var r=c(this,2,e,1>>0},getFloat32:function(e,t){return z(c(this,4,e,1"+a+""}},{"../internals/require-object-coercible":113}],36:[function(e,t,r){"use strict";function n(){return this}var i=e("../internals/iterators-core").IteratorPrototype,o=e("../internals/object-create"),a=e("../internals/create-property-descriptor"),s=e("../internals/set-to-string-tag"),u=e("../internals/iterators");t.exports=function(e,t,r){var l=t+" Iterator";return e.prototype=o(i,{next:a(1,r)}),s(e,l,!1,!0),u[l]=n,e}},{"../internals/create-property-descriptor":38,"../internals/iterators":79,"../internals/iterators-core":78,"../internals/object-create":90,"../internals/set-to-string-tag":117}],37:[function(e,t,r){var n=e("../internals/descriptors"),i=e("../internals/object-define-property"),o=e("../internals/create-property-descriptor");t.exports=n?function(e,t,r){return i.f(e,t,o(1,r))}:function(e,t,r){return e[t]=r,e}},{"../internals/create-property-descriptor":38,"../internals/descriptors":42,"../internals/object-define-property":92}],38:[function(e,t,r){t.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},{}],39:[function(e,t,r){"use strict";var n=e("../internals/to-primitive"),i=e("../internals/object-define-property"),o=e("../internals/create-property-descriptor");t.exports=function(e,t,r){var a=n(t);a in e?i.f(e,a,o(0,r)):e[a]=r}},{"../internals/create-property-descriptor":38,"../internals/object-define-property":92,"../internals/to-primitive":138}],40:[function(e,t,r){"use strict";function n(){return this}var i=e("../internals/export"),o=e("../internals/create-iterator-constructor"),a=e("../internals/object-get-prototype-of"),s=e("../internals/object-set-prototype-of"),u=e("../internals/set-to-string-tag"),l=e("../internals/create-non-enumerable-property"),c=e("../internals/redefine"),f=e("../internals/well-known-symbol"),d=e("../internals/is-pure"),h=e("../internals/iterators"),p=e("../internals/iterators-core"),m=p.IteratorPrototype,y=p.BUGGY_SAFARI_ITERATORS,v=f("iterator"),g="values",b="entries";t.exports=function(e,t,r,f,p,w,x){function _(e){if(e===p&&P)return P;if(!y&&e in M)return M[e];switch(e){case"keys":case g:case b:return function(){return new r(this,e)}}return function(){return new r(this)}}o(r,t,f);var S,k,E,A=t+" Iterator",j=!1,M=e.prototype,T=M[v]||M["@@iterator"]||p&&M[p],P=!y&&T||_(p),C="Array"==t&&M.entries||T;if(C&&(S=a(C.call(new e)),m!==Object.prototype&&S.next&&(d||a(S)===m||(s?s(S,m):"function"!=typeof S[v]&&l(S,v,n)),u(S,A,!0,!0),d&&(h[A]=n))),p==g&&T&&T.name!==g&&(j=!0,P=function(){return T.call(this)}),d&&!x||M[v]===P||l(M,v,P),h[t]=P,p)if(k={values:_(g),keys:w?P:_("keys"),entries:_(b)},x)for(E in k)!y&&!j&&E in M||c(M,E,k[E]);else i({target:t,proto:!0,forced:y||j},k);return k}},{"../internals/create-iterator-constructor":36,"../internals/create-non-enumerable-property":37,"../internals/export":49,"../internals/is-pure":75,"../internals/iterators":79,"../internals/iterators-core":78,"../internals/object-get-prototype-of":97,"../internals/object-set-prototype-of":101,"../internals/redefine":108,"../internals/set-to-string-tag":117,"../internals/well-known-symbol":146}],41:[function(e,t,r){var n=e("../internals/path"),i=e("../internals/has"),o=e("../internals/well-known-symbol-wrapped"),a=e("../internals/object-define-property").f;t.exports=function(e){var t=n.Symbol||(n.Symbol={});i(t,e)||a(t,e,{value:o.f(e)})}},{"../internals/has":60,"../internals/object-define-property":92,"../internals/path":104,"../internals/well-known-symbol-wrapped":145}],42:[function(e,t,r){var n=e("../internals/fails");t.exports=!n((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},{"../internals/fails":50}],43:[function(e,t,r){var n=e("../internals/global"),i=e("../internals/is-object"),o=n.document,a=i(o)&&i(o.createElement);t.exports=function(e){return a?o.createElement(e):{}}},{"../internals/global":59,"../internals/is-object":74}],44:[function(e,t,r){t.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},{}],45:[function(e,t,r){var n=e("../internals/engine-user-agent");t.exports=/(iphone|ipod|ipad).*applewebkit/i.test(n)},{"../internals/engine-user-agent":46}],46:[function(e,t,r){var n=e("../internals/get-built-in");t.exports=n("navigator","userAgent")||""},{"../internals/get-built-in":56}],47:[function(e,t,r){var n,i,o=e("../internals/global"),a=e("../internals/engine-user-agent"),s=o.process,u=s&&s.versions,l=u&&u.v8;l?i=(n=l.split("."))[0]+n[1]:a&&(!(n=a.match(/Edge\/(\d+)/))||74<=n[1])&&(n=a.match(/Chrome\/(\d+)/))&&(i=n[1]),t.exports=i&&+i},{"../internals/engine-user-agent":46,"../internals/global":59}],48:[function(e,t,r){t.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},{}],49:[function(e,t,r){var n=e("../internals/global"),i=e("../internals/object-get-own-property-descriptor").f,o=e("../internals/create-non-enumerable-property"),a=e("../internals/redefine"),s=e("../internals/set-global"),u=e("../internals/copy-constructor-properties"),l=e("../internals/is-forced");t.exports=function(e,t){var r,c,f,d,h,p=e.target,m=e.global,y=e.stat;if(r=m?n:y?n[p]||s(p,{}):(n[p]||{}).prototype)for(c in t){if(d=t[c],f=e.noTargetGet?(h=i(r,c))&&h.value:r[c],!l(m?c:p+(y?".":"#")+c,e.forced)&&void 0!==f){if(typeof d==typeof f)continue;u(d,f)}(e.sham||f&&f.sham)&&o(d,"sham",!0),a(r,c,d,e)}}},{"../internals/copy-constructor-properties":32,"../internals/create-non-enumerable-property":37,"../internals/global":59,"../internals/is-forced":73,"../internals/object-get-own-property-descriptor":93,"../internals/redefine":108,"../internals/set-global":115}],50:[function(e,t,r){t.exports=function(e){try{return!!e()}catch(e){return!0}}},{}],51:[function(e,t,r){"use strict";e("../modules/es.regexp.exec");var n=e("../internals/redefine"),i=e("../internals/fails"),o=e("../internals/well-known-symbol"),a=e("../internals/regexp-exec"),s=e("../internals/create-non-enumerable-property"),u=o("species"),l=!i((function(){var e=/./;return e.exec=function(){var e=[];return e.groups={a:"7"},e},"7"!=="".replace(e,"$")})),c="$0"==="a".replace(/./,"$0"),f=o("replace"),d=!!/./[f]&&""===/./[f]("a","$0"),h=!i((function(){var e=/(?:)/,t=e.exec;e.exec=function(){return t.apply(this,arguments)};var r="ab".split(e);return 2!==r.length||"a"!==r[0]||"b"!==r[1]}));t.exports=function(e,t,r,f){var p=o(e),m=!i((function(){var t={};return t[p]=function(){return 7},7!=""[e](t)})),y=m&&!i((function(){var t=!1,r=/a/;return"split"===e&&((r={constructor:{}}).constructor[u]=function(){return r},r.flags="",r[p]=/./[p]),r.exec=function(){return t=!0,null},r[p](""),!t}));if(!m||!y||"replace"===e&&(!l||!c||d)||"split"===e&&!h){var v=/./[p],g=r(p,""[e],(function(e,t,r,n,i){return t.exec===a?m&&!i?{done:!0,value:v.call(t,r,n)}:{done:!0,value:e.call(r,t,n)}:{done:!1}}),{REPLACE_KEEPS_$0:c,REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE:d}),b=g[0],w=g[1];n(String.prototype,e,b),n(RegExp.prototype,p,2==t?function(e,t){return w.call(e,this,t)}:function(e){return w.call(e,this)})}f&&s(RegExp.prototype[p],"sham",!0)}},{"../internals/create-non-enumerable-property":37,"../internals/fails":50,"../internals/redefine":108,"../internals/regexp-exec":110,"../internals/well-known-symbol":146,"../modules/es.regexp.exec":181}],52:[function(e,t,r){"use strict";var n=e("../internals/is-array"),i=e("../internals/to-length"),o=e("../internals/function-bind-context"),a=function e(t,r,a,s,u,l,c,f){for(var d,h=u,p=0,m=!!c&&o(c,f,3);p>1,m=23===t?i(2,-24)-i(2,-77):0,y=e<0||0===e&&1/e<0?1:0,v=0;for((e=n(e))!=e||e===1/0?(l=e!=e?1:0,u=h):(u=o(a(e)/s),e*(c=i(2,-u))<1&&(u--,c*=2),2<=(e+=1<=u+p?m/c:m*i(2,1-p))*c&&(u++,c/=2),h<=u+p?(l=0,u=h):1<=u+p?(l=(e*c-1)*i(2,t),u+=p):(l=e*i(2,p-1)*i(2,t),u=0));8<=t;f[v++]=255&l,l/=256,t-=8);for(u=u<>1,u=o-7,l=n-1,c=e[l--],f=127&c;for(c>>=7;0>=-u,u+=t;0"+e+""}var o,a=e("../internals/an-object"),s=e("../internals/object-define-properties"),u=e("../internals/enum-bug-keys"),l=e("../internals/hidden-keys"),c=e("../internals/html"),f=e("../internals/document-create-element"),d=e("../internals/shared-key"),h="prototype",p="script",m=d("IE_PROTO"),y=function(){try{o=document.domain&&new ActiveXObject("htmlfile")}catch(e){}var e,t;y=o?function(e){e.write(i("")),e.close();var t=e.parentWindow.Object;return e=null,t}(o):((t=f("iframe")).style.display="none",c.appendChild(t),t.src=String("javascript:"),(e=t.contentWindow.document).open(),e.write(i("document.F=Object")),e.close(),e.F);for(var r=u.length;r--;)delete y[h][u[r]];return y()};l[m]=!0,t.exports=Object.create||function(e,t){var r;return null!==e?(n[h]=a(e),r=new n,n[h]=null,r[m]=e):r=y(),void 0===t?r:s(r,t)}},{"../internals/an-object":10,"../internals/document-create-element":43,"../internals/enum-bug-keys":48,"../internals/hidden-keys":61,"../internals/html":63,"../internals/object-define-properties":91,"../internals/shared-key":118}],91:[function(e,t,r){var n=e("../internals/descriptors"),i=e("../internals/object-define-property"),o=e("../internals/an-object"),a=e("../internals/object-keys");t.exports=n?Object.defineProperties:function(e,t){o(e);for(var r,n=a(t),s=n.length,u=0;uu;)n(s,r=t[u++])&&(~o(l,r)||l.push(r));return l}},{"../internals/array-includes":18,"../internals/has":60,"../internals/hidden-keys":61,"../internals/to-indexed-object":132}],99:[function(e,t,r){var n=e("../internals/object-keys-internal"),i=e("../internals/enum-bug-keys");t.exports=Object.keys||function(e){return n(e,i)}},{"../internals/enum-bug-keys":48,"../internals/object-keys-internal":98}],100:[function(e,t,r){"use strict";var n={}.propertyIsEnumerable,i=Object.getOwnPropertyDescriptor,o=i&&!n.call({1:2},1);r.f=o?function(e){var t=i(this,e);return!!t&&t.enumerable}:n},{}],101:[function(e,t,r){var n=e("../internals/an-object"),i=e("../internals/a-possible-prototype");t.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var e,t=!1,r={};try{(e=Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set).call(r,[]),t=r instanceof Array}catch(r){}return function(r,o){return n(r),i(o),t?e.call(r,o):r.__proto__=o,r}}():void 0)},{"../internals/a-possible-prototype":6,"../internals/an-object":10}],102:[function(e,t,r){"use strict";var n=e("../internals/to-string-tag-support"),i=e("../internals/classof");t.exports=n?{}.toString:function(){return"[object "+i(this)+"]"}},{"../internals/classof":29,"../internals/to-string-tag-support":139}],103:[function(e,t,r){var n=e("../internals/get-built-in"),i=e("../internals/object-get-own-property-names"),o=e("../internals/object-get-own-property-symbols"),a=e("../internals/an-object");t.exports=n("Reflect","ownKeys")||function(e){var t=i.f(a(e)),r=o.f;return r?t.concat(r(e)):t}},{"../internals/an-object":10,"../internals/get-built-in":56,"../internals/object-get-own-property-names":95,"../internals/object-get-own-property-symbols":96}],104:[function(e,t,r){var n=e("../internals/global");t.exports=n},{"../internals/global":59}],105:[function(e,t,r){t.exports=function(e){try{return{error:!1,value:e()}}catch(e){return{error:!0,value:e}}}},{}],106:[function(e,t,r){var n=e("../internals/an-object"),i=e("../internals/is-object"),o=e("../internals/new-promise-capability");t.exports=function(e,t){if(n(e),i(t)&&t.constructor===e)return t;var r=o.f(e);return(0,r.resolve)(t),r.promise}},{"../internals/an-object":10,"../internals/is-object":74,"../internals/new-promise-capability":86}],107:[function(e,t,r){var n=e("../internals/redefine");t.exports=function(e,t,r){for(var i in t)n(e,i,t[i],r);return e}},{"../internals/redefine":108}],108:[function(e,t,r){var n=e("../internals/global"),i=e("../internals/create-non-enumerable-property"),o=e("../internals/has"),a=e("../internals/set-global"),s=e("../internals/inspect-source"),u=e("../internals/internal-state"),l=u.get,c=u.enforce,f=String(String).split("String");(t.exports=function(e,t,r,s){var u=!!s&&!!s.unsafe,l=!!s&&!!s.enumerable,d=!!s&&!!s.noTargetGet;"function"==typeof r&&("string"!=typeof t||o(r,"name")||i(r,"name",t),c(r).source=f.join("string"==typeof t?t:"")),e!==n?(u?!d&&e[t]&&(l=!0):delete e[t],l?e[t]=r:i(e,t,r)):l?e[t]=r:a(t,r)})(Function.prototype,"toString",(function(){return"function"==typeof this&&l(this).source||s(this)}))},{"../internals/create-non-enumerable-property":37,"../internals/global":59,"../internals/has":60,"../internals/inspect-source":68,"../internals/internal-state":70,"../internals/set-global":115}],109:[function(e,t,r){var n=e("./classof-raw"),i=e("./regexp-exec");t.exports=function(e,t){var r=e.exec;if("function"==typeof r){var o=r.call(e,t);if("object"!=typeof o)throw TypeError("RegExp exec method returned something other than an Object or null");return o}if("RegExp"!==n(e))throw TypeError("RegExp#exec called on incompatible receiver");return i.call(e,t)}},{"./classof-raw":28,"./regexp-exec":110}],110:[function(e,t,r){"use strict";var n,i,o=e("./regexp-flags"),a=e("./regexp-sticky-helpers"),s=RegExp.prototype.exec,u=String.prototype.replace,l=s,c=(n=/a/,i=/b*/g,s.call(n,"a"),s.call(i,"a"),0!==n.lastIndex||0!==i.lastIndex),f=a.UNSUPPORTED_Y||a.BROKEN_CARET,d=void 0!==/()??/.exec("")[1];(c||d||f)&&(l=function(e){var t,r,n,i,a=this,l=f&&a.sticky,h=o.call(a),p=a.source,m=0,y=e;return l&&(-1===(h=h.replace("y","")).indexOf("g")&&(h+="g"),y=String(e).slice(a.lastIndex),0>1,e+=c(e/t);455c((a-d)/v))throw RangeError(l);for(d+=(y-u)*v,u=y,t=0;ta)throw RangeError(l);if(r==u){for(var g=d,b=36;;b+=36){var w=b<=h?1:h+26<=b?26:b-h;if(g>>=1)&&(t+=t))1&o&&(r+=t);return r}},{"../internals/require-object-coercible":113,"../internals/to-integer":133}],126:[function(e,t,r){var n=e("../internals/fails"),i=e("../internals/whitespaces");t.exports=function(e){return n((function(){return!!i[e]()||"\u200b\x85\u180e"!="\u200b\x85\u180e"[e]()||i[e].name!==e}))}},{"../internals/fails":50,"../internals/whitespaces":147}],127:[function(e,t,r){function n(e){return function(t){var r=String(i(t));return 1&e&&(r=r.replace(a,"")),2&e&&(r=r.replace(s,"")),r}}var i=e("../internals/require-object-coercible"),o="["+e("../internals/whitespaces")+"]",a=RegExp("^"+o+o+"*"),s=RegExp(o+o+"*$");t.exports={start:n(1),end:n(2),trim:n(3)}},{"../internals/require-object-coercible":113,"../internals/whitespaces":147}],128:[function(e,t,r){function n(e){if(k.hasOwnProperty(e)){var t=k[e];delete k[e],t()}}function i(e){return function(){n(e)}}function o(e){n(e.data)}function a(e){c.postMessage(e+"",v.protocol+"//"+v.host)}var s,u,l,c=e("../internals/global"),f=e("../internals/fails"),d=e("../internals/classof-raw"),h=e("../internals/function-bind-context"),p=e("../internals/html"),m=e("../internals/document-create-element"),y=e("../internals/engine-is-ios"),v=c.location,g=c.setImmediate,b=c.clearImmediate,w=c.process,x=c.MessageChannel,_=c.Dispatch,S=0,k={},E="onreadystatechange";g&&b||(g=function(e){for(var t=[],r=1;r=t.length?{value:e.target=void 0,done:!0}:"keys"==r?{value:n,done:!1}:"values"==r?{value:t[n],done:!1}:{value:[n,t[n]],done:!1}}),"values"),o.Arguments=o.Array,i("keys"),i("values"),i("entries")},{"../internals/add-to-unscopables":7,"../internals/define-iterator":40,"../internals/internal-state":70,"../internals/iterators":79,"../internals/to-indexed-object":132}],159:[function(e,t,r){"use strict";var n=e("../internals/export"),i=e("../internals/indexed-object"),o=e("../internals/to-indexed-object"),a=e("../internals/array-method-is-strict"),s=[].join,u=i!=Object,l=a("join",",");n({target:"Array",proto:!0,forced:u||!l},{join:function(e){return s.call(o(this),void 0===e?",":e)}})},{"../internals/array-method-is-strict":22,"../internals/export":49,"../internals/indexed-object":66,"../internals/to-indexed-object":132}],160:[function(e,t,r){var n=e("../internals/export"),i=e("../internals/array-last-index-of");n({target:"Array",proto:!0,forced:i!==[].lastIndexOf},{lastIndexOf:i})},{"../internals/array-last-index-of":20,"../internals/export":49}],161:[function(e,t,r){"use strict";var n=e("../internals/export"),i=e("../internals/array-iteration").map,o=e("../internals/array-method-has-species-support"),a=e("../internals/array-method-uses-to-length"),s=o("map"),u=a("map");n({target:"Array",proto:!0,forced:!s||!u},{map:function(e,t){return i(this,e,1E;E++)u(b,_=k[E])&&!u(S,_)&&y(S,_,m(b,_));(S.prototype=w).constructor=S,s(o,g,S)}},{"../internals/classof-raw":28,"../internals/descriptors":42,"../internals/fails":50,"../internals/global":59,"../internals/has":60,"../internals/inherit-if-required":67,"../internals/is-forced":73,"../internals/object-create":90,"../internals/object-define-property":92,"../internals/object-get-own-property-descriptor":93,"../internals/object-get-own-property-names":95,"../internals/redefine":108,"../internals/string-trim":127,"../internals/to-primitive":138}],171:[function(e,t,r){e("../internals/export")({target:"Number",stat:!0},{isFinite:e("../internals/number-is-finite")})},{"../internals/export":49,"../internals/number-is-finite":88}],172:[function(e,t,r){"use strict";var n=e("../internals/export"),i=e("../internals/to-integer"),o=e("../internals/this-number-value"),a=e("../internals/string-repeat"),s=e("../internals/fails"),u=1..toFixed,l=Math.floor,c=function e(t,r,n){return 0===r?n:r%2==1?e(t,r-1,n*t):e(t*t,r/2,n)};n({target:"Number",proto:!0,forced:u&&("0.000"!==8e-5.toFixed(3)||"1"!==.9.toFixed(0)||"1.25"!==1.255.toFixed(2)||"1000000000000000128"!==(0xde0b6b3a7640080).toFixed(0))||!s((function(){u.call({})}))},{toFixed:function(e){function t(e,t){for(var r=-1,n=t;++r<6;)n+=e*m[r],m[r]=n%1e7,n=l(n/1e7)}function r(e){for(var t=6,r=0;0<=--t;)r+=m[t],m[t]=l(r/e),r=r%e*1e7}function n(){for(var e=6,t="";0<=--e;)if(""!==t||0===e||0!==m[e]){var r=String(m[e]);t=""===t?r:t+a.call("0",7-r.length)+r}return t}var s,u,f,d,h=o(this),p=i(e),m=[0,0,0,0,0,0],y="",v="0";if(p<0||20s;){var u,l,c,f=i[s++],d=a?f.ok:f.fail,h=f.resolve,p=f.reject,m=f.domain;try{d?(a||(2===t.rejection&&ie(e,t),t.rejection=1),!0===d?u=o:(m&&m.enter(),u=d(o),m&&(m.exit(),c=!0)),u===f.promise?p(H("Promise-chain cycle")):(l=n(u))?l.call(u,h,p):h(u)):p(o)}catch(o){m&&!c&&m.exit(),p(o)}}t.reactions=[],t.notified=!1,r&&!t.rejection&&re(e,t)}))}}function o(e,t,r){var n,i;J?((n=Z.createEvent("Event")).promise=t,n.reason=r,n.initEvent(e,!1,!0),p.dispatchEvent(n)):n={promise:t,reason:r},(i=p["on"+e])?i(n):e===$&&O("Unhandled promise rejection",r)}function a(e,t,r,n){return function(i){e(t,r,i,n)}}function s(e,t,r,n){t.done||(t.done=!0,n&&(t=n),t.value=r,t.state=2,i(e,t,!0))}var u,l,c,f,d=e("../internals/export"),h=e("../internals/is-pure"),p=e("../internals/global"),m=e("../internals/get-built-in"),y=e("../internals/native-promise-constructor"),v=e("../internals/redefine"),g=e("../internals/redefine-all"),b=e("../internals/set-to-string-tag"),w=e("../internals/set-species"),x=e("../internals/is-object"),_=e("../internals/a-function"),S=e("../internals/an-instance"),k=e("../internals/classof-raw"),E=e("../internals/inspect-source"),A=e("../internals/iterate"),j=e("../internals/check-correctness-of-iteration"),M=e("../internals/species-constructor"),T=e("../internals/task").set,P=e("../internals/microtask"),C=e("../internals/promise-resolve"),O=e("../internals/host-report-errors"),R=e("../internals/new-promise-capability"),I=e("../internals/perform"),L=e("../internals/internal-state"),N=e("../internals/is-forced"),D=e("../internals/well-known-symbol"),F=e("../internals/engine-v8-version"),U=D("species"),B="Promise",G=L.get,V=L.set,z=L.getterFor(B),q=y,H=p.TypeError,Z=p.document,W=p.process,K=m("fetch"),X=R.f,Y=X,Q="process"==k(W),J=!!(Z&&Z.createEvent&&p.dispatchEvent),$="unhandledrejection",ee=N(B,(function(){if(E(q)===String(q)){if(66===F)return!0;if(!Q&&"function"!=typeof PromiseRejectionEvent)return!0}if(h&&!q.prototype.finally)return!0;if(51<=F&&/native code/.test(q))return!1;function e(e){e((function(){}),(function(){}))}var t=q.resolve(1);return(t.constructor={})[U]=e,!(t.then((function(){}))instanceof e)})),te=ee||!j((function(e){q.all(e).catch((function(){}))})),re=function(e,t){T.call(p,(function(){var r,n=t.value;if(ne(t)&&(r=I((function(){Q?W.emit("unhandledRejection",n,e):o($,e,n)})),t.rejection=Q||ne(t)?2:1,r.error))throw r.value}))},ne=function(e){return 1!==e.rejection&&!e.parent},ie=function(e,t){T.call(p,(function(){Q?W.emit("rejectionHandled",e):o("rejectionhandled",e,t.value)}))},oe=function e(t,r,o,u){if(!r.done){r.done=!0,u&&(r=u);try{if(t===o)throw H("Promise can't be resolved itself");var l=n(o);l?P((function(){var n={done:!1};try{l.call(o,a(e,t,n,r),a(s,t,n,r))}catch(o){s(t,n,o,r)}})):(r.value=o,r.state=1,i(t,r,!1))}catch(o){s(t,{done:!1},o,r)}}};ee&&(q=function(e){S(this,q,B),_(e),u.call(this);var t=G(this);try{e(a(oe,this,t),a(s,this,t))}catch(e){s(this,t,e)}},(u=function(){V(this,{type:B,done:!1,notified:!1,parent:!1,reactions:[],rejection:!1,state:0,value:void 0})}).prototype=g(q.prototype,{then:function(e,t){var r=z(this),n=X(M(this,q));return n.ok="function"!=typeof e||e,n.fail="function"==typeof t&&t,n.domain=Q?W.domain:void 0,r.parent=!0,r.reactions.push(n),0!=r.state&&i(this,r,!1),n.promise},catch:function(e){return this.then(void 0,e)}}),l=function(){var e=new u,t=G(e);this.promise=e,this.resolve=a(oe,e,t),this.reject=a(s,e,t)},R.f=X=function(e){return e===q||e===c?new l(e):Y(e)},h||"function"!=typeof y||(f=y.prototype.then,v(y.prototype,"then",(function(e,t){var r=this;return new q((function(e,t){f.call(r,e,t)})).then(e,t)}),{unsafe:!0}),"function"==typeof K&&d({global:!0,enumerable:!0,forced:!0},{fetch:function(e){return C(q,K.apply(p,arguments))}}))),d({global:!0,wrap:!0,forced:ee},{Promise:q}),b(q,B,!1,!0),w(B),c=m(B),d({target:B,stat:!0,forced:ee},{reject:function(e){var t=X(this);return t.reject.call(void 0,e),t.promise}}),d({target:B,stat:!0,forced:h||ee},{resolve:function(e){return C(h&&this===c?q:this,e)}}),d({target:B,stat:!0,forced:te},{all:function(e){var t=this,r=X(t),n=r.resolve,i=r.reject,o=I((function(){var r=_(t.resolve),o=[],a=0,s=1;A(e,(function(e){var u=a++,l=!1;o.push(void 0),s++,r.call(t,e).then((function(e){l||(l=!0,o[u]=e,--s||n(o))}),i)})),--s||n(o)}));return o.error&&i(o.value),r.promise},race:function(e){var t=this,r=X(t),n=r.reject,i=I((function(){var i=_(t.resolve);A(e,(function(e){i.call(t,e).then(r.resolve,n)}))}));return i.error&&n(i.value),r.promise}})},{"../internals/a-function":5,"../internals/an-instance":9,"../internals/check-correctness-of-iteration":27,"../internals/classof-raw":28,"../internals/engine-v8-version":47,"../internals/export":49,"../internals/get-built-in":56,"../internals/global":59,"../internals/host-report-errors":62,"../internals/inspect-source":68,"../internals/internal-state":70,"../internals/is-forced":73,"../internals/is-object":74,"../internals/is-pure":75,"../internals/iterate":77,"../internals/microtask":81,"../internals/native-promise-constructor":82,"../internals/new-promise-capability":86,"../internals/perform":105,"../internals/promise-resolve":106,"../internals/redefine":108,"../internals/redefine-all":107,"../internals/set-species":116,"../internals/set-to-string-tag":117,"../internals/species-constructor":121,"../internals/task":128,"../internals/well-known-symbol":146}],179:[function(e,t,r){var n=e("../internals/export"),i=e("../internals/get-built-in"),o=e("../internals/a-function"),a=e("../internals/an-object"),s=e("../internals/is-object"),u=e("../internals/object-create"),l=e("../internals/function-bind"),c=e("../internals/fails"),f=i("Reflect","construct"),d=c((function(){function e(){}return!(f((function(){}),[],e)instanceof e)})),h=!c((function(){f((function(){}))})),p=d||h;n({target:"Reflect",stat:!0,forced:p,sham:p},{construct:function(e,t,r){o(e),a(t);var n=arguments.length<3?e:o(r);if(h&&!d)return f(e,t,n);if(e==n){switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3])}var i=[null];return i.push.apply(i,t),new(l.apply(e,i))}var c=n.prototype,p=u(s(c)?c:Object.prototype),m=Function.apply.call(e,p,t);return s(m)?m:p}})},{"../internals/a-function":5,"../internals/an-object":10,"../internals/export":49,"../internals/fails":50,"../internals/function-bind":55,"../internals/get-built-in":56,"../internals/is-object":74,"../internals/object-create":90}],180:[function(e,t,r){var n=e("../internals/descriptors"),i=e("../internals/global"),o=e("../internals/is-forced"),a=e("../internals/inherit-if-required"),s=e("../internals/object-define-property").f,u=e("../internals/object-get-own-property-names").f,l=e("../internals/is-regexp"),c=e("../internals/regexp-flags"),f=e("../internals/regexp-sticky-helpers"),d=e("../internals/redefine"),h=e("../internals/fails"),p=e("../internals/internal-state").set,m=e("../internals/set-species"),y=e("../internals/well-known-symbol")("match"),v=i.RegExp,g=v.prototype,b=/a/g,w=/a/g,x=new v(b)!==b,_=f.UNSUPPORTED_Y;if(n&&o("RegExp",!x||_||h((function(){return w[y]=!1,v(b)!=b||v(w)==w||"/a/i"!=v(b,"i")})))){for(var S=function(e){e in k||s(k,e,{configurable:!0,get:function(){return v[e]},set:function(t){v[e]=t}})},k=function e(t,r){var n,i=this instanceof e,o=l(t),s=void 0===r;if(!i&&o&&t.constructor===e&&s)return t;x?o&&!s&&(t=t.source):t instanceof e&&(s&&(r=c.call(t)),t=t.source),_&&(n=!!r&&-1A;)S(E[A++]);(g.constructor=k).prototype=g,d(i,"RegExp",k)}m("RegExp")},{"../internals/descriptors":42,"../internals/fails":50,"../internals/global":59,"../internals/inherit-if-required":67,"../internals/internal-state":70,"../internals/is-forced":73,"../internals/is-regexp":76,"../internals/object-define-property":92,"../internals/object-get-own-property-names":95,"../internals/redefine":108,"../internals/regexp-flags":111,"../internals/regexp-sticky-helpers":112,"../internals/set-species":116,"../internals/well-known-symbol":146}],181:[function(e,t,r){"use strict";var n=e("../internals/export"),i=e("../internals/regexp-exec");n({target:"RegExp",proto:!0,forced:/./.exec!==i},{exec:i})},{"../internals/export":49,"../internals/regexp-exec":110}],182:[function(e,t,r){"use strict";var n=e("../internals/redefine"),i=e("../internals/an-object"),o=e("../internals/fails"),a=e("../internals/regexp-flags"),s="toString",u=RegExp.prototype,l=u[s],c=o((function(){return"/a/b"!=l.call({source:"a",flags:"b"})})),f=l.name!=s;(c||f)&&n(RegExp.prototype,s,(function(){var e=i(this),t=String(e.source),r=e.flags;return"/"+t+"/"+String(void 0===r&&e instanceof RegExp&&!("flags"in u)?a.call(e):r)}),{unsafe:!0})},{"../internals/an-object":10,"../internals/fails":50,"../internals/redefine":108,"../internals/regexp-flags":111}],183:[function(e,t,r){"use strict";var n=e("../internals/collection"),i=e("../internals/collection-strong");t.exports=n("Set",(function(e){return function(t){return e(this,arguments.length?t:void 0)}}),i)},{"../internals/collection":31,"../internals/collection-strong":30}],184:[function(e,t,r){"use strict";var n,i=e("../internals/export"),o=e("../internals/object-get-own-property-descriptor").f,a=e("../internals/to-length"),s=e("../internals/not-a-regexp"),u=e("../internals/require-object-coercible"),l=e("../internals/correct-is-regexp-logic"),c=e("../internals/is-pure"),f="".endsWith,d=Math.min,h=l("endsWith");i({target:"String",proto:!0,forced:!(!c&&!h&&(n=o(String.prototype,"endsWith"))&&!n.writable)&&!h},{endsWith:function(e,t){var r=String(u(this));s(e);var n=1=r.length?{value:void 0,done:!0}:(e=n(r,i),t.index+=e.length,{value:e,done:!1})}))},{"../internals/define-iterator":40,"../internals/internal-state":70,"../internals/string-multibyte":123}],187:[function(e,t,r){"use strict";var n=e("../internals/fix-regexp-well-known-symbol-logic"),i=e("../internals/an-object"),o=e("../internals/to-length"),a=e("../internals/require-object-coercible"),s=e("../internals/advance-string-index"),u=e("../internals/regexp-exec-abstract");n("match",1,(function(e,t,r){return[function(t){var r=a(this),n=null==t?void 0:t[e];return void 0!==n?n.call(t,r):new RegExp(t)[e](String(r))},function(e){var n=r(t,e,this);if(n.done)return n.value;var a=i(e),l=String(this);if(!a.global)return u(a,l);for(var c,f=a.unicode,d=[],h=a.lastIndex=0;null!==(c=u(a,l));){var p=String(c[0]);""===(d[h]=p)&&(a.lastIndex=s(l,o(a.lastIndex),f)),h++}return 0===h?null:d}]}))},{"../internals/advance-string-index":8,"../internals/an-object":10,"../internals/fix-regexp-well-known-symbol-logic":51,"../internals/regexp-exec-abstract":109,"../internals/require-object-coercible":113,"../internals/to-length":134}],188:[function(e,t,r){e("../internals/export")({target:"String",proto:!0},{repeat:e("../internals/string-repeat")})},{"../internals/export":49,"../internals/string-repeat":125}],189:[function(e,t,r){"use strict";var n=e("../internals/fix-regexp-well-known-symbol-logic"),i=e("../internals/an-object"),o=e("../internals/to-object"),a=e("../internals/to-length"),s=e("../internals/to-integer"),u=e("../internals/require-object-coercible"),l=e("../internals/advance-string-index"),c=e("../internals/regexp-exec-abstract"),f=Math.max,d=Math.min,h=Math.floor,p=/\$([$&'`]|\d\d?|<[^>]*>)/g,m=/\$([$&'`]|\d\d?)/g;n("replace",2,(function(e,t,r,n){var y=n.REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE,v=n.REPLACE_KEEPS_$0,g=y?"$":"$0";return[function(r,n){var i=u(this),o=null==r?void 0:r[e];return void 0!==o?o.call(r,i,n):t.call(String(i),r,n)},function(e,n){if(!y&&v||"string"==typeof n&&-1===n.indexOf(g)){var o=r(t,e,this,n);if(o.done)return o.value}var u=i(e),h=String(this),p="function"==typeof n;p||(n=String(n));var m=u.global;if(m){var w=u.unicode;u.lastIndex=0}for(var x=[];;){var _=c(u,h);if(null===_)break;if(x.push(_),!m)break;""===String(_[0])&&(u.lastIndex=l(h,a(u.lastIndex),w))}for(var S,k="",E=0,A=0;A>>0;if(0==o)return[];if(void 0===e)return[n];if(!i(e))return t.call(n,e,o);for(var s,u,l,c=[],d=(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")+(e.sticky?"y":""),p=0,y=new RegExp(e.source,d+"g");(s=f.call(y,n))&&!(p<(u=y.lastIndex)&&(c.push(n.slice(p,s.index)),1=o));)y.lastIndex===s.index&&y.lastIndex++;return p===n.length?!l&&y.test("")||c.push(""):c.push(n.slice(p)),c.length>o?c.slice(0,o):c}:"0".split(void 0,0).length?function(e,r){return void 0===e&&0===r?[]:t.call(this,e,r)}:t,[function(t,r){var i=a(this),o=null==t?void 0:t[e];return void 0!==o?o.call(t,i,r):n.call(String(i),t,r)},function(e,i){var a=r(n,e,this,i,n!==t);if(a.done)return a.value;var f=o(e),d=String(this),h=s(f,RegExp),v=f.unicode,g=(f.ignoreCase?"i":"")+(f.multiline?"m":"")+(f.unicode?"u":"")+(y?"y":"g"),b=new h(y?f:"^(?:"+f.source+")",g),w=void 0===i?m:i>>>0;if(0==w)return[];if(0===d.length)return null===c(b,d)?[d]:[];for(var x=0,_=0,S=[];_e.key){i.splice(t,0,e);break}t===r&&i.push(e)}n.updateURL()},forEach:function(e,t){for(var r,n=L(this).entries,i=w(e,1=I(256,5-t))return null}else if(255":1,"`":1}),$=x({},J,{"#":1,"?":1,"{":1,"}":1}),ee=x({},$,{"/":1,":":1,";":1,"=":1,"@":1,"[":1,"\\":1,"]":1,"^":1,"|":1}),te=function(e,t){var r=S(e,0);return 32>1,c=-7,f=r?i-1:0,d=r?-1:1,h=e[t+f];for(f+=d,o=h&(1<<-c)-1,h>>=-c,c+=s;0>=-c,c+=n;0>1,d=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,h=n?0:o-1,p=n?1:-1,m=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=c):(a=Math.floor(Math.log(t)/Math.LN2),t*(u=Math.pow(2,-a))<1&&(a--,u*=2),2<=(t+=1<=a+f?d/u:d*Math.pow(2,1-f))*u&&(a++,u/=2),c<=a+f?(s=0,a=c):1<=a+f?(s=(t*u-1)*Math.pow(2,i),a+=f):(s=t*Math.pow(2,f-1)*Math.pow(2,i),a=0));8<=i;e[r+h]=255&s,h+=p,s/=256,i-=8);for(a=a<Math.abs(e[0])&&(t=1),Math.abs(e[2])>Math.abs(e[t])&&(t=2),t}function E(e,t){e.f+=t.f,e.b.f+=t.b.f}function A(e,t,r){return e=e.a,t=t.a,r=r.a,t.b.a===e?r.b.a===e?o(t.a,r.a)?s(r.b.a,t.a,r.a)<=0:0<=s(t.b.a,r.a,t.a):s(r.b.a,e,r.a)<=0:r.b.a===e?0<=s(t.b.a,e,t.a):(t=a(t.b.a,e,t.a),(e=a(r.b.a,e,r.a))<=t)}function j(e){e.a.i=null;var t=e.e;t.a.c=t.c,t.c.a=t.a,e.e=null}function M(e,t){p(e.a),e.c=!1,(e.a=t).i=e}function T(e){for(var t=e.a.a;(e=fe(e)).a.a===t;);return e.c&&(M(e,t=y(ce(e).a.b,e.a.e)),e=fe(e)),e}function P(e,t,r){var n=new le;return n.a=r,n.e=q(e.f,t.e,n),r.i=n}function C(e,t){switch(e.s){case 100130:return 0!=(1&t);case 100131:return 0!==t;case 100132:return 0>1]],c[l[d]])?se(r,d):ue(r,d)),c[u]=null,f[u]=r.b,r.b=u}else for(r.c[-(u+1)]=null;0Math.max(y.a,g.a))return!1;if(o(p,y)){if(0n.f&&(n.f*=2,n.c=ie(n.c,n.f+1)),0===n.b?r=i:(r=n.b,n.b=n.c[n.b]),n.e[r]=t,n.c[r]=i,n.d[i]=r,n.h&&ue(n,i),r}return n=e.a++,e.c[n]=t,-(n+1)}function re(e){if(0===e.a)return ae(e.b);var t=e.c[e.d[e.a-1]];if(0!==e.b.a&&o(oe(e.b),t))return ae(e.b);for(;--e.a,0e.a||o(n[s],n[l])){i[r[a]=s]=a;break}i[r[a]=l]=a,a=u}}function ue(e,t){for(var r=e.d,n=e.e,i=e.c,a=t,s=r[a];;){var u=a>>1,l=r[u];if(0==u||o(n[l],n[s])){i[r[a]=s]=a;break}i[r[a]=l]=a,a=u}}function le(){this.e=this.a=null,this.f=0,this.c=this.b=this.h=this.d=!1}function ce(e){return e.e.c.b}function fe(e){return e.e.a.b}(n=Z.prototype).x=function(){W(this,0)},n.B=function(e,t){switch(e){case 100142:return;case 100140:switch(t){case 100130:case 100131:case 100132:case 100133:case 100134:return void(this.s=t)}break;case 100141:return void(this.m=!!t);default:return void K(this,100900)}K(this,100901)},n.y=function(e){switch(e){case 100142:return 0;case 100140:return this.s;case 100141:return this.m;default:K(this,100900)}return!1},n.A=function(e,t,r){this.j[0]=e,this.j[1]=t,this.j[2]=r},n.z=function(e,t){var r=t||null;switch(e){case 100100:case 100106:this.h=r;break;case 100104:case 100110:this.l=r;break;case 100101:case 100107:this.k=r;break;case 100102:case 100108:this.i=r;break;case 100103:case 100109:this.p=r;break;case 100105:case 100111:this.o=r;break;case 100112:this.r=r;break;default:K(this,100900)}},n.C=function(e,t){var r=!1,n=[0,0,0];W(this,2);for(var i=0;i<3;++i){var o=e[i];o<-1e150&&(o=-1e150,r=!0),1e150a[d]&&(a[d]=h,l[d]=f)}if(f=0,a[1]-u[1]>a[0]-u[0]&&(f=1),a[2]-u[2]>a[f]-u[f]&&(f=2),u[f]>=a[f])n[0]=0,n[1]=0,n[2]=1;else{for(a=0,u=c[f],l=l[f],c=[0,0,0],u=[u.g[0]-l.g[0],u.g[1]-l.g[1],u.g[2]-l.g[2]],d=[0,0,0],f=r.e;f!==r;f=f.e)d[0]=f.g[0]-l.g[0],d[1]=f.g[1]-l.g[1],d[2]=f.g[2]-l.g[2],c[0]=u[1]*d[2]-u[2]*d[1],c[1]=u[2]*d[0]-u[0]*d[2],c[2]=u[0]*d[1]-u[1]*d[0],a<(h=c[0]*c[0]+c[1]*c[1]+c[2]*c[2])&&(a=h,n[0]=c[0],n[1]=c[1],n[2]=c[2]);a<=0&&(n[0]=n[1]=n[2]=0,n[k(u)]=1)}r=!0}for(c=k(n),f=this.b.c,a=(c+1)%3,l=(c+2)%3,c=0>=u,c-=u,y!=o){if(y==a)break;for(var v=y>8,++g;var w=b;if(n>=8;null!==m&&s<4096&&(p[s++]=m<<8|w,l+1<=s&&u<12&&(++u,l=l<<1|1)),m=y}else s=1+a,l=(1<<(u=i+1))-1,m=null}return d!==n&&console.log("Warning, gif stream shorter than expected."),r}try{r.GifWriter=function(e,t,r,n){var i=0,o=void 0===(n=void 0===n?{}:n).loop?null:n.loop,a=void 0===n.palette?null:n.palette;if(t<=0||r<=0||65535>=1;)++u;if(c=1<>8&255,e[i++]=255&r,e[i++]=r>>8&255,e[i++]=(null!==a?128:0)|u,e[i++]=l,e[i++]=0,null!==a)for(var f=0,d=a.length;f>16&255,e[i++]=h>>8&255,e[i++]=255&h}if(null!==o){if(o<0||65535>8&255,e[i++]=0}var p=!1;this.addFrame=function(t,r,n,o,u,l){if(!0===p&&(--i,p=!1),l=void 0===l?{}:l,t<0||r<0||65535>=1;)++h;d=1<>8&255,e[i++]=g,e[i++]=0),e[i++]=44,e[i++]=255&t,e[i++]=t>>8&255,e[i++]=255&r,e[i++]=r>>8&255,e[i++]=255&n,e[i++]=n>>8&255,e[i++]=255&o,e[i++]=o>>8&255,e[i++]=!0===c?128|h-1:0,!0===c)for(var b=0,w=f.length;b>16&255,e[i++]=x>>8&255,e[i++]=255&x}return i=function(e,t,r,n){e[t++]=r;var i=t++,o=1<>=8,c-=8,t===i+256&&(e[i]=255,i=t++)}function h(e){f|=e<>=8,c-=8,t===i+256&&(e[i]=255,i=t++);4096===u?(h(o),u=1+s,l=r+1,m={}):(1<>7,s=1<<1+(7&o);e[t++],e[t++];var u=null,l=null;a&&(u=t,t+=3*(l=s));var c=!0,f=[],d=0,h=null,p=0,m=null;for(this.width=r,this.height=i;c&&t>2&7,t++;break;case 254:for(;;){if(!(0<=(j=e[t++])))throw Error("Invalid block size");if(0===j)break;t+=j}break;default:throw new Error("Unknown graphic control label: 0x"+e[t-1].toString(16))}break;case 44:var v=e[t++]|e[t++]<<8,g=e[t++]|e[t++]<<8,b=e[t++]|e[t++]<<8,w=e[t++]|e[t++]<<8,x=e[t++],_=x>>6&1,S=u,k=l,E=!1;x>>7&&(E=!0,S=t,t+=3*(k=1<<1+(7&x)));var A=t;for(t++;;){var j;if(!(0<=(j=e[t++])))throw Error("Invalid block size");if(0===j)break;t+=j}f.push({x:v,y:g,width:b,height:w,has_local_palette:E,palette_offset:S,palette_size:k,data_offset:A,data_length:t-A,transparent_index:h,interlaced:!!_,delay:d,disposal:p});break;case 59:c=!1;break;default:throw new Error("Unknown gif block: 0x"+e[t-1].toString(16))}this.numFrames=function(){return f.length},this.loopCount=function(){return m},this.frameInfo=function(e){if(e<0||e>=f.length)throw new Error("Frame index out of range.");return f[e]},this.decodeAndBlitFrameBGRA=function(t,i){var o=this.frameInfo(t),a=o.width*o.height,s=new Uint8Array(a);n(e,o.data_offset,s,a);var u=o.palette_offset,l=o.transparent_index;null===l&&(l=256);var c=o.width,f=r-c,d=c,h=4*(o.y*r+o.x),p=4*((o.y+o.height)*r+o.x),m=h,y=4*f;!0===o.interlaced&&(y+=4*r*7);for(var v=8,g=0,b=s.length;g>=1)),w===l)m+=4;else{var x=e[u+3*w],_=e[u+3*w+1],S=e[u+3*w+2];i[m++]=S,i[m++]=_,i[m++]=x,i[m++]=255}--d}},this.decodeAndBlitFrameRGBA=function(t,i){var o=this.frameInfo(t),a=o.width*o.height,s=new Uint8Array(a);n(e,o.data_offset,s,a);var u=o.palette_offset,l=o.transparent_index;null===l&&(l=256);var c=o.width,f=r-c,d=c,h=4*(o.y*r+o.x),p=4*((o.y+o.height)*r+o.x),m=h,y=4*f;!0===o.interlaced&&(y+=4*r*7);for(var v=8,g=0,b=s.length;g>=1)),w===l)m+=4;else{var x=e[u+3*w],_=e[u+3*w+1],S=e[u+3*w+2];i[m++]=x,i[m++]=_,i[m++]=S,i[m++]=255}--d}}}}catch(e){}},{}],239:[function(t,r,n){(function(i){var o,a;o=this,a=function(e){"use strict";function r(e){if(null==this)throw TypeError();var t=String(this),r=t.length,n=e?Number(e):0;if(n!=n&&(n=0),!(n<0||r<=n)){var i,o=t.charCodeAt(n);return 55296<=o&&o<=56319&&n+1>>=1,t}function _(e,t,r){if(!t)return r;for(;e.bitcount<24;)e.tag|=e.source[e.sourceIndex++]<>>16-t;return e.tag>>>=t,e.bitcount-=t,n+r}function S(e,t){for(;e.bitcount<24;)e.tag|=e.source[e.sourceIndex++]<>>=1,++i,r+=t.table[i],0<=(n-=t.table[i]););return e.tag=o,e.bitcount-=i,t.trans[r+n]}function k(e,t,r){var n,i,o,a,s,u;for(n=_(e,5,257),i=_(e,5,1),o=_(e,4,4),a=0;a<19;++a)v[a]=0;for(a=0;athis.x2&&(this.x2=e)),"number"==typeof t&&((isNaN(this.y1)||isNaN(this.y2))&&(this.y1=t,this.y2=t),tthis.y2&&(this.y2=t))},T.prototype.addX=function(e){this.addPoint(e,null)},T.prototype.addY=function(e){this.addPoint(null,e)},T.prototype.addBezier=function(e,t,r,n,i,o,a,s){var u=[e,t],l=[r,n],c=[i,o],f=[a,s];this.addPoint(e,t),this.addPoint(a,s);for(var d=0;d<=1;d++){var h=6*u[d]-12*l[d]+6*c[d],p=-3*u[d]+9*l[d]-9*c[d]+3*f[d],m=3*l[d]-3*u[d];if(0!=p){var y=Math.pow(h,2)-4*m*p;if(!(y<0)){var v=(-h+Math.sqrt(y))/(2*p);0"},P.prototype.toDOMElement=function(e){var t=this.toPathData(e),r=document.createElementNS("http://www.w3.org/2000/svg","path");return r.setAttribute("d",t),r};var R={fail:C,argument:O,assert:O},I={},L={},N={};function D(e){return function(){return e}}L.BYTE=function(e){return R.argument(0<=e&&e<=255,"Byte value should be between 0 and 255."),[e]},N.BYTE=D(1),L.CHAR=function(e){return[e.charCodeAt(0)]},N.CHAR=D(1),L.CHARARRAY=function(e){for(var t=[],r=0;r>8&255,255&e]},N.USHORT=D(2),L.SHORT=function(e){return 32768<=e&&(e=-(65536-e)),[e>>8&255,255&e]},N.SHORT=D(2),L.UINT24=function(e){return[e>>16&255,e>>8&255,255&e]},N.UINT24=D(3),L.ULONG=function(e){return[e>>24&255,e>>16&255,e>>8&255,255&e]},N.ULONG=D(4),L.LONG=function(e){return 2147483648<=e&&(e=-(4294967296-e)),[e>>24&255,e>>16&255,e>>8&255,255&e]},N.LONG=D(4),L.FIXED=L.ULONG,N.FIXED=N.ULONG,L.FWORD=L.SHORT,N.FWORD=N.SHORT,L.UFWORD=L.USHORT,N.UFWORD=N.USHORT,L.LONGDATETIME=function(e){return[0,0,0,0,e>>24&255,e>>16&255,e>>8&255,255&e]},N.LONGDATETIME=D(8),L.TAG=function(e){return R.argument(4===e.length,"Tag should be exactly 4 ASCII characters."),[e.charCodeAt(0),e.charCodeAt(1),e.charCodeAt(2),e.charCodeAt(3)]},N.TAG=D(4),L.Card8=L.BYTE,N.Card8=N.BYTE,L.Card16=L.USHORT,N.Card16=N.USHORT,L.OffSize=L.BYTE,N.OffSize=N.BYTE,L.SID=L.USHORT,N.SID=N.USHORT,L.NUMBER=function(e){return-107<=e&&e<=107?[e+139]:108<=e&&e<=1131?[247+((e-=108)>>8),255&e]:-1131<=e&&e<=-108?[251+((e=-e-108)>>8),255&e]:-32768<=e&&e<=32767?L.NUMBER16(e):L.NUMBER32(e)},N.NUMBER=function(e){return L.NUMBER(e).length},L.NUMBER16=function(e){return[28,e>>8&255,255&e]},N.NUMBER16=D(3),L.NUMBER32=function(e){return[29,e>>24&255,e>>16&255,e>>8&255,255&e]},N.NUMBER32=D(5),L.REAL=function(e){var t=e.toString(),r=/\.(\d*?)(?:9{5,20}|0{5,20})\d{0,2}(?:e(.+)|$)/.exec(t);if(r){var n=parseFloat("1e"+((r[2]?+r[2]:0)+r[1].length));t=(Math.round(e*n)/n).toString()}for(var i="",o=0,a=t.length;o>8&255,t[t.length]=255&n}return t},N.UTF16=function(e){return 2*e.length};var F={"x-mac-croatian":"\xc4\xc5\xc7\xc9\xd1\xd6\xdc\xe1\xe0\xe2\xe4\xe3\xe5\xe7\xe9\xe8\xea\xeb\xed\xec\xee\xef\xf1\xf3\xf2\xf4\xf6\xf5\xfa\xf9\xfb\xfc\u2020\xb0\xa2\xa3\xa7\u2022\xb6\xdf\xae\u0160\u2122\xb4\xa8\u2260\u017d\xd8\u221e\xb1\u2264\u2265\u2206\xb5\u2202\u2211\u220f\u0161\u222b\xaa\xba\u03a9\u017e\xf8\xbf\xa1\xac\u221a\u0192\u2248\u0106\xab\u010c\u2026\xa0\xc0\xc3\xd5\u0152\u0153\u0110\u2014\u201c\u201d\u2018\u2019\xf7\u25ca\uf8ff\xa9\u2044\u20ac\u2039\u203a\xc6\xbb\u2013\xb7\u201a\u201e\u2030\xc2\u0107\xc1\u010d\xc8\xcd\xce\xcf\xcc\xd3\xd4\u0111\xd2\xda\xdb\xd9\u0131\u02c6\u02dc\xaf\u03c0\xcb\u02da\xb8\xca\xe6\u02c7","x-mac-cyrillic":"\u0410\u0411\u0412\u0413\u0414\u0415\u0416\u0417\u0418\u0419\u041a\u041b\u041c\u041d\u041e\u041f\u0420\u0421\u0422\u0423\u0424\u0425\u0426\u0427\u0428\u0429\u042a\u042b\u042c\u042d\u042e\u042f\u2020\xb0\u0490\xa3\xa7\u2022\xb6\u0406\xae\xa9\u2122\u0402\u0452\u2260\u0403\u0453\u221e\xb1\u2264\u2265\u0456\xb5\u0491\u0408\u0404\u0454\u0407\u0457\u0409\u0459\u040a\u045a\u0458\u0405\xac\u221a\u0192\u2248\u2206\xab\xbb\u2026\xa0\u040b\u045b\u040c\u045c\u0455\u2013\u2014\u201c\u201d\u2018\u2019\xf7\u201e\u040e\u045e\u040f\u045f\u2116\u0401\u0451\u044f\u0430\u0431\u0432\u0433\u0434\u0435\u0436\u0437\u0438\u0439\u043a\u043b\u043c\u043d\u043e\u043f\u0440\u0441\u0442\u0443\u0444\u0445\u0446\u0447\u0448\u0449\u044a\u044b\u044c\u044d\u044e","x-mac-gaelic":"\xc4\xc5\xc7\xc9\xd1\xd6\xdc\xe1\xe0\xe2\xe4\xe3\xe5\xe7\xe9\xe8\xea\xeb\xed\xec\xee\xef\xf1\xf3\xf2\xf4\xf6\xf5\xfa\xf9\xfb\xfc\u2020\xb0\xa2\xa3\xa7\u2022\xb6\xdf\xae\xa9\u2122\xb4\xa8\u2260\xc6\xd8\u1e02\xb1\u2264\u2265\u1e03\u010a\u010b\u1e0a\u1e0b\u1e1e\u1e1f\u0120\u0121\u1e40\xe6\xf8\u1e41\u1e56\u1e57\u027c\u0192\u017f\u1e60\xab\xbb\u2026\xa0\xc0\xc3\xd5\u0152\u0153\u2013\u2014\u201c\u201d\u2018\u2019\u1e61\u1e9b\xff\u0178\u1e6a\u20ac\u2039\u203a\u0176\u0177\u1e6b\xb7\u1ef2\u1ef3\u204a\xc2\xca\xc1\xcb\xc8\xcd\xce\xcf\xcc\xd3\xd4\u2663\xd2\xda\xdb\xd9\u0131\xdd\xfd\u0174\u0175\u1e84\u1e85\u1e80\u1e81\u1e82\u1e83","x-mac-greek":"\xc4\xb9\xb2\xc9\xb3\xd6\xdc\u0385\xe0\xe2\xe4\u0384\xa8\xe7\xe9\xe8\xea\xeb\xa3\u2122\xee\xef\u2022\xbd\u2030\xf4\xf6\xa6\u20ac\xf9\xfb\xfc\u2020\u0393\u0394\u0398\u039b\u039e\u03a0\xdf\xae\xa9\u03a3\u03aa\xa7\u2260\xb0\xb7\u0391\xb1\u2264\u2265\xa5\u0392\u0395\u0396\u0397\u0399\u039a\u039c\u03a6\u03ab\u03a8\u03a9\u03ac\u039d\xac\u039f\u03a1\u2248\u03a4\xab\xbb\u2026\xa0\u03a5\u03a7\u0386\u0388\u0153\u2013\u2015\u201c\u201d\u2018\u2019\xf7\u0389\u038a\u038c\u038e\u03ad\u03ae\u03af\u03cc\u038f\u03cd\u03b1\u03b2\u03c8\u03b4\u03b5\u03c6\u03b3\u03b7\u03b9\u03be\u03ba\u03bb\u03bc\u03bd\u03bf\u03c0\u03ce\u03c1\u03c3\u03c4\u03b8\u03c9\u03c2\u03c7\u03c5\u03b6\u03ca\u03cb\u0390\u03b0\xad","x-mac-icelandic":"\xc4\xc5\xc7\xc9\xd1\xd6\xdc\xe1\xe0\xe2\xe4\xe3\xe5\xe7\xe9\xe8\xea\xeb\xed\xec\xee\xef\xf1\xf3\xf2\xf4\xf6\xf5\xfa\xf9\xfb\xfc\xdd\xb0\xa2\xa3\xa7\u2022\xb6\xdf\xae\xa9\u2122\xb4\xa8\u2260\xc6\xd8\u221e\xb1\u2264\u2265\xa5\xb5\u2202\u2211\u220f\u03c0\u222b\xaa\xba\u03a9\xe6\xf8\xbf\xa1\xac\u221a\u0192\u2248\u2206\xab\xbb\u2026\xa0\xc0\xc3\xd5\u0152\u0153\u2013\u2014\u201c\u201d\u2018\u2019\xf7\u25ca\xff\u0178\u2044\u20ac\xd0\xf0\xde\xfe\xfd\xb7\u201a\u201e\u2030\xc2\xca\xc1\xcb\xc8\xcd\xce\xcf\xcc\xd3\xd4\uf8ff\xd2\xda\xdb\xd9\u0131\u02c6\u02dc\xaf\u02d8\u02d9\u02da\xb8\u02dd\u02db\u02c7","x-mac-inuit":"\u1403\u1404\u1405\u1406\u140a\u140b\u1431\u1432\u1433\u1434\u1438\u1439\u1449\u144e\u144f\u1450\u1451\u1455\u1456\u1466\u146d\u146e\u146f\u1470\u1472\u1473\u1483\u148b\u148c\u148d\u148e\u1490\u1491\xb0\u14a1\u14a5\u14a6\u2022\xb6\u14a7\xae\xa9\u2122\u14a8\u14aa\u14ab\u14bb\u14c2\u14c3\u14c4\u14c5\u14c7\u14c8\u14d0\u14ef\u14f0\u14f1\u14f2\u14f4\u14f5\u1505\u14d5\u14d6\u14d7\u14d8\u14da\u14db\u14ea\u1528\u1529\u152a\u152b\u152d\u2026\xa0\u152e\u153e\u1555\u1556\u1557\u2013\u2014\u201c\u201d\u2018\u2019\u1558\u1559\u155a\u155d\u1546\u1547\u1548\u1549\u154b\u154c\u1550\u157f\u1580\u1581\u1582\u1583\u1584\u1585\u158f\u1590\u1591\u1592\u1593\u1594\u1595\u1671\u1672\u1673\u1674\u1675\u1676\u1596\u15a0\u15a1\u15a2\u15a3\u15a4\u15a5\u15a6\u157c\u0141\u0142","x-mac-ce":"\xc4\u0100\u0101\xc9\u0104\xd6\xdc\xe1\u0105\u010c\xe4\u010d\u0106\u0107\xe9\u0179\u017a\u010e\xed\u010f\u0112\u0113\u0116\xf3\u0117\xf4\xf6\xf5\xfa\u011a\u011b\xfc\u2020\xb0\u0118\xa3\xa7\u2022\xb6\xdf\xae\xa9\u2122\u0119\xa8\u2260\u0123\u012e\u012f\u012a\u2264\u2265\u012b\u0136\u2202\u2211\u0142\u013b\u013c\u013d\u013e\u0139\u013a\u0145\u0146\u0143\xac\u221a\u0144\u0147\u2206\xab\xbb\u2026\xa0\u0148\u0150\xd5\u0151\u014c\u2013\u2014\u201c\u201d\u2018\u2019\xf7\u25ca\u014d\u0154\u0155\u0158\u2039\u203a\u0159\u0156\u0157\u0160\u201a\u201e\u0161\u015a\u015b\xc1\u0164\u0165\xcd\u017d\u017e\u016a\xd3\xd4\u016b\u016e\xda\u016f\u0170\u0171\u0172\u0173\xdd\xfd\u0137\u017b\u0141\u017c\u0122\u02c7",macintosh:"\xc4\xc5\xc7\xc9\xd1\xd6\xdc\xe1\xe0\xe2\xe4\xe3\xe5\xe7\xe9\xe8\xea\xeb\xed\xec\xee\xef\xf1\xf3\xf2\xf4\xf6\xf5\xfa\xf9\xfb\xfc\u2020\xb0\xa2\xa3\xa7\u2022\xb6\xdf\xae\xa9\u2122\xb4\xa8\u2260\xc6\xd8\u221e\xb1\u2264\u2265\xa5\xb5\u2202\u2211\u220f\u03c0\u222b\xaa\xba\u03a9\xe6\xf8\xbf\xa1\xac\u221a\u0192\u2248\u2206\xab\xbb\u2026\xa0\xc0\xc3\xd5\u0152\u0153\u2013\u2014\u201c\u201d\u2018\u2019\xf7\u25ca\xff\u0178\u2044\u20ac\u2039\u203a\ufb01\ufb02\u2021\xb7\u201a\u201e\u2030\xc2\xca\xc1\xcb\xc8\xcd\xce\xcf\xcc\xd3\xd4\uf8ff\xd2\xda\xdb\xd9\u0131\u02c6\u02dc\xaf\u02d8\u02d9\u02da\xb8\u02dd\u02db\u02c7","x-mac-romanian":"\xc4\xc5\xc7\xc9\xd1\xd6\xdc\xe1\xe0\xe2\xe4\xe3\xe5\xe7\xe9\xe8\xea\xeb\xed\xec\xee\xef\xf1\xf3\xf2\xf4\xf6\xf5\xfa\xf9\xfb\xfc\u2020\xb0\xa2\xa3\xa7\u2022\xb6\xdf\xae\xa9\u2122\xb4\xa8\u2260\u0102\u0218\u221e\xb1\u2264\u2265\xa5\xb5\u2202\u2211\u220f\u03c0\u222b\xaa\xba\u03a9\u0103\u0219\xbf\xa1\xac\u221a\u0192\u2248\u2206\xab\xbb\u2026\xa0\xc0\xc3\xd5\u0152\u0153\u2013\u2014\u201c\u201d\u2018\u2019\xf7\u25ca\xff\u0178\u2044\u20ac\u2039\u203a\u021a\u021b\u2021\xb7\u201a\u201e\u2030\xc2\xca\xc1\xcb\xc8\xcd\xce\xcf\xcc\xd3\xd4\uf8ff\xd2\xda\xdb\xd9\u0131\u02c6\u02dc\xaf\u02d8\u02d9\u02da\xb8\u02dd\u02db\u02c7","x-mac-turkish":"\xc4\xc5\xc7\xc9\xd1\xd6\xdc\xe1\xe0\xe2\xe4\xe3\xe5\xe7\xe9\xe8\xea\xeb\xed\xec\xee\xef\xf1\xf3\xf2\xf4\xf6\xf5\xfa\xf9\xfb\xfc\u2020\xb0\xa2\xa3\xa7\u2022\xb6\xdf\xae\xa9\u2122\xb4\xa8\u2260\xc6\xd8\u221e\xb1\u2264\u2265\xa5\xb5\u2202\u2211\u220f\u03c0\u222b\xaa\xba\u03a9\xe6\xf8\xbf\xa1\xac\u221a\u0192\u2248\u2206\xab\xbb\u2026\xa0\xc0\xc3\xd5\u0152\u0153\u2013\u2014\u201c\u201d\u2018\u2019\xf7\u25ca\xff\u0178\u011e\u011f\u0130\u0131\u015e\u015f\u2021\xb7\u201a\u201e\u2030\xc2\xca\xc1\xcb\xc8\xcd\xce\xcf\xcc\xd3\xd4\uf8ff\xd2\xda\xdb\xd9\uf8a0\u02c6\u02dc\xaf\u02d8\u02d9\u02da\xb8\u02dd\u02db\u02c7"};I.MACSTRING=function(e,t,r,n){var i=F[n];if(void 0!==i){for(var o="",a=0;a>8&255,u+256&255)}return o}L.MACSTRING=function(e,t){var r=function(e){if(!U)for(var t in U={},F)U[t]=new String(t);var r=U[e];if(void 0!==r){if(B){var n=B.get(r);if(void 0!==n)return n}var i=F[e];if(void 0!==i){for(var o={},a=0;a>8,t[f+1]=255&d,t=t.concat(n[c])}return t},N.TABLE=function(e){for(var t=0,r=e.fields.length,n=0;n>1,t.skip("uShort",3),e.glyphIndexMap={};for(var a=new ue.Parser(r,n+i+14),s=new ue.Parser(r,n+i+16+2*o),u=new ue.Parser(r,n+i+16+4*o),l=new ue.Parser(r,n+i+16+6*o),c=n+i+16+8*o,f=0;f>4,o=15&n;if(15==i)break;if(t+=r[i],15==o)break;t+=r[o]}return parseFloat(t)}(e);if(32<=t&&t<=246)return t-139;if(247<=t&&t<=250)return 256*(t-247)+e.parseByte()+108;if(251<=t&&t<=254)return 256*-(t-251)-e.parseByte()-108;throw new Error("Invalid b0 "+t)}function je(e,t,r){t=void 0!==t?t:0;var n=new ue.Parser(e,t),i=[],o=[];for(r=void 0!==r?r:e.length;n.relativeOffset>1,d.length=0,p=!0}return function r(l){for(var g,b,S,k,E,A,j,M,T,P,C,O,R=0;RMath.abs(O-v)?y=C+d.shift():v=O+d.shift(),f.curveTo(n,i,o,a,j,M),f.curveTo(T,P,C,O,y,v);break;default:console.log("Glyph "+t.index+": unknown operator 1200"+I),d.length=0}break;case 14:0>3;break;case 21:2>16),R+=2;break;case 29:E=d.pop()+e.gsubrsBias,(A=e.gsubrs[E])&&r(A);break;case 30:for(;0=r.begin&&e=he.length){var a=n.parseChar();r.names.push(n.parseString(a))}break;case 2.5:r.numberOfGlyphs=n.parseUShort(),r.offset=new Array(r.numberOfGlyphs);for(var s=0;st.value.tag?1:-1})),t.fields=t.fields.concat(n),t.fields=t.fields.concat(i),t}function vt(e,t,r){for(var n=0;n 123 are reserved for internal usage");h|=1<>>1,o=e[i].tag;if(o===t)return i;o>>1,o=e[i];if(o===t)return i;o>>1,a=(r=e[o]).start;if(a===t)return r;a(r=e[n-1]).end?0:r}function _t(e,t){this.font=e,this.tableName=t}function St(e){_t.call(this,e,"gpos")}function kt(e){_t.call(this,e,"gsub")}function Et(e,t){var r=e.length;if(r!==t.length)return!1;for(var n=0;nt.points.length-1||n.matchedPoints[1]>i.points.length-1)throw Error("Matched points out of range in "+t.name);var a=t.points[n.matchedPoints[0]],s=i.points[n.matchedPoints[1]],u={xScale:n.xScale,scale01:n.scale01,scale10:n.scale10,yScale:n.yScale,dx:0,dy:0};s=Ct([s],u)[0],u.dx=a.x-s.x,u.dy=a.y-s.y,o=Ct(i.points,u)}t.points=t.points.concat(o)}}return Ot(t.points)}(St.prototype=_t.prototype={searchTag:bt,binSearch:wt,getTable:function(e){var t=this.font.tables[this.tableName];return!t&&e&&(t=this.font.tables[this.tableName]=this.createDefaultTable()),t},getScriptNames:function(){var e=this.getTable();return e?e.scripts.map((function(e){return e.tag})):[]},getDefaultScriptName:function(){var e=this.getTable();if(e){for(var t=!1,r=0;r=s[l-1].tag,"Features must be added in alphabetical order."),o={tag:r,feature:{params:0,lookupListIndexes:[]}},s.push(o),a.push(l),o.feature}}},getLookupTables:function(e,t,r,n,i){var o=this.getFeatureTable(e,t,r,i),a=[];if(o){for(var s,u=o.lookupListIndexes,l=this.font.tables[this.tableName].lookups,c=0;c",u),r.stack.push(Math.round(64*u))}function gr(t,r){var n=r.stack,i=n.pop(),o=r.fv,a=r.pv,s=r.ppem,u=r.deltaBase+16*(t-1),l=r.deltaShift,c=r.z0;e.DEBUG&&console.log(r.step,"DELTAP["+t+"]",i,n);for(var f=0;f>4)===s){var p=(15&h)-8;0<=p&&p++,e.DEBUG&&console.log(r.step,"DELTAPFIX",d,"by",p*l);var m=c[d];o.setRelative(m,m,p*l,a)}}}function br(t,r){var n=r.stack,i=n.pop();e.DEBUG&&console.log(r.step,"ROUND[]"),n.push(64*r.round(i/64))}function wr(t,r){var n=r.stack,i=n.pop(),o=r.ppem,a=r.deltaBase+16*(t-1),s=r.deltaShift;e.DEBUG&&console.log(r.step,"DELTAC["+t+"]",i,n);for(var u=0;u>4)===o){var f=(15&c)-8;0<=f&&f++;var d=f*s;e.DEBUG&&console.log(r.step,"DELTACFIX",l,"by",d),r.cvt[l]+=d}}}function xr(t,r){var n,i,o=r.stack,a=o.pop(),s=o.pop(),u=r.z2[a],l=r.z1[s];e.DEBUG&&console.log(r.step,"SDPVTL["+t+"]",a,s),i=t?(n=u.y-l.y,l.x-u.x):(n=l.x-u.x,l.y-u.y),r.dpv=Yt(n,i)}function _r(t,r){var n=r.stack,i=r.prog,o=r.ip;e.DEBUG&&console.log(r.step,"PUSHB["+t+"]");for(var a=0;a":"_")+(i?"R":"_")+(0===o?"Gr":1===o?"Bl":2===o?"Wh":"")+"]",t?d+"("+a.cvt[d]+","+c+")":"",h,"(d =",s,"->",l*u,")"),a.rp1=a.rp0,a.rp2=h,r&&(a.rp0=h)}Ut.prototype.exec=function(t,r){if("number"!=typeof r)throw new Error("Point size is not a number!");if(!(2",i),u.interpolate(d,a,s,l),u.touch(d)}t.loop=1},pr.bind(void 0,0),pr.bind(void 0,1),function(t){for(var r=t.stack,n=t.rp0,i=t.z0[n],o=t.loop,a=t.fv,s=t.pv,u=t.z1;o--;){var l=r.pop(),c=u[l];e.DEBUG&&console.log(t.step,(1").concat(t,"");this.dummyDOM||(this.dummyDOM=document.getElementById(n).parentNode),this.descriptions?this.descriptions.fallbackElements||(this.descriptions.fallbackElements={}):this.descriptions={fallbackElements:{}},this.descriptions.fallbackElements[e]?this.descriptions.fallbackElements[e].innerHTML!==a&&(this.descriptions.fallbackElements[e].innerHTML=a):this._describeElementHTML("fallback",e,a),r===this.LABEL&&(this.descriptions.labelElements||(this.descriptions.labelElements={}),this.descriptions.labelElements[e]?this.descriptions.labelElements[e].innerHTML!==a&&(this.descriptions.labelElements[e].innerHTML=a):this._describeElementHTML("label",e,a))}},i.default.prototype._describeHTML=function(e,t){var r=this.canvas.id;if("fallback"===e){if(this.dummyDOM.querySelector("#".concat(r+o)))this.dummyDOM.querySelector("#"+r+s).insertAdjacentHTML("beforebegin",'

'));else{var n='

');this.dummyDOM.querySelector("#".concat(r,"accessibleOutput"))?this.dummyDOM.querySelector("#".concat(r,"accessibleOutput")).insertAdjacentHTML("beforebegin",n):this.dummyDOM.querySelector("#".concat(r)).innerHTML=n}return this.descriptions.fallback=this.dummyDOM.querySelector("#".concat(r).concat(a)),void(this.descriptions.fallback.innerHTML=t)}if("label"===e){if(this.dummyDOM.querySelector("#".concat(r+u)))this.dummyDOM.querySelector("#".concat(r+c))&&this.dummyDOM.querySelector("#".concat(r+c)).insertAdjacentHTML("beforebegin",'

'));else{var i='

');this.dummyDOM.querySelector("#".concat(r,"accessibleOutputLabel"))?this.dummyDOM.querySelector("#".concat(r,"accessibleOutputLabel")).insertAdjacentHTML("beforebegin",i):this.dummyDOM.querySelector("#"+r).insertAdjacentHTML("afterend",i)}return this.descriptions.label=this.dummyDOM.querySelector("#"+r+l),void(this.descriptions.label.innerHTML=t)}},i.default.prototype._describeElementHTML=function(e,t,r){var n=this.canvas.id;if("fallback"===e){if(this.dummyDOM.querySelector("#".concat(n+o)))this.dummyDOM.querySelector("#"+n+s)||this.dummyDOM.querySelector("#"+n+a).insertAdjacentHTML("afterend",'
Canvas elements and their descriptions
'));else{var i='
Canvas elements and their descriptions
');this.dummyDOM.querySelector("#".concat(n,"accessibleOutput"))?this.dummyDOM.querySelector("#".concat(n,"accessibleOutput")).insertAdjacentHTML("beforebegin",i):this.dummyDOM.querySelector("#"+n).innerHTML=i}var f=document.createElement("tr");return f.id=n+"_fte_"+t,this.dummyDOM.querySelector("#"+n+s).appendChild(f),this.descriptions.fallbackElements[t]=this.dummyDOM.querySelector("#".concat(n).concat("_fte_").concat(t)),void(this.descriptions.fallbackElements[t].innerHTML=r)}if("label"===e){if(this.dummyDOM.querySelector("#".concat(n+u)))this.dummyDOM.querySelector("#".concat(n+c))||this.dummyDOM.querySelector("#"+n+l).insertAdjacentHTML("afterend",'
'));else{var d='
');this.dummyDOM.querySelector("#".concat(n,"accessibleOutputLabel"))?this.dummyDOM.querySelector("#".concat(n,"accessibleOutputLabel")).insertAdjacentHTML("beforebegin",d):this.dummyDOM.querySelector("#"+n).insertAdjacentHTML("afterend",d)}var h=document.createElement("tr");h.id=n+"_lte_"+t,this.dummyDOM.querySelector("#"+n+c).appendChild(h),this.descriptions.labelElements[t]=this.dummyDOM.querySelector("#".concat(n).concat("_lte_").concat(t)),this.descriptions.labelElements[t].innerHTML=r}};var d=i.default;r.default=d},{"../core/main":264,"core-js/modules/es.array.concat":149,"core-js/modules/es.regexp.exec":181,"core-js/modules/es.string.ends-with":184,"core-js/modules/es.string.replace":189}],245:[function(e,t,r){"use strict";e("core-js/modules/es.array.concat"),e("core-js/modules/es.array.map"),Object.defineProperty(r,"__esModule",{value:!0}),r.default=void 0;var n,i=(n=e("../core/main"))&&n.__esModule?n:{default:n};i.default.prototype._updateGridOutput=function(e){if(this.dummyDOM.querySelector("#".concat(e,"_summary"))){var t=this._accessibleOutputs[e],r=function(e,t){var r="",n="",i=0;for(var o in t){var a=0;for(var s in t[o]){var u='
  • ').concat(t[o][s].color," ").concat(o,",");"line"===o?u+=" location = ".concat(t[o][s].pos,", length = ").concat(t[o][s].length," pixels"):(u+=" location = ".concat(t[o][s].pos),"point"!==o&&(u+=", area = ".concat(t[o][s].area," %")),u+="
  • "),r+=u,a++,i++}n=1').concat(t[a][s].color," ").concat(a,"
    "):'').concat(t[a][s].color," ").concat(a," midpoint"),i[t[a][s].loc.locY][t[a][s].loc.locX]?i[t[a][s].loc.locY][t[a][s].loc.locX]=i[t[a][s].loc.locY][t[a][s].loc.locX]+" "+u:i[t[a][s].loc.locY][t[a][s].loc.locX]=u,r++}for(var l in i){var c="";for(var f in i[l])c+="",void 0!==i[l][f]&&(c+=i[l][f]),c+="";n=n+c+""}return n}(e,this.ingredients.shapes);n!==t.summary.innerHTML&&(t.summary.innerHTML=n),i!==t.map.innerHTML&&(t.map.innerHTML=i),r.details!==t.shapeDetails.innerHTML&&(t.shapeDetails.innerHTML=r.details),this._accessibleOutputs[e]=t}};var o=i.default;r.default=o},{"../core/main":264,"core-js/modules/es.array.concat":149,"core-js/modules/es.array.map":161}],246:[function(e,t,r){"use strict";e("core-js/modules/es.array.concat"),e("core-js/modules/es.array.fill"),e("core-js/modules/es.array.map"),e("core-js/modules/es.number.to-fixed"),Object.defineProperty(r,"__esModule",{value:!0}),r.default=void 0;var n,i=(n=e("../core/main"))&&n.__esModule?n:{default:n};function o(e,t,r){return e[0]<.4*t?e[1]<.4*r?"top left":e[1]>.6*r?"bottom left":"mid left":e[0]>.6*t?e[1]<.4*r?"top right":e[1]>.6*r?"bottom right":"mid right":e[1]<.4*r?"top middle":e[1]>.6*r?"bottom middle":"middle"}function a(e,t,r){var n=Math.floor(e[0]/t*10),i=Math.floor(e[1]/r*10);return 10===n&&--n,10===i&&--i,{locX:n,locY:i}}i.default.prototype.textOutput=function(e){i.default._validateParameters("textOutput",arguments),this._accessibleOutputs.text||(this._accessibleOutputs.text=!0,this._createOutput("textOutput","Fallback"),e===this.LABEL&&(this._accessibleOutputs.textLabel=!0,this._createOutput("textOutput","Label")))},i.default.prototype.gridOutput=function(e){i.default._validateParameters("gridOutput",arguments),this._accessibleOutputs.grid||(this._accessibleOutputs.grid=!0,this._createOutput("gridOutput","Fallback"),e===this.LABEL&&(this._accessibleOutputs.gridLabel=!0,this._createOutput("gridOutput","Label")))},i.default.prototype._addAccsOutput=function(){return this._accessibleOutputs||(this._accessibleOutputs={text:!1,grid:!1,textLabel:!1,gridLabel:!1}),this._accessibleOutputs.grid||this._accessibleOutputs.text},i.default.prototype._createOutput=function(e,t){var r,n,i,o=this.canvas.id;this.ingredients||(this.ingredients={shapes:{},colors:{background:"white",fill:"white",stroke:"black"},pShapes:""}),this.dummyDOM||(this.dummyDOM=document.getElementById(o).parentNode);var a="";"Fallback"===t?(r=o+e,n=o+"accessibleOutput",this.dummyDOM.querySelector("#".concat(n))||(this.dummyDOM.querySelector("#".concat(o,"_Description"))?this.dummyDOM.querySelector("#".concat(o,"_Description")).insertAdjacentHTML("afterend",'
    ')):this.dummyDOM.querySelector("#".concat(o)).innerHTML='
    '))):"Label"===t&&(r=o+e+(a=t),n=o+"accessibleOutput"+t,this.dummyDOM.querySelector("#".concat(n))||(this.dummyDOM.querySelector("#".concat(o,"_Label"))?this.dummyDOM.querySelector("#".concat(o,"_Label")).insertAdjacentHTML("afterend",'
    ')):this.dummyDOM.querySelector("#".concat(o)).insertAdjacentHTML("afterend",'
    ')))),this._accessibleOutputs[r]={},"textOutput"===e?(a="#".concat(o,"gridOutput").concat(a),i='
    Text Output

      '),this.dummyDOM.querySelector(a)?this.dummyDOM.querySelector(a).insertAdjacentHTML("beforebegin",i):this.dummyDOM.querySelector("#".concat(n)).innerHTML=i,this._accessibleOutputs[r].list=this.dummyDOM.querySelector("#".concat(r,"_list"))):"gridOutput"===e&&(a="#".concat(o,"textOutput").concat(a),i='
      Grid Output

        '),this.dummyDOM.querySelector(a)?this.dummyDOM.querySelector(a).insertAdjacentHTML("afterend",i):this.dummyDOM.querySelector("#".concat(n)).innerHTML=i,this._accessibleOutputs[r].map=this.dummyDOM.querySelector("#".concat(r,"_map"))),this._accessibleOutputs[r].shapeDetails=this.dummyDOM.querySelector("#".concat(r,"_shapeDetails")),this._accessibleOutputs[r].summary=this.dummyDOM.querySelector("#".concat(r,"_summary"))},i.default.prototype._updateAccsOutput=function(){var e=this.canvas.id;JSON.stringify(this.ingredients.shapes)!==this.ingredients.pShapes&&(this.ingredients.pShapes=JSON.stringify(this.ingredients.shapes),this._accessibleOutputs.text&&this._updateTextOutput(e+"textOutput"),this._accessibleOutputs.grid&&this._updateGridOutput(e+"gridOutput"),this._accessibleOutputs.textLabel&&this._updateTextOutput(e+"textOutputLabel"),this._accessibleOutputs.gridLabel&&this._updateGridOutput(e+"gridOutputLabel"))},i.default.prototype._accsBackground=function(e){this.ingredients.pShapes=JSON.stringify(this.ingredients.shapes),this.ingredients.shapes={},this.ingredients.colors.backgroundRGBA!==e&&(this.ingredients.colors.backgroundRGBA=e,this.ingredients.colors.background=this._rgbColorName(e))},i.default.prototype._accsCanvasColors=function(e,t){"fill"===e?this.ingredients.colors.fillRGBA!==t&&(this.ingredients.colors.fillRGBA=t,this.ingredients.colors.fill=this._rgbColorName(t)):"stroke"===e&&this.ingredients.colors.strokeRGBA!==t&&(this.ingredients.colors.strokeRGBA=t,this.ingredients.colors.stroke=this._rgbColorName(t))},i.default.prototype._accsOutput=function(e,t){"ellipse"===e&&t[2]===t[3]?e="circle":"rectangle"===e&&t[2]===t[3]&&(e="square");var r={},n=!0,i=function(e,t){var r,n;return n="rectangle"===e||"ellipse"===e||"arc"===e||"circle"===e||"square"===e?(r=Math.round(t[0]+t[2]/2),Math.round(t[1]+t[3]/2)):"triangle"===e?(r=(t[0]+t[2]+t[4])/3,(t[1]+t[3]+t[5])/3):"quadrilateral"===e?(r=(t[0]+t[2]+t[4]+t[6])/4,(t[1]+t[3]+t[5]+t[7])/4):"line"===e?(r=(t[0]+t[2])/2,(t[1]+t[3])/2):(r=t[0],t[1]),[r,n]}(e,t);if("line"===e){r.color=this.ingredients.colors.stroke,r.length=Math.round(this.dist(t[0],t[1],t[2],t[3]));var s=o([t[0],[1]],this.width,this.height),u=o([t[2],[3]],this.width,this.height);r.loc=a(i,this.width,this.height),r.pos=s===u?"at ".concat(s):"from ".concat(s," to ").concat(u)}else"point"===e?r.color=this.ingredients.colors.stroke:(r.color=this.ingredients.colors.fill,r.area=function(e,t,r,n){var i=0;if("arc"===e){var o=((t[5]-t[4])%(2*Math.PI)+2*Math.PI)%(2*Math.PI);if(i=o*t[2]*t[3]/8,"open"===t[6]||"chord"===t[6]){var a=t[0],s=t[1],u=t[0]+t[2]/2*Math.cos(t[4]).toFixed(2),l=t[1]+t[3]/2*Math.sin(t[4]).toFixed(2),c=t[0]+t[2]/2*Math.cos(t[5]).toFixed(2),f=t[1]+t[3]/2*Math.sin(t[5]).toFixed(2),d=Math.abs(a*(l-f)+u*(f-s)+c*(s-l))/2;o>Math.PI?i+=d:i-=d}}else"ellipse"===e||"circle"===e?i=3.14*t[2]/2*t[3]/2:"line"===e||"point"===e?i=0:"quadrilateral"===e?i=Math.abs((t[6]+t[0])*(t[7]-t[1])+(t[0]+t[2])*(t[1]-t[3])+(t[2]+t[4])*(t[3]-t[5])+(t[4]+t[6])*(t[5]-t[7]))/2:"rectangle"===e||"square"===e?i=t[2]*t[3]:"triangle"===e&&(i=Math.abs(t[0]*(t[3]-t[5])+t[2]*(t[5]-t[1])+t[4]*(t[1]-t[3]))/2);return Math.round(100*i/(r*n))}(e,t,this.width,this.height)),r.pos=o(i,this.width,this.height),r.loc=a(i,this.width,this.height);if(this.ingredients.shapes[e]){if(this.ingredients.shapes[e]!==[r]){for(var l in this.ingredients.shapes[e])JSON.stringify(this.ingredients.shapes[e][l])===JSON.stringify(r)&&(n=!1);!0===n&&this.ingredients.shapes[e].push(r)}}else this.ingredients.shapes[e]=[r]};var s=i.default;r.default=s},{"../core/main":264,"core-js/modules/es.array.concat":149,"core-js/modules/es.array.fill":151,"core-js/modules/es.array.map":161,"core-js/modules/es.number.to-fixed":172}],247:[function(e,t,r){"use strict";e("core-js/modules/es.array.concat"),Object.defineProperty(r,"__esModule",{value:!0}),r.default=void 0;var n,i=(n=e("../core/main"))&&n.__esModule?n:{default:n};i.default.prototype._updateTextOutput=function(e){if(this.dummyDOM.querySelector("#".concat(e,"_summary"))){var t=this._accessibleOutputs[e],r=function(e,t){var r="",n=0;for(var i in t)for(var o in t[i]){var a='
      • ').concat(t[i][o].color," ").concat(i,"");"line"===i?a+=", ".concat(t[i][o].pos,", ").concat(t[i][o].length," pixels long.
      • "):(a+=", at ".concat(t[i][o].pos),"point"!==i&&(a+=", covering ".concat(t[i][o].area,"% of the canvas")),a+="."),r+=a,n++}return{numShapes:n,listShapes:r}}(e,this.ingredients.shapes),n=function(e,t,r,n){var i="Your output is a, ".concat(r," by ").concat(n," pixels, ").concat(t," canvas containing the following");return i=1===e?"".concat(i," shape:"):"".concat(i," ").concat(e," shapes:")}(r.numShapes,this.ingredients.colors.background,this.width,this.height),i=function(e,t){var r="",n=0;for(var i in t)for(var o in t[i]){var a='').concat(t[i][o].color," ").concat(i,"");"line"===i?a+="location = ".concat(t[i][o].pos,"length = ").concat(t[i][o].length," pixels"):(a+="location = ".concat(t[i][o].pos,""),"point"!==i&&(a+=" area = ".concat(t[i][o].area,"%")),a+=""),r+=a,n++}return r}(e,this.ingredients.shapes);n!==t.summary.innerHTML&&(t.summary.innerHTML=n),r.listShapes!==t.list.innerHTML&&(t.list.innerHTML=r.listShapes),i!==t.shapeDetails.innerHTML&&(t.shapeDetails.innerHTML=i),this._accessibleOutputs[e]=t}};var o=i.default;r.default=o},{"../core/main":264,"core-js/modules/es.array.concat":149}],248:[function(e,t,r){"use strict";var n,i=(n=e("./core/main"))&&n.__esModule?n:{default:n};e("./core/constants"),e("./core/environment"),e("./core/friendly_errors/stacktrace"),e("./core/friendly_errors/validate_params"),e("./core/friendly_errors/file_errors"),e("./core/friendly_errors/fes_core"),e("./core/friendly_errors/sketch_reader"),e("./core/helpers"),e("./core/legacy"),e("./core/preload"),e("./core/p5.Element"),e("./core/p5.Graphics"),e("./core/p5.Renderer"),e("./core/p5.Renderer2D"),e("./core/rendering"),e("./core/shim"),e("./core/structure"),e("./core/transform"),e("./core/shape/2d_primitives"),e("./core/shape/attributes"),e("./core/shape/curves"),e("./core/shape/vertex"),e("./accessibility/outputs"),e("./accessibility/textOutput"),e("./accessibility/gridOutput"),e("./accessibility/color_namer"),e("./color/color_conversion"),e("./color/creating_reading"),e("./color/p5.Color"),e("./color/setting"),e("./data/p5.TypedDict"),e("./data/local_storage.js"),e("./dom/dom"),e("./accessibility/describe"),e("./events/acceleration"),e("./events/keyboard"),e("./events/mouse"),e("./events/touch"),e("./image/filters"),e("./image/image"),e("./image/loading_displaying"),e("./image/p5.Image"),e("./image/pixels"),e("./io/files"),e("./io/p5.Table"),e("./io/p5.TableRow"),e("./io/p5.XML"),e("./math/calculation"),e("./math/math"),e("./math/noise"),e("./math/p5.Vector"),e("./math/random"),e("./math/trigonometry"),e("./typography/attributes"),e("./typography/loading_displaying"),e("./typography/p5.Font"),e("./utilities/array_functions"),e("./utilities/conversion"),e("./utilities/string_functions"),e("./utilities/time_date"),e("./webgl/3d_primitives"),e("./webgl/interaction"),e("./webgl/light"),e("./webgl/loading"),e("./webgl/material"),e("./webgl/p5.Camera"),e("./webgl/p5.Geometry"),e("./webgl/p5.Matrix"),e("./webgl/p5.RendererGL.Immediate"),e("./webgl/p5.RendererGL"),e("./webgl/p5.RendererGL.Retained"),e("./webgl/p5.Shader"),e("./webgl/p5.RenderBuffer"),e("./webgl/p5.Texture"),e("./webgl/text"),e("./core/init"),t.exports=i.default},{"./accessibility/color_namer":243,"./accessibility/describe":244,"./accessibility/gridOutput":245,"./accessibility/outputs":246,"./accessibility/textOutput":247,"./color/color_conversion":249,"./color/creating_reading":250,"./color/p5.Color":251,"./color/setting":252,"./core/constants":253,"./core/environment":254,"./core/friendly_errors/fes_core":255,"./core/friendly_errors/file_errors":256,"./core/friendly_errors/sketch_reader":257,"./core/friendly_errors/stacktrace":258,"./core/friendly_errors/validate_params":259,"./core/helpers":260,"./core/init":261,"./core/legacy":263,"./core/main":264,"./core/p5.Element":265,"./core/p5.Graphics":266,"./core/p5.Renderer":267,"./core/p5.Renderer2D":268,"./core/preload":269,"./core/rendering":270,"./core/shape/2d_primitives":271,"./core/shape/attributes":272,"./core/shape/curves":273,"./core/shape/vertex":274,"./core/shim":275,"./core/structure":276,"./core/transform":277,"./data/local_storage.js":278,"./data/p5.TypedDict":279,"./dom/dom":280,"./events/acceleration":281,"./events/keyboard":282,"./events/mouse":283,"./events/touch":284,"./image/filters":285,"./image/image":286,"./image/loading_displaying":287,"./image/p5.Image":288,"./image/pixels":289,"./io/files":290,"./io/p5.Table":291,"./io/p5.TableRow":292,"./io/p5.XML":293,"./math/calculation":294,"./math/math":295,"./math/noise":296,"./math/p5.Vector":297,"./math/random":298,"./math/trigonometry":299,"./typography/attributes":300,"./typography/loading_displaying":301,"./typography/p5.Font":302,"./utilities/array_functions":303,"./utilities/conversion":304,"./utilities/string_functions":305,"./utilities/time_date":306,"./webgl/3d_primitives":307,"./webgl/interaction":308,"./webgl/light":309,"./webgl/loading":310,"./webgl/material":311,"./webgl/p5.Camera":312,"./webgl/p5.Geometry":313,"./webgl/p5.Matrix":314,"./webgl/p5.RenderBuffer":315,"./webgl/p5.RendererGL":318,"./webgl/p5.RendererGL.Immediate":316,"./webgl/p5.RendererGL.Retained":317,"./webgl/p5.Shader":319,"./webgl/p5.Texture":320,"./webgl/text":321}],249:[function(e,t,r){"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.default=void 0;var n,i=(n=e("../core/main"))&&n.__esModule?n:{default:n};i.default.ColorConversion={},i.default.ColorConversion._hsbaToHSLA=function(e){var t=e[0],r=e[1],n=e[2],i=(2-r)*n/2;return 0!=i&&(1==i?r=0:i<.5?r/=2-r:r=r*n/(2-2*i)),[t,r,i,e[3]]},i.default.ColorConversion._hsbaToRGBA=function(e){var t=6*e[0],r=e[1],n=e[2],i=[];if(0===r)i=[n,n,n,e[3]];else{var o,a,s,u=Math.floor(t),l=n*(1-r),c=n*(1-r*(t-u)),f=n*(1-r*(1+u-t));s=1===u?(o=c,a=n,l):2===u?(o=l,a=n,f):3===u?(o=l,a=c,n):4===u?(o=f,a=l,n):5===u?(o=n,a=l,c):(o=n,a=f,l),i=[o,a,s,e[3]]}return i},i.default.ColorConversion._hslaToHSBA=function(e){var t,r=e[0],n=e[1],i=e[2];return[r,n=2*((t=i<.5?(1+n)*i:i+n-i*n)-i)/t,t,e[3]]},i.default.ColorConversion._hslaToRGBA=function(e){var t=6*e[0],r=e[1],n=e[2],i=[];if(0===r)i=[n,n,n,e[3]];else{var o,a=2*n-(o=n<.5?(1+r)*n:n+r-n*r),s=function(e,t,r){return e<0?e+=6:6<=e&&(e-=6),e<1?t+(r-t)*e:e<3?r:e<4?t+(r-t)*(4-e):t};i=[s(2+t,a,o),s(t,a,o),s(t-2,a,o),e[3]]}return i},i.default.ColorConversion._rgbaToHSBA=function(e){var t,r,n=e[0],i=e[1],o=e[2],a=Math.max(n,i,o),s=a-Math.min(n,i,o);return 0==s?r=t=0:(r=s/a,n===a?t=(i-o)/s:i===a?t=2+(o-n)/s:o===a&&(t=4+(n-i)/s),t<0?t+=6:6<=t&&(t-=6)),[t/6,r,a,e[3]]},i.default.ColorConversion._rgbaToHSLA=function(e){var t,r,n=e[0],i=e[1],o=e[2],a=Math.max(n,i,o),s=Math.min(n,i,o),u=a+s,l=a-s;return 0==l?r=t=0:(r=u<1?l/u:l/(2-u),n===a?t=(i-o)/l:i===a?t=2+(o-n)/l:o===a&&(t=4+(n-i)/l),t<0?t+=6:6<=t&&(t-=6)),[t/6,r,u/2,e[3]]};var o=i.default.ColorConversion;r.default=o},{"../core/main":264}],250:[function(e,t,r){"use strict";function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}e("core-js/modules/es.array.map"),Object.defineProperty(r,"__esModule",{value:!0}),r.default=void 0;var i,o=(i=e("../core/main"))&&i.__esModule?i:{default:i},a=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==n(e)&&"function"!=typeof e)return{default:e};var t=s();if(t&&t.has(e))return t.get(e);var r={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var a=i?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,t&&t.set(e,r),r}(e("../core/constants"));function s(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return s=function(){return e},e}e("./p5.Color"),e("../core/friendly_errors/validate_params"),e("../core/friendly_errors/file_errors"),e("../core/friendly_errors/fes_core"),o.default.prototype.alpha=function(e){return o.default._validateParameters("alpha",arguments),this.color(e)._getAlpha()},o.default.prototype.blue=function(e){return o.default._validateParameters("blue",arguments),this.color(e)._getBlue()},o.default.prototype.brightness=function(e){return o.default._validateParameters("brightness",arguments),this.color(e)._getBrightness()},o.default.prototype.color=function(){if(o.default._validateParameters("color",arguments),arguments[0]instanceof o.default.Color)return arguments[0];var e=arguments[0]instanceof Array?arguments[0]:arguments;return new o.default.Color(this,e)},o.default.prototype.green=function(e){return o.default._validateParameters("green",arguments),this.color(e)._getGreen()},o.default.prototype.hue=function(e){return o.default._validateParameters("hue",arguments),this.color(e)._getHue()},o.default.prototype.lerpColor=function(e,t,r){o.default._validateParameters("lerpColor",arguments);var n,i,s,u,l,c,f=this._colorMode,d=this._colorMaxes;if(f===a.RGB)l=e.levels.map((function(e){return e/255})),c=t.levels.map((function(e){return e/255}));else if(f===a.HSB)e._getBrightness(),t._getBrightness(),l=e.hsba,c=t.hsba;else{if(f!==a.HSL)throw new Error("".concat(f,"cannot be used for interpolation."));e._getLightness(),t._getLightness(),l=e.hsla,c=t.hsla}return r=Math.max(Math.min(r,1),0),void 0===this.lerp&&(this.lerp=function(e,t,r){return r*(t-e)+e}),n=this.lerp(l[0],c[0],r),i=this.lerp(l[1],c[1],r),s=this.lerp(l[2],c[2],r),u=this.lerp(l[3],c[3],r),n*=d[f][0],i*=d[f][1],s*=d[f][2],u*=d[f][3],this.color(n,i,s,u)},o.default.prototype.lightness=function(e){return o.default._validateParameters("lightness",arguments),this.color(e)._getLightness()},o.default.prototype.red=function(e){return o.default._validateParameters("red",arguments),this.color(e)._getRed()},o.default.prototype.saturation=function(e){return o.default._validateParameters("saturation",arguments),this.color(e)._getSaturation()};var u=o.default;r.default=u},{"../core/constants":253,"../core/friendly_errors/fes_core":255,"../core/friendly_errors/file_errors":256,"../core/friendly_errors/validate_params":259,"../core/main":264,"./p5.Color":251,"core-js/modules/es.array.map":161}],251:[function(e,t,r){"use strict";function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}e("core-js/modules/es.array.join"),e("core-js/modules/es.array.map"),e("core-js/modules/es.array.slice"),e("core-js/modules/es.object.to-string"),e("core-js/modules/es.regexp.constructor"),e("core-js/modules/es.regexp.exec"),e("core-js/modules/es.regexp.to-string"),e("core-js/modules/es.string.trim"),Object.defineProperty(r,"__esModule",{value:!0}),r.default=void 0;var i=u(e("../core/main")),o=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==n(e)&&"function"!=typeof e)return{default:e};var t=s();if(t&&t.has(e))return t.get(e);var r={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var a=i?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,t&&t.set(e,r),r}(e("../core/constants")),a=u(e("./color_conversion"));function s(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return s=function(){return e},e}function u(e){return e&&e.__esModule?e:{default:e}}i.default.Color=function(e,t){if(this._storeModeAndMaxes(e._colorMode,e._colorMaxes),this.mode!==o.RGB&&this.mode!==o.HSL&&this.mode!==o.HSB)throw new Error("".concat(this.mode," is an invalid colorMode."));return this._array=i.default.Color._parseInputs.apply(this,t),this._calculateLevels(),this},i.default.Color.prototype.toString=function(e){var t=this.levels,r=this._array,n=r[3];switch(e){case"#rrggbb":return"#".concat(t[0]<16?"0".concat(t[0].toString(16)):t[0].toString(16),t[1]<16?"0".concat(t[1].toString(16)):t[1].toString(16),t[2]<16?"0".concat(t[2].toString(16)):t[2].toString(16));case"#rrggbbaa":return"#".concat(t[0]<16?"0".concat(t[0].toString(16)):t[0].toString(16),t[1]<16?"0".concat(t[1].toString(16)):t[1].toString(16),t[2]<16?"0".concat(t[2].toString(16)):t[2].toString(16),t[3]<16?"0".concat(t[3].toString(16)):t[3].toString(16));case"#rgb":return"#".concat(Math.round(15*r[0]).toString(16),Math.round(15*r[1]).toString(16),Math.round(15*r[2]).toString(16));case"#rgba":return"#".concat(Math.round(15*r[0]).toString(16),Math.round(15*r[1]).toString(16),Math.round(15*r[2]).toString(16),Math.round(15*r[3]).toString(16));case"rgb":return"rgb(".concat(t[0],", ",t[1],", ",t[2],")");case"rgb%":return"rgb(".concat((100*r[0]).toPrecision(3),"%, ",(100*r[1]).toPrecision(3),"%, ",(100*r[2]).toPrecision(3),"%)");case"rgba%":return"rgba(".concat((100*r[0]).toPrecision(3),"%, ",(100*r[1]).toPrecision(3),"%, ",(100*r[2]).toPrecision(3),"%, ",(100*r[3]).toPrecision(3),"%)");case"hsb":case"hsv":return this.hsba||(this.hsba=a.default._rgbaToHSBA(this._array)),"hsb(".concat(this.hsba[0]*this.maxes[o.HSB][0],", ",this.hsba[1]*this.maxes[o.HSB][1],", ",this.hsba[2]*this.maxes[o.HSB][2],")");case"hsb%":case"hsv%":return this.hsba||(this.hsba=a.default._rgbaToHSBA(this._array)),"hsb(".concat((100*this.hsba[0]).toPrecision(3),"%, ",(100*this.hsba[1]).toPrecision(3),"%, ",(100*this.hsba[2]).toPrecision(3),"%)");case"hsba":case"hsva":return this.hsba||(this.hsba=a.default._rgbaToHSBA(this._array)),"hsba(".concat(this.hsba[0]*this.maxes[o.HSB][0],", ",this.hsba[1]*this.maxes[o.HSB][1],", ",this.hsba[2]*this.maxes[o.HSB][2],", ",n,")");case"hsba%":case"hsva%":return this.hsba||(this.hsba=a.default._rgbaToHSBA(this._array)),"hsba(".concat((100*this.hsba[0]).toPrecision(3),"%, ",(100*this.hsba[1]).toPrecision(3),"%, ",(100*this.hsba[2]).toPrecision(3),"%, ",(100*n).toPrecision(3),"%)");case"hsl":return this.hsla||(this.hsla=a.default._rgbaToHSLA(this._array)),"hsl(".concat(this.hsla[0]*this.maxes[o.HSL][0],", ",this.hsla[1]*this.maxes[o.HSL][1],", ",this.hsla[2]*this.maxes[o.HSL][2],")");case"hsl%":return this.hsla||(this.hsla=a.default._rgbaToHSLA(this._array)),"hsl(".concat((100*this.hsla[0]).toPrecision(3),"%, ",(100*this.hsla[1]).toPrecision(3),"%, ",(100*this.hsla[2]).toPrecision(3),"%)");case"hsla":return this.hsla||(this.hsla=a.default._rgbaToHSLA(this._array)),"hsla(".concat(this.hsla[0]*this.maxes[o.HSL][0],", ",this.hsla[1]*this.maxes[o.HSL][1],", ",this.hsla[2]*this.maxes[o.HSL][2],", ",n,")");case"hsla%":return this.hsla||(this.hsla=a.default._rgbaToHSLA(this._array)),"hsl(".concat((100*this.hsla[0]).toPrecision(3),"%, ",(100*this.hsla[1]).toPrecision(3),"%, ",(100*this.hsla[2]).toPrecision(3),"%, ",(100*n).toPrecision(3),"%)");default:return"rgba(".concat(t[0],",",t[1],",",t[2],",",n,")")}},i.default.Color.prototype.setRed=function(e){this._array[0]=e/this.maxes[o.RGB][0],this._calculateLevels()},i.default.Color.prototype.setGreen=function(e){this._array[1]=e/this.maxes[o.RGB][1],this._calculateLevels()},i.default.Color.prototype.setBlue=function(e){this._array[2]=e/this.maxes[o.RGB][2],this._calculateLevels()},i.default.Color.prototype.setAlpha=function(e){this._array[3]=e/this.maxes[this.mode][3],this._calculateLevels()},i.default.Color.prototype._calculateLevels=function(){for(var e=this._array,t=this.levels=new Array(e.length),r=e.length-1;0<=r;--r)t[r]=Math.round(255*e[r])},i.default.Color.prototype._getAlpha=function(){return this._array[3]*this.maxes[this.mode][3]},i.default.Color.prototype._storeModeAndMaxes=function(e,t){this.mode=e,this.maxes=t},i.default.Color.prototype._getMode=function(){return this.mode},i.default.Color.prototype._getMaxes=function(){return this.maxes},i.default.Color.prototype._getBlue=function(){return this._array[2]*this.maxes[o.RGB][2]},i.default.Color.prototype._getBrightness=function(){return this.hsba||(this.hsba=a.default._rgbaToHSBA(this._array)),this.hsba[2]*this.maxes[o.HSB][2]},i.default.Color.prototype._getGreen=function(){return this._array[1]*this.maxes[o.RGB][1]},i.default.Color.prototype._getHue=function(){return this.mode===o.HSB?(this.hsba||(this.hsba=a.default._rgbaToHSBA(this._array)),this.hsba[0]*this.maxes[o.HSB][0]):(this.hsla||(this.hsla=a.default._rgbaToHSLA(this._array)),this.hsla[0]*this.maxes[o.HSL][0])},i.default.Color.prototype._getLightness=function(){return this.hsla||(this.hsla=a.default._rgbaToHSLA(this._array)),this.hsla[2]*this.maxes[o.HSL][2]},i.default.Color.prototype._getRed=function(){return this._array[0]*this.maxes[o.RGB][0]},i.default.Color.prototype._getSaturation=function(){return this.mode===o.HSB?(this.hsba||(this.hsba=a.default._rgbaToHSBA(this._array)),this.hsba[1]*this.maxes[o.HSB][1]):(this.hsla||(this.hsla=a.default._rgbaToHSLA(this._array)),this.hsla[1]*this.maxes[o.HSL][1])};var l={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},c=/\s*/,f=/(\d{1,3})/,d=/((?:\d+(?:\.\d+)?)|(?:\.\d+))/,h=new RegExp("".concat(d.source,"%")),p={HEX3:/^#([a-f0-9])([a-f0-9])([a-f0-9])$/i,HEX4:/^#([a-f0-9])([a-f0-9])([a-f0-9])([a-f0-9])$/i,HEX6:/^#([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})$/i,HEX8:/^#([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})$/i,RGB:new RegExp(["^rgb\\(",f.source,",",f.source,",",f.source,"\\)$"].join(c.source),"i"),RGB_PERCENT:new RegExp(["^rgb\\(",h.source,",",h.source,",",h.source,"\\)$"].join(c.source),"i"),RGBA:new RegExp(["^rgba\\(",f.source,",",f.source,",",f.source,",",d.source,"\\)$"].join(c.source),"i"),RGBA_PERCENT:new RegExp(["^rgba\\(",h.source,",",h.source,",",h.source,",",d.source,"\\)$"].join(c.source),"i"),HSL:new RegExp(["^hsl\\(",f.source,",",h.source,",",h.source,"\\)$"].join(c.source),"i"),HSLA:new RegExp(["^hsla\\(",f.source,",",h.source,",",h.source,",",d.source,"\\)$"].join(c.source),"i"),HSB:new RegExp(["^hsb\\(",f.source,",",h.source,",",h.source,"\\)$"].join(c.source),"i"),HSBA:new RegExp(["^hsba\\(",f.source,",",h.source,",",h.source,",",d.source,"\\)$"].join(c.source),"i")};i.default.Color._parseInputs=function(e,t,r,n){var s,u=arguments.length,c=this.mode,f=this.maxes[c],d=[];if(3<=u){for(d[0]=e/f[0],d[1]=t/f[1],d[2]=r/f[2],d[3]="number"==typeof n?n/f[3]:1,s=d.length-1;0<=s;--s){var h=d[s];h<0?d[s]=0:1"].indexOf(i[0])?void 0:i[0],lineNumber:i[1],columnNumber:i[2],source:e}}),this)},parseFFOrSafari:function(e){return e.stack.split("\n").filter((function(e){return!e.match(r)}),this).map((function(e){if(-1 eval")&&(e=e.replace(/ line (\d+)(?: > eval line \d+)* > eval:\d+:\d+/g,":$1")),-1===e.indexOf("@")&&-1===e.indexOf(":"))return{functionName:e};var t=/((.*".+"[^@]*)?[^@]*)(?:@)/,r=e.match(t),n=r&&r[1]?r[1]:void 0,i=this.extractLocation(e.replace(t,""));return{functionName:n,fileName:i[0],lineNumber:i[1],columnNumber:i[2],source:e}}),this)},parseOpera:function(e){return!e.stacktrace||-1e.stacktrace.split("\n").length?this.parseOpera9(e):e.stack?this.parseOpera11(e):this.parseOpera10(e)},parseOpera9:function(e){for(var t=/Line (\d+).*script (?:in )?(\S+)/i,r=e.message.split("\n"),n=[],i=2,o=r.length;i/,"$2").replace(/\([^)]*\)/g,"")||void 0;return i.match(/\(([^)]*)\)/)&&(t=i.replace(/^[^(]+\(([^)]*)\)$/,"$1")),{functionName:o,args:void 0===t||"[arguments not available]"===t?void 0:t.split(","),fileName:n[0],lineNumber:n[1],columnNumber:n[2],source:e}}),this)}}}i.default._getErrorStackParser=function(){return new o};var a=i.default;r.default=a},{"../main":264,"core-js/modules/es.array.filter":152,"core-js/modules/es.array.index-of":157,"core-js/modules/es.array.join":159,"core-js/modules/es.array.map":161,"core-js/modules/es.array.slice":162,"core-js/modules/es.regexp.exec":181,"core-js/modules/es.string.match":187,"core-js/modules/es.string.replace":189,"core-js/modules/es.string.split":191}],259:[function(e,t,r){"use strict";e("core-js/modules/es.symbol"),e("core-js/modules/es.symbol.description"),e("core-js/modules/es.symbol.iterator"),e("core-js/modules/es.array.concat"),e("core-js/modules/es.array.for-each"),e("core-js/modules/es.array.includes"),e("core-js/modules/es.array.index-of"),e("core-js/modules/es.array.iterator"),e("core-js/modules/es.array.join"),e("core-js/modules/es.array.last-index-of"),e("core-js/modules/es.array.map"),e("core-js/modules/es.array.slice"),e("core-js/modules/es.function.name"),e("core-js/modules/es.map"),e("core-js/modules/es.number.constructor"),e("core-js/modules/es.object.get-prototype-of"),e("core-js/modules/es.object.keys"),e("core-js/modules/es.object.to-string"),e("core-js/modules/es.reflect.construct"),e("core-js/modules/es.regexp.exec"),e("core-js/modules/es.regexp.to-string"),e("core-js/modules/es.set"),e("core-js/modules/es.string.includes"),e("core-js/modules/es.string.iterator"),e("core-js/modules/es.string.split"),e("core-js/modules/web.dom-collections.for-each"),e("core-js/modules/web.dom-collections.iterator"),Object.defineProperty(r,"__esModule",{value:!0}),r.default=void 0;var n,i=(n=e("../main"))&&n.__esModule?n:{default:n};function o(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return o=function(){return e},e}function a(e){return(a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}(function(e){if((!e||!e.__esModule)&&null!==e&&("object"===a(e)||"function"==typeof e)){var t=o();if(t&&t.has(e))return t.get(e);var r={},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var s=n?Object.getOwnPropertyDescriptor(e,i):null;s&&(s.get||s.set)?Object.defineProperty(r,i,s):r[i]=e[i]}r.default=e,t&&t.set(e,r)}})(e("../constants")),e("../internationalization"),i.default._validateParameters=i.default._clearValidateParamsCache=function(){};var s=i.default;r.default=s},{"../../../docs/parameterData.json":void 0,"../constants":253,"../internationalization":262,"../main":264,"core-js/modules/es.array.concat":149,"core-js/modules/es.array.for-each":154,"core-js/modules/es.array.includes":156,"core-js/modules/es.array.index-of":157,"core-js/modules/es.array.iterator":158,"core-js/modules/es.array.join":159,"core-js/modules/es.array.last-index-of":160,"core-js/modules/es.array.map":161,"core-js/modules/es.array.slice":162,"core-js/modules/es.function.name":166,"core-js/modules/es.map":167,"core-js/modules/es.number.constructor":170,"core-js/modules/es.object.get-prototype-of":175,"core-js/modules/es.object.keys":176,"core-js/modules/es.object.to-string":177,"core-js/modules/es.reflect.construct":179,"core-js/modules/es.regexp.exec":181,"core-js/modules/es.regexp.to-string":182,"core-js/modules/es.set":183,"core-js/modules/es.string.includes":185,"core-js/modules/es.string.iterator":186,"core-js/modules/es.string.split":191,"core-js/modules/es.symbol":196,"core-js/modules/es.symbol.description":194,"core-js/modules/es.symbol.iterator":195,"core-js/modules/web.dom-collections.for-each":228,"core-js/modules/web.dom-collections.iterator":229}],260:[function(e,t,r){"use strict";function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(r,"__esModule",{value:!0}),r.default=void 0;var i=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==n(e)&&"function"!=typeof e)return{default:e};var t=o();if(t&&t.has(e))return t.get(e);var r={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if(Object.prototype.hasOwnProperty.call(e,a)){var s=i?Object.getOwnPropertyDescriptor(e,a):null;s&&(s.get||s.set)?Object.defineProperty(r,a,s):r[a]=e[a]}return r.default=e,t&&t.set(e,r),r}(e("./constants"));function o(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return o=function(){return e},e}var a={modeAdjust:function(e,t,r,n,o){return o===i.CORNER?{x:e,y:t,w:r,h:n}:o===i.CORNERS?{x:e,y:t,w:r-e,h:n-t}:o===i.RADIUS?{x:e-r,y:t-n,w:2*r,h:2*n}:o===i.CENTER?{x:e-.5*r,y:t-.5*n,w:r,h:n}:void 0}};r.default=a},{"./constants":253}],261:[function(e,t,r){"use strict";e("core-js/modules/es.array.iterator"),e("core-js/modules/es.object.to-string"),e("core-js/modules/es.promise"),e("core-js/modules/es.string.iterator"),e("core-js/modules/web.dom-collections.iterator");var n,i=(n=e("../core/main"))&&n.__esModule?n:{default:n};e("./internationalization");var o=Promise.resolve();Promise.all([new Promise((function(e,t){"complete"===document.readyState?e():window.addEventListener("load",e,!1)})),o]).then((function(){void 0===window._setupDone?window.mocha||(window.setup&&"function"==typeof window.setup||window.draw&&"function"==typeof window.draw)&&!i.default.instance&&new i.default:console.warn("p5.js seems to have been imported multiple times. Please remove the duplicate import")}))},{"../core/main":264,"./internationalization":262,"core-js/modules/es.array.iterator":158,"core-js/modules/es.object.to-string":177,"core-js/modules/es.promise":178,"core-js/modules/es.string.iterator":186,"core-js/modules/web.dom-collections.iterator":229}],262:[function(e,t,r){"use strict";e("core-js/modules/es.array.includes"),e("core-js/modules/es.array.iterator"),e("core-js/modules/es.array.join"),e("core-js/modules/es.array.slice"),e("core-js/modules/es.object.keys"),e("core-js/modules/es.object.to-string"),e("core-js/modules/es.promise"),e("core-js/modules/es.regexp.exec"),e("core-js/modules/es.string.includes"),e("core-js/modules/es.string.iterator"),e("core-js/modules/es.string.split"),e("core-js/modules/web.dom-collections.iterator"),Object.defineProperty(r,"__esModule",{value:!0}),r.setTranslatorLanguage=r.currentTranslatorLanguage=r.availableTranslatorLanguages=r.initialize=r.translator=void 0;var n,i,o=s(e("i18next")),a=s(e("i18next-browser-languagedetector"));function s(e){return e&&e.__esModule?e:{default:e}}function u(e,t){for(var r=0;r=s.width||t>=s.height?[0,0,0,0]:this._getPixel(e,t);var u=new i.default.Image(r,n);return u.canvas.getContext("2d").drawImage(s,e,t,r*a,n*a,0,0,r,n),u},i.default.Renderer.prototype.textLeading=function(e){return"number"==typeof e?(this._setProperty("_leadingSet",!0),this._setProperty("_textLeading",e),this._pInst):this._textLeading},i.default.Renderer.prototype.textSize=function(e){return"number"==typeof e?(this._setProperty("_textSize",e),this._leadingSet||this._setProperty("_textLeading",e*o._DEFAULT_LEADMULT),this._applyTextProperties()):this._textSize},i.default.Renderer.prototype.textStyle=function(e){return e?(e!==o.NORMAL&&e!==o.ITALIC&&e!==o.BOLD&&e!==o.BOLDITALIC||this._setProperty("_textStyle",e),this._applyTextProperties()):this._textStyle},i.default.Renderer.prototype.textAscent=function(){return null===this._textAscent&&this._updateTextMetrics(),this._textAscent},i.default.Renderer.prototype.textDescent=function(){return null===this._textDescent&&this._updateTextMetrics(),this._textDescent},i.default.Renderer.prototype.textAlign=function(e,t){return void 0!==e?(this._setProperty("_textAlign",e),void 0!==t&&this._setProperty("_textBaseline",t),this._applyTextProperties()):{horizontal:this._textAlign,vertical:this._textBaseline}},i.default.Renderer.prototype.textWrap=function(e){return this._setProperty("_textWrap",e),this._textWrap},i.default.Renderer.prototype.text=function(e,t,r,n,i){var a,s,u,l,c,f,d,h=this._pInst,p=this._textWrap,m=Number.MAX_VALUE;if((this._doFill||this._doStroke)&&void 0!==e){if("string"!=typeof e&&(e=e.toString()),a=(e=e.replace(/(\t)/g," ")).split("\n"),void 0!==n){switch(this._rectMode===o.CENTER&&(t-=n/2),this._textAlign){case o.CENTER:t+=n/2;break;case o.RIGHT:t+=n}var y=!1;if(void 0!==i){switch(this._rectMode===o.CENTER&&(r-=i/2),this._textBaseline){case o.BOTTOM:d=r+i,r=Math.max(d,r);break;case o.CENTER:d=r+i/2,r=Math.max(d,r);break;case o.BASELINE:y=!0,this._textBaseline=o.TOP}m=r+i-h.textAscent()}if(p===o.WORD){for(var v=[],g=0;go.HALF_PI&&e<=3*o.HALF_PI?Math.atan(r/n*Math.tan(e))+o.PI:Math.atan(r/n*Math.tan(e))+o.TWO_PI,t=t<=o.HALF_PI?Math.atan(r/n*Math.tan(t)):t>o.HALF_PI&&t<=3*o.HALF_PI?Math.atan(r/n*Math.tan(t))+o.PI:Math.atan(r/n*Math.tan(t))+o.TWO_PI),tp||Math.abs(this.accelerationY-this.pAccelerationY)>p||Math.abs(this.accelerationZ-this.pAccelerationZ)>p)&&r.deviceMoved(),"function"==typeof r.deviceTurned){var n=this.rotationX+180,i=this.pRotationX+180,o=u+180;0>>24],u+=A[(16711680&O)>>16],l+=A[(65280&O)>>8],c+=A[255&O],r+=o[E],d++}j[h=C+S]=f/r,M[h]=u/r,T[h]=l/r,P[h]=c/r}C+=g}for(m=(p=-n)*g,k=C=0;k>>16,e[r+1]=(65280&t[n])>>>8,e[r+2]=255&t[n],e[r+3]=(4278190080&t[n])>>>24},s._toImageData=function(e){return e instanceof ImageData?e:e.getContext("2d").getImageData(0,0,e.width,e.height)},s._createImageData=function(e,t){return s._tmpCanvas=document.createElement("canvas"),s._tmpCtx=s._tmpCanvas.getContext("2d"),this._tmpCtx.createImageData(e,t)},s.apply=function(e,t,r){var n=e.getContext("2d"),i=n.getImageData(0,0,e.width,e.height),o=t(i,r);o instanceof ImageData?n.putImageData(o,0,0,0,0,e.width,e.height):n.putImageData(i,0,0,0,0,e.width,e.height)},s.threshold=function(e,t){var r=s._toPixels(e);void 0===t&&(t=.5);for(var n=Math.floor(255*t),i=0;i>8)/n,r[i+1]=255*(a*t>>8)/n,r[i+2]=255*(u*t>>8)/n}},s.dilate=function(e){for(var t,r,n,i,o,a,u,l,c,f,d,h,p,m,y,v,g,b=s._toPixels(e),w=0,x=b.length?b.length/4:0,_=new Int32Array(x);w>16&255)+151*(n>>8&255)+28*(255&n))<(y=77*(d>>16&255)+151*(d>>8&255)+28*(255&d))&&(i=d,o=y),o<(m=77*((f=s._getARGB(b,a))>>16&255)+151*(f>>8&255)+28*(255&f))&&(i=f,o=m),o<(v=77*(h>>16&255)+151*(h>>8&255)+28*(255&h))&&(i=h,o=v),o<(g=77*(p>>16&255)+151*(p>>8&255)+28*(255&p))&&(i=p,o=g),_[w++]=i;s._setPixels(b,_)},s.erode=function(e){for(var t,r,n,i,o,a,u,l,c,f,d,h,p,m,y,v,g,b=s._toPixels(e),w=0,x=b.length?b.length/4:0,_=new Int32Array(x);w>16&255)+151*(d>>8&255)+28*(255&d))<(o=77*(n>>16&255)+151*(n>>8&255)+28*(255&n))&&(i=d,o=y),(m=77*((f=s._getARGB(b,a))>>16&255)+151*(f>>8&255)+28*(255&f))>16&255)+151*(h>>8&255)+28*(255&h))>16&255)+151*(p>>8&255)+28*(255&p))=n){var i=Math.floor(t.timeDisplayed/n);if(t.timeDisplayed=0,t.lastChangeTime=r,t.displayIndex+=i,t.loopCount=Math.floor(t.displayIndex/t.numFrames),null!==t.loopLimit&&t.loopCount>=t.loopLimit)t.playing=!1;else{var o=t.displayIndex%t.numFrames;this.drawingContext.putImageData(t.frames[o].image,0,0),t.displayIndex=o,this.setModified(!0)}}}},n.default.Image.prototype._setProperty=function(e,t){this[e]=t,this.setModified(!0)},n.default.Image.prototype.loadPixels=function(){n.default.Renderer2D.prototype.loadPixels.call(this),this.setModified(!0)},n.default.Image.prototype.updatePixels=function(e,t,r,i){n.default.Renderer2D.prototype.updatePixels.call(this,e,t,r,i),this.setModified(!0)},n.default.Image.prototype.get=function(e,t,r,i){return n.default._validateParameters("p5.Image.get",arguments),n.default.Renderer2D.prototype.get.apply(this,arguments)},n.default.Image.prototype._getPixel=n.default.Renderer2D.prototype._getPixel,n.default.Image.prototype.set=function(e,t,r){n.default.Renderer2D.prototype.set.call(this,e,t,r),this.setModified(!0)},n.default.Image.prototype.resize=function(e,t){0===e&&0===t?(e=this.canvas.width,t=this.canvas.height):0===e?e=this.canvas.width*t/this.canvas.height:0===t&&(t=this.canvas.height*e/this.canvas.width),e=Math.floor(e),t=Math.floor(t);var r=document.createElement("canvas");if(r.width=e,r.height=t,this.gifProperties)for(var n=this.gifProperties,i=function(e,t){for(var r=0,n=0;n/g,">").replace(/"/g,""").replace(/'/g,"'")}function c(e,t){t&&!0!==t&&"true"!==t||(t="");var r="";return(e=e||"untitled")&&e.includes(".")&&(r=e.split(".").pop()),t&&r!==t&&(r=t,e="".concat(e,".").concat(r)),[e,r]}e("../core/friendly_errors/validate_params"),e("../core/friendly_errors/file_errors"),e("../core/friendly_errors/fes_core"),n.default.prototype.loadJSON=function(){for(var e=arguments.length,t=new Array(e),r=0;r"),o.print(""),o.print(' '),o.print(""),o.print(""),o.print(" "),"0"!==a[0]){o.print(" ");for(var d=0;d".concat(h)),o.print(" ")}o.print(" ")}for(var p=0;p");for(var m=0;m".concat(y)),o.print(" ")}o.print(" ")}o.print("
        "),o.print(""),o.print("")}o.close(),o.clear()},n.default.prototype.writeFile=function(e,t,r){var i="application/octet-stream";n.default.prototype._isSafari()&&(i="text/plain");var o=new Blob(e,{type:i});n.default.prototype.downloadFile(o,t,r)},n.default.prototype.downloadFile=function(e,t,r){var i=c(t,r),a=i[0];if(e instanceof Blob)o.default.saveAs(e,a);else{var s=document.createElement("a");if(s.href=e,s.download=a,s.onclick=function(e){var t;t=e,document.body.removeChild(t.target),e.stopPropagation()},s.style.display="none",document.body.appendChild(s),n.default.prototype._isSafari()){var u="Hello, Safari user! To download this file...\n";u+="1. Go to File --\x3e Save As.\n",u+='2. Choose "Page Source" as the Format.\n',u+='3. Name it with this extension: ."'.concat(i[1],'"'),alert(u)}s.click()}},n.default.prototype._checkFileExtension=c,n.default.prototype._isSafari=function(){return 0>>0},getSeed:function(){return t},rand:function(){return(r=(1664525*r+1013904223)%n)/n}});i.setSeed(e),a=new Array(4096);for(var o=0;o<4096;o++)a[o]=i.rand()};var c=i.default;r.default=c},{"../core/main":264}],297:[function(e,t,r){"use strict";function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}e("core-js/modules/es.array.concat"),e("core-js/modules/es.array.every"),e("core-js/modules/es.array.slice"),e("core-js/modules/es.array.some"),e("core-js/modules/es.math.sign"),e("core-js/modules/es.number.constructor"),e("core-js/modules/es.number.is-finite"),e("core-js/modules/es.object.to-string"),e("core-js/modules/es.regexp.to-string"),e("core-js/modules/es.string.sub"),Object.defineProperty(r,"__esModule",{value:!0}),r.default=void 0;var i,o=(i=e("../core/main"))&&i.__esModule?i:{default:i},a=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==n(e)&&"function"!=typeof e)return{default:e};var t=s();if(t&&t.has(e))return t.get(e);var r={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var a=i?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,t&&t.set(e,r),r}(e("../core/constants"));function s(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return s=function(){return e},e}function u(e,t){return 0!==e&&(this.x=this.x%e),0!==t&&(this.y=this.y%t),this}function l(e,t,r){return 0!==e&&(this.x=this.x%e),0!==t&&(this.y=this.y%t),0!==r&&(this.z=this.z%r),this}o.default.Vector=function(e,t,r,n,i){var o,a,s;s="[object Function]"==={}.toString.call(e)?(this.isPInst=!0,this._fromRadians=e,this._toRadians=t,o=r||0,a=n||0,i||0):(o=e||0,a=t||0,r||0),this.x=o,this.y=a,this.z=s},o.default.Vector.prototype.toString=function(){return"p5.Vector Object : [".concat(this.x,", ").concat(this.y,", ").concat(this.z,"]")},o.default.Vector.prototype.set=function(e,t,r){return e instanceof o.default.Vector?(this.x=e.x||0,this.y=e.y||0,this.z=e.z||0):e instanceof Array?(this.x=e[0]||0,this.y=e[1]||0,this.z=e[2]||0):(this.x=e||0,this.y=t||0,this.z=r||0),this},o.default.Vector.prototype.copy=function(){return this.isPInst?new o.default.Vector(this._fromRadians,this._toRadians,this.x,this.y,this.z):new o.default.Vector(this.x,this.y,this.z)},o.default.Vector.prototype.add=function(e,t,r){return e instanceof o.default.Vector?(this.x+=e.x||0,this.y+=e.y||0,this.z+=e.z||0):e instanceof Array?(this.x+=e[0]||0,this.y+=e[1]||0,this.z+=e[2]||0):(this.x+=e||0,this.y+=t||0,this.z+=r||0),this},o.default.Vector.prototype.rem=function(e,t,r){if(e instanceof o.default.Vector){if(Number.isFinite(e.x)&&Number.isFinite(e.y)&&Number.isFinite(e.z)){var n=parseFloat(e.x),i=parseFloat(e.y),a=parseFloat(e.z);return l.call(this,n,i,a)}}else if(e instanceof Array){if(e.every((function(e){return Number.isFinite(e)}))){if(2===e.length)return u.call(this,e[0],e[1]);if(3===e.length)return l.call(this,e[0],e[1],e[2])}}else if(1===arguments.length){if(Number.isFinite(e)&&0!==e)return this.x=this.x%e,this.y=this.y%e,this.z=this.z%e,this}else if(2===arguments.length){var s=Array.prototype.slice.call(arguments);if(s.every((function(e){return Number.isFinite(e)}))&&2===s.length)return u.call(this,s[0],s[1])}else if(3===arguments.length){var c=Array.prototype.slice.call(arguments);if(c.every((function(e){return Number.isFinite(e)}))&&3===c.length)return l.call(this,c[0],c[1],c[2])}},o.default.Vector.prototype.sub=function(e,t,r){return e instanceof o.default.Vector?(this.x-=e.x||0,this.y-=e.y||0,this.z-=e.z||0):e instanceof Array?(this.x-=e[0]||0,this.y-=e[1]||0,this.z-=e[2]||0):(this.x-=e||0,this.y-=t||0,this.z-=r||0),this},o.default.Vector.prototype.mult=function(e,t,r){if(e instanceof o.default.Vector)return Number.isFinite(e.x)&&Number.isFinite(e.y)&&Number.isFinite(e.z)&&"number"==typeof e.x&&"number"==typeof e.y&&"number"==typeof e.z?(this.x*=e.x,this.y*=e.y,this.z*=e.z):console.warn("p5.Vector.prototype.mult:","x contains components that are either undefined or not finite numbers"),this;if(e instanceof Array)return e.every((function(e){return Number.isFinite(e)}))&&e.every((function(e){return"number"==typeof e}))?1===e.length?(this.x*=e[0],this.y*=e[0],this.z*=e[0]):2===e.length?(this.x*=e[0],this.y*=e[1]):3===e.length&&(this.x*=e[0],this.y*=e[1],this.z*=e[2]):console.warn("p5.Vector.prototype.mult:","x contains elements that are either undefined or not finite numbers"),this;var n=Array.prototype.slice.call(arguments);return n.every((function(e){return Number.isFinite(e)}))&&n.every((function(e){return"number"==typeof e}))?(1===arguments.length&&(this.x*=e,this.y*=e,this.z*=e),2===arguments.length&&(this.x*=e,this.y*=t),3===arguments.length&&(this.x*=e,this.y*=t,this.z*=r)):console.warn("p5.Vector.prototype.mult:","x, y, or z arguments are either undefined or not a finite number"),this},o.default.Vector.prototype.div=function(e,t,r){if(e instanceof o.default.Vector){if(Number.isFinite(e.x)&&Number.isFinite(e.y)&&Number.isFinite(e.z)&&"number"==typeof e.x&&"number"==typeof e.y&&"number"==typeof e.z){if(0===e.x||0===e.y||0===e.z)return console.warn("p5.Vector.prototype.div:","divide by 0"),this;this.x/=e.x,this.y/=e.y,this.z/=e.z}else console.warn("p5.Vector.prototype.div:","x contains components that are either undefined or not finite numbers");return this}if(e instanceof Array){if(e.every((function(e){return Number.isFinite(e)}))&&e.every((function(e){return"number"==typeof e}))){if(e.some((function(e){return 0===e})))return console.warn("p5.Vector.prototype.div:","divide by 0"),this;1===e.length?(this.x/=e[0],this.y/=e[0],this.z/=e[0]):2===e.length?(this.x/=e[0],this.y/=e[1]):3===e.length&&(this.x/=e[0],this.y/=e[1],this.z/=e[2])}else console.warn("p5.Vector.prototype.div:","x contains components that are either undefined or not finite numbers");return this}var n=Array.prototype.slice.call(arguments);if(n.every((function(e){return Number.isFinite(e)}))&&n.every((function(e){return"number"==typeof e}))){if(n.some((function(e){return 0===e})))return console.warn("p5.Vector.prototype.div:","divide by 0"),this;1===arguments.length&&(this.x/=e,this.y/=e,this.z/=e),2===arguments.length&&(this.x/=e,this.y/=t),3===arguments.length&&(this.x/=e,this.y/=t,this.z/=r)}else console.warn("p5.Vector.prototype.div:","x, y, or z arguments are either undefined or not a finite number");return this},o.default.Vector.prototype.mag=function(){return Math.sqrt(this.magSq())},o.default.Vector.prototype.magSq=function(){var e=this.x,t=this.y,r=this.z;return e*e+t*t+r*r},o.default.Vector.prototype.dot=function(e,t,r){return e instanceof o.default.Vector?this.dot(e.x,e.y,e.z):this.x*(e||0)+this.y*(t||0)+this.z*(r||0)},o.default.Vector.prototype.cross=function(e){var t=this.y*e.z-this.z*e.y,r=this.z*e.x-this.x*e.z,n=this.x*e.y-this.y*e.x;return this.isPInst?new o.default.Vector(this._fromRadians,this._toRadians,t,r,n):new o.default.Vector(t,r,n)},o.default.Vector.prototype.dist=function(e){return e.copy().sub(this).mag()},o.default.Vector.prototype.normalize=function(){var e=this.mag();return 0!==e&&this.mult(1/e),this},o.default.Vector.prototype.limit=function(e){var t=this.magSq();return e*e>>0},i.default.prototype.randomSeed=function(e){this._lcgSetSeed(o,e),this._gaussian_previous=!1},i.default.prototype.random=function(e,t){var r;if(i.default._validateParameters("random",arguments),r=null!=this[o]?this._lcg(o):Math.random(),void 0===e)return r;if(void 0===t)return e instanceof Array?e[Math.floor(r*e.length)]:r*e;if(tv){var M=d,T=u,P=l;d=f+v*(s&&f=t&&(r=r.substring(r.length-t,r.length)),r}},i.default.prototype.unhex=function(e){return e instanceof Array?e.map(i.default.prototype.unhex):parseInt("0x".concat(e),16)};var o=i.default;r.default=o},{"../core/main":264,"core-js/modules/es.array.map":161,"core-js/modules/es.number.constructor":170,"core-js/modules/es.object.to-string":177,"core-js/modules/es.regexp.to-string":182,"core-js/modules/es.string.repeat":188}],305:[function(e,t,r){"use strict";e("core-js/modules/es.array.filter"),e("core-js/modules/es.array.index-of"),e("core-js/modules/es.array.join"),e("core-js/modules/es.array.map"),e("core-js/modules/es.array.slice"),e("core-js/modules/es.object.to-string"),e("core-js/modules/es.regexp.constructor"),e("core-js/modules/es.regexp.exec"),e("core-js/modules/es.regexp.to-string"),e("core-js/modules/es.string.match"),e("core-js/modules/es.string.replace"),e("core-js/modules/es.string.split"),e("core-js/modules/es.string.trim"),Object.defineProperty(r,"__esModule",{value:!0}),r.default=void 0;var n,i=(n=e("../core/main"))&&n.__esModule?n:{default:n};function o(e,t,r){var n=e<0,i=n?e.toString().substring(1):e.toString(),o=i.indexOf("."),a=-1!==o?i.substring(0,o):i,s=-1!==o?i.substring(o+1):"",u=n?"-":"";if(void 0!==r){var l="";(-1!==o||0r&&(s=s.substring(0,r));for(var c=0;cn.length)for(var o=t-(n+=-1===r?".":"").length+1,a=0;a=a.TWO_PI?"".concat(t="ellipse","|").concat(d,"|"):"".concat(t="arc","|").concat(l,"|").concat(c,"|").concat(f,"|").concat(d,"|"),!this.geometryInHash(r)){var h=new o.default.Geometry(d,1,(function(){if(this.strokeIndices=[],l.toFixed(10)!==c.toFixed(10)){f!==a.PIE&&void 0!==f||(this.vertices.push(new o.default.Vector(.5,.5,0)),this.uvs.push([.5,.5]));for(var e=0;e<=d;e++){var t=e/d*(c-l)+l,r=.5+Math.cos(t)/2,n=.5+Math.sin(t)/2;this.vertices.push(new o.default.Vector(r,n,0)),this.uvs.push([r,n]),e>5&31)/31,(b>>10&31)/31):(r=s,n=u,l)}for(var w=new i.default.Vector(y,v,g),x=1;x<=3;x++){var _=m+12*x,S=new i.default.Vector(c.getFloat32(_,!0),c.getFloat32(4+_,!0),c.getFloat32(8+_,!0));e.vertices.push(S),e.vertexNormals.push(w),d&&a.push(r,n,o)}e.faces.push([3*p,3*p+1,3*p+2]),e.uvs.push([0,0],[0,0],[0,0])}}(e,t);else{var r=new DataView(t);if(!("TextDecoder"in window))return console.warn("Sorry, ASCII STL loading only works in browsers that support TextDecoder (https://caniuse.com/#feat=textencoder)");!function(e,t){for(var r,n,o="",a=[],s=0;sMath.PI?u=Math.PI:u<=0&&(u=.001);var l=Math.sin(u)*a*Math.sin(s),c=Math.cos(u)*a,f=Math.sin(u)*a*Math.cos(s);this.camera(l+this.centerX,c+this.centerY,f+this.centerZ,this.centerX,this.centerY,this.centerZ,0,1,0)},i.default.Camera.prototype._isActive=function(){return this===this._renderer._curCamera},i.default.prototype.setCamera=function(e){this._renderer._curCamera=e,this._renderer.uPMatrix.set(e.projMatrix.mat4[0],e.projMatrix.mat4[1],e.projMatrix.mat4[2],e.projMatrix.mat4[3],e.projMatrix.mat4[4],e.projMatrix.mat4[5],e.projMatrix.mat4[6],e.projMatrix.mat4[7],e.projMatrix.mat4[8],e.projMatrix.mat4[9],e.projMatrix.mat4[10],e.projMatrix.mat4[11],e.projMatrix.mat4[12],e.projMatrix.mat4[13],e.projMatrix.mat4[14],e.projMatrix.mat4[15])};var o=i.default.Camera;r.default=o},{"../core/main":264}],313:[function(e,t,r){"use strict";e("core-js/modules/es.string.sub"),Object.defineProperty(r,"__esModule",{value:!0}),r.default=void 0;var n,i=(n=e("../core/main"))&&n.__esModule?n:{default:n};i.default.Geometry=function(e,t,r){return this.vertices=[],this.lineVertices=[],this.lineNormals=[],this.vertexNormals=[],this.faces=[],this.uvs=[],this.edges=[],this.vertexColors=[],this.detailX=void 0!==e?e:1,this.detailY=void 0!==t?t:1,this.dirtyFlags={},r instanceof Function&&r.call(this),this},i.default.Geometry.prototype.reset=function(){this.lineVertices.length=0,this.lineNormals.length=0,this.vertices.length=0,this.edges.length=0,this.vertexColors.length=0,this.vertexNormals.length=0,this.uvs.length=0,this.dirtyFlags={}},i.default.Geometry.prototype.computeFaces=function(){this.faces.length=0;for(var e,t,r,n,i=this.detailX+1,o=0;othis.vertices.length-1-this.detailX;n--)e.add(this.vertexNormals[n]);e=i.default.Vector.div(e,this.detailX);for(var o=this.vertices.length-1;o>this.vertices.length-1-this.detailX;o--)this.vertexNormals[o]=e;return this},i.default.Geometry.prototype._makeTriangleEdges=function(){if(this.edges.length=0,Array.isArray(this.strokeIndices))for(var e=0,t=this.strokeIndices.length;e 65535 triangles. Your web browser does not support the WebGL Extension OES_element_index_uint.");n.drawElements(n.TRIANGLES,r.vertexCount,r.indexBufferType,0)}else n.drawArrays(e||n.TRIANGLES,0,r.vertexCount)},i.default.RendererGL.prototype._drawPoints=function(e,t){var r=this.GL,n=this._getImmediatePointShader();this._setPointUniforms(n),this._bindBuffer(t,r.ARRAY_BUFFER,this._vToNArray(e),Float32Array,r.STATIC_DRAW),n.enableAttrib(n.attributes.aPosition,3),r.drawArrays(r.Points,0,e.length),n.unbindShader()};var a=i.default.RendererGL;r.default=a},{"../core/main":264,"./p5.RenderBuffer":315,"./p5.RendererGL":318,"core-js/modules/es.array.fill":151,"core-js/modules/es.array.iterator":158,"core-js/modules/es.array.some":163,"core-js/modules/es.object.keys":176,"core-js/modules/es.object.to-string":177,"core-js/modules/es.string.iterator":186,"core-js/modules/es.symbol":196,"core-js/modules/es.symbol.description":194,"core-js/modules/es.symbol.iterator":195,"core-js/modules/es.typed-array.copy-within":197,"core-js/modules/es.typed-array.every":198,"core-js/modules/es.typed-array.fill":199,"core-js/modules/es.typed-array.filter":200,"core-js/modules/es.typed-array.find":202,"core-js/modules/es.typed-array.find-index":201,"core-js/modules/es.typed-array.float32-array":203,"core-js/modules/es.typed-array.for-each":205,"core-js/modules/es.typed-array.includes":206,"core-js/modules/es.typed-array.index-of":207,"core-js/modules/es.typed-array.iterator":210,"core-js/modules/es.typed-array.join":211,"core-js/modules/es.typed-array.last-index-of":212,"core-js/modules/es.typed-array.map":213,"core-js/modules/es.typed-array.reduce":215,"core-js/modules/es.typed-array.reduce-right":214,"core-js/modules/es.typed-array.reverse":216,"core-js/modules/es.typed-array.set":217,"core-js/modules/es.typed-array.slice":218,"core-js/modules/es.typed-array.some":219,"core-js/modules/es.typed-array.sort":220,"core-js/modules/es.typed-array.subarray":221,"core-js/modules/es.typed-array.to-locale-string":222,"core-js/modules/es.typed-array.to-string":223,"core-js/modules/es.typed-array.uint16-array":224,"core-js/modules/es.typed-array.uint32-array":225,"core-js/modules/web.dom-collections.iterator":229}],318:[function(e,t,r){"use strict";function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}e("core-js/modules/es.symbol"),e("core-js/modules/es.symbol.description"),e("core-js/modules/es.symbol.iterator"),e("core-js/modules/es.array.concat"),e("core-js/modules/es.array.fill"),e("core-js/modules/es.array.filter"),e("core-js/modules/es.array.from"),e("core-js/modules/es.array.includes"),e("core-js/modules/es.array.iterator"),e("core-js/modules/es.array.slice"),e("core-js/modules/es.object.assign"),e("core-js/modules/es.object.to-string"),e("core-js/modules/es.regexp.to-string"),e("core-js/modules/es.string.includes"),e("core-js/modules/es.string.iterator"),e("core-js/modules/es.typed-array.float32-array"),e("core-js/modules/es.typed-array.float64-array"),e("core-js/modules/es.typed-array.int16-array"),e("core-js/modules/es.typed-array.uint8-array"),e("core-js/modules/es.typed-array.uint16-array"),e("core-js/modules/es.typed-array.uint32-array"),e("core-js/modules/es.typed-array.copy-within"),e("core-js/modules/es.typed-array.every"),e("core-js/modules/es.typed-array.fill"),e("core-js/modules/es.typed-array.filter"),e("core-js/modules/es.typed-array.find"),e("core-js/modules/es.typed-array.find-index"),e("core-js/modules/es.typed-array.for-each"),e("core-js/modules/es.typed-array.includes"),e("core-js/modules/es.typed-array.index-of"),e("core-js/modules/es.typed-array.iterator"),e("core-js/modules/es.typed-array.join"),e("core-js/modules/es.typed-array.last-index-of"),e("core-js/modules/es.typed-array.map"),e("core-js/modules/es.typed-array.reduce"),e("core-js/modules/es.typed-array.reduce-right"),e("core-js/modules/es.typed-array.reverse"),e("core-js/modules/es.typed-array.set"),e("core-js/modules/es.typed-array.slice"),e("core-js/modules/es.typed-array.some"),e("core-js/modules/es.typed-array.sort"),e("core-js/modules/es.typed-array.subarray"),e("core-js/modules/es.typed-array.to-locale-string"),e("core-js/modules/es.typed-array.to-string"),e("core-js/modules/web.dom-collections.iterator"),Object.defineProperty(r,"__esModule",{value:!0}),r.default=void 0;var i=u(e("../core/main")),o=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==n(e)&&"function"!=typeof e)return{default:e};var t=s();if(t&&t.has(e))return t.get(e);var r={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var a=i?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,t&&t.set(e,r),r}(e("../core/constants")),a=u(e("libtess"));function s(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return s=function(){return e},e}function u(e){return e&&e.__esModule?e:{default:e}}function l(e){return function(e){if(Array.isArray(e)){for(var t=0,r=new Array(e.length);t vTexCoord.y;\n bool y1 = p1.y > vTexCoord.y;\n bool y2 = p2.y > vTexCoord.y;\n\n // could web be under the curve (after t1)?\n if (y1 ? !y2 : y0) {\n // add the coverage for t1\n coverage.x += saturate(C1.x + 0.5);\n // calculate the anti-aliasing for t1\n weight.x = min(weight.x, abs(C1.x));\n }\n\n // are we outside the curve (after t2)?\n if (y1 ? !y0 : y2) {\n // subtract the coverage for t2\n coverage.x -= saturate(C2.x + 0.5);\n // calculate the anti-aliasing for t2\n weight.x = min(weight.x, abs(C2.x));\n }\n}\n\n// this is essentially the same as coverageX, but with the axes swapped\nvoid coverageY(vec2 p0, vec2 p1, vec2 p2) {\n\n vec2 C1, C2;\n calulateCrossings(p0, p1, p2, C1, C2);\n\n bool x0 = p0.x > vTexCoord.x;\n bool x1 = p1.x > vTexCoord.x;\n bool x2 = p2.x > vTexCoord.x;\n\n if (x1 ? !x2 : x0) {\n coverage.y -= saturate(C1.y + 0.5);\n weight.y = min(weight.y, abs(C1.y));\n }\n\n if (x1 ? !x0 : x2) {\n coverage.y += saturate(C2.y + 0.5);\n weight.y = min(weight.y, abs(C2.y));\n }\n}\n\nvoid main() {\n\n // calculate the pixel scale based on screen-coordinates\n pixelScale = hardness / fwidth(vTexCoord);\n\n // which grid cell is this pixel in?\n ivec2 gridCoord = ifloor(vTexCoord * vec2(uGridSize));\n\n // intersect curves in this row\n {\n // the index into the row info bitmap\n int rowIndex = gridCoord.y + uGridOffset.y;\n // fetch the info texel\n vec4 rowInfo = getTexel(uSamplerRows, rowIndex, uGridImageSize);\n // unpack the rowInfo\n int rowStrokeIndex = getInt16(rowInfo.xy);\n int rowStrokeCount = getInt16(rowInfo.zw);\n\n for (int iRowStroke = INT(0); iRowStroke < N; iRowStroke++) {\n if (iRowStroke >= rowStrokeCount)\n break;\n\n // each stroke is made up of 3 points: the start and control point\n // and the start of the next curve.\n // fetch the indices of this pair of strokes:\n vec4 strokeIndices = getTexel(uSamplerRowStrokes, rowStrokeIndex++, uCellsImageSize);\n\n // unpack the stroke index\n int strokePos = getInt16(strokeIndices.xy);\n\n // fetch the two strokes\n vec4 stroke0 = getTexel(uSamplerStrokes, strokePos + INT(0), uStrokeImageSize);\n vec4 stroke1 = getTexel(uSamplerStrokes, strokePos + INT(1), uStrokeImageSize);\n\n // calculate the coverage\n coverageX(stroke0.xy, stroke0.zw, stroke1.xy);\n }\n }\n\n // intersect curves in this column\n {\n int colIndex = gridCoord.x + uGridOffset.x;\n vec4 colInfo = getTexel(uSamplerCols, colIndex, uGridImageSize);\n int colStrokeIndex = getInt16(colInfo.xy);\n int colStrokeCount = getInt16(colInfo.zw);\n \n for (int iColStroke = INT(0); iColStroke < N; iColStroke++) {\n if (iColStroke >= colStrokeCount)\n break;\n\n vec4 strokeIndices = getTexel(uSamplerColStrokes, colStrokeIndex++, uCellsImageSize);\n\n int strokePos = getInt16(strokeIndices.xy);\n vec4 stroke0 = getTexel(uSamplerStrokes, strokePos + INT(0), uStrokeImageSize);\n vec4 stroke1 = getTexel(uSamplerStrokes, strokePos + INT(1), uStrokeImageSize);\n coverageY(stroke0.xy, stroke0.zw, stroke1.xy);\n }\n }\n\n weight = saturate(1.0 - weight * 2.0);\n float distance = max(weight.x + weight.y, minDistance); // manhattan approx.\n float antialias = abs(dot(coverage, weight) / distance);\n float cover = min(abs(coverage.x), abs(coverage.y));\n gl_FragColor = uMaterialColor;\n gl_FragColor.a *= saturate(max(antialias, cover));\n}",lineVert:"/*\n Part of the Processing project - http://processing.org\n Copyright (c) 2012-15 The Processing Foundation\n Copyright (c) 2004-12 Ben Fry and Casey Reas\n Copyright (c) 2001-04 Massachusetts Institute of Technology\n This library is free software; you can redistribute it and/or\n modify it under the terms of the GNU Lesser General Public\n License as published by the Free Software Foundation, version 2.1.\n This library is distributed in the hope that it will be useful,\n but WITHOUT ANY WARRANTY; without even the implied warranty of\n MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\n Lesser General Public License for more details.\n You should have received a copy of the GNU Lesser General\n Public License along with this library; if not, write to the\n Free Software Foundation, Inc., 59 Temple Place, Suite 330,\n Boston, MA 02111-1307 USA\n*/\n\n#define PROCESSING_LINE_SHADER\n\nuniform mat4 uModelViewMatrix;\nuniform mat4 uProjectionMatrix;\nuniform float uStrokeWeight;\n\nuniform vec4 uViewport;\nuniform int uPerspective;\n\nattribute vec4 aPosition;\nattribute vec4 aDirection;\n \nvoid main() {\n // using a scale <1 moves the lines towards the camera\n // in order to prevent popping effects due to half of\n // the line disappearing behind the geometry faces.\n vec3 scale = vec3(0.9995);\n\n vec4 posp = uModelViewMatrix * aPosition;\n vec4 posq = uModelViewMatrix * (aPosition + vec4(aDirection.xyz, 0));\n\n // Moving vertices slightly toward the camera\n // to avoid depth-fighting with the fill triangles.\n // Discussed here:\n // http://www.opengl.org/discussion_boards/ubbthreads.php?ubb=showflat&Number=252848 \n posp.xyz = posp.xyz * scale;\n posq.xyz = posq.xyz * scale;\n\n vec4 p = uProjectionMatrix * posp;\n vec4 q = uProjectionMatrix * posq;\n\n // formula to convert from clip space (range -1..1) to screen space (range 0..[width or height])\n // screen_p = (p.xy/p.w + <1,1>) * 0.5 * uViewport.zw\n\n // prevent division by W by transforming the tangent formula (div by 0 causes\n // the line to disappear, see https://github.com/processing/processing/issues/5183)\n // t = screen_q - screen_p\n //\n // tangent is normalized and we don't care which aDirection it points to (+-)\n // t = +- normalize( screen_q - screen_p )\n // t = +- normalize( (q.xy/q.w+<1,1>)*0.5*uViewport.zw - (p.xy/p.w+<1,1>)*0.5*uViewport.zw )\n //\n // extract common factor, <1,1> - <1,1> cancels out\n // t = +- normalize( (q.xy/q.w - p.xy/p.w) * 0.5 * uViewport.zw )\n //\n // convert to common divisor\n // t = +- normalize( ((q.xy*p.w - p.xy*q.w) / (p.w*q.w)) * 0.5 * uViewport.zw )\n //\n // remove the common scalar divisor/factor, not needed due to normalize and +-\n // (keep uViewport - can't remove because it has different components for x and y\n // and corrects for aspect ratio, see https://github.com/processing/processing/issues/5181)\n // t = +- normalize( (q.xy*p.w - p.xy*q.w) * uViewport.zw )\n\n vec2 tangent = normalize((q.xy*p.w - p.xy*q.w) * uViewport.zw);\n\n // flip tangent to normal (it's already normalized)\n vec2 normal = vec2(-tangent.y, tangent.x);\n\n float thickness = aDirection.w * uStrokeWeight;\n vec2 offset = normal * thickness / 2.0;\n\n vec2 curPerspScale;\n\n if(uPerspective == 1) {\n // Perspective ---\n // convert from world to clip by multiplying with projection scaling factor\n // to get the right thickness (see https://github.com/processing/processing/issues/5182)\n // invert Y, projections in Processing invert Y\n curPerspScale = (uProjectionMatrix * vec4(1, -1, 0, 0)).xy;\n } else {\n // No Perspective ---\n // multiply by W (to cancel out division by W later in the pipeline) and\n // convert from screen to clip (derived from clip to screen above)\n curPerspScale = p.w / (0.5 * uViewport.zw);\n }\n\n gl_Position.xy = p.xy + offset.xy * curPerspScale;\n gl_Position.zw = p.zw;\n}\n",lineFrag:"precision mediump float;\nprecision mediump int;\n\nuniform vec4 uMaterialColor;\n\nvoid main() {\n gl_FragColor = uMaterialColor;\n}",pointVert:"attribute vec3 aPosition;\nuniform float uPointSize;\nvarying float vStrokeWeight;\nuniform mat4 uModelViewMatrix;\nuniform mat4 uProjectionMatrix;\nvoid main() {\n\tvec4 positionVec4 = vec4(aPosition, 1.0);\n\tgl_Position = uProjectionMatrix * uModelViewMatrix * positionVec4;\n\tgl_PointSize = uPointSize;\n\tvStrokeWeight = uPointSize;\n}",pointFrag:"precision mediump float;\nprecision mediump int;\nuniform vec4 uMaterialColor;\nvarying float vStrokeWeight;\n\nvoid main(){\n\tfloat mask = 0.0;\n\n\t// make a circular mask using the gl_PointCoord (goes from 0 - 1 on a point)\n // might be able to get a nicer edge on big strokeweights with smoothstep but slightly less performant\n\n\tmask = step(0.98, length(gl_PointCoord * 2.0 - 1.0));\n\n\t// if strokeWeight is 1 or less lets just draw a square\n\t// this prevents weird artifacting from carving circles when our points are really small\n\t// if strokeWeight is larger than 1, we just use it as is\n\n\tmask = mix(0.0, mask, clamp(floor(vStrokeWeight - 0.5),0.0,1.0));\n\n\t// throw away the borders of the mask\n // otherwise we get weird alpha blending issues\n\n\tif(mask > 0.98){\n discard;\n \t}\n\n \tgl_FragColor = vec4(uMaterialColor.rgb * (1.0 - mask), uMaterialColor.a) ;\n}"};i.default.RendererGL=function(e,t,r,n){return i.default.Renderer.call(this,e,t,r),this._setAttributeDefaults(t),this._initContext(),this.isP3D=!0,this.GL=this.drawingContext,this._pInst._setProperty("drawingContext",this.drawingContext),this._isErasing=!1,this._enableLighting=!1,this.ambientLightColors=[],this.specularColors=[1,1,1],this.directionalLightDirections=[],this.directionalLightDiffuseColors=[],this.directionalLightSpecularColors=[],this.pointLightPositions=[],this.pointLightDiffuseColors=[],this.pointLightSpecularColors=[],this.spotLightPositions=[],this.spotLightDirections=[],this.spotLightDiffuseColors=[],this.spotLightSpecularColors=[],this.spotLightAngle=[],this.spotLightConc=[],this.drawMode=o.FILL,this.curFillColor=this._cachedFillStyle=[1,1,1,1],this.curStrokeColor=this._cachedStrokeStyle=[0,0,0,1],this.curBlendMode=o.BLEND,this._cachedBlendMode=void 0,this.blendExt=this.GL.getExtension("EXT_blend_minmax"),this._isBlending=!1,this._useSpecularMaterial=!1,this._useEmissiveMaterial=!1,this._useNormalMaterial=!1,this._useShininess=1,this._tint=[255,255,255,255],this.constantAttenuation=1,this.linearAttenuation=0,this.quadraticAttenuation=0,this.uMVMatrix=new i.default.Matrix,this.uPMatrix=new i.default.Matrix,this.uNMatrix=new i.default.Matrix("mat3"),this._currentNormal=new i.default.Vector(0,0,1),this._curCamera=new i.default.Camera(this),this._curCamera._computeCameraDefaultSettings(),this._curCamera._setDefaultCamera(),this._defaultLightShader=void 0,this._defaultImmediateModeShader=void 0,this._defaultNormalShader=void 0,this._defaultColorShader=void 0,this._defaultPointShader=void 0,this.userFillShader=void 0,this.userStrokeShader=void 0,this.userPointShader=void 0,this.retainedMode={geometry:{},buffers:{stroke:[new i.default.RenderBuffer(3,"lineVertices","lineVertexBuffer","aPosition",this,this._flatten),new i.default.RenderBuffer(4,"lineNormals","lineNormalBuffer","aDirection",this,this._flatten)],fill:[new i.default.RenderBuffer(3,"vertices","vertexBuffer","aPosition",this,this._vToNArray),new i.default.RenderBuffer(3,"vertexNormals","normalBuffer","aNormal",this,this._vToNArray),new i.default.RenderBuffer(4,"vertexColors","colorBuffer","aVertexColor",this),new i.default.RenderBuffer(3,"vertexAmbients","ambientBuffer","aAmbientColor",this),new i.default.RenderBuffer(2,"uvs","uvBuffer","aTexCoord",this,this._flatten)],text:[new i.default.RenderBuffer(3,"vertices","vertexBuffer","aPosition",this,this._vToNArray),new i.default.RenderBuffer(2,"uvs","uvBuffer","aTexCoord",this,this._flatten)]}},this.immediateMode={geometry:new i.default.Geometry,shapeMode:o.TRIANGLE_FAN,_bezierVertex:[],_quadraticVertex:[],_curveVertex:[],buffers:{fill:[new i.default.RenderBuffer(3,"vertices","vertexBuffer","aPosition",this,this._vToNArray),new i.default.RenderBuffer(3,"vertexNormals","normalBuffer","aNormal",this,this._vToNArray),new i.default.RenderBuffer(4,"vertexColors","colorBuffer","aVertexColor",this),new i.default.RenderBuffer(3,"vertexAmbients","ambientBuffer","aAmbientColor",this),new i.default.RenderBuffer(2,"uvs","uvBuffer","aTexCoord",this,this._flatten)],stroke:[new i.default.RenderBuffer(3,"lineVertices","lineVertexBuffer","aPosition",this,this._flatten),new i.default.RenderBuffer(4,"lineNormals","lineNormalBuffer","aDirection",this,this._flatten)],point:this.GL.createBuffer()}},this.pointSize=5,this.curStrokeWeight=1,this.textures=[],this.textureMode=o.IMAGE,this.textureWrapX=o.CLAMP,this.textureWrapY=o.CLAMP,this._tex=null,this._curveTightness=6,this._lookUpTableBezier=[],this._lookUpTableQuadratic=[],this._lutBezierDetail=0,this._lutQuadraticDetail=0,this._tessy=this._initTessy(),this.fontInfos={},this._curShader=void 0,this},i.default.RendererGL.prototype=Object.create(i.default.Renderer.prototype),i.default.RendererGL.prototype._setAttributeDefaults=function(e){var t={alpha:!1,depth:!0,stencil:!0,antialias:navigator.userAgent.toLowerCase().includes("safari"),premultipliedAlpha:!1,preserveDrawingBuffer:!0,perPixelLighting:!0};null===e._glAttributes?e._glAttributes=t:e._glAttributes=Object.assign(t,e._glAttributes)},i.default.RendererGL.prototype._initContext=function(){try{if(this.drawingContext=this.canvas.getContext("webgl",this._pInst._glAttributes)||this.canvas.getContext("experimental-webgl",this._pInst._glAttributes),null===this.drawingContext)throw new Error("Error creating webgl context");var e=this.drawingContext;e.enable(e.DEPTH_TEST),e.depthFunc(e.LEQUAL),e.viewport(0,0,e.drawingBufferWidth,e.drawingBufferHeight),this._viewport=this.drawingContext.getParameter(this.drawingContext.VIEWPORT)}catch(e){throw e}},i.default.RendererGL.prototype._resetContext=function(e,t){var r=this.width,n=this.height,o=this.canvas.id,a=this._pInst instanceof i.default.Graphics;if(a){var s=this._pInst;s.canvas.parentNode.removeChild(s.canvas),s.canvas=document.createElement("canvas"),(s._pInst._userNode||document.body).appendChild(s.canvas),i.default.Element.call(s,s.canvas,s._pInst),s.width=r,s.height=n}else{var u=this.canvas;u&&u.parentNode.removeChild(u),(u=document.createElement("canvas")).id=o,this._pInst._userNode?this._pInst._userNode.appendChild(u):document.body.appendChild(u),this._pInst.canvas=u}var l=new i.default.RendererGL(this._pInst.canvas,this._pInst,!a);this._pInst._setProperty("_renderer",l),l.resize(r,n),l._applyDefaults(),a||this._pInst._elements.push(l),"function"==typeof t&&setTimeout((function(){t.apply(window._renderer,e)}),0)},i.default.prototype.setAttributes=function(e,t){if(void 0!==this._glAttributes){var r=!0;if(void 0!==t?(null===this._glAttributes&&(this._glAttributes={}),this._glAttributes[e]!==t&&(this._glAttributes[e]=t,r=!1)):e instanceof Object&&this._glAttributes!==e&&(this._glAttributes=e,r=!1),this._renderer.isP3D&&!r){if(!this._setupDone)for(var n in this._renderer.retainedMode.geometry)if(this._renderer.retainedMode.geometry.hasOwnProperty(n))return void console.error("Sorry, Could not set the attributes, you need to call setAttributes() before calling the other drawing methods in setup()");this.push(),this._renderer._resetContext(),this.pop(),this._renderer._curCamera&&(this._renderer._curCamera._renderer=this._renderer)}}else console.log("You are trying to use setAttributes on a p5.Graphics object that does not use a WEBGL renderer.")},i.default.RendererGL.prototype._update=function(){this.uMVMatrix.set(this._curCamera.cameraMatrix.mat4[0],this._curCamera.cameraMatrix.mat4[1],this._curCamera.cameraMatrix.mat4[2],this._curCamera.cameraMatrix.mat4[3],this._curCamera.cameraMatrix.mat4[4],this._curCamera.cameraMatrix.mat4[5],this._curCamera.cameraMatrix.mat4[6],this._curCamera.cameraMatrix.mat4[7],this._curCamera.cameraMatrix.mat4[8],this._curCamera.cameraMatrix.mat4[9],this._curCamera.cameraMatrix.mat4[10],this._curCamera.cameraMatrix.mat4[11],this._curCamera.cameraMatrix.mat4[12],this._curCamera.cameraMatrix.mat4[13],this._curCamera.cameraMatrix.mat4[14],this._curCamera.cameraMatrix.mat4[15]),this.ambientLightColors.length=0,this.specularColors=[1,1,1],this.directionalLightDirections.length=0,this.directionalLightDiffuseColors.length=0,this.directionalLightSpecularColors.length=0,this.pointLightPositions.length=0,this.pointLightDiffuseColors.length=0,this.pointLightSpecularColors.length=0,this.spotLightPositions.length=0,this.spotLightDirections.length=0,this.spotLightDiffuseColors.length=0,this.spotLightSpecularColors.length=0,this.spotLightAngle.length=0,this.spotLightConc.length=0,this._enableLighting=!1,this._tint=[255,255,255,255],this.GL.clear(this.GL.DEPTH_BUFFER_BIT)},i.default.RendererGL.prototype.background=function(){var e,t=(e=this._pInst).color.apply(e,arguments),r=t.levels[0]/255,n=t.levels[1]/255,i=t.levels[2]/255,o=t.levels[3]/255;this.GL.clearColor(r,n,i,o),this.GL.clear(this.GL.COLOR_BUFFER_BIT)},i.default.RendererGL.prototype.fill=function(e,t,r,n){var a=i.default.prototype.color.apply(this._pInst,arguments);this.curFillColor=a._array,this.drawMode=o.FILL,this._useNormalMaterial=!1,this._tex=null},i.default.RendererGL.prototype.stroke=function(e,t,r,n){arguments[3]=255;var o=i.default.prototype.color.apply(this._pInst,arguments);this.curStrokeColor=o._array},i.default.RendererGL.prototype.strokeCap=function(e){console.error("Sorry, strokeCap() is not yet implemented in WEBGL mode")},i.default.RendererGL.prototype.strokeJoin=function(e){console.error("Sorry, strokeJoin() is not yet implemented in WEBGL mode")},i.default.RendererGL.prototype.filter=function(e){console.error("filter() does not work in WEBGL mode")},i.default.RendererGL.prototype.blendMode=function(e){e===o.DARKEST||e===o.LIGHTEST||e===o.ADD||e===o.BLEND||e===o.SUBTRACT||e===o.SCREEN||e===o.EXCLUSION||e===o.REPLACE||e===o.MULTIPLY||e===o.REMOVE?this.curBlendMode=e:e!==o.BURN&&e!==o.OVERLAY&&e!==o.HARD_LIGHT&&e!==o.SOFT_LIGHT&&e!==o.DODGE||console.warn("BURN, OVERLAY, HARD_LIGHT, SOFT_LIGHT, and DODGE only work for blendMode in 2D mode.")},i.default.RendererGL.prototype.erase=function(e,t){this._isErasing||(this._applyBlendMode(o.REMOVE),this._isErasing=!0,this._cachedFillStyle=this.curFillColor.slice(),this.curFillColor=[1,1,1,e/255],this._cachedStrokeStyle=this.curStrokeColor.slice(),this.curStrokeColor=[1,1,1,t/255])},i.default.RendererGL.prototype.noErase=function(){this._isErasing&&(this._isErasing=!1,this.curFillColor=this._cachedFillStyle.slice(),this.curStrokeColor=this._cachedStrokeStyle.slice(),this.blendMode(this._cachedBlendMode))},i.default.RendererGL.prototype.strokeWeight=function(e){this.curStrokeWeight!==e&&(this.pointSize=e,this.curStrokeWeight=e)},i.default.RendererGL.prototype._getPixel=function(e,t){var r;return r=new Uint8Array(4),this.drawingContext.readPixels(e,t,1,1,this.drawingContext.RGBA,this.drawingContext.UNSIGNED_BYTE,r),[r[0],r[1],r[2],r[3]]},i.default.RendererGL.prototype.loadPixels=function(){var e=this._pixelsState;if(!0===this._pInst._glAttributes.preserveDrawingBuffer){var t=e.pixels,r=this.GL.drawingBufferWidth*this.GL.drawingBufferHeight*4;t instanceof Uint8Array&&t.length===r||(t=new Uint8Array(r),this._pixelsState._setProperty("pixels",t));var n=this._pInst._pixelDensity;this.GL.readPixels(0,0,this.width*n,this.height*n,this.GL.RGBA,this.GL.UNSIGNED_BYTE,t)}else console.log("loadPixels only works in WebGL when preserveDrawingBuffer is true.")},i.default.RendererGL.prototype.geometryInHash=function(e){return void 0!==this.retainedMode.geometry[e]},i.default.RendererGL.prototype.resize=function(e,t){i.default.Renderer.prototype.resize.call(this,e,t),this.GL.viewport(0,0,this.GL.drawingBufferWidth,this.GL.drawingBufferHeight),this._viewport=this.GL.getParameter(this.GL.VIEWPORT),this._curCamera._resize();var r=this._pixelsState;void 0!==r.pixels&&r._setProperty("pixels",new Uint8Array(this.GL.drawingBufferWidth*this.GL.drawingBufferHeight*4))},i.default.RendererGL.prototype.clear=function(){var e=(arguments.length<=0?void 0:arguments[0])||0,t=(arguments.length<=1?void 0:arguments[1])||0,r=(arguments.length<=2?void 0:arguments[2])||0,n=(arguments.length<=3?void 0:arguments[3])||0;this.GL.clearColor(e,t,r,n),this.GL.clearDepth(1),this.GL.clear(this.GL.COLOR_BUFFER_BIT|this.GL.DEPTH_BUFFER_BIT)},i.default.RendererGL.prototype.applyMatrix=function(e,t,r,n,o,a){16===arguments.length?i.default.Matrix.prototype.apply.apply(this.uMVMatrix,arguments):this.uMVMatrix.apply([e,t,0,0,r,n,0,0,0,0,1,0,o,a,0,1])},i.default.RendererGL.prototype.translate=function(e,t,r){return e instanceof i.default.Vector&&(r=e.z,t=e.y,e=e.x),this.uMVMatrix.translate([e,t,r]),this},i.default.RendererGL.prototype.scale=function(e,t,r){return this.uMVMatrix.scale(e,t,r),this},i.default.RendererGL.prototype.rotate=function(e,t){return void 0===t?this.rotateZ(e):(i.default.Matrix.prototype.rotate.apply(this.uMVMatrix,arguments),this)},i.default.RendererGL.prototype.rotateX=function(e){return this.rotate(e,1,0,0),this},i.default.RendererGL.prototype.rotateY=function(e){return this.rotate(e,0,1,0),this},i.default.RendererGL.prototype.rotateZ=function(e){return this.rotate(e,0,0,1),this},i.default.RendererGL.prototype.push=function(){var e=i.default.Renderer.prototype.push.apply(this),t=e.properties;return t.uMVMatrix=this.uMVMatrix.copy(),t.uPMatrix=this.uPMatrix.copy(),t._curCamera=this._curCamera,this._curCamera=this._curCamera.copy(),t.ambientLightColors=this.ambientLightColors.slice(),t.specularColors=this.specularColors.slice(),t.directionalLightDirections=this.directionalLightDirections.slice(),t.directionalLightDiffuseColors=this.directionalLightDiffuseColors.slice(),t.directionalLightSpecularColors=this.directionalLightSpecularColors.slice(),t.pointLightPositions=this.pointLightPositions.slice(),t.pointLightDiffuseColors=this.pointLightDiffuseColors.slice(),t.pointLightSpecularColors=this.pointLightSpecularColors.slice(),t.spotLightPositions=this.spotLightPositions.slice(),t.spotLightDirections=this.spotLightDirections.slice(),t.spotLightDiffuseColors=this.spotLightDiffuseColors.slice(),t.spotLightSpecularColors=this.spotLightSpecularColors.slice(),t.spotLightAngle=this.spotLightAngle.slice(),t.spotLightConc=this.spotLightConc.slice(),t.userFillShader=this.userFillShader,t.userStrokeShader=this.userStrokeShader,t.userPointShader=this.userPointShader,t.pointSize=this.pointSize,t.curStrokeWeight=this.curStrokeWeight,t.curStrokeColor=this.curStrokeColor,t.curFillColor=this.curFillColor,t._useSpecularMaterial=this._useSpecularMaterial,t._useEmissiveMaterial=this._useEmissiveMaterial,t._useShininess=this._useShininess,t.constantAttenuation=this.constantAttenuation,t.linearAttenuation=this.linearAttenuation,t.quadraticAttenuation=this.quadraticAttenuation,t._enableLighting=this._enableLighting,t._useNormalMaterial=this._useNormalMaterial,t._tex=this._tex,t.drawMode=this.drawMode,t._currentNormal=this._currentNormal,e},i.default.RendererGL.prototype.resetMatrix=function(){return this.uMVMatrix=i.default.Matrix.identity(this._pInst),this},i.default.RendererGL.prototype._getImmediateStrokeShader=function(){var e=this.userStrokeShader;return e&&e.isStrokeShader()?e:this._getLineShader()},i.default.RendererGL.prototype._getRetainedStrokeShader=i.default.RendererGL.prototype._getImmediateStrokeShader,i.default.RendererGL.prototype._getImmediateFillShader=function(){var e=this.userFillShader;if(this._useNormalMaterial&&(!e||!e.isNormalShader()))return this._getNormalShader();if(this._enableLighting){if(!e||!e.isLightShader())return this._getLightShader()}else if(this._tex){if(!e||!e.isTextureShader())return this._getLightShader()}else if(!e)return this._getImmediateModeShader();return e},i.default.RendererGL.prototype._getRetainedFillShader=function(){if(this._useNormalMaterial)return this._getNormalShader();var e=this.userFillShader;if(this._enableLighting){if(!e||!e.isLightShader())return this._getLightShader()}else if(this._tex){if(!e||!e.isTextureShader())return this._getLightShader()}else if(!e)return this._getColorShader();return e},i.default.RendererGL.prototype._getImmediatePointShader=function(){var e=this.userPointShader;return e&&e.isPointShader()?e:this._getPointShader()},i.default.RendererGL.prototype._getRetainedLineShader=i.default.RendererGL.prototype._getImmediateLineShader,i.default.RendererGL.prototype._getLightShader=function(){return this._defaultLightShader||(this._pInst._glAttributes.perPixelLighting?this._defaultLightShader=new i.default.Shader(this,f.phongVert,f.phongFrag):this._defaultLightShader=new i.default.Shader(this,f.lightVert,f.lightTextureFrag)),this._defaultLightShader},i.default.RendererGL.prototype._getImmediateModeShader=function(){return this._defaultImmediateModeShader||(this._defaultImmediateModeShader=new i.default.Shader(this,f.immediateVert,f.vertexColorFrag)),this._defaultImmediateModeShader},i.default.RendererGL.prototype._getNormalShader=function(){return this._defaultNormalShader||(this._defaultNormalShader=new i.default.Shader(this,f.normalVert,f.normalFrag)),this._defaultNormalShader},i.default.RendererGL.prototype._getColorShader=function(){return this._defaultColorShader||(this._defaultColorShader=new i.default.Shader(this,f.normalVert,f.basicFrag)),this._defaultColorShader},i.default.RendererGL.prototype._getPointShader=function(){return this._defaultPointShader||(this._defaultPointShader=new i.default.Shader(this,f.pointVert,f.pointFrag)),this._defaultPointShader},i.default.RendererGL.prototype._getLineShader=function(){return this._defaultLineShader||(this._defaultLineShader=new i.default.Shader(this,f.lineVert,f.lineFrag)),this._defaultLineShader},i.default.RendererGL.prototype._getFontShader=function(){return this._defaultFontShader||(this.GL.getExtension("OES_standard_derivatives"),this._defaultFontShader=new i.default.Shader(this,f.fontVert,f.fontFrag)),this._defaultFontShader},i.default.RendererGL.prototype._getEmptyTexture=function(){if(!this._emptyTexture){var e=new i.default.Image(1,1);e.set(0,0,255),this._emptyTexture=new i.default.Texture(this,e)}return this._emptyTexture},i.default.RendererGL.prototype.getTexture=function(e){var t=this.textures,r=!0,n=!1,o=void 0;try{for(var a,s=t[Symbol.iterator]();!(r=(a=s.next()).done);r=!0){var u=a.value;if(u.src===e)return u}}catch(e){n=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(n)throw o}}var l=new i.default.Texture(this,e);return t.push(l),l},i.default.RendererGL.prototype._setStrokeUniforms=function(e){e.bindShader(),e.setUniform("uMaterialColor",this.curStrokeColor),e.setUniform("uStrokeWeight",this.curStrokeWeight)},i.default.RendererGL.prototype._setFillUniforms=function(e){e.bindShader(),e.setUniform("uMaterialColor",this.curFillColor),e.setUniform("isTexture",!!this._tex),this._tex&&e.setUniform("uSampler",this._tex),e.setUniform("uTint",this._tint),e.setUniform("uSpecular",this._useSpecularMaterial),e.setUniform("uEmissive",this._useEmissiveMaterial),e.setUniform("uShininess",this._useShininess),e.setUniform("uUseLighting",this._enableLighting);var t=this.pointLightDiffuseColors.length/3;e.setUniform("uPointLightCount",t),e.setUniform("uPointLightLocation",this.pointLightPositions),e.setUniform("uPointLightDiffuseColors",this.pointLightDiffuseColors),e.setUniform("uPointLightSpecularColors",this.pointLightSpecularColors);var r=this.directionalLightDiffuseColors.length/3;e.setUniform("uDirectionalLightCount",r),e.setUniform("uLightingDirection",this.directionalLightDirections),e.setUniform("uDirectionalDiffuseColors",this.directionalLightDiffuseColors),e.setUniform("uDirectionalSpecularColors",this.directionalLightSpecularColors);var n=this.ambientLightColors.length/3;e.setUniform("uAmbientLightCount",n),e.setUniform("uAmbientColor",this.ambientLightColors);var i=this.spotLightDiffuseColors.length/3;e.setUniform("uSpotLightCount",i),e.setUniform("uSpotLightAngle",this.spotLightAngle),e.setUniform("uSpotLightConc",this.spotLightConc),e.setUniform("uSpotLightDiffuseColors",this.spotLightDiffuseColors),e.setUniform("uSpotLightSpecularColors",this.spotLightSpecularColors),e.setUniform("uSpotLightLocation",this.spotLightPositions),e.setUniform("uSpotLightDirection",this.spotLightDirections),e.setUniform("uConstantAttenuation",this.constantAttenuation),e.setUniform("uLinearAttenuation",this.linearAttenuation),e.setUniform("uQuadraticAttenuation",this.quadraticAttenuation),e.bindTextures()},i.default.RendererGL.prototype._setPointUniforms=function(e){e.bindShader(),e.setUniform("uMaterialColor",this.curStrokeColor),e.setUniform("uPointSize",this.pointSize*this._pInst._pixelDensity)},i.default.RendererGL.prototype._bindBuffer=function(e,t,r,n,i){if(t=t||this.GL.ARRAY_BUFFER,this.GL.bindBuffer(t,e),void 0!==r){var o=new(n||Float32Array)(r);this.GL.bufferData(t,o,i||this.GL.STATIC_DRAW)}},i.default.RendererGL.prototype._arraysEqual=function(e,t){var r=e.length;if(r!==t.length)return!1;for(var n=0;n>7,127&h,d>>7,127&d);for(var p=0;p>7,127&m,0,0)}}return{cellImageInfo:u,dimOffset:o,dimImageInfo:i}}return(t=this.glyphInfos[e.index]={glyph:e,uGlyphRect:[n.x1,-n.y1,n.x2,-n.y2],strokeImageInfo:U,strokes:y,colInfo:z(g,this.colDimImageInfos,this.colCellImageInfos),rowInfo:z(v,this.rowDimImageInfos,this.rowCellImageInfos)}).uGridOffset=[t.colInfo.dimOffset,t.rowInfo.dimOffset],t}}e("./p5.Shader"),e("./p5.RendererGL.Retained"),o.default.RendererGL.prototype._applyTextProperties=function(){},o.default.RendererGL.prototype.textWidth=function(e){return this._isOpenType()?this._textFont._textWidth(e,this._textSize):0};var f=Math.sqrt(3);o.default.RendererGL.prototype._renderText=function(e,t,r,n,i){if(this._textFont&&"string"!=typeof this._textFont){if(!(i<=n)&&this._doFill){if(!this._isOpenType())return console.log("WEBGL: only Opentype (.otf) and Truetype (.ttf) fonts are supported"),e;e.push();var s=this._doStroke,u=this.drawMode;this._doStroke=!1,this.drawMode=a.TEXTURE;var l=this._textFont.font,f=this._textFont._fontInfo;f=f||(this._textFont._fontInfo=new c(l));var d=this._textFont._handleAlignment(this,t,r,n),h=this._textSize/l.unitsPerEm;this.translate(d.x,d.y,0),this.scale(h,h,1);var p=this.GL,m=!this._defaultFontShader,y=this._getFontShader();y.init(),y.bindShader(),m&&(y.setUniform("uGridImageSize",[64,64]),y.setUniform("uCellsImageSize",[64,64]),y.setUniform("uStrokeImageSize",[64,64]),y.setUniform("uGridSize",[9,9])),this._applyColorBlend(this.curFillColor);var v=this.retainedMode.geometry.glyph;if(!v){var g=this._textGeom=new o.default.Geometry(1,1,(function(){for(var e=0;e<=1;e++)for(var t=0;t<=1;t++)this.vertices.push(new o.default.Vector(t,e,0)),this.uvs.push(t,e)}));g.computeFaces().computeNormals(),v=this.createBuffers("glyph",g)}var b=!0,w=!1,x=void 0;try{for(var _,S=this.retainedMode.buffers.text[Symbol.iterator]();!(b=(_=S.next()).done);b=!0)_.value._prepareBuffer(v,y)}catch(e){w=!0,x=e}finally{try{b||null==S.return||S.return()}finally{if(w)throw x}}this._bindBuffer(v.indexBuffer,p.ELEMENT_ARRAY_BUFFER),y.setUniform("uMaterialColor",this.curFillColor);try{var k=0,E=null,A=l.stringToGlyphs(t),j=!0,M=!1,T=void 0;try{for(var P,C=A[Symbol.iterator]();!(j=(P=C.next()).done);j=!0){var O=P.value;E&&(k+=l.getKerningValue(E,O));var R=f.getGlyphInfo(O);if(R.uGlyphRect){var I=R.rowInfo,L=R.colInfo;y.setUniform("uSamplerStrokes",R.strokeImageInfo.imageData),y.setUniform("uSamplerRowStrokes",I.cellImageInfo.imageData),y.setUniform("uSamplerRows",I.dimImageInfo.imageData),y.setUniform("uSamplerColStrokes",L.cellImageInfo.imageData),y.setUniform("uSamplerCols",L.dimImageInfo.imageData),y.setUniform("uGridOffset",R.uGridOffset),y.setUniform("uGlyphRect",R.uGlyphRect),y.setUniform("uGlyphOffset",k),y.bindTextures(),p.drawElements(p.TRIANGLES,6,this.GL.UNSIGNED_SHORT,0)}k+=O.advanceWidth,E=O}}catch(e){M=!0,T=e}finally{try{j||null==C.return||C.return()}finally{if(M)throw T}}}finally{y.unbindShader(),this._doStroke=s,this.drawMode=u,e.pop()}return e}}else console.log("WEBGL: you must load and set a font before drawing text. See `loadFont` and `textFont` for more details.")}},{"../core/constants":253,"../core/main":264,"./p5.RendererGL.Retained":317,"./p5.Shader":319,"core-js/modules/es.array.iterator":158,"core-js/modules/es.object.to-string":177,"core-js/modules/es.regexp.exec":181,"core-js/modules/es.string.iterator":186,"core-js/modules/es.string.split":191,"core-js/modules/es.string.sub":192,"core-js/modules/es.symbol":196,"core-js/modules/es.symbol.description":194,"core-js/modules/es.symbol.iterator":195,"core-js/modules/web.dom-collections.iterator":229}]},{},[248])(248)}()},2610:function(e,t,r){"use strict";var n=r(969),i=r(3401);function o(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,r=1;r