@skmtc/core 0.16.3 → 0.26.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +0 -1
- package/esm/anchors/buildSidecar.js +1 -1
- package/esm/anchors/postPass.d.ts +1 -1
- package/esm/anchors/postPass.js +1 -1
- package/esm/anchors/sidecar.d.ts +2 -2
- package/esm/anchors/sidecar.js +1 -1
- package/esm/context/CoreContext.d.ts +7 -1
- package/esm/context/CoreContext.d.ts.map +1 -1
- package/esm/context/CoreContext.js +17 -11
- package/esm/context/GenerateContext.d.ts +28 -7
- package/esm/context/GenerateContext.d.ts.map +1 -1
- package/esm/context/GenerateContext.js +164 -86
- package/esm/context/ParseContext.d.ts +16 -0
- package/esm/context/ParseContext.d.ts.map +1 -1
- package/esm/context/ParseContext.js +16 -0
- package/esm/context/ParseIssue.d.ts +1 -1
- package/esm/context/RenderContext.d.ts +2 -6
- package/esm/context/RenderContext.d.ts.map +1 -1
- package/esm/context/RenderContext.js +4 -14
- package/esm/context/generateTypes.d.ts +35 -8
- package/esm/context/generateTypes.d.ts.map +1 -1
- package/{script/deps/jsr.io/@std/fs/1.0.23 → esm/deps/jsr.io/@std/fs/1.0.24}/exists.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/internal/1.0.14/_os.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/internal/1.0.14/_os.js +14 -0
- package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/os.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/log/0.224.14/rotating_file_handler.js +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/assert_path.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/assert_path.js +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/constants.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/constants.js +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/from_file_url.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/from_file_url.js +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/normalize.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/normalize.js +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/normalize_string.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/normalize_string.js +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/join.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/join.js +2 -2
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/normalize.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/normalize.js +2 -2
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/_util.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/_util.js +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/from_file_url.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/from_file_url.js +1 -1
- package/{script/deps/jsr.io/@std/path/1.1.4 → esm/deps/jsr.io/@std/path/1.1.6}/posix/join.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/join.js +1 -1
- package/{script/deps/jsr.io/@std/path/1.1.4 → esm/deps/jsr.io/@std/path/1.1.6}/posix/normalize.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/normalize.js +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/windows/_util.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/windows/_util.js +1 -1
- package/{script/deps/jsr.io/@std/path/1.1.4 → esm/deps/jsr.io/@std/path/1.1.6}/windows/from_file_url.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/windows/from_file_url.js +1 -1
- package/{script/deps/jsr.io/@std/path/1.1.4 → esm/deps/jsr.io/@std/path/1.1.6}/windows/join.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/windows/join.js +1 -1
- package/{script/deps/jsr.io/@std/path/1.1.4 → esm/deps/jsr.io/@std/path/1.1.6}/windows/normalize.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/windows/normalize.js +1 -1
- package/esm/dsl/CodeFileBase.d.ts +57 -24
- package/esm/dsl/CodeFileBase.d.ts.map +1 -1
- package/esm/dsl/CodeFileBase.js +35 -53
- package/esm/dsl/FileBase.d.ts +21 -25
- package/esm/dsl/FileBase.d.ts.map +1 -1
- package/esm/dsl/FileBase.js +20 -29
- package/esm/dsl/GeneratorKeys.d.ts +19 -19
- package/esm/dsl/GeneratorKeys.d.ts.map +1 -1
- package/esm/dsl/GeneratorKeys.js +6 -5
- package/esm/dsl/IdentifierBase.d.ts +19 -5
- package/esm/dsl/IdentifierBase.d.ts.map +1 -1
- package/esm/dsl/IdentifierBase.js +21 -5
- package/esm/dsl/IdentifierType.d.ts +8 -14
- package/esm/dsl/IdentifierType.d.ts.map +1 -1
- package/esm/dsl/Lang.d.ts +18 -38
- package/esm/dsl/Lang.d.ts.map +1 -1
- package/esm/dsl/MarkdownFile.d.ts +55 -0
- package/esm/dsl/MarkdownFile.d.ts.map +1 -0
- package/esm/dsl/MarkdownFile.js +58 -0
- package/esm/dsl/model/ModelDriver.d.ts +3 -1
- package/esm/dsl/model/ModelDriver.d.ts.map +1 -1
- package/esm/dsl/model/ModelDriver.js +29 -2
- package/esm/dsl/model/toModelEntry.d.ts +24 -14
- package/esm/dsl/model/toModelEntry.d.ts.map +1 -1
- package/esm/dsl/model/toModelEntry.js +7 -3
- package/esm/dsl/model/toModelProjectionBase.d.ts +31 -18
- package/esm/dsl/model/toModelProjectionBase.d.ts.map +1 -1
- package/esm/dsl/model/toModelProjectionBase.js +3 -3
- package/esm/dsl/model/types.d.ts +23 -27
- package/esm/dsl/model/types.d.ts.map +1 -1
- package/esm/dsl/operation/gql/GqlOperationDriver.d.ts +3 -1
- package/esm/dsl/operation/gql/GqlOperationDriver.d.ts.map +1 -1
- package/esm/dsl/operation/gql/GqlOperationDriver.js +12 -9
- package/esm/dsl/operation/gql/toGqlOperationEntry.d.ts +20 -15
- package/esm/dsl/operation/gql/toGqlOperationEntry.d.ts.map +1 -1
- package/esm/dsl/operation/gql/toGqlOperationEntry.js +3 -25
- package/esm/dsl/operation/gql/toGqlOperationProjectionBase.d.ts +11 -10
- package/esm/dsl/operation/gql/toGqlOperationProjectionBase.d.ts.map +1 -1
- package/esm/dsl/operation/gql/types.d.ts +1 -28
- package/esm/dsl/operation/gql/types.d.ts.map +1 -1
- package/esm/dsl/operation/oas/OasOperationDriver.d.ts +3 -1
- package/esm/dsl/operation/oas/OasOperationDriver.d.ts.map +1 -1
- package/esm/dsl/operation/oas/OasOperationDriver.js +12 -9
- package/esm/dsl/operation/oas/toOasOperationEntry.d.ts +21 -17
- package/esm/dsl/operation/oas/toOasOperationEntry.d.ts.map +1 -1
- package/esm/dsl/operation/oas/toOasOperationEntry.js +3 -32
- package/esm/dsl/operation/oas/toOasOperationProjectionBase.d.ts +11 -10
- package/esm/dsl/operation/oas/toOasOperationProjectionBase.d.ts.map +1 -1
- package/esm/dsl/operation/oas/types.d.ts +1 -38
- package/esm/dsl/operation/oas/types.d.ts.map +1 -1
- package/esm/dsl/webhook/WebhookDriver.d.ts +3 -1
- package/esm/dsl/webhook/WebhookDriver.d.ts.map +1 -1
- package/esm/dsl/webhook/WebhookDriver.js +12 -9
- package/esm/dsl/webhook/toWebhookEntry.d.ts +21 -16
- package/esm/dsl/webhook/toWebhookEntry.d.ts.map +1 -1
- package/esm/dsl/webhook/toWebhookEntry.js +3 -32
- package/esm/dsl/webhook/toWebhookProjectionBase.d.ts +11 -10
- package/esm/dsl/webhook/toWebhookProjectionBase.d.ts.map +1 -1
- package/esm/dsl/webhook/types.d.ts +1 -36
- package/esm/dsl/webhook/types.d.ts.map +1 -1
- package/esm/enrichments/toEnrichmentDescriptor.d.ts +72 -27
- package/esm/enrichments/toEnrichmentDescriptor.d.ts.map +1 -1
- package/esm/enrichments/toEnrichmentDescriptor.js +57 -31
- package/esm/enrichments/validateConfig.d.ts +60 -0
- package/esm/enrichments/validateConfig.d.ts.map +1 -0
- package/esm/enrichments/validateConfig.js +176 -0
- package/esm/helpers/isImported.js +1 -1
- package/esm/helpers/toResolvedArtifactPath.js +1 -1
- package/esm/mod.d.ts +8 -1
- package/esm/mod.d.ts.map +1 -1
- package/esm/mod.js +8 -1
- package/esm/oas/array/Array.d.ts +2 -0
- package/esm/oas/array/Array.d.ts.map +1 -1
- package/esm/oas/array/Array.js +4 -0
- package/esm/oas/boolean/Boolean.d.ts +3 -1
- package/esm/oas/boolean/Boolean.d.ts.map +1 -1
- package/esm/oas/boolean/Boolean.js +4 -0
- package/esm/oas/components/Components.d.ts +5 -0
- package/esm/oas/components/Components.d.ts.map +1 -1
- package/esm/oas/components/Components.js +6 -1
- package/esm/oas/integer/Integer.d.ts +3 -1
- package/esm/oas/integer/Integer.d.ts.map +1 -1
- package/esm/oas/integer/Integer.js +4 -0
- package/esm/oas/link/Link.d.ts +68 -0
- package/esm/oas/link/Link.d.ts.map +1 -0
- package/esm/oas/link/Link.js +107 -0
- package/esm/oas/number/Number.d.ts +3 -1
- package/esm/oas/number/Number.d.ts.map +1 -1
- package/esm/oas/number/Number.js +4 -0
- package/esm/oas/object/Object.d.ts +9 -0
- package/esm/oas/object/Object.d.ts.map +1 -1
- package/esm/oas/object/Object.js +14 -0
- package/esm/oas/operation/Operation.d.ts +15 -0
- package/esm/oas/operation/Operation.d.ts.map +1 -1
- package/esm/oas/operation/Operation.js +33 -0
- package/esm/oas/ref/Ref.d.ts +23 -1
- package/esm/oas/ref/Ref.d.ts.map +1 -1
- package/esm/oas/ref/Ref.js +32 -0
- package/esm/oas/ref/ref-types.d.ts +18 -1
- package/esm/oas/ref/ref-types.d.ts.map +1 -1
- package/esm/oas/ref/ref-types.js +12 -1
- package/esm/oas/response/Response.d.ts +4 -0
- package/esm/oas/response/Response.d.ts.map +1 -1
- package/esm/oas/response/Response.js +7 -0
- package/esm/oas/schemaPath/traverseSchema.d.ts +31 -0
- package/esm/oas/schemaPath/traverseSchema.d.ts.map +1 -0
- package/esm/oas/schemaPath/traverseSchema.js +113 -0
- package/esm/oas/string/String.d.ts +3 -1
- package/esm/oas/string/String.d.ts.map +1 -1
- package/esm/oas/string/String.js +4 -0
- package/esm/oas/union/Union.d.ts +9 -0
- package/esm/oas/union/Union.d.ts.map +1 -1
- package/esm/oas/union/Union.js +14 -0
- package/esm/oas/unknown/Unknown.d.ts +3 -1
- package/esm/oas/unknown/Unknown.d.ts.map +1 -1
- package/esm/oas/unknown/Unknown.js +4 -0
- package/esm/parse/v3-0/_merge-all-of/decompose-union.d.ts.map +1 -1
- package/esm/parse/v3-0/_merge-all-of/decompose-union.js +8 -12
- package/esm/parse/v3-0/_merge-all-of/merge-union.d.ts.map +1 -1
- package/esm/parse/v3-0/_merge-all-of/merge-union.js +0 -8
- package/esm/parse/v3-0/components/toComponentsV3.d.ts.map +1 -1
- package/esm/parse/v3-0/components/toComponentsV3.js +3 -1
- package/esm/parse/v3-0/link/toLinksV3.d.ts +17 -0
- package/esm/parse/v3-0/link/toLinksV3.d.ts.map +1 -0
- package/esm/parse/v3-0/link/toLinksV3.js +40 -0
- package/esm/parse/v3-0/object/toObject.d.ts.map +1 -1
- package/esm/parse/v3-0/object/toObject.js +3 -1
- package/esm/parse/v3-0/response/toResponseV3.d.ts.map +1 -1
- package/esm/parse/v3-0/response/toResponseV3.js +4 -1
- package/esm/parse/v3-0/schema/toSchemasV3.d.ts.map +1 -1
- package/esm/parse/v3-0/schema/toSchemasV3.js +8 -0
- package/esm/parse/v3-0/union/toUnion.d.ts.map +1 -1
- package/esm/parse/v3-0/union/toUnion.js +3 -1
- package/esm/parse/v3-1/_merge-all-of/decompose-union.d.ts.map +1 -1
- package/esm/parse/v3-1/_merge-all-of/decompose-union.js +8 -12
- package/esm/parse/v3-1/_merge-all-of/merge-union.d.ts.map +1 -1
- package/esm/parse/v3-1/_merge-all-of/merge-union.js +0 -8
- package/esm/parse/v3-1/components/toComponentsV3.d.ts.map +1 -1
- package/esm/parse/v3-1/components/toComponentsV3.js +3 -1
- package/esm/parse/v3-1/link/toLinksV3.d.ts +17 -0
- package/esm/parse/v3-1/link/toLinksV3.d.ts.map +1 -0
- package/esm/parse/v3-1/link/toLinksV3.js +40 -0
- package/esm/parse/v3-1/object/toObject.d.ts.map +1 -1
- package/esm/parse/v3-1/object/toObject.js +3 -1
- package/esm/parse/v3-1/response/toResponseV3.d.ts.map +1 -1
- package/esm/parse/v3-1/response/toResponseV3.js +4 -1
- package/esm/parse/v3-1/schema/toSchemasV3.d.ts.map +1 -1
- package/esm/parse/v3-1/schema/toSchemasV3.js +8 -0
- package/esm/parse/v3-1/union/toUnion.d.ts.map +1 -1
- package/esm/parse/v3-1/union/toUnion.js +3 -1
- package/esm/run/toArtifacts.d.ts +8 -1
- package/esm/run/toArtifacts.d.ts.map +1 -1
- package/esm/run/toArtifacts.js +5 -5
- package/esm/run/toInspection.d.ts +8 -0
- package/esm/run/toInspection.d.ts.map +1 -0
- package/esm/run/toInspection.js +78 -0
- package/esm/types/Enrichments.d.ts +19 -8
- package/esm/types/Enrichments.d.ts.map +1 -1
- package/esm/types/Enrichments.js +4 -3
- package/esm/types/GeneratorType.d.ts +5 -5
- package/esm/types/GeneratorType.d.ts.map +1 -1
- package/esm/types/Manifest.d.ts +1 -2
- package/esm/types/Manifest.d.ts.map +1 -1
- package/esm/types/Manifest.js +1 -2
- package/esm/types/ModuleSelect.d.ts +81 -0
- package/esm/types/ModuleSelect.d.ts.map +1 -0
- package/esm/types/ModuleSelect.js +63 -0
- package/esm/types/Preview.d.ts +4 -27
- package/esm/types/Preview.d.ts.map +1 -1
- package/esm/types/Preview.js +4 -25
- package/esm/types/SchemaPath.d.ts +17 -0
- package/esm/types/SchemaPath.d.ts.map +1 -0
- package/esm/types/SchemaPath.js +9 -0
- package/esm/types/Settings.d.ts +24 -3
- package/esm/types/Settings.d.ts.map +1 -1
- package/esm/types/Settings.js +20 -13
- package/esm/types/SkmtcDocument.d.ts +1 -1
- package/esm/types/SupportedSubjects.d.ts +1 -1
- package/package.json +1 -1
- package/script/anchors/buildSidecar.js +1 -1
- package/script/anchors/postPass.d.ts +1 -1
- package/script/anchors/postPass.js +1 -1
- package/script/anchors/sidecar.d.ts +2 -2
- package/script/anchors/sidecar.js +1 -1
- package/script/context/CoreContext.d.ts +7 -1
- package/script/context/CoreContext.d.ts.map +1 -1
- package/script/context/CoreContext.js +17 -11
- package/script/context/GenerateContext.d.ts +28 -7
- package/script/context/GenerateContext.d.ts.map +1 -1
- package/script/context/GenerateContext.js +164 -86
- package/script/context/ParseContext.d.ts +16 -0
- package/script/context/ParseContext.d.ts.map +1 -1
- package/script/context/ParseContext.js +16 -0
- package/script/context/ParseIssue.d.ts +1 -1
- package/script/context/RenderContext.d.ts +2 -6
- package/script/context/RenderContext.d.ts.map +1 -1
- package/script/context/RenderContext.js +4 -14
- package/script/context/generateTypes.d.ts +35 -8
- package/script/context/generateTypes.d.ts.map +1 -1
- package/{esm/deps/jsr.io/@std/fs/1.0.23 → script/deps/jsr.io/@std/fs/1.0.24}/exists.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/internal/1.0.14/_os.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/_os.js +7 -5
- package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/os.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/log/0.224.14/rotating_file_handler.js +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/assert_path.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/assert_path.js +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/constants.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/constants.js +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/from_file_url.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/from_file_url.js +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/normalize.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/normalize.js +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/normalize_string.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/normalize_string.js +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/join.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/join.js +2 -2
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/normalize.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/normalize.js +2 -2
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/_util.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/_util.js +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/from_file_url.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/from_file_url.js +1 -1
- package/{esm/deps/jsr.io/@std/path/1.1.4 → script/deps/jsr.io/@std/path/1.1.6}/posix/join.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/join.js +1 -1
- package/{esm/deps/jsr.io/@std/path/1.1.4 → script/deps/jsr.io/@std/path/1.1.6}/posix/normalize.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/normalize.js +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/windows/_util.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/windows/_util.js +1 -1
- package/{esm/deps/jsr.io/@std/path/1.1.4 → script/deps/jsr.io/@std/path/1.1.6}/windows/from_file_url.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/windows/from_file_url.js +1 -1
- package/{esm/deps/jsr.io/@std/path/1.1.4 → script/deps/jsr.io/@std/path/1.1.6}/windows/join.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/windows/join.js +1 -1
- package/{esm/deps/jsr.io/@std/path/1.1.4 → script/deps/jsr.io/@std/path/1.1.6}/windows/normalize.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/windows/normalize.js +1 -1
- package/script/dsl/CodeFileBase.d.ts +57 -24
- package/script/dsl/CodeFileBase.d.ts.map +1 -1
- package/script/dsl/CodeFileBase.js +37 -54
- package/script/dsl/FileBase.d.ts +21 -25
- package/script/dsl/FileBase.d.ts.map +1 -1
- package/script/dsl/FileBase.js +20 -29
- package/script/dsl/GeneratorKeys.d.ts +19 -19
- package/script/dsl/GeneratorKeys.d.ts.map +1 -1
- package/script/dsl/GeneratorKeys.js +6 -5
- package/script/dsl/IdentifierBase.d.ts +19 -5
- package/script/dsl/IdentifierBase.d.ts.map +1 -1
- package/script/dsl/IdentifierBase.js +21 -5
- package/script/dsl/IdentifierType.d.ts +8 -14
- package/script/dsl/IdentifierType.d.ts.map +1 -1
- package/script/dsl/Lang.d.ts +18 -38
- package/script/dsl/Lang.d.ts.map +1 -1
- package/script/dsl/MarkdownFile.d.ts +55 -0
- package/script/dsl/MarkdownFile.d.ts.map +1 -0
- package/script/dsl/MarkdownFile.js +62 -0
- package/script/dsl/model/ModelDriver.d.ts +3 -1
- package/script/dsl/model/ModelDriver.d.ts.map +1 -1
- package/script/dsl/model/ModelDriver.js +29 -2
- package/script/dsl/model/toModelEntry.d.ts +24 -14
- package/script/dsl/model/toModelEntry.d.ts.map +1 -1
- package/script/dsl/model/toModelEntry.js +7 -3
- package/script/dsl/model/toModelProjectionBase.d.ts +31 -18
- package/script/dsl/model/toModelProjectionBase.d.ts.map +1 -1
- package/script/dsl/model/toModelProjectionBase.js +3 -3
- package/script/dsl/model/types.d.ts +23 -27
- package/script/dsl/model/types.d.ts.map +1 -1
- package/script/dsl/operation/gql/GqlOperationDriver.d.ts +3 -1
- package/script/dsl/operation/gql/GqlOperationDriver.d.ts.map +1 -1
- package/script/dsl/operation/gql/GqlOperationDriver.js +12 -9
- package/script/dsl/operation/gql/toGqlOperationEntry.d.ts +20 -15
- package/script/dsl/operation/gql/toGqlOperationEntry.d.ts.map +1 -1
- package/script/dsl/operation/gql/toGqlOperationEntry.js +3 -61
- package/script/dsl/operation/gql/toGqlOperationProjectionBase.d.ts +11 -10
- package/script/dsl/operation/gql/toGqlOperationProjectionBase.d.ts.map +1 -1
- package/script/dsl/operation/gql/types.d.ts +1 -28
- package/script/dsl/operation/gql/types.d.ts.map +1 -1
- package/script/dsl/operation/oas/OasOperationDriver.d.ts +3 -1
- package/script/dsl/operation/oas/OasOperationDriver.d.ts.map +1 -1
- package/script/dsl/operation/oas/OasOperationDriver.js +12 -9
- package/script/dsl/operation/oas/toOasOperationEntry.d.ts +21 -17
- package/script/dsl/operation/oas/toOasOperationEntry.d.ts.map +1 -1
- package/script/dsl/operation/oas/toOasOperationEntry.js +3 -68
- package/script/dsl/operation/oas/toOasOperationProjectionBase.d.ts +11 -10
- package/script/dsl/operation/oas/toOasOperationProjectionBase.d.ts.map +1 -1
- package/script/dsl/operation/oas/types.d.ts +1 -38
- package/script/dsl/operation/oas/types.d.ts.map +1 -1
- package/script/dsl/webhook/WebhookDriver.d.ts +3 -1
- package/script/dsl/webhook/WebhookDriver.d.ts.map +1 -1
- package/script/dsl/webhook/WebhookDriver.js +12 -9
- package/script/dsl/webhook/toWebhookEntry.d.ts +21 -16
- package/script/dsl/webhook/toWebhookEntry.d.ts.map +1 -1
- package/script/dsl/webhook/toWebhookEntry.js +3 -68
- package/script/dsl/webhook/toWebhookProjectionBase.d.ts +11 -10
- package/script/dsl/webhook/toWebhookProjectionBase.d.ts.map +1 -1
- package/script/dsl/webhook/types.d.ts +1 -36
- package/script/dsl/webhook/types.d.ts.map +1 -1
- package/script/enrichments/toEnrichmentDescriptor.d.ts +72 -27
- package/script/enrichments/toEnrichmentDescriptor.d.ts.map +1 -1
- package/script/enrichments/toEnrichmentDescriptor.js +57 -31
- package/script/enrichments/validateConfig.d.ts +60 -0
- package/script/enrichments/validateConfig.d.ts.map +1 -0
- package/script/enrichments/validateConfig.js +213 -0
- package/script/helpers/isImported.js +1 -1
- package/script/helpers/toResolvedArtifactPath.js +1 -1
- package/script/mod.d.ts +8 -1
- package/script/mod.d.ts.map +1 -1
- package/script/mod.js +8 -1
- package/script/oas/array/Array.d.ts +2 -0
- package/script/oas/array/Array.d.ts.map +1 -1
- package/script/oas/array/Array.js +4 -0
- package/script/oas/boolean/Boolean.d.ts +3 -1
- package/script/oas/boolean/Boolean.d.ts.map +1 -1
- package/script/oas/boolean/Boolean.js +4 -0
- package/script/oas/components/Components.d.ts +5 -0
- package/script/oas/components/Components.d.ts.map +1 -1
- package/script/oas/components/Components.js +6 -1
- package/script/oas/integer/Integer.d.ts +3 -1
- package/script/oas/integer/Integer.d.ts.map +1 -1
- package/script/oas/integer/Integer.js +4 -0
- package/script/oas/link/Link.d.ts +68 -0
- package/script/oas/link/Link.d.ts.map +1 -0
- package/script/oas/link/Link.js +111 -0
- package/script/oas/number/Number.d.ts +3 -1
- package/script/oas/number/Number.d.ts.map +1 -1
- package/script/oas/number/Number.js +4 -0
- package/script/oas/object/Object.d.ts +9 -0
- package/script/oas/object/Object.d.ts.map +1 -1
- package/script/oas/object/Object.js +14 -0
- package/script/oas/operation/Operation.d.ts +15 -0
- package/script/oas/operation/Operation.d.ts.map +1 -1
- package/script/oas/operation/Operation.js +33 -0
- package/script/oas/ref/Ref.d.ts +23 -1
- package/script/oas/ref/Ref.d.ts.map +1 -1
- package/script/oas/ref/Ref.js +32 -0
- package/script/oas/ref/ref-types.d.ts +18 -1
- package/script/oas/ref/ref-types.d.ts.map +1 -1
- package/script/oas/ref/ref-types.js +13 -2
- package/script/oas/response/Response.d.ts +4 -0
- package/script/oas/response/Response.d.ts.map +1 -1
- package/script/oas/response/Response.js +7 -0
- package/script/oas/schemaPath/traverseSchema.d.ts +31 -0
- package/script/oas/schemaPath/traverseSchema.d.ts.map +1 -0
- package/script/oas/schemaPath/traverseSchema.js +117 -0
- package/script/oas/string/String.d.ts +3 -1
- package/script/oas/string/String.d.ts.map +1 -1
- package/script/oas/string/String.js +4 -0
- package/script/oas/union/Union.d.ts +9 -0
- package/script/oas/union/Union.d.ts.map +1 -1
- package/script/oas/union/Union.js +14 -0
- package/script/oas/unknown/Unknown.d.ts +3 -1
- package/script/oas/unknown/Unknown.d.ts.map +1 -1
- package/script/oas/unknown/Unknown.js +4 -0
- package/script/parse/v3-0/_merge-all-of/decompose-union.d.ts.map +1 -1
- package/script/parse/v3-0/_merge-all-of/decompose-union.js +8 -12
- package/script/parse/v3-0/_merge-all-of/merge-union.d.ts.map +1 -1
- package/script/parse/v3-0/_merge-all-of/merge-union.js +0 -8
- package/script/parse/v3-0/components/toComponentsV3.d.ts.map +1 -1
- package/script/parse/v3-0/components/toComponentsV3.js +3 -1
- package/script/parse/v3-0/link/toLinksV3.d.ts +17 -0
- package/script/parse/v3-0/link/toLinksV3.d.ts.map +1 -0
- package/script/parse/v3-0/link/toLinksV3.js +44 -0
- package/script/parse/v3-0/object/toObject.d.ts.map +1 -1
- package/script/parse/v3-0/object/toObject.js +3 -1
- package/script/parse/v3-0/response/toResponseV3.d.ts.map +1 -1
- package/script/parse/v3-0/response/toResponseV3.js +4 -1
- package/script/parse/v3-0/schema/toSchemasV3.d.ts.map +1 -1
- package/script/parse/v3-0/schema/toSchemasV3.js +8 -0
- package/script/parse/v3-0/union/toUnion.d.ts.map +1 -1
- package/script/parse/v3-0/union/toUnion.js +3 -1
- package/script/parse/v3-1/_merge-all-of/decompose-union.d.ts.map +1 -1
- package/script/parse/v3-1/_merge-all-of/decompose-union.js +8 -12
- package/script/parse/v3-1/_merge-all-of/merge-union.d.ts.map +1 -1
- package/script/parse/v3-1/_merge-all-of/merge-union.js +0 -8
- package/script/parse/v3-1/components/toComponentsV3.d.ts.map +1 -1
- package/script/parse/v3-1/components/toComponentsV3.js +3 -1
- package/script/parse/v3-1/link/toLinksV3.d.ts +17 -0
- package/script/parse/v3-1/link/toLinksV3.d.ts.map +1 -0
- package/script/parse/v3-1/link/toLinksV3.js +44 -0
- package/script/parse/v3-1/object/toObject.d.ts.map +1 -1
- package/script/parse/v3-1/object/toObject.js +3 -1
- package/script/parse/v3-1/response/toResponseV3.d.ts.map +1 -1
- package/script/parse/v3-1/response/toResponseV3.js +4 -1
- package/script/parse/v3-1/schema/toSchemasV3.d.ts.map +1 -1
- package/script/parse/v3-1/schema/toSchemasV3.js +8 -0
- package/script/parse/v3-1/union/toUnion.d.ts.map +1 -1
- package/script/parse/v3-1/union/toUnion.js +3 -1
- package/script/run/toArtifacts.d.ts +8 -1
- package/script/run/toArtifacts.d.ts.map +1 -1
- package/script/run/toArtifacts.js +5 -5
- package/script/run/toInspection.d.ts +8 -0
- package/script/run/toInspection.d.ts.map +1 -0
- package/script/run/toInspection.js +82 -0
- package/script/types/Enrichments.d.ts +19 -8
- package/script/types/Enrichments.d.ts.map +1 -1
- package/script/types/Enrichments.js +5 -4
- package/script/types/GeneratorType.d.ts +5 -5
- package/script/types/GeneratorType.d.ts.map +1 -1
- package/script/types/Manifest.d.ts +1 -2
- package/script/types/Manifest.d.ts.map +1 -1
- package/script/types/Manifest.js +0 -1
- package/script/types/ModuleSelect.d.ts +81 -0
- package/script/types/ModuleSelect.d.ts.map +1 -0
- package/script/types/ModuleSelect.js +101 -0
- package/script/types/Preview.d.ts +4 -27
- package/script/types/Preview.d.ts.map +1 -1
- package/script/types/Preview.js +5 -26
- package/script/types/SchemaPath.d.ts +17 -0
- package/script/types/SchemaPath.d.ts.map +1 -0
- package/script/types/{AccessorPath.js → SchemaPath.js} +7 -7
- package/script/types/Settings.d.ts +24 -3
- package/script/types/Settings.d.ts.map +1 -1
- package/script/types/Settings.js +17 -10
- package/script/types/SkmtcDocument.d.ts +1 -1
- package/script/types/SupportedSubjects.d.ts +1 -1
- package/esm/deps/jsr.io/@std/internal/1.0.13/_os.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/internal/1.0.13/_os.js +0 -12
- package/esm/types/AccessorPath.d.ts +0 -17
- package/esm/types/AccessorPath.d.ts.map +0 -1
- package/esm/types/AccessorPath.js +0 -9
- package/script/deps/jsr.io/@std/internal/1.0.13/_os.d.ts.map +0 -1
- package/script/types/AccessorPath.d.ts +0 -17
- package/script/types/AccessorPath.d.ts.map +0 -1
- /package/esm/deps/jsr.io/@std/fs/{1.0.23 → 1.0.24}/exists.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/fs/{1.0.23 → 1.0.24}/exists.js +0 -0
- /package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/_os.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/os.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/os.js +0 -0
- /package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/assert_path.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/constants.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/from_file_url.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/normalize.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/normalize_string.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/join.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/normalize.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/_util.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/from_file_url.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/join.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/normalize.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/windows/_util.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/windows/from_file_url.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/windows/join.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/windows/normalize.d.ts +0 -0
- /package/script/deps/jsr.io/@std/fs/{1.0.23 → 1.0.24}/exists.d.ts +0 -0
- /package/script/deps/jsr.io/@std/fs/{1.0.23 → 1.0.24}/exists.js +0 -0
- /package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/_os.d.ts +0 -0
- /package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/os.d.ts +0 -0
- /package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/os.js +0 -0
- /package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/assert_path.d.ts +0 -0
- /package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/constants.d.ts +0 -0
- /package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/from_file_url.d.ts +0 -0
- /package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/normalize.d.ts +0 -0
- /package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/_common/normalize_string.d.ts +0 -0
- /package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/join.d.ts +0 -0
- /package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/normalize.d.ts +0 -0
- /package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/_util.d.ts +0 -0
- /package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/from_file_url.d.ts +0 -0
- /package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/join.d.ts +0 -0
- /package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/posix/normalize.d.ts +0 -0
- /package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/windows/_util.d.ts +0 -0
- /package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/windows/from_file_url.d.ts +0 -0
- /package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/windows/join.d.ts +0 -0
- /package/script/deps/jsr.io/@std/path/{1.1.4 → 1.1.6}/windows/normalize.d.ts +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/dsl/model/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,gCAAgC,CAAA;AACzE,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,YAAY,CAAA;AACtC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAC5D,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAA;AACrD,OAAO,KAAK,EAA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,CAAC,GAAG,CAAC,CAAA;IACrD,EAAE,EAAE,MAAM,CAAA;IACV,IAAI,EAAE,OAAO,CAAA;IACb;;;;;OAKG;IACH,IAAI,EAAE,IAAI,CAAA;IACV,gCAAgC;IAChC,gBAAgB,EAAE,CAAC,IAAI,EAAE,yBAAyB,CAAC,cAAc,CAAC,KAAK,MAAM,CAAA;IAC7E;;;;;OAKG;IACH,gBAAgB,EAAE,CAAC,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,mBAAmB,KAAK,cAAc,CAAA;IACpF,YAAY,EAAE,CAAC,IAAI,EAAE,qBAAqB,CAAC,cAAc,CAAC,KAAK,MAAM,CAAA;IACrE,aAAa,EAAE,CAAC,EAAE,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,EAAE,sBAAsB,KAAK,cAAc,CAAA;IACxF;;;;;;OAMG;IACH,WAAW,CAAC,EAAE,CAAC,IAAI,EAAE,oBAAoB,KAAK,OAAO,CAAA;IACrD,eAAe,EAAE,eAAe,CAAA;IAChC;;;;;OAKG;IACH,gBAAgB,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,cAAc,CAAA;CAEnD,GAAG,QAAQ,CAAA"}
|
|
@@ -15,8 +15,10 @@ type CreateGqlOperationArgs<V extends GeneratedValue, EnrichmentType = undefined
|
|
|
15
15
|
* peer's enrichment for this variant, asserts the variant exists
|
|
16
16
|
* (or is the default `'main'` which is always permitted), and
|
|
17
17
|
* threads it into the projection's `ContentSettings`.
|
|
18
|
+
* Optional — omitting it means `'main'`, so variants-unaware
|
|
19
|
+
* callers keep working unchanged.
|
|
18
20
|
*/
|
|
19
|
-
variant
|
|
21
|
+
variant?: string;
|
|
20
22
|
};
|
|
21
23
|
/**
|
|
22
24
|
* Driver for the GraphQL operation insertion lifecycle.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GqlOperationDriver.d.ts","sourceRoot":"","sources":["../../../../src/dsl/operation/gql/GqlOperationDriver.ts"],"names":[],"mappings":"A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AAE,cAAc,CAAC,CAAA;IACrD,SAAS,EAAE,YAAY,CAAA;IACvB,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB;;;;;;;OAOG;IACH,OAAO,CAAC,EAAE,MAAM,CAAA;CACjB,CAAA;AAWD;;;;;;;;GAQG;AACH,qBAAa,kBAAkB,CAAC,CAAC,SAAS,cAAc,EAAE,cAAc,GAAG,SAAS;IAClF,OAAO,EAAE,mBAAmB,CAAA;IAC5B,UAAU,EAAE,sBAAsB,CAAC,CAAC,EAAE,cAAc,CAAC,CAAA;IACrD,SAAS,EAAE,YAAY,CAAA;IACvB,QAAQ,EAAE,eAAe,CAAC,cAAc,CAAC,CAAA;IACzC,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB,UAAU,EAAE,mBAAmB,CAAC,CAAC,CAAC,CAAA;IAClC,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,OAAO,EAAE,MAAM,CAAA;gBAEH,EACV,OAAO,EACP,UAAU,EACV,SAAS,EACT,eAAe,EACf,QAAQ,EACR,OAAyB,EAC1B,EAAE,sBAAsB,CAAC,CAAC,EAAE,cAAc,CAAC;IA0B5C,OAAO,CAAC,KAAK;IAsBb;;;;;OAKG;IACH,OAAO,CAAC,UAAU;IAYlB,OAAO,CAAC,aAAa;IAgCrB,OAAO,CAAC,gBAAgB;CAsBzB"}
|
|
@@ -4,7 +4,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.GqlOperationDriver = void 0;
|
|
7
|
-
const normalize_js_1 = require("../../../deps/jsr.io/@std/path/1.1.
|
|
7
|
+
const normalize_js_1 = require("../../../deps/jsr.io/@std/path/1.1.6/normalize.js");
|
|
8
8
|
const GeneratorKeys_js_1 = require("../../GeneratorKeys.js");
|
|
9
9
|
const Variant_js_1 = require("../../../types/Variant.js");
|
|
10
10
|
const get_js_1 = __importDefault(require("lodash-es/get.js"));
|
|
@@ -18,7 +18,7 @@ const get_js_1 = __importDefault(require("lodash-es/get.js"));
|
|
|
18
18
|
* into `destinationPath` if it differs from the projection's `exportPath`.
|
|
19
19
|
*/
|
|
20
20
|
class GqlOperationDriver {
|
|
21
|
-
constructor({ context, projection, operation, destinationPath, noExport, variant }) {
|
|
21
|
+
constructor({ context, projection, operation, destinationPath, noExport, variant = Variant_js_1.DEFAULT_VARIANT }) {
|
|
22
22
|
Object.defineProperty(this, "context", {
|
|
23
23
|
enumerable: true,
|
|
24
24
|
configurable: true,
|
|
@@ -79,7 +79,7 @@ class GqlOperationDriver {
|
|
|
79
79
|
operation,
|
|
80
80
|
variant
|
|
81
81
|
});
|
|
82
|
-
assertPeerSupported({ context, projection, operation });
|
|
82
|
+
assertPeerSupported({ context, projection, operation, variant });
|
|
83
83
|
this.settings = this.context.toOperationContentSettings({
|
|
84
84
|
operation,
|
|
85
85
|
projection,
|
|
@@ -171,7 +171,12 @@ const assertPeerVariantExists = ({ context, generatorId, operation, variant }) =
|
|
|
171
171
|
if (variant === Variant_js_1.DEFAULT_VARIANT) {
|
|
172
172
|
return;
|
|
173
173
|
}
|
|
174
|
-
const opEnrichments = (0, get_js_1.default)(context.settings, [
|
|
174
|
+
const opEnrichments = (0, get_js_1.default)(context.settings, [
|
|
175
|
+
'enrichments',
|
|
176
|
+
generatorId,
|
|
177
|
+
operation.rootKind,
|
|
178
|
+
operation.fieldName
|
|
179
|
+
]);
|
|
175
180
|
const operationLabel = `${operation.rootKind} ${operation.fieldName}`;
|
|
176
181
|
if (opEnrichments === null || opEnrichments === undefined) {
|
|
177
182
|
throw new Error(`[${generatorId}] Cannot insert variant '${variant}' for '${operationLabel}' — ` +
|
|
@@ -198,11 +203,9 @@ const assertPeerVariantExists = ({ context, generatorId, operation, variant }) =
|
|
|
198
203
|
* `GenerateContext`'s per-item `try/catch`. A peer with no static
|
|
199
204
|
* `isSupported` is treated as supporting every operation.
|
|
200
205
|
*/
|
|
201
|
-
const assertPeerSupported = ({ context, projection, operation }) => {
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
}
|
|
205
|
-
if (!projection.isSupported({ operation, context })) {
|
|
206
|
+
const assertPeerSupported = ({ context, projection, operation, variant }) => {
|
|
207
|
+
const isSupported = projection.isSupported ?? (() => true);
|
|
208
|
+
if (!isSupported({ operation, context, variant })) {
|
|
206
209
|
const operationLabel = `${operation.rootKind} ${operation.fieldName}`;
|
|
207
210
|
throw new Error(`[${projection.id}] Cannot insert '${operationLabel}' — peer generator ` +
|
|
208
211
|
`does not support this operation (isSupported returned false).`);
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import * as v from 'valibot';
|
|
1
|
+
import type * as v from 'valibot';
|
|
2
2
|
import type { GqlOperation } from '../../../gql/operation/GqlOperation.js';
|
|
3
3
|
import type { EnrichmentRequest } from '../../../types/EnrichmentRequest.js';
|
|
4
|
-
import type { IsSupportedGqlOperationArgs, ToGqlOperationPreviewModuleArgs,
|
|
5
|
-
import type {
|
|
4
|
+
import type { IsSupportedGqlOperationArgs, ToGqlOperationPreviewModuleArgs, TransformGqlOperationArgs } from './types.js';
|
|
5
|
+
import type { PreviewModule } from '../../../types/Preview.js';
|
|
6
6
|
/**
|
|
7
7
|
* Configuration arguments for creating GraphQL operation generator entries.
|
|
8
8
|
*
|
|
@@ -15,9 +15,23 @@ export type ToGqlOperationConfigArgs<EnrichmentType = undefined> = {
|
|
|
15
15
|
id: string;
|
|
16
16
|
transform: ({ context, operation, variant }: TransformGqlOperationArgs) => void;
|
|
17
17
|
toEnrichmentSchema: () => v.GenericSchema<EnrichmentType>;
|
|
18
|
-
isSupported?: (
|
|
18
|
+
isSupported?: (args: IsSupportedGqlOperationArgs) => boolean;
|
|
19
|
+
/**
|
|
20
|
+
* Optional: whether this generator entry supports variants. Defaults to a
|
|
21
|
+
* function returning `false` when omitted.
|
|
22
|
+
*/
|
|
23
|
+
supportsVariant?: () => boolean;
|
|
24
|
+
toPreviewModule?: ({ context, operation }: ToGqlOperationPreviewModuleArgs) => PreviewModule;
|
|
25
|
+
toEnrichmentRequest?: <RequestedEnrichment extends EnrichmentType>(operation: GqlOperation) => EnrichmentRequest<RequestedEnrichment> | undefined;
|
|
26
|
+
};
|
|
27
|
+
export type GqlOperationEntry<EnrichmentType = undefined> = {
|
|
28
|
+
id: string;
|
|
29
|
+
type: 'gqlOperation';
|
|
30
|
+
transform: ({ context, operation, variant }: TransformGqlOperationArgs) => void;
|
|
31
|
+
toEnrichmentSchema: () => v.GenericSchema<EnrichmentType>;
|
|
32
|
+
isSupported: (args: IsSupportedGqlOperationArgs) => boolean;
|
|
33
|
+
supportsVariant: () => boolean;
|
|
19
34
|
toPreviewModule?: ({ context, operation }: ToGqlOperationPreviewModuleArgs) => PreviewModule;
|
|
20
|
-
toMappingModule?: ({ context, operation }: ToGqlOperationMappingArgs) => MappingModule;
|
|
21
35
|
toEnrichmentRequest?: <RequestedEnrichment extends EnrichmentType>(operation: GqlOperation) => EnrichmentRequest<RequestedEnrichment> | undefined;
|
|
22
36
|
};
|
|
23
37
|
/**
|
|
@@ -31,14 +45,5 @@ export type ToGqlOperationConfigArgs<EnrichmentType = undefined> = {
|
|
|
31
45
|
* @param config - Configuration object defining operation behavior
|
|
32
46
|
* @returns Configured operation generator entry ready for pipeline integration
|
|
33
47
|
*/
|
|
34
|
-
export declare const toGqlOperationEntry: <EnrichmentType = undefined>({ id, transform, toEnrichmentSchema, isSupported,
|
|
35
|
-
id: string;
|
|
36
|
-
type: "gqlOperation";
|
|
37
|
-
transform: ({ context, operation, variant }: TransformGqlOperationArgs) => void;
|
|
38
|
-
toEnrichmentSchema: () => v.GenericSchema<EnrichmentType>;
|
|
39
|
-
isSupported: ({ context, operation }: IsSupportedGqlOperationArgs) => boolean;
|
|
40
|
-
toPreviewModule?: ({ context, operation }: ToGqlOperationPreviewModuleArgs) => PreviewModule;
|
|
41
|
-
toMappingModule?: ({ context, operation }: ToGqlOperationMappingArgs) => MappingModule;
|
|
42
|
-
toEnrichmentRequest?: <RequestedEnrichment extends EnrichmentType>(operation: GqlOperation) => EnrichmentRequest<RequestedEnrichment> | undefined;
|
|
43
|
-
};
|
|
48
|
+
export declare const toGqlOperationEntry: <EnrichmentType = undefined>({ id, transform, toEnrichmentSchema, isSupported, supportsVariant, toPreviewModule, toEnrichmentRequest }: ToGqlOperationConfigArgs<EnrichmentType>) => GqlOperationEntry<EnrichmentType>;
|
|
44
49
|
//# sourceMappingURL=toGqlOperationEntry.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"toGqlOperationEntry.d.ts","sourceRoot":"","sources":["../../../../src/dsl/operation/gql/toGqlOperationEntry.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;
|
|
1
|
+
{"version":3,"file":"toGqlOperationEntry.d.ts","sourceRoot":"","sources":["../../../../src/dsl/operation/gql/toGqlOperationEntry.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,CAAC,MAAM,SAAS,CAAA;AACjC,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,wCAAwC,CAAA;AAC1E,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAA;AAC5E,OAAO,KAAK,EACV,2BAA2B,EAC3B,+BAA+B,EAE/B,yBAAyB,EAC1B,MAAM,YAAY,CAAA;AACnB,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAA;AAE9D;;;;;;;GAOG;AACH,MAAM,MAAM,wBAAwB,CAAC,cAAc,GAAG,SAAS,IAAI;IACjE,EAAE,EAAE,MAAM,CAAA;IACV,SAAS,EAAE,CAAC,EAAE,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,EAAE,yBAAyB,KAAK,IAAI,CAAA;IAC/E,kBAAkB,EAAE,MAAM,CAAC,CAAC,aAAa,CAAC,cAAc,CAAC,CAAA;IACzD,WAAW,CAAC,EAAE,C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
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
-
var ownKeys = function(o) {
|
|
20
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
-
var ar = [];
|
|
22
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
-
return ar;
|
|
24
|
-
};
|
|
25
|
-
return ownKeys(o);
|
|
26
|
-
};
|
|
27
|
-
return function (mod) {
|
|
28
|
-
if (mod && mod.__esModule) return mod;
|
|
29
|
-
var result = {};
|
|
30
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
-
__setModuleDefault(result, mod);
|
|
32
|
-
return result;
|
|
33
|
-
};
|
|
34
|
-
})();
|
|
35
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
36
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
37
|
-
};
|
|
38
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
3
|
exports.toGqlOperationEntry = void 0;
|
|
40
|
-
const v = __importStar(require("valibot"));
|
|
41
|
-
const Enrichments_js_1 = require("../../../types/Enrichments.js");
|
|
42
|
-
const get_js_1 = __importDefault(require("lodash-es/get.js"));
|
|
43
4
|
/**
|
|
44
5
|
* Creates a configured GraphQL operation generator entry.
|
|
45
6
|
*
|
|
@@ -51,34 +12,15 @@ const get_js_1 = __importDefault(require("lodash-es/get.js"));
|
|
|
51
12
|
* @param config - Configuration object defining operation behavior
|
|
52
13
|
* @returns Configured operation generator entry ready for pipeline integration
|
|
53
14
|
*/
|
|
54
|
-
const toGqlOperationEntry = ({ id, transform, toEnrichmentSchema, isSupported,
|
|
15
|
+
const toGqlOperationEntry = ({ id, transform, toEnrichmentSchema, isSupported, supportsVariant, toPreviewModule, toEnrichmentRequest }) => {
|
|
55
16
|
return {
|
|
56
17
|
id,
|
|
57
18
|
type: 'gqlOperation',
|
|
58
19
|
transform,
|
|
59
20
|
toEnrichmentSchema,
|
|
60
|
-
isSupported:
|
|
61
|
-
|
|
62
|
-
return true;
|
|
63
|
-
}
|
|
64
|
-
// Assemble the `{ subject, generator, stack }` enrichment umbrella and
|
|
65
|
-
// parse it cast-free — see the OAS-side shim for the rationale. Subject
|
|
66
|
-
// is variant-scoped (`[id][rootKind][fieldName][variant]`); generator
|
|
67
|
-
// and stack are run-constants.
|
|
68
|
-
const raw = {
|
|
69
|
-
subject: (0, get_js_1.default)(context.settings, ['enrichments', id, operation.rootKind, operation.fieldName, variant]),
|
|
70
|
-
generator: (0, get_js_1.default)(context.settings, ['enrichments', id, Enrichments_js_1.GENERATOR_ENRICHMENT_KEY]),
|
|
71
|
-
stack: (0, get_js_1.default)(context.settings, ['enrichments', Enrichments_js_1.STACK_ENRICHMENT_KEY])
|
|
72
|
-
};
|
|
73
|
-
return isSupported({
|
|
74
|
-
context,
|
|
75
|
-
operation,
|
|
76
|
-
enrichments: v.parse(toEnrichmentSchema(), raw),
|
|
77
|
-
variant
|
|
78
|
-
});
|
|
79
|
-
},
|
|
21
|
+
isSupported: isSupported ?? (() => true),
|
|
22
|
+
supportsVariant: supportsVariant ?? (() => false),
|
|
80
23
|
toPreviewModule,
|
|
81
|
-
toMappingModule,
|
|
82
24
|
toEnrichmentRequest
|
|
83
25
|
};
|
|
84
26
|
};
|
|
@@ -2,7 +2,7 @@ import type { GenerateContextType } from '../../../context/generateTypes.js';
|
|
|
2
2
|
import type { InsertOperationOptions, InsertModelOptions, InsertNormalizedModelArgs, InsertNormalizedModelReturn } from '../../../context/generateTypes.js';
|
|
3
3
|
import type { GqlOperation } from '../../../gql/operation/GqlOperation.js';
|
|
4
4
|
import type { ContentSettings } from '../../ContentSettings.js';
|
|
5
|
-
import type {
|
|
5
|
+
import type { LangSnippetConstructor } from '../../Lang.js';
|
|
6
6
|
import type { IdentifierType } from '../../IdentifierType.js';
|
|
7
7
|
import type { GeneratedValue } from '../../GeneratedValue.js';
|
|
8
8
|
import type { Inserted } from '../../Inserted.js';
|
|
@@ -17,20 +17,21 @@ import * as v from 'valibot';
|
|
|
17
17
|
* Configuration for {@link toGqlOperationProjectionBase}.
|
|
18
18
|
*
|
|
19
19
|
* Generic over the language `L`: a language veneer parameterizes this config
|
|
20
|
-
* (`GqlOperationProjectionBaseConfig<E,
|
|
21
|
-
* return tightens to that language's `
|
|
20
|
+
* (`GqlOperationProjectionBaseConfig<E, KtIdentifierType>`) so
|
|
21
|
+
* `toIdentifierType`'s return tightens to that language's `type` vocabulary —
|
|
22
|
+
* no recast.
|
|
22
23
|
*/
|
|
23
|
-
export type GqlOperationProjectionBaseConfig<EnrichmentType = undefined,
|
|
24
|
+
export type GqlOperationProjectionBaseConfig<EnrichmentType = undefined, IdType extends IdentifierType = IdentifierType> = {
|
|
24
25
|
id: string;
|
|
25
26
|
/** Pure: the cache-key name (the cache-check path runs this). */
|
|
26
27
|
toIdentifierName: (args: ToGqlOperationIdentifierNameArgs<EnrichmentType>) => string;
|
|
27
28
|
/**
|
|
28
29
|
* Context-aware, overridable: the non-`name` parts of the identifier,
|
|
29
30
|
* derived from the operation/schema. Runs only on cache-miss. Returns this
|
|
30
|
-
* language's `
|
|
31
|
-
* the tightening rides the type argument
|
|
31
|
+
* language's `XxIdentifierType` (`IdType`; the loose `kind: string` by
|
|
32
|
+
* default); the tightening rides the type argument.
|
|
32
33
|
*/
|
|
33
|
-
toIdentifierType: (operation: GqlOperation, context: GenerateContextType) =>
|
|
34
|
+
toIdentifierType: (operation: GqlOperation, context: GenerateContextType) => IdType;
|
|
34
35
|
toExportPath: (args: ToGqlOperationExportPathArgs<EnrichmentType>) => string;
|
|
35
36
|
/**
|
|
36
37
|
* Required composite schema for the `{ subject, generator, stack }`
|
|
@@ -77,7 +78,7 @@ type ToEnrichmentsArgs = {
|
|
|
77
78
|
* `GqlOperationProjectionBase` lives here now, because the base class is no
|
|
78
79
|
* longer statically known.
|
|
79
80
|
*/
|
|
80
|
-
export declare const toGqlOperationProjectionBase: <EnrichmentType = undefined,
|
|
81
|
+
export declare const toGqlOperationProjectionBase: <EnrichmentType = undefined, IdType extends IdentifierType = IdentifierType>(base: LangSnippetConstructor, config: GqlOperationProjectionBaseConfig<EnrichmentType, IdType>) => {
|
|
81
82
|
new (args: GqlOperationProjectionConstructorArgs<EnrichmentType>): {
|
|
82
83
|
settings: ContentSettings<EnrichmentType>;
|
|
83
84
|
operation: GqlOperation;
|
|
@@ -115,14 +116,14 @@ export declare const toGqlOperationProjectionBase: <EnrichmentType = undefined,
|
|
|
115
116
|
id: string;
|
|
116
117
|
type: "gqlOperation";
|
|
117
118
|
toIdentifierName: (args: ToGqlOperationIdentifierNameArgs<EnrichmentType>) => string;
|
|
118
|
-
toIdentifierType: (operation: GqlOperation, context: GenerateContextType) =>
|
|
119
|
+
toIdentifierType: (operation: GqlOperation, context: GenerateContextType) => IdType;
|
|
119
120
|
toExportPath: (args: ToGqlOperationExportPathArgs<EnrichmentType>) => string;
|
|
120
121
|
isSupported: (args: {
|
|
121
122
|
operation: GqlOperation;
|
|
122
123
|
context: GenerateContextType;
|
|
123
124
|
}) => boolean;
|
|
124
125
|
toEnrichments: ({ operation, context, variant }: ToEnrichmentsArgs) => EnrichmentType;
|
|
125
|
-
lang:
|
|
126
|
+
lang: import("../../Lang.js").Lang;
|
|
126
127
|
};
|
|
127
128
|
export {};
|
|
128
129
|
//# sourceMappingURL=toGqlOperationProjectionBase.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"toGqlOperationProjectionBase.d.ts","sourceRoot":"","sources":["../../../../src/dsl/operation/gql/toGqlOperationProjectionBase.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,mCAAmC,CAAA;AAC5E,OAAO,KAAK,EACV,sBAAsB,EACtB,kBAAkB,EAClB,yBAAyB,EACzB,2BAA2B,EAC5B,MAAM,mCAAmC,CAAA;AAC1C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,wCAAwC,CAAA;AAC1E,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAA;AAC/D,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"toGqlOperationProjectionBase.d.ts","sourceRoot":"","sources":["../../../../src/dsl/operation/gql/toGqlOperationProjectionBase.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,mCAAmC,CAAA;AAC5E,OAAO,KAAK,EACV,sBAAsB,EACtB,kBAAkB,EAClB,yBAAyB,EACzB,2BAA2B,EAC5B,MAAM,mCAAmC,CAAA;AAC1C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,wCAAwC,CAAA;AAC1E,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAA;AAC/D,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,eAAe,CAAA;AAC3D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAA;AAC7D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAA;AAC7D,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAA;AAC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G,cAAc;;CA4GxC,CAAA"}
|
|
@@ -4,9 +4,6 @@ import type { ContentSettings } from '../../ContentSettings.js';
|
|
|
4
4
|
import type { GenerateContextType } from '../../../context/generateTypes.js';
|
|
5
5
|
import type { IdentifierType } from '../../IdentifierType.js';
|
|
6
6
|
import type { GeneratedValue } from '../../GeneratedValue.js';
|
|
7
|
-
import type { EnrichmentRequest } from '../../../types/EnrichmentRequest.js';
|
|
8
|
-
import type * as v from 'valibot';
|
|
9
|
-
import type { MappingModule, PreviewModule } from '../../../types/Preview.js';
|
|
10
7
|
/**
|
|
11
8
|
* External constructor signature for a GraphQL operation projection class.
|
|
12
9
|
*
|
|
@@ -32,13 +29,6 @@ export type TransformGqlOperationArgs = {
|
|
|
32
29
|
export type WithTransformGqlOperation = {
|
|
33
30
|
transformOperation: (operation: GqlOperation) => void;
|
|
34
31
|
};
|
|
35
|
-
export type IsSupportedGqlOperationConfigArgs<EnrichmentType = undefined> = {
|
|
36
|
-
context: GenerateContextType;
|
|
37
|
-
operation: GqlOperation;
|
|
38
|
-
enrichments: EnrichmentType;
|
|
39
|
-
/** Operation variant being probed (see {@link Variant}) */
|
|
40
|
-
variant: string;
|
|
41
|
-
};
|
|
42
32
|
export type IsSupportedGqlOperationArgs = {
|
|
43
33
|
context: GenerateContextType;
|
|
44
34
|
operation: GqlOperation;
|
|
@@ -119,23 +109,6 @@ export type GqlOperationProjection<V extends GeneratedValue, EnrichmentType = un
|
|
|
119
109
|
* projection may omit it, in which case it is treated as supporting
|
|
120
110
|
* every operation.
|
|
121
111
|
*/
|
|
122
|
-
isSupported?: (args:
|
|
123
|
-
operation: GqlOperation;
|
|
124
|
-
context: GenerateContextType;
|
|
125
|
-
}) => boolean;
|
|
112
|
+
isSupported?: (args: IsSupportedGqlOperationArgs) => boolean;
|
|
126
113
|
} & Function;
|
|
127
|
-
/**
|
|
128
|
-
* Pipeline-side configuration for a GraphQL operation projection (built by
|
|
129
|
-
* `toGqlOperationEntry`).
|
|
130
|
-
*/
|
|
131
|
-
export type GqlOperationConfig<EnrichmentType = undefined> = {
|
|
132
|
-
id: string;
|
|
133
|
-
type: 'gqlOperation';
|
|
134
|
-
transform: ({ context, operation, variant }: TransformGqlOperationArgs) => void;
|
|
135
|
-
toEnrichmentSchema: () => v.GenericSchema<EnrichmentType>;
|
|
136
|
-
isSupported: ({ context, operation }: IsSupportedGqlOperationArgs) => boolean;
|
|
137
|
-
toPreviewModule?: ({ context, operation }: ToGqlOperationPreviewModuleArgs) => PreviewModule;
|
|
138
|
-
toMappingModule?: ({ context, operation }: ToGqlOperationMappingArgs) => MappingModule;
|
|
139
|
-
toEnrichmentRequest?: <RequestedEnrichment extends EnrichmentType>(operation: GqlOperation) => EnrichmentRequest<RequestedEnrichment> | undefined;
|
|
140
|
-
};
|
|
141
114
|
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/dsl/operation/gql/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,wCAAwC,CAAA;AAC1E,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,eAAe,CAAA;AACzC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAA;AAC/D,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,mCAAmC,CAAA;AAC5E,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAA;AAC7D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAA;
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/dsl/operation/gql/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,wCAAwC,CAAA;AAC1E,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,eAAe,CAAA;AACzC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAA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@ type CreateOperationArgs<V extends GeneratedValue, EnrichmentType = undefined> =
|
|
|
15
15
|
* peer's enrichment for this variant, asserts the variant exists
|
|
16
16
|
* (or is the default `'main'` which is always permitted), and
|
|
17
17
|
* threads it into the projection's `ContentSettings`.
|
|
18
|
+
* Optional — omitting it means `'main'`, so variants-unaware
|
|
19
|
+
* callers keep working unchanged.
|
|
18
20
|
*/
|
|
19
|
-
variant
|
|
21
|
+
variant?: string;
|
|
20
22
|
};
|
|
21
23
|
/**
|
|
22
24
|
* Driver for the OAS operation insertion lifecycle.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"OasOperationDriver.d.ts","sourceRoot":"","sources":["../../../../src/dsl/operation/oas/OasOperationDriver.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,YAAY,CAAA;AACxD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,qCAAqC,CAAA;AACvE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAA;AAI/D,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAA;AAClE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAA;AAE7D,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,mCAAmC,CAAA;AAK5E,KAAK,mBAAmB,CAAC,CAAC,SAAS,cAAc,EAAE,cAAc,GAAG,SAAS,IAAI;IAC/E,OAAO,EAAE,mBAAmB,CAAA;IAC5B,UAAU,EAAE,sBAAsB,CAAC,CAAC,EAAE,cAAc,CAAC,CAAA;IACrD,SAAS,EAAE,YAAY,CAAA;IACvB,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB
|
|
1
|
+
{"version":3,"file":"OasOperationDriver.d.ts","sourceRoot":"","sources":["../../../../src/dsl/operation/oas/OasOperationDriver.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,sBA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;IAsBb;;;;;OAKG;IACH,OAAO,CAAC,UAAU;IAYlB,OAAO,CAAC,aAAa;IAgCrB,OAAO,CAAC,gBAAgB;CAsBzB"}
|
|
@@ -4,7 +4,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.OasOperationDriver = void 0;
|
|
7
|
-
const normalize_js_1 = require("../../../deps/jsr.io/@std/path/1.1.
|
|
7
|
+
const normalize_js_1 = require("../../../deps/jsr.io/@std/path/1.1.6/normalize.js");
|
|
8
8
|
const GeneratorKeys_js_1 = require("../../GeneratorKeys.js");
|
|
9
9
|
const Variant_js_1 = require("../../../types/Variant.js");
|
|
10
10
|
const get_js_1 = __importDefault(require("lodash-es/get.js"));
|
|
@@ -18,7 +18,7 @@ const get_js_1 = __importDefault(require("lodash-es/get.js"));
|
|
|
18
18
|
* from the projection's `exportPath`.
|
|
19
19
|
*/
|
|
20
20
|
class OasOperationDriver {
|
|
21
|
-
constructor({ context, projection, operation, destinationPath, noExport, variant }) {
|
|
21
|
+
constructor({ context, projection, operation, destinationPath, noExport, variant = Variant_js_1.DEFAULT_VARIANT }) {
|
|
22
22
|
Object.defineProperty(this, "context", {
|
|
23
23
|
enumerable: true,
|
|
24
24
|
configurable: true,
|
|
@@ -79,7 +79,7 @@ class OasOperationDriver {
|
|
|
79
79
|
operation,
|
|
80
80
|
variant
|
|
81
81
|
});
|
|
82
|
-
assertPeerSupported({ context, projection, operation });
|
|
82
|
+
assertPeerSupported({ context, projection, operation, variant });
|
|
83
83
|
this.settings = this.context.toOperationContentSettings({
|
|
84
84
|
operation,
|
|
85
85
|
projection,
|
|
@@ -178,7 +178,12 @@ const assertPeerVariantExists = ({ context, generatorId, operation, variant }) =
|
|
|
178
178
|
if (variant === Variant_js_1.DEFAULT_VARIANT) {
|
|
179
179
|
return;
|
|
180
180
|
}
|
|
181
|
-
const opEnrichments = (0, get_js_1.default)(context.settings, [
|
|
181
|
+
const opEnrichments = (0, get_js_1.default)(context.settings, [
|
|
182
|
+
'enrichments',
|
|
183
|
+
generatorId,
|
|
184
|
+
operation.path,
|
|
185
|
+
operation.method
|
|
186
|
+
]);
|
|
182
187
|
const operationLabel = `${operation.method.toUpperCase()} ${operation.path}`;
|
|
183
188
|
if (opEnrichments === null || opEnrichments === undefined) {
|
|
184
189
|
throw new Error(`[${generatorId}] Cannot insert variant '${variant}' for '${operationLabel}' — ` +
|
|
@@ -215,11 +220,9 @@ const assertPeerVariantExists = ({ context, generatorId, operation, variant }) =
|
|
|
215
220
|
* supporting every operation: `toOasOperationProjectionBase` defaults
|
|
216
221
|
* it to `() => true`, and a hand-rolled projection may omit it.
|
|
217
222
|
*/
|
|
218
|
-
const assertPeerSupported = ({ context, projection, operation }) => {
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
}
|
|
222
|
-
if (!projection.isSupported({ operation, context })) {
|
|
223
|
+
const assertPeerSupported = ({ context, projection, operation, variant }) => {
|
|
224
|
+
const isSupported = projection.isSupported ?? (() => true);
|
|
225
|
+
if (!isSupported({ operation, context, variant })) {
|
|
223
226
|
const operationLabel = `${operation.method.toUpperCase()} ${operation.path}`;
|
|
224
227
|
throw new Error(`[${projection.id}] Cannot insert '${operationLabel}' — peer generator ` +
|
|
225
228
|
`does not support this operation (isSupported returned false).`);
|
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
import * as v from 'valibot';
|
|
1
|
+
import type * as v from 'valibot';
|
|
2
2
|
import type { OasOperation } from '../../../oas/operation/Operation.js';
|
|
3
3
|
import type { EnrichmentRequest } from '../../../types/EnrichmentRequest.js';
|
|
4
|
-
import type { IsSupportedOasOperationArgs, ToOasOperationPreviewModuleArgs,
|
|
5
|
-
import type {
|
|
6
|
-
import type { MappingModule, PreviewModule } from '../../../types/Preview.js';
|
|
4
|
+
import type { IsSupportedOasOperationArgs, ToOasOperationPreviewModuleArgs, ToOasOperationEnrichmentsArgs, TransformOasOperationArgs } from './types.js';
|
|
5
|
+
import type { PreviewModule } from '../../../types/Preview.js';
|
|
7
6
|
/**
|
|
8
7
|
* Configuration arguments for creating operation generator entries.
|
|
9
8
|
*
|
|
@@ -16,9 +15,13 @@ export type ToOasOperationConfigArgs<EnrichmentType = undefined> = {
|
|
|
16
15
|
id: string;
|
|
17
16
|
transform: ({ context, operation, variant }: TransformOasOperationArgs) => void;
|
|
18
17
|
toEnrichmentSchema: () => v.GenericSchema<EnrichmentType>;
|
|
19
|
-
isSupported?: (
|
|
18
|
+
isSupported?: (args: IsSupportedOasOperationArgs) => boolean;
|
|
19
|
+
/**
|
|
20
|
+
* Optional: whether this generator entry supports variants. Defaults to a
|
|
21
|
+
* function returning `false` when omitted.
|
|
22
|
+
*/
|
|
23
|
+
supportsVariant?: () => boolean;
|
|
20
24
|
toPreviewModule?: ({ context, operation }: ToOasOperationPreviewModuleArgs) => PreviewModule;
|
|
21
|
-
toMappingModule?: ({ context, operation }: ToOasOperationMappingArgs) => MappingModule;
|
|
22
25
|
toEnrichmentRequest?: <RequestedEnrichment extends EnrichmentType>(operation: OasOperation) => EnrichmentRequest<RequestedEnrichment> | undefined;
|
|
23
26
|
/**
|
|
24
27
|
* Optional: compute the DEFAULT enrichment values for an operation from its
|
|
@@ -30,6 +33,17 @@ export type ToOasOperationConfigArgs<EnrichmentType = undefined> = {
|
|
|
30
33
|
*/
|
|
31
34
|
toEnrichmentDefaults?: ({ operation, context, variant }: ToOasOperationEnrichmentsArgs) => EnrichmentType | undefined;
|
|
32
35
|
};
|
|
36
|
+
export type OasOperationEntry<EnrichmentType = undefined> = {
|
|
37
|
+
id: string;
|
|
38
|
+
type: 'oasOperation';
|
|
39
|
+
transform: ({ context, operation, variant }: TransformOasOperationArgs) => void;
|
|
40
|
+
toEnrichmentSchema: () => v.GenericSchema<EnrichmentType>;
|
|
41
|
+
isSupported: (args: IsSupportedOasOperationArgs) => boolean;
|
|
42
|
+
supportsVariant: () => boolean;
|
|
43
|
+
toPreviewModule?: ({ context, operation }: ToOasOperationPreviewModuleArgs) => PreviewModule;
|
|
44
|
+
toEnrichmentRequest?: <RequestedEnrichment extends EnrichmentType>(operation: OasOperation) => EnrichmentRequest<RequestedEnrichment> | undefined;
|
|
45
|
+
toEnrichmentDefaults?: ({ operation, context, variant }: ToOasOperationEnrichmentsArgs) => EnrichmentType | undefined;
|
|
46
|
+
};
|
|
33
47
|
/**
|
|
34
48
|
* Creates a configured operation generator entry.
|
|
35
49
|
*
|
|
@@ -56,15 +70,5 @@ export type ToOasOperationConfigArgs<EnrichmentType = undefined> = {
|
|
|
56
70
|
* });
|
|
57
71
|
* ```
|
|
58
72
|
*/
|
|
59
|
-
export declare const toOasOperationEntry: <EnrichmentType = undefined>({ id, transform, toEnrichmentSchema, isSupported,
|
|
60
|
-
id: string;
|
|
61
|
-
type: "oasOperation";
|
|
62
|
-
transform: ({ context, operation, variant }: TransformOasOperationArgs) => void;
|
|
63
|
-
toEnrichmentSchema: () => v.GenericSchema<EnrichmentType>;
|
|
64
|
-
isSupported: ({ context, operation }: IsSupportedOasOperationArgs) => boolean;
|
|
65
|
-
toPreviewModule?: ({ context, operation }: ToOasOperationPreviewModuleArgs) => PreviewModule;
|
|
66
|
-
toMappingModule?: ({ context, operation }: ToOasOperationMappingArgs) => MappingModule;
|
|
67
|
-
toEnrichmentRequest?: <RequestedEnrichment extends EnrichmentType>(operation: OasOperation) => EnrichmentRequest<RequestedEnrichment> | undefined;
|
|
68
|
-
toEnrichmentDefaults?: ({ operation, context, variant }: ToOasOperationEnrichmentsArgs) => EnrichmentType | undefined;
|
|
69
|
-
};
|
|
73
|
+
export declare const toOasOperationEntry: <EnrichmentType = undefined>({ id, transform, toEnrichmentSchema, isSupported, supportsVariant, toPreviewModule, toEnrichmentRequest, toEnrichmentDefaults }: ToOasOperationConfigArgs<EnrichmentType>) => OasOperationEntry<EnrichmentType>;
|
|
70
74
|
//# sourceMappingURL=toOasOperationEntry.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"toOasOperationEntry.d.ts","sourceRoot":"","sources":["../../../../src/dsl/operation/oas/toOasOperationEntry.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;
|
|
1
|
+
{"version":3,"file":"toOasOperationEntry.d.ts","sourceRoot":"","sources":["../../../../src/dsl/operation/oas/toOasOperationEntry.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,CAAC,MAAM,SAAS,CAAA;AACjC,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,qCAAqC,CAAA;AACvE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAA;AAC5E,OAAO,KAAK,EACV,2BAA2B,EAC3B,+BAA+B,EAE/B,6BAA6B,EAC7B,yBAAyB,EAC1B,MAAM,YAAY,CAAA;AACnB,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAA;AAE9D;;;;;;;GAOG;AACH,MAAM,MAAM,wBAAwB,CAAC,cAAc,GAAG,SAAS,IAAI;IACjE,EAAE,EAAE,MAAM,CAAA;IACV,SAAS,EAAE,CAAC,EAAE,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,EAAE,yBAAyB,KAAK,IAAI,CAAA;IAC/E,kBAAkB,EAAE,MAAM,CAAC,CAAC,aAAa,CAAC,cAAc,CAAC,CAAA;IACzD,WAAW,CAAC,EAAE,CAAC,IAAI,EAAE,2BAA2B,KAAK,OAAO,CAAA;IAC5D;;;OAGG;IACH,eAAe,CAAC,EAAE,MAAM,OAAO,CAAA;IAC/B,eAAe,CAAC,EAAE,CAAC,EAAE,OAAO,EAAE,SAAS,EAAE,EAAE,+BAA+B,KAAK,aAAa,CAAA;IAC5F,mBAAmB,CAAC,EAAE,CAAC,mBAAmB,SAAS,cAAc,EAC/D,SAAS,EAAE,YAAY,KACpB,iBAAiB,CAAC,mBAAmB,CAAC,GAAG,SAAS,CAAA;IACvD;;;;;;;OAOG;I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