@tsed/schema 8.9.5 → 8.10.0-rc.2
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/lib/browser/components/async-api/channelsMapper.js +51 -0
- package/lib/browser/components/async-api/channelsMapper.js.map +1 -0
- package/lib/browser/components/async-api/generate.js +15 -0
- package/lib/browser/components/async-api/generate.js.map +1 -0
- package/lib/browser/components/async-api/messageMapper.js +31 -0
- package/lib/browser/components/async-api/messageMapper.js.map +1 -0
- package/lib/browser/components/async-api/payloadMapper.js +47 -0
- package/lib/browser/components/async-api/payloadMapper.js.map +1 -0
- package/lib/browser/components/async-api/responseMapper.js +37 -0
- package/lib/browser/components/async-api/responseMapper.js.map +1 -0
- package/lib/browser/components/default/anyMapper.js +25 -0
- package/lib/browser/components/default/anyMapper.js.map +1 -0
- package/lib/browser/components/default/classMapper.js +36 -0
- package/lib/browser/components/default/classMapper.js.map +1 -0
- package/lib/browser/components/default/discriminatorMappingMapper.js +22 -0
- package/lib/browser/components/default/discriminatorMappingMapper.js.map +1 -0
- package/lib/browser/components/default/enumsMapper.js +10 -0
- package/lib/browser/components/default/enumsMapper.js.map +1 -0
- package/lib/browser/components/default/genericsMapper.js +51 -0
- package/lib/browser/components/default/genericsMapper.js.map +1 -0
- package/lib/browser/components/default/inheritedClassMapper.js +30 -0
- package/lib/browser/components/default/inheritedClassMapper.js.map +1 -0
- package/lib/browser/components/default/itemMapper.js +9 -0
- package/lib/browser/components/default/itemMapper.js.map +1 -0
- package/lib/browser/components/default/lazyRefMapper.js +17 -0
- package/lib/browser/components/default/lazyRefMapper.js.map +1 -0
- package/lib/browser/components/default/mapMapper.js +10 -0
- package/lib/browser/components/default/mapMapper.js.map +1 -0
- package/lib/browser/components/default/nullableMapper.js +32 -0
- package/lib/browser/components/default/nullableMapper.js.map +1 -0
- package/lib/browser/components/default/objectMapper.js +24 -0
- package/lib/browser/components/default/objectMapper.js.map +1 -0
- package/lib/browser/components/default/ofMapper.js +14 -0
- package/lib/browser/components/default/ofMapper.js.map +1 -0
- package/lib/browser/components/default/propertiesMapper.js +21 -0
- package/lib/browser/components/default/propertiesMapper.js.map +1 -0
- package/lib/browser/components/default/requiredMapper.js +28 -0
- package/lib/browser/components/default/requiredMapper.js.map +1 -0
- package/lib/browser/components/default/schemaMapper.js +68 -0
- package/lib/browser/components/default/schemaMapper.js.map +1 -0
- package/lib/browser/components/index.js +66 -0
- package/lib/browser/components/index.js.map +1 -0
- package/lib/browser/components/open-spec/discriminatorMappingMapper.js +7 -0
- package/lib/browser/components/open-spec/discriminatorMappingMapper.js.map +1 -0
- package/lib/browser/components/open-spec/enumsMapper.js +13 -0
- package/lib/browser/components/open-spec/enumsMapper.js.map +1 -0
- package/lib/browser/components/open-spec/generate.js +18 -0
- package/lib/browser/components/open-spec/generate.js.map +1 -0
- package/lib/browser/components/open-spec/nullableMapper.js +36 -0
- package/lib/browser/components/open-spec/nullableMapper.js.map +1 -0
- package/lib/browser/components/open-spec/operationInFilesMapper.js +21 -0
- package/lib/browser/components/open-spec/operationInFilesMapper.js.map +1 -0
- package/lib/browser/components/open-spec/operationInParameterMapper.js +31 -0
- package/lib/browser/components/open-spec/operationInParameterMapper.js.map +1 -0
- package/lib/browser/components/open-spec/operationInParametersMapper.js +9 -0
- package/lib/browser/components/open-spec/operationInParametersMapper.js.map +1 -0
- package/lib/browser/components/open-spec/operationInQueryMapper.js +46 -0
- package/lib/browser/components/open-spec/operationInQueryMapper.js.map +1 -0
- package/lib/browser/components/open-spec/operationMapper.js +33 -0
- package/lib/browser/components/open-spec/operationMapper.js.map +1 -0
- package/lib/browser/components/open-spec/operationMediaMapper.js +10 -0
- package/lib/browser/components/open-spec/operationMediaMapper.js.map +1 -0
- package/lib/browser/components/open-spec/operationRequestBodyMapper.js +40 -0
- package/lib/browser/components/open-spec/operationRequestBodyMapper.js.map +1 -0
- package/lib/browser/components/open-spec/operationResponseMapper.js +17 -0
- package/lib/browser/components/open-spec/operationResponseMapper.js.map +1 -0
- package/lib/browser/components/open-spec/pathsMapper.js +88 -0
- package/lib/browser/components/open-spec/pathsMapper.js.map +1 -0
- package/lib/browser/constants/OperationVerbs.js +24 -0
- package/lib/browser/constants/OperationVerbs.js.map +1 -0
- package/lib/browser/constants/httpStatusMessages.js +25 -0
- package/lib/browser/constants/httpStatusMessages.js.map +1 -0
- package/lib/browser/constants/jsonSchemaProperties.js +21 -0
- package/lib/browser/constants/jsonSchemaProperties.js.map +1 -0
- package/lib/browser/decorators/class/children.js +13 -0
- package/lib/browser/decorators/class/children.js.map +1 -0
- package/lib/browser/decorators/class/discriminatorValue.js +11 -0
- package/lib/browser/decorators/class/discriminatorValue.js.map +1 -0
- package/lib/browser/decorators/collections/collectionContains.js +8 -0
- package/lib/browser/decorators/collections/collectionContains.js.map +1 -0
- package/lib/browser/decorators/collections/collectionOf.js +26 -0
- package/lib/browser/decorators/collections/collectionOf.js.map +1 -0
- package/lib/browser/decorators/collections/maxItems.js +13 -0
- package/lib/browser/decorators/collections/maxItems.js.map +1 -0
- package/lib/browser/decorators/collections/maxProperties.js +13 -0
- package/lib/browser/decorators/collections/maxProperties.js.map +1 -0
- package/lib/browser/decorators/collections/minItems.js +13 -0
- package/lib/browser/decorators/collections/minItems.js.map +1 -0
- package/lib/browser/decorators/collections/minProperties.js +13 -0
- package/lib/browser/decorators/collections/minProperties.js.map +1 -0
- package/lib/browser/decorators/collections/uniqueItems.js +9 -0
- package/lib/browser/decorators/collections/uniqueItems.js.map +1 -0
- package/lib/browser/decorators/common/additionalProperties.js +10 -0
- package/lib/browser/decorators/common/additionalProperties.js.map +1 -0
- package/lib/browser/decorators/common/allOf.js +10 -0
- package/lib/browser/decorators/common/allOf.js.map +1 -0
- package/lib/browser/decorators/common/allow.js +16 -0
- package/lib/browser/decorators/common/allow.js.map +1 -0
- package/lib/browser/decorators/common/any.js +10 -0
- package/lib/browser/decorators/common/any.js.map +1 -0
- package/lib/browser/decorators/common/anyOf.js +10 -0
- package/lib/browser/decorators/common/anyOf.js.map +1 -0
- package/lib/browser/decorators/common/const.js +10 -0
- package/lib/browser/decorators/common/const.js.map +1 -0
- package/lib/browser/decorators/common/customKey.js +18 -0
- package/lib/browser/decorators/common/customKey.js.map +1 -0
- package/lib/browser/decorators/common/default.js +10 -0
- package/lib/browser/decorators/common/default.js.map +1 -0
- package/lib/browser/decorators/common/defaultMsg.js +9 -0
- package/lib/browser/decorators/common/defaultMsg.js.map +1 -0
- package/lib/browser/decorators/common/description.js +23 -0
- package/lib/browser/decorators/common/description.js.map +1 -0
- package/lib/browser/decorators/common/discriminatorKey.js +15 -0
- package/lib/browser/decorators/common/discriminatorKey.js.map +1 -0
- package/lib/browser/decorators/common/enum.js +12 -0
- package/lib/browser/decorators/common/enum.js.map +1 -0
- package/lib/browser/decorators/common/errorMsg.js +11 -0
- package/lib/browser/decorators/common/errorMsg.js.map +1 -0
- package/lib/browser/decorators/common/example.js +10 -0
- package/lib/browser/decorators/common/example.js.map +1 -0
- package/lib/browser/decorators/common/examples.js +10 -0
- package/lib/browser/decorators/common/examples.js.map +1 -0
- package/lib/browser/decorators/common/exclusiveMaximum.js +7 -0
- package/lib/browser/decorators/common/exclusiveMaximum.js.map +1 -0
- package/lib/browser/decorators/common/exclusiveMinimum.js +7 -0
- package/lib/browser/decorators/common/exclusiveMinimum.js.map +1 -0
- package/lib/browser/decorators/common/format.js +16 -0
- package/lib/browser/decorators/common/format.js.map +1 -0
- package/lib/browser/decorators/common/forwardGroups.js +10 -0
- package/lib/browser/decorators/common/forwardGroups.js.map +1 -0
- package/lib/browser/decorators/common/groups.js +31 -0
- package/lib/browser/decorators/common/groups.js.map +1 -0
- package/lib/browser/decorators/common/hidden.js +8 -0
- package/lib/browser/decorators/common/hidden.js.map +1 -0
- package/lib/browser/decorators/common/ignore.js +10 -0
- package/lib/browser/decorators/common/ignore.js.map +1 -0
- package/lib/browser/decorators/common/integer.js +10 -0
- package/lib/browser/decorators/common/integer.js.map +1 -0
- package/lib/browser/decorators/common/jsonEntityFn.js +11 -0
- package/lib/browser/decorators/common/jsonEntityFn.js.map +1 -0
- package/lib/browser/decorators/common/labelledAs.js +10 -0
- package/lib/browser/decorators/common/labelledAs.js.map +1 -0
- package/lib/browser/decorators/common/maxLength.js +13 -0
- package/lib/browser/decorators/common/maxLength.js.map +1 -0
- package/lib/browser/decorators/common/maximum.js +10 -0
- package/lib/browser/decorators/common/maximum.js.map +1 -0
- package/lib/browser/decorators/common/minLength.js +13 -0
- package/lib/browser/decorators/common/minLength.js.map +1 -0
- package/lib/browser/decorators/common/minimum.js +10 -0
- package/lib/browser/decorators/common/minimum.js.map +1 -0
- package/lib/browser/decorators/common/multipleOf.js +13 -0
- package/lib/browser/decorators/common/multipleOf.js.map +1 -0
- package/lib/browser/decorators/common/name.js +20 -0
- package/lib/browser/decorators/common/name.js.map +1 -0
- package/lib/browser/decorators/common/nullable.js +10 -0
- package/lib/browser/decorators/common/nullable.js.map +1 -0
- package/lib/browser/decorators/common/oneOf.js +10 -0
- package/lib/browser/decorators/common/oneOf.js.map +1 -0
- package/lib/browser/decorators/common/optional.js +18 -0
- package/lib/browser/decorators/common/optional.js.map +1 -0
- package/lib/browser/decorators/common/pattern.js +9 -0
- package/lib/browser/decorators/common/pattern.js.map +1 -0
- package/lib/browser/decorators/common/property.js +11 -0
- package/lib/browser/decorators/common/property.js.map +1 -0
- package/lib/browser/decorators/common/readOnly.js +10 -0
- package/lib/browser/decorators/common/readOnly.js.map +1 -0
- package/lib/browser/decorators/common/recordOf.js +15 -0
- package/lib/browser/decorators/common/recordOf.js.map +1 -0
- package/lib/browser/decorators/common/required.js +8 -0
- package/lib/browser/decorators/common/required.js.map +1 -0
- package/lib/browser/decorators/common/requiredGroups.js +11 -0
- package/lib/browser/decorators/common/requiredGroups.js.map +1 -0
- package/lib/browser/decorators/common/schema.js +16 -0
- package/lib/browser/decorators/common/schema.js.map +1 -0
- package/lib/browser/decorators/common/title.js +10 -0
- package/lib/browser/decorators/common/title.js.map +1 -0
- package/lib/browser/decorators/common/typeError.js +10 -0
- package/lib/browser/decorators/common/typeError.js.map +1 -0
- package/lib/browser/decorators/common/writeOnly.js +10 -0
- package/lib/browser/decorators/common/writeOnly.js.map +1 -0
- package/lib/browser/decorators/config/jsonEntityComponent.js +10 -0
- package/lib/browser/decorators/config/jsonEntityComponent.js.map +1 -0
- package/lib/browser/decorators/generics/genericOf.js +19 -0
- package/lib/browser/decorators/generics/genericOf.js.map +1 -0
- package/lib/browser/decorators/generics/generics.js +11 -0
- package/lib/browser/decorators/generics/generics.js.map +1 -0
- package/lib/browser/decorators/operations/acceptMime.js +9 -0
- package/lib/browser/decorators/operations/acceptMime.js.map +1 -0
- package/lib/browser/decorators/operations/consumes.js +20 -0
- package/lib/browser/decorators/operations/consumes.js.map +1 -0
- package/lib/browser/decorators/operations/contentType.js +8 -0
- package/lib/browser/decorators/operations/contentType.js.map +1 -0
- package/lib/browser/decorators/operations/deprecated.js +26 -0
- package/lib/browser/decorators/operations/deprecated.js.map +1 -0
- package/lib/browser/decorators/operations/header.js +9 -0
- package/lib/browser/decorators/operations/header.js.map +1 -0
- package/lib/browser/decorators/operations/in.js +27 -0
- package/lib/browser/decorators/operations/in.js.map +1 -0
- package/lib/browser/decorators/operations/inFile.js +27 -0
- package/lib/browser/decorators/operations/inFile.js.map +1 -0
- package/lib/browser/decorators/operations/location.js +8 -0
- package/lib/browser/decorators/operations/location.js.map +1 -0
- package/lib/browser/decorators/operations/operation.js +45 -0
- package/lib/browser/decorators/operations/operation.js.map +1 -0
- package/lib/browser/decorators/operations/operationId.js +13 -0
- package/lib/browser/decorators/operations/operationId.js.map +1 -0
- package/lib/browser/decorators/operations/operationPath.js +13 -0
- package/lib/browser/decorators/operations/operationPath.js.map +1 -0
- package/lib/browser/decorators/operations/partial.js +8 -0
- package/lib/browser/decorators/operations/partial.js.map +1 -0
- package/lib/browser/decorators/operations/path.js +13 -0
- package/lib/browser/decorators/operations/path.js.map +1 -0
- package/lib/browser/decorators/operations/produces.js +20 -0
- package/lib/browser/decorators/operations/produces.js.map +1 -0
- package/lib/browser/decorators/operations/publish.js +9 -0
- package/lib/browser/decorators/operations/publish.js.map +1 -0
- package/lib/browser/decorators/operations/redirect.js +20 -0
- package/lib/browser/decorators/operations/redirect.js.map +1 -0
- package/lib/browser/decorators/operations/returns.js +180 -0
- package/lib/browser/decorators/operations/returns.js.map +1 -0
- package/lib/browser/decorators/operations/route.js +37 -0
- package/lib/browser/decorators/operations/route.js.map +1 -0
- package/lib/browser/decorators/operations/security.js +20 -0
- package/lib/browser/decorators/operations/security.js.map +1 -0
- package/lib/browser/decorators/operations/status.js +8 -0
- package/lib/browser/decorators/operations/status.js.map +1 -0
- package/lib/browser/decorators/operations/subscribe.js +9 -0
- package/lib/browser/decorators/operations/subscribe.js.map +1 -0
- package/lib/browser/decorators/operations/summary.js +13 -0
- package/lib/browser/decorators/operations/summary.js.map +1 -0
- package/lib/browser/decorators/operations/tags.js +25 -0
- package/lib/browser/decorators/operations/tags.js.map +1 -0
- package/lib/browser/decorators/operations/view.js +8 -0
- package/lib/browser/decorators/operations/view.js.map +1 -0
- package/lib/browser/domain/DecoratorContext.js +62 -0
- package/lib/browser/domain/DecoratorContext.js.map +1 -0
- package/lib/browser/domain/JsonAliasMap.js +7 -0
- package/lib/browser/domain/JsonAliasMap.js.map +1 -0
- package/lib/browser/domain/JsonClassStore.js +32 -0
- package/lib/browser/domain/JsonClassStore.js.map +1 -0
- package/lib/browser/domain/JsonDiscriminator.js +41 -0
- package/lib/browser/domain/JsonDiscriminator.js.map +1 -0
- package/lib/browser/domain/JsonEntityStore.js +131 -0
- package/lib/browser/domain/JsonEntityStore.js.map +1 -0
- package/lib/browser/domain/JsonFormatTypes.js +5 -0
- package/lib/browser/domain/JsonFormatTypes.js.map +1 -0
- package/lib/browser/domain/JsonLazyRef.js +20 -0
- package/lib/browser/domain/JsonLazyRef.js.map +1 -0
- package/lib/browser/domain/JsonMap.js +19 -0
- package/lib/browser/domain/JsonMap.js.map +1 -0
- package/lib/browser/domain/JsonMedia.js +16 -0
- package/lib/browser/domain/JsonMedia.js.map +1 -0
- package/lib/browser/domain/JsonMethodStore.js +121 -0
- package/lib/browser/domain/JsonMethodStore.js.map +1 -0
- package/lib/browser/domain/JsonOperation.js +129 -0
- package/lib/browser/domain/JsonOperation.js.map +1 -0
- package/lib/browser/domain/JsonOperationPathsMap.js +13 -0
- package/lib/browser/domain/JsonOperationPathsMap.js.map +1 -0
- package/lib/browser/domain/JsonOperationRoute.js +54 -0
- package/lib/browser/domain/JsonOperationRoute.js.map +1 -0
- package/lib/browser/domain/JsonParameter.js +41 -0
- package/lib/browser/domain/JsonParameter.js.map +1 -0
- package/lib/browser/domain/JsonParameterStore.js +69 -0
- package/lib/browser/domain/JsonParameterStore.js.map +1 -0
- package/lib/browser/domain/JsonParameterTypes.js +13 -0
- package/lib/browser/domain/JsonParameterTypes.js.map +1 -0
- package/lib/browser/domain/JsonPropertyStore.js +64 -0
- package/lib/browser/domain/JsonPropertyStore.js.map +1 -0
- package/lib/browser/domain/JsonRequestBody.js +24 -0
- package/lib/browser/domain/JsonRequestBody.js.map +1 -0
- package/lib/browser/domain/JsonResponse.js +36 -0
- package/lib/browser/domain/JsonResponse.js.map +1 -0
- package/lib/browser/domain/JsonSchema.js +625 -0
- package/lib/browser/domain/JsonSchema.js.map +1 -0
- package/lib/browser/domain/SpecTypes.js +5 -0
- package/lib/browser/domain/SpecTypes.js.map +1 -0
- package/lib/browser/domain/__fixtures__/inspectOperationsPaths.js +10 -0
- package/lib/browser/domain/__fixtures__/inspectOperationsPaths.js.map +1 -0
- package/lib/browser/fn/allOf.js +8 -0
- package/lib/browser/fn/allOf.js.map +1 -0
- package/lib/browser/fn/any.js +8 -0
- package/lib/browser/fn/any.js.map +1 -0
- package/lib/browser/fn/anyOf.js +8 -0
- package/lib/browser/fn/anyOf.js.map +1 -0
- package/lib/browser/fn/boolean.js +8 -0
- package/lib/browser/fn/boolean.js.map +1 -0
- package/lib/browser/fn/collection.js +16 -0
- package/lib/browser/fn/collection.js.map +1 -0
- package/lib/browser/fn/date.js +17 -0
- package/lib/browser/fn/date.js.map +1 -0
- package/lib/browser/fn/email.js +9 -0
- package/lib/browser/fn/email.js.map +1 -0
- package/lib/browser/fn/enums.js +10 -0
- package/lib/browser/fn/enums.js.map +1 -0
- package/lib/browser/fn/from.js +18 -0
- package/lib/browser/fn/from.js.map +1 -0
- package/lib/browser/fn/integer.js +8 -0
- package/lib/browser/fn/integer.js.map +1 -0
- package/lib/browser/fn/lazyRef.js +14 -0
- package/lib/browser/fn/lazyRef.js.map +1 -0
- package/lib/browser/fn/number.js +8 -0
- package/lib/browser/fn/number.js.map +1 -0
- package/lib/browser/fn/object.js +8 -0
- package/lib/browser/fn/object.js.map +1 -0
- package/lib/browser/fn/oneOf.js +8 -0
- package/lib/browser/fn/oneOf.js.map +1 -0
- package/lib/browser/fn/string.js +8 -0
- package/lib/browser/fn/string.js.map +1 -0
- package/lib/browser/fn/uri.js +9 -0
- package/lib/browser/fn/uri.js.map +1 -0
- package/lib/browser/fn/url.js +9 -0
- package/lib/browser/fn/url.js.map +1 -0
- package/lib/browser/hooks/alterIgnore.js +12 -0
- package/lib/browser/hooks/alterIgnore.js.map +1 -0
- package/lib/browser/hooks/alterOneOf.js +30 -0
- package/lib/browser/hooks/alterOneOf.js.map +1 -0
- package/lib/browser/hooks/alterRequiredGroups.js +8 -0
- package/lib/browser/hooks/alterRequiredGroups.js.map +1 -0
- package/lib/browser/index.js +450 -0
- package/lib/browser/index.js.map +1 -0
- package/lib/browser/registries/JsonSchemaMapperContainer.js +27 -0
- package/lib/browser/registries/JsonSchemaMapperContainer.js.map +1 -0
- package/lib/browser/registries/enumRegistries.js +5 -0
- package/lib/browser/registries/enumRegistries.js.map +1 -0
- package/lib/browser/utils/buildPath.js +7 -0
- package/lib/browser/utils/buildPath.js.map +1 -0
- package/lib/browser/utils/concatParameters.js +7 -0
- package/lib/browser/utils/concatParameters.js.map +1 -0
- package/lib/browser/utils/concatPath.js +17 -0
- package/lib/browser/utils/concatPath.js.map +1 -0
- package/lib/browser/utils/defineStatusModel.js +12 -0
- package/lib/browser/utils/defineStatusModel.js.map +1 -0
- package/lib/browser/utils/generateSpec.js +24 -0
- package/lib/browser/utils/generateSpec.js.map +1 -0
- package/lib/browser/utils/generics.js +26 -0
- package/lib/browser/utils/generics.js.map +1 -0
- package/lib/browser/utils/getComputedType.js +8 -0
- package/lib/browser/utils/getComputedType.js.map +1 -0
- package/lib/browser/utils/getInheritedStores.js +10 -0
- package/lib/browser/utils/getInheritedStores.js.map +1 -0
- package/lib/browser/utils/getJsonEntityStore.js +17 -0
- package/lib/browser/utils/getJsonEntityStore.js.map +1 -0
- package/lib/browser/utils/getJsonPathParameters.js +51 -0
- package/lib/browser/utils/getJsonPathParameters.js.map +1 -0
- package/lib/browser/utils/getJsonSchema.js +72 -0
- package/lib/browser/utils/getJsonSchema.js.map +1 -0
- package/lib/browser/utils/getJsonType.js +10 -0
- package/lib/browser/utils/getJsonType.js.map +1 -0
- package/lib/browser/utils/getOperationsRoutes.js +30 -0
- package/lib/browser/utils/getOperationsRoutes.js.map +1 -0
- package/lib/browser/utils/getOperationsStores.js +24 -0
- package/lib/browser/utils/getOperationsStores.js.map +1 -0
- package/lib/browser/utils/getPropertiesStores.js +26 -0
- package/lib/browser/utils/getPropertiesStores.js.map +1 -0
- package/lib/browser/utils/getSpec.js +56 -0
- package/lib/browser/utils/getSpec.js.map +1 -0
- package/lib/browser/utils/getSpecType.js +12 -0
- package/lib/browser/utils/getSpecType.js.map +1 -0
- package/lib/browser/utils/isSuccessStatus.js +6 -0
- package/lib/browser/utils/isSuccessStatus.js.map +1 -0
- package/lib/browser/utils/mapHeaders.js +14 -0
- package/lib/browser/utils/mapHeaders.js.map +1 -0
- package/lib/browser/utils/mapOpenSpec.js +27 -0
- package/lib/browser/utils/mapOpenSpec.js.map +1 -0
- package/lib/browser/utils/mapOpenSpec2.js +40 -0
- package/lib/browser/utils/mapOpenSpec2.js.map +1 -0
- package/lib/browser/utils/mapOpenSpec3.js +19 -0
- package/lib/browser/utils/mapOpenSpec3.js.map +1 -0
- package/lib/browser/utils/mapOpenSpecInfo.js +16 -0
- package/lib/browser/utils/mapOpenSpecInfo.js.map +1 -0
- package/lib/browser/utils/mapOperationOptions.js +17 -0
- package/lib/browser/utils/mapOperationOptions.js.map +1 -0
- package/lib/browser/utils/matchGroups.js +27 -0
- package/lib/browser/utils/matchGroups.js.map +1 -0
- package/lib/browser/utils/mergeSpec.js +23 -0
- package/lib/browser/utils/mergeSpec.js.map +1 -0
- package/lib/browser/utils/operationIdFormatter.js +29 -0
- package/lib/browser/utils/operationIdFormatter.js.map +1 -0
- package/lib/browser/utils/ref.js +32 -0
- package/lib/browser/utils/ref.js.map +1 -0
- package/lib/browser/utils/removeHiddenOperation.js +7 -0
- package/lib/browser/utils/removeHiddenOperation.js.map +1 -0
- package/lib/browser/utils/serializeEnumValues.js +11 -0
- package/lib/browser/utils/serializeEnumValues.js.map +1 -0
- package/lib/browser/utils/somethingOf.js +7 -0
- package/lib/browser/utils/somethingOf.js.map +1 -0
- package/lib/browser/utils/toJsonMapCollection.js +8 -0
- package/lib/browser/utils/toJsonMapCollection.js.map +1 -0
- package/lib/browser/utils/toJsonRegex.js +7 -0
- package/lib/browser/utils/toJsonRegex.js.map +1 -0
- package/lib/browser/utils/transformToOS2.js +302 -0
- package/lib/browser/utils/transformToOS2.js.map +1 -0
- package/lib/browser/utils/withErrorMsg.js +31 -0
- package/lib/browser/utils/withErrorMsg.js.map +1 -0
- package/lib/esm/domain/JsonEntityStore.js +6 -0
- package/lib/esm/domain/JsonEntityStore.js.map +1 -1
- package/lib/types/domain/JsonEntityStore.d.ts +2 -0
- package/package.json +19 -16
- package/src/domain/JsonEntityStore.ts +8 -0
- package/vite.config.mts +45 -0
- package/lib/browser/schema.umd.min.js +0 -3
- package/lib/browser/schema.umd.min.js.LICENSE.txt +0 -6
- package/lib/browser/schema.umd.min.js.map +0 -1
- package/webpack.config.cjs +0 -8
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"recordOf.js","sources":["../../../../src/decorators/common/recordOf.ts"],"sourcesContent":["import {Schema} from \"./schema.js\";\n\n/**\n * Constructs a json schema object type whose property keys are keys and whose property values are type.\n *\n * ## Example\n *\n * ```typescript\n * type keys = 'one' | 'two';\n *\n * class Part {\n * prop: string;\n * }\n *\n * type Parts = Record<keys, Part>;\n *\n * class Test {\n * @RecordOf(Part, 'one', 'two')\n * parts: Parts;\n * }\n * ```\n *\n * Will produce:\n *\n * ```json\n * {\n * \"type\": \"object\",\n * \"properties\": {\n * \"one\": {\n * \"$ref\": \"#/components/schemas/Part\"\n * },\n * \"two\": {\n * \"$ref\": \"#/components/schemas/Part\"\n * },\n * },\n * }\n * ```\n *\n * @param model\n * @param keys\n * @decorator\n * @validation\n * @swagger\n * @schema\n * @classDecorator\n * @input\n */\nexport function RecordOf(model: any, ...keys: string[]) {\n return Schema({\n properties: {\n ...keys.reduce((initial, key) => {\n return {\n ...initial,\n [key]: model\n };\n }, {})\n }\n });\n}\n"],"names":["RecordOf","model","keys","Schema","initial","key"],"mappings":";AA+CgB,SAAAA,EAASC,MAAeC,GAAgB;AACtD,SAAOC,EAAO;AAAA,IACZ,YAAY;AAAA,MACV,GAAGD,EAAK,OAAO,CAACE,GAASC,OAChB;AAAA,QACL,GAAGD;AAAA,QACH,CAACC,CAAG,GAAGJ;AAAA,MACT,IACC,CAAE,CAAA;AAAA,IAAA;AAAA,EACP,CACD;AACH;"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { withErrorMsg as t } from "../../utils/withErrorMsg.js";
|
|
2
|
+
import { Allow as e } from "./allow.js";
|
|
3
|
+
import { Optional as i } from "./optional.js";
|
|
4
|
+
const f = t("required", (r = !0, ...o) => r ? e(...o) : i());
|
|
5
|
+
export {
|
|
6
|
+
f as Required
|
|
7
|
+
};
|
|
8
|
+
//# sourceMappingURL=required.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"required.js","sources":["../../../../src/decorators/common/required.ts"],"sourcesContent":["import {withErrorMsg} from \"../../utils/withErrorMsg.js\";\nimport {Allow} from \"./allow.js\";\nimport {Optional} from \"./optional.js\";\n\n/**\n * Add required annotation on Property or Parameter.\n *\n * The @@Required@@ decorator can be used on two cases.\n *\n * To decorate a parameters:\n *\n * ```typescript\n * @Post(\"/\")\n * async method(@Required() @BodyParams(\"field\") field: string) {}\n * ```\n *\n * To decorate a model:\n *\n * ```typescript\n * class Model {\n * @Required()\n * field: string;\n * }\n * ```\n *\n * ::: tip\n * Required will throw a BadRequest when the given value is `null`, an empty string or `undefined`.\n * :::\n *\n * ### Allow values\n *\n * In some case, you didn't want trigger a BadRequest when the value is an empty string for example.\n * The decorator `@Allow()`, allow you to configure a value list for which there will be no exception.\n *\n * ```typescript\n * class Model {\n * @Allow(\"\") // add automatically required flag\n * field: string;\n * }\n * ```\n *\n * @decorator\n * @validation\n * @swagger\n * @schema\n * @input\n */\nexport const Required = withErrorMsg(\"required\", (required: boolean = true, ...allowedRequiredValues: any[]) => {\n return required ? Allow(...allowedRequiredValues) : Optional();\n});\n"],"names":["Required","withErrorMsg","required","allowedRequiredValues","Allow","Optional"],"mappings":";;;AA+CO,MAAMA,IAAWC,EAAa,YAAY,CAACC,IAAoB,OAASC,MACtED,IAAWE,EAAM,GAAGD,CAAqB,IAAIE,EAAS,CAC9D;"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { matchGroups as p } from "../../utils/matchGroups.js";
|
|
2
|
+
import { JsonEntityFn as u } from "./jsonEntityFn.js";
|
|
3
|
+
function s(...t) {
|
|
4
|
+
return u((r) => {
|
|
5
|
+
r.parent.schema.$hooks.on("requiredGroups", (o, e) => p(t, e) ? o.filter((n) => n !== r.propertyKey) : o);
|
|
6
|
+
});
|
|
7
|
+
}
|
|
8
|
+
export {
|
|
9
|
+
s as RequiredGroups
|
|
10
|
+
};
|
|
11
|
+
//# sourceMappingURL=requiredGroups.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"requiredGroups.js","sources":["../../../../src/decorators/common/requiredGroups.ts"],"sourcesContent":["import {matchGroups} from \"../../utils/matchGroups.js\";\nimport {JsonEntityFn} from \"./jsonEntityFn.js\";\n\n/**\n * Apply groups validation strategy for required property.\n *\n * @decorator\n * @validation\n * @swagger\n * @schema\n * @input\n */\nexport function RequiredGroups(...groups: string[]): PropertyDecorator {\n return JsonEntityFn((entity) => {\n entity.parent.schema.$hooks.on(\"requiredGroups\", (required: string[], givenGroups: string[]) => {\n if (matchGroups(groups, givenGroups)) {\n return required.filter((key: string) => key !== entity.propertyKey);\n }\n\n return required;\n });\n });\n}\n"],"names":["RequiredGroups","groups","JsonEntityFn","entity","required","givenGroups","matchGroups","key"],"mappings":";;AAYO,SAASA,KAAkBC,GAAqC;AAC9D,SAAAC,EAAa,CAACC,MAAW;AAC9B,IAAAA,EAAO,OAAO,OAAO,OAAO,GAAG,kBAAkB,CAACC,GAAoBC,MAChEC,EAAYL,GAAQI,CAAW,IAC1BD,EAAS,OAAO,CAACG,MAAgBA,MAAQJ,EAAO,WAAW,IAG7DC,CACR;AAAA,EAAA,CACF;AACH;"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { JsonEntityFn as r } from "./jsonEntityFn.js";
|
|
2
|
+
function s(n) {
|
|
3
|
+
return r((t) => {
|
|
4
|
+
t.schema.assign(n);
|
|
5
|
+
});
|
|
6
|
+
}
|
|
7
|
+
function c(n, t) {
|
|
8
|
+
return r((e) => {
|
|
9
|
+
e.schema.set(n, t);
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
export {
|
|
13
|
+
c as For,
|
|
14
|
+
s as Schema
|
|
15
|
+
};
|
|
16
|
+
//# sourceMappingURL=schema.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema.js","sources":["../../../../src/decorators/common/schema.ts"],"sourcesContent":["import {JsonSchema, JsonSchemaObject} from \"../../domain/JsonSchema.js\";\nimport {SpecTypes} from \"../../domain/SpecTypes.js\";\nimport {JsonEntityFn} from \"./jsonEntityFn.js\";\n\n/**\n * Write data formatted to JsonSchema.\n *\n * ## Example\n *\n * ```typescript\n * @Schema({title: \"test\"})\n * class Model {\n * @Schema({formatMinimum: \"1987-10-24\"})\n * @Format(\"date\")\n * birthDate: Date\n * }\n * ```\n *\n * Will produce:\n *\n * ```json\n * {\n * \"type\": \"object\",\n * \"title\": \"test\",\n * \"properties\": {\n * \"birthdate\": {\n * \"type\": \"string\",\n * \"format\": \"date\",\n * \"formatMinimum\": \"1987-10-24\"\n * }\n * }\n * }\n * ```\n *\n * @param partialSchema\n * @decorator\n * @validation\n * @swagger\n * @schema\n * @classDecorator\n * @input\n */\nexport function Schema(partialSchema: Partial<JsonSchemaObject> | JsonSchema) {\n return JsonEntityFn((entity) => {\n entity.schema.assign(partialSchema);\n });\n}\n\n/**\n * Apply specific schema depending on the spec version\n * @param specType\n * @param schema\n * @decorator\n * @validation\n * @swagger\n * @schema\n * @classDecorator\n * @input\n */\nexport function For(specType: SpecTypes, schema: any) {\n return JsonEntityFn((entity) => {\n entity.schema.set(specType, schema);\n });\n}\n"],"names":["Schema","partialSchema","JsonEntityFn","entity","For","specType","schema"],"mappings":";AA0CO,SAASA,EAAOC,GAAuD;AACrE,SAAAC,EAAa,CAACC,MAAW;AACvB,IAAAA,EAAA,OAAO,OAAOF,CAAa;AAAA,EAAA,CACnC;AACH;AAagB,SAAAG,EAAIC,GAAqBC,GAAa;AAC7C,SAAAJ,EAAa,CAACC,MAAW;AACvB,IAAAA,EAAA,OAAO,IAAIE,GAAUC,CAAM;AAAA,EAAA,CACnC;AACH;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"title.js","sources":["../../../../src/decorators/common/title.ts"],"sourcesContent":["import {JsonEntityFn} from \"./jsonEntityFn.js\";\n\n/**\n * Add title metadata on the decorated element.\n *\n * ::: warning\n * For v6 user, use @@Title@@ from @tsed/schema instead of @tsed/platform-http.\n * :::\n *\n * ## Example\n *\n * ```typescript\n * class Model {\n * @Title(\"title\")\n * id: string;\n * }\n * ```\n *\n * Will produce:\n *\n * ```json\n * {\n * \"type\": \"object\",\n * \"properties\": {\n * \"id\": {\n * \"type\": \"string\",\n * \"title\": \"title\"\n * }\n * }\n * }\n * ```\n *\n * @param {string} title\n * @decorator\n * @validation\n * @swagger\n * @schema\n * @classDecorator\n * @input\n */\nexport function Title(title: string) {\n return JsonEntityFn((entity) => {\n entity.schema.title(title);\n });\n}\n"],"names":["Title","title","JsonEntityFn","entity"],"mappings":";AAwCO,SAASA,EAAMC,GAAe;AAC5B,SAAAC,EAAa,CAACC,MAAW;AACvB,IAAAA,EAAA,OAAO,MAAMF,CAAK;AAAA,EAAA,CAC1B;AACH;"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { useDecorators as o } from "@tsed/core";
|
|
2
|
+
import { ErrorMsg as t } from "./errorMsg.js";
|
|
3
|
+
import { JsonEntityFn as e } from "./jsonEntityFn.js";
|
|
4
|
+
function i(r) {
|
|
5
|
+
return e(() => o(t({ type: r })));
|
|
6
|
+
}
|
|
7
|
+
export {
|
|
8
|
+
i as TypeError
|
|
9
|
+
};
|
|
10
|
+
//# sourceMappingURL=typeError.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"typeError.js","sources":["../../../../src/decorators/common/typeError.ts"],"sourcesContent":["import {useDecorators} from \"@tsed/core\";\n\nimport {ErrorMsg} from \"./errorMsg.js\";\nimport {JsonEntityFn} from \"./jsonEntityFn.js\";\n\n/**\n * Create a new custom formats validator\n * @param name\n * @param options\n * @decorator\n * @ajv\n */\nexport function TypeError(msg: string): ClassDecorator {\n return JsonEntityFn(() => useDecorators(ErrorMsg({type: msg})));\n}\n"],"names":["TypeError","msg","JsonEntityFn","useDecorators","ErrorMsg"],"mappings":";;;AAYO,SAASA,EAAUC,GAA6B;AAC9C,SAAAC,EAAa,MAAMC,EAAcC,EAAS,EAAC,MAAMH,EAAI,CAAA,CAAC,CAAC;AAChE;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"writeOnly.js","sources":["../../../../src/decorators/common/writeOnly.ts"],"sourcesContent":["import {JsonEntityStore} from \"../../domain/JsonEntityStore.js\";\nimport {JsonEntityFn} from \"./jsonEntityFn.js\";\n/**\n * Set the property as WriteOnly.\n *\n * @returns {Function}\n * @decorator\n * @validation\n * @property\n * @parameter\n * @schema\n */\nexport function WriteOnly(writeOnly: boolean = true) {\n return JsonEntityFn((store: JsonEntityStore) => {\n store.itemSchema.writeOnly(writeOnly);\n });\n}\n"],"names":["WriteOnly","writeOnly","JsonEntityFn","store"],"mappings":";AAYgB,SAAAA,EAAUC,IAAqB,IAAM;AAC5C,SAAAC,EAAa,CAACC,MAA2B;AACxC,IAAAA,EAAA,WAAW,UAAUF,CAAS;AAAA,EAAA,CACrC;AACH;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"jsonEntityComponent.js","sources":["../../../../src/decorators/config/jsonEntityComponent.ts"],"sourcesContent":["import {DecoratorTypes, Type} from \"@tsed/core\";\n\nimport {JsonEntitiesContainer, JsonEntityStore} from \"../../domain/JsonEntityStore.js\";\n\n/**\n * Declare a new JsonEntityStore class for a specific decorator type.\n *\n * @ignore\n * @param type\n * @decorator\n */\nexport function JsonEntityComponent(type: DecoratorTypes) {\n return (target: Type<JsonEntityStore>) => {\n JsonEntitiesContainer.set(type, target);\n };\n}\n"],"names":["JsonEntityComponent","type","target","JsonEntitiesContainer"],"mappings":";AAWO,SAASA,EAAoBC,GAAsB;AACxD,SAAO,CAACC,MAAkC;AAClB,IAAAC,EAAA,IAAIF,GAAMC,CAAM;AAAA,EACxC;AACF;"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { isObject as s } from "@tsed/core";
|
|
2
|
+
import { JsonEntityStore as i } from "../../domain/JsonEntityStore.js";
|
|
3
|
+
import { string as c } from "../../fn/string.js";
|
|
4
|
+
function u(n) {
|
|
5
|
+
return s(n) && !("toJSON" in n);
|
|
6
|
+
}
|
|
7
|
+
function O(...n) {
|
|
8
|
+
const e = [
|
|
9
|
+
n.map((r) => u(r) ? c().enum(Object.values(r)) : r)
|
|
10
|
+
], t = (...r) => {
|
|
11
|
+
const o = i.from(...r);
|
|
12
|
+
o.nestedGenerics = e;
|
|
13
|
+
};
|
|
14
|
+
return t.Nested = (...r) => (e.push(r), t), t;
|
|
15
|
+
}
|
|
16
|
+
export {
|
|
17
|
+
O as GenericOf
|
|
18
|
+
};
|
|
19
|
+
//# sourceMappingURL=genericOf.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"genericOf.js","sources":["../../../../src/decorators/generics/genericOf.ts"],"sourcesContent":["import {isObject, Type} from \"@tsed/core\";\n\nimport {JsonEntityStore} from \"../../domain/JsonEntityStore.js\";\nimport {string} from \"../../fn/string.js\";\nimport {GenericValue} from \"../../utils/generics.js\";\n\n/**\n * @ignore\n */\nfunction isEnum(type: any) {\n return isObject(type) && !(\"toJSON\" in type);\n}\n\nexport interface GenericOfChainedDecorators {\n (...args: any): any;\n\n /**\n * Declare a nested generic models\n * @param generics\n */\n Nested(...generics: GenericValue[]): this;\n}\n\n/**\n * Set the types of a Generic class.\n *\n * ## Example\n *\n * ```typescript\n * class Product {\n * @Property()\n * label: string;\n * }\n *\n * @Generics(\"T\")\n * class Paginated<T> {\n * @CollectionOf(\"T\")\n * data: T[];\n *\n * @Property()\n * totalCount: number;\n * }\n *\n * class Payload {\n * @GenericOf(Product)\n * products: Paginated<Product>;\n * }\n * ```\n *\n * ## Example with nested generics\n *\n * ```typescript\n * class Product {\n * @Property()\n * label: string;\n * }\n *\n * @Generics(\"T\")\n * class Paginated<T> {\n * @CollectionOf(\"T\")\n * data: T[];\n *\n * @Property()\n * totalCount: number;\n * }\n *\n * @Generics(\"D\")\n * class Submission<D> {\n * @Property()\n * _id: string;\n *\n * @Property(\"D\")\n * data: D;\n * }\n *\n * class Payload {\n * @GenericOf(Submissions).Nested(Product)\n * submissions: Paginated<Submission<Product>>;\n * }\n * ```\n *\n * @param {Type<any>[]} generics\n * @decorator\n * @validation\n * @swagger\n * @schema\n * @input\n * @generics\n */\nexport function GenericOf(...generics: GenericValue[]): GenericOfChainedDecorators {\n const nestedGenerics: GenericValue[][] = [\n generics.map((type) => {\n if (isEnum(type)) {\n return string().enum(Object.values(type));\n }\n return type;\n })\n ];\n\n const decorator = (...args: any) => {\n const store = JsonEntityStore.from(...args);\n store.nestedGenerics = nestedGenerics;\n };\n\n decorator.Nested = (...generics: any) => {\n nestedGenerics.push(generics);\n\n return decorator;\n };\n\n return decorator;\n}\n"],"names":["isEnum","type","isObject","GenericOf","generics","nestedGenerics","string","decorator","args","store","JsonEntityStore"],"mappings":";;;AASA,SAASA,EAAOC,GAAW;AACzB,SAAOC,EAASD,CAAI,KAAK,EAAE,YAAYA;AACzC;AA8EO,SAASE,KAAaC,GAAsD;AACjF,QAAMC,IAAmC;AAAA,IACvCD,EAAS,IAAI,CAACH,MACRD,EAAOC,CAAI,IACNK,EAAS,EAAA,KAAK,OAAO,OAAOL,CAAI,CAAC,IAEnCA,CACR;AAAA,EACH,GAEMM,IAAY,IAAIC,MAAc;AAClC,UAAMC,IAAQC,EAAgB,KAAK,GAAGF,CAAI;AAC1C,IAAAC,EAAM,iBAAiBJ;AAAA,EACzB;AAEU,SAAAE,EAAA,SAAS,IAAIH,OACrBC,EAAe,KAAKD,CAAQ,GAErBG,IAGFA;AACT;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"generics.js","sources":["../../../../src/decorators/generics/generics.ts"],"sourcesContent":["import {JsonEntityStore} from \"../../domain/JsonEntityStore.js\";\n\n/**\n * Define generics list. This list is used by @@GenericOf@@ and the @@getJsonSchema@@ function to build the correct JsonSchema.\n *\n * See @@GenericOf@@ decorator for more details.\n *\n * @param generics\n * @decorator\n * @validation\n * @swagger\n * @schema\n * @input\n * @generics\n */\nexport function Generics(...generics: string[]): ClassDecorator {\n return (target: any) => {\n const storedSchema = JsonEntityStore.from(target);\n\n storedSchema.schema.genericLabels = generics;\n };\n}\n"],"names":["Generics","generics","target","storedSchema","JsonEntityStore"],"mappings":";AAeO,SAASA,KAAYC,GAAoC;AAC9D,SAAO,CAACC,MAAgB;AAChB,UAAAC,IAAeC,EAAgB,KAAKF,CAAM;AAEhD,IAAAC,EAAa,OAAO,gBAAgBF;AAAA,EACtC;AACF;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"acceptMime.js","sources":["../../../../src/decorators/operations/acceptMime.ts"],"sourcesContent":["import {StoreSet, useDecorators} from \"@tsed/core\";\n\nimport {Consumes} from \"./consumes.js\";\n\n/**\n * Set a mime list which are acceptable and checks if the specified content types are acceptable, based on the request’s Accept HTTP header field.\n *\n * ```typescript\n * @Controller('/mypath')\n * export class MyCtrl {\n *\n * @Get('/')\n * @AcceptMime('application/x-www-form-urlencoded')\n * public getResource(){}\n * }\n * ```\n *\n * @param mimes\n * @decorator\n * @operation\n * @response\n */\nexport function AcceptMime(...mimes: string[]): ClassDecorator & MethodDecorator {\n return useDecorators(Consumes(...mimes), StoreSet(\"acceptMimes\", mimes));\n}\n"],"names":["AcceptMime","mimes","useDecorators","Consumes","StoreSet"],"mappings":";;AAsBO,SAASA,KAAcC,GAAmD;AACxE,SAAAC,EAAcC,EAAS,GAAGF,CAAK,GAAGG,EAAS,eAAeH,CAAK,CAAC;AACzE;"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { UnsupportedDecoratorType as a, DecoratorTypes as t, decorateMethodsOf as p } from "@tsed/core";
|
|
2
|
+
import { JsonEntityFn as c } from "../common/jsonEntityFn.js";
|
|
3
|
+
function n(...e) {
|
|
4
|
+
return c((o, r) => {
|
|
5
|
+
switch (o.decoratorType) {
|
|
6
|
+
case t.METHOD:
|
|
7
|
+
o.operation.consumes(e);
|
|
8
|
+
break;
|
|
9
|
+
case t.CLASS:
|
|
10
|
+
p(r[0], n(...e));
|
|
11
|
+
break;
|
|
12
|
+
default:
|
|
13
|
+
throw new a(n, r);
|
|
14
|
+
}
|
|
15
|
+
});
|
|
16
|
+
}
|
|
17
|
+
export {
|
|
18
|
+
n as Consumes
|
|
19
|
+
};
|
|
20
|
+
//# sourceMappingURL=consumes.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"consumes.js","sources":["../../../../src/decorators/operations/consumes.ts"],"sourcesContent":["import {decorateMethodsOf, DecoratorTypes, UnsupportedDecoratorType} from \"@tsed/core\";\n\nimport {JsonEntityFn} from \"../common/jsonEntityFn.js\";\n\n/**\n * Add consumes metadata on the decorated element.\n *\n * ## Examples\n *\n * ```typescript\n * class Model {\n * @Consumes(\"application/x-www-form-urlencoded\")\n * id: string;\n * }\n * ```\n *\n * @param consumes\n * @decorator\n * @swagger\n * @classDecorator\n * @operation\n */\nexport function Consumes(...consumes: string[]): ClassDecorator & MethodDecorator {\n return JsonEntityFn((store, args) => {\n switch (store.decoratorType) {\n case DecoratorTypes.METHOD:\n store.operation!.consumes(consumes);\n break;\n case DecoratorTypes.CLASS:\n decorateMethodsOf(args[0], Consumes(...consumes));\n break;\n\n default:\n throw new UnsupportedDecoratorType(Consumes, args);\n }\n });\n}\n"],"names":["Consumes","consumes","JsonEntityFn","store","args","DecoratorTypes","decorateMethodsOf","UnsupportedDecoratorType"],"mappings":";;AAsBO,SAASA,KAAYC,GAAsD;AACzE,SAAAC,EAAa,CAACC,GAAOC,MAAS;AACnC,YAAQD,EAAM,eAAe;AAAA,MAC3B,KAAKE,EAAe;AACZ,QAAAF,EAAA,UAAW,SAASF,CAAQ;AAClC;AAAA,MACF,KAAKI,EAAe;AAClB,QAAAC,EAAkBF,EAAK,CAAC,GAAGJ,EAAS,GAAGC,CAAQ,CAAC;AAChD;AAAA,MAEF;AACQ,cAAA,IAAIM,EAAyBP,GAAUI,CAAI;AAAA,IAAA;AAAA,EACrD,CACD;AACH;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"contentType.js","sources":["../../../../src/decorators/operations/contentType.ts"],"sourcesContent":["import {Returns} from \"./returns.js\";\n\n/**\n * Sets the Content-Type HTTP header to the MIME type as determined by mime.lookup() for the specified type.\n * If type contains the “/” character, then it sets the `Content-Type` to type.\n *\n * ```typescript\n * @ContentType('.html'); // => 'text/html'\n * @ContentType('html'); // => 'text/html'\n * @ContentType('json'); // => 'application/json'\n * @ContentType('application/json'); // => 'application/json'\n * @ContentType('png'); // => image/png\n * private myMethod() {}\n * ```\n *\n * @param type\n * @decorator\n * @operation\n * @response\n * @headers\n */\nexport function ContentType(type: string) {\n return Returns().ContentType(type);\n}\n"],"names":["ContentType","type","Returns"],"mappings":";AAqBO,SAASA,EAAYC,GAAc;AACjC,SAAAC,EAAA,EAAU,YAAYD,CAAI;AACnC;"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { decoratorTypeOf as c, UnsupportedDecoratorType as p, DecoratorTypes as r, decorateMethodsOf as n } from "@tsed/core";
|
|
2
|
+
import { JsonEntityFn as s } from "../common/jsonEntityFn.js";
|
|
3
|
+
function a(e = !0) {
|
|
4
|
+
return s((t, o) => {
|
|
5
|
+
switch (c(o)) {
|
|
6
|
+
case r.METHOD:
|
|
7
|
+
t.operation.deprecated(e);
|
|
8
|
+
break;
|
|
9
|
+
case r.CLASS:
|
|
10
|
+
n(o[0], a(e));
|
|
11
|
+
break;
|
|
12
|
+
case r.PARAM:
|
|
13
|
+
t.parameter.set("deprecated", e);
|
|
14
|
+
break;
|
|
15
|
+
case r.PROP:
|
|
16
|
+
t.schema.set("deprecated", e);
|
|
17
|
+
break;
|
|
18
|
+
default:
|
|
19
|
+
throw new p(a, o);
|
|
20
|
+
}
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
export {
|
|
24
|
+
a as Deprecated
|
|
25
|
+
};
|
|
26
|
+
//# sourceMappingURL=deprecated.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"deprecated.js","sources":["../../../../src/decorators/operations/deprecated.ts"],"sourcesContent":["import {decorateMethodsOf, decoratorTypeOf, DecoratorTypes, UnsupportedDecoratorType} from \"@tsed/core\";\n\nimport {JsonParameterStore} from \"../../domain/JsonParameterStore.js\";\nimport {JsonPropertyStore} from \"../../domain/JsonPropertyStore.js\";\nimport {JsonEntityFn} from \"../common/jsonEntityFn.js\";\n\n/**\n * Add deprecated metadata on the decorated element.\n *\n * ## Examples\n *\n * ```typescript\n *\n * @Deprecated()\n * class MyCtrl {\n * @Deprecated()\n * @Get(\"/\")\n * method(){\n * }\n * }\n * ```\n *\n * @param deprecated\n * @decorator\n * @swagger\n * @schema\n * @operation\n */\nexport function Deprecated(deprecated: boolean = true) {\n return JsonEntityFn((store, args) => {\n switch (decoratorTypeOf(args)) {\n case DecoratorTypes.METHOD:\n store.operation!.deprecated(deprecated);\n break;\n case DecoratorTypes.CLASS:\n decorateMethodsOf(args[0], Deprecated(deprecated));\n break;\n case DecoratorTypes.PARAM:\n (store as JsonParameterStore).parameter.set(\"deprecated\", deprecated);\n break;\n case DecoratorTypes.PROP:\n (store as JsonPropertyStore).schema.set(\"deprecated\", deprecated);\n break;\n\n default:\n throw new UnsupportedDecoratorType(Deprecated, args);\n }\n });\n}\n"],"names":["Deprecated","deprecated","JsonEntityFn","store","args","decoratorTypeOf","DecoratorTypes","decorateMethodsOf","UnsupportedDecoratorType"],"mappings":";;AA4BgB,SAAAA,EAAWC,IAAsB,IAAM;AAC9C,SAAAC,EAAa,CAACC,GAAOC,MAAS;AAC3B,YAAAC,EAAgBD,CAAI,GAAG;AAAA,MAC7B,KAAKE,EAAe;AACZ,QAAAH,EAAA,UAAW,WAAWF,CAAU;AACtC;AAAA,MACF,KAAKK,EAAe;AAClB,QAAAC,EAAkBH,EAAK,CAAC,GAAGJ,EAAWC,CAAU,CAAC;AACjD;AAAA,MACF,KAAKK,EAAe;AACjB,QAAAH,EAA6B,UAAU,IAAI,cAAcF,CAAU;AACpE;AAAA,MACF,KAAKK,EAAe;AACjB,QAAAH,EAA4B,OAAO,IAAI,cAAcF,CAAU;AAChE;AAAA,MAEF;AACQ,cAAA,IAAIO,EAAyBR,GAAYI,CAAI;AAAA,IAAA;AAAA,EACvD,CACD;AACH;"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { isString as o } from "@tsed/core";
|
|
2
|
+
import { Returns as r } from "./returns.js";
|
|
3
|
+
function m(i, t) {
|
|
4
|
+
return t !== void 0 && (i = { [i]: t }), t === void 0 && o(i) && (i = { [i]: { type: "string" } }), r().Headers(i);
|
|
5
|
+
}
|
|
6
|
+
export {
|
|
7
|
+
m as Header
|
|
8
|
+
};
|
|
9
|
+
//# sourceMappingURL=header.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"header.js","sources":["../../../../src/decorators/operations/header.ts"],"sourcesContent":["import {isString} from \"@tsed/core\";\n\nimport {JsonHeader, JsonHeaders} from \"../../interfaces/JsonOpenSpec.js\";\nimport {Returns} from \"./returns.js\";\n\n/**\n * Sets the response’s HTTP header field to value. To set multiple fields at once, pass an object as the parameter.\n *\n * ```typescript\n * @Header('Content-Type', 'text/plain');\n * private myMethod() {}\n *\n * @Status(204)\n * @Header({\n * \"Content-Type\": \"text/plain\",\n * \"Content-Length\": 123,\n * \"ETag\": {\n * \"value\": \"12345\",\n * \"description\": \"header description\"\n * }\n * })\n * private myMethod() {}\n * ```\n *\n * This example will produce the swagger responses object:\n *\n * ```json\n * {\n * \"responses\": {\n * \"204\": {\n * \"description\": \"Description\",\n * \"headers\": {\n * \"Content-Type\": {\n * \"type\": \"string\"\n * },\n * \"Content-Length\": {\n * \"type\": \"number\"\n * },\n * \"ETag\": {\n * \"type\": \"string\",\n * \"description\": \"header description\"\n * }\n * }\n * }\n * }\n * }\n * ```\n *\n * @decorator\n * @operation\n * @response\n */\nexport function Header(headers: string | number | JsonHeaders, value?: string | number | JsonHeader) {\n if (value !== undefined) {\n headers = {[headers as string]: value};\n }\n if (value === undefined && isString(headers)) {\n headers = {[headers as string]: {type: \"string\"}};\n }\n\n return Returns().Headers(headers as JsonHeaders);\n}\n"],"names":["Header","headers","value","isString","Returns"],"mappings":";;AAoDgB,SAAAA,EAAOC,GAAwCC,GAAsC;AACnG,SAAIA,MAAU,WACZD,IAAU,EAAC,CAACA,CAAiB,GAAGC,EAAK,IAEnCA,MAAU,UAAaC,EAASF,CAAO,MACzCA,IAAU,EAAC,CAACA,CAAiB,GAAG,EAAC,MAAM,WAAS,IAG3CG,EAAA,EAAU,QAAQH,CAAsB;AACjD;"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { UnsupportedDecoratorType as i, DecoratorTypes as a, decorateMethodsOf as p } from "@tsed/core";
|
|
2
|
+
import { JsonEntityStore as u } from "../../domain/JsonEntityStore.js";
|
|
3
|
+
import { JsonParameter as d } from "../../domain/JsonParameter.js";
|
|
4
|
+
import { JsonSchema as f } from "../../domain/JsonSchema.js";
|
|
5
|
+
function S(c) {
|
|
6
|
+
const t = new d(), o = {}, e = (r, s, m) => {
|
|
7
|
+
const n = u.from(r, s, m);
|
|
8
|
+
switch (n.decoratorType) {
|
|
9
|
+
case a.PARAM:
|
|
10
|
+
n.parameter.in(c);
|
|
11
|
+
break;
|
|
12
|
+
case a.METHOD:
|
|
13
|
+
t.in(c), n.operation.addParameter(-1, t), t.schema(f.from(o));
|
|
14
|
+
break;
|
|
15
|
+
case a.CLASS:
|
|
16
|
+
p(r, e);
|
|
17
|
+
break;
|
|
18
|
+
default:
|
|
19
|
+
throw new i(S, [r, s, m]);
|
|
20
|
+
}
|
|
21
|
+
};
|
|
22
|
+
return e.Type = (r) => (o.type = r, e), e.Name = (r) => (t.name(r), e), e.Description = (r) => (t.description(r), e), e.Required = (r = !0) => (t.required(r), e), e.Pattern = (r) => e.Schema({ pattern: r.toString() }), e.Schema = (r) => (Object.assign(o, r.toJSON ? r.toJSON() : r), e), e;
|
|
23
|
+
}
|
|
24
|
+
export {
|
|
25
|
+
S as In
|
|
26
|
+
};
|
|
27
|
+
//# sourceMappingURL=in.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"in.js","sources":["../../../../src/decorators/operations/in.ts"],"sourcesContent":["import {decorateMethodsOf, DecoratorTypes, Type, UnsupportedDecoratorType} from \"@tsed/core\";\n\nimport {JsonEntityStore} from \"../../domain/JsonEntityStore.js\";\nimport {JsonMethodStore} from \"../../domain/JsonMethodStore.js\";\nimport {JsonParameter} from \"../../domain/JsonParameter.js\";\nimport {JsonParameterStore} from \"../../domain/JsonParameterStore.js\";\nimport {JsonParameterTypes} from \"../../domain/JsonParameterTypes.js\";\nimport {JsonSchema, JsonSchemaObject} from \"../../domain/JsonSchema.js\";\n\nexport interface InChainedDecorators {\n <T>(target: Object, propertyKey: string | symbol, descriptor: TypedPropertyDescriptor<T>): TypedPropertyDescriptor<T> | void;\n\n (target: Object, propertyKey: string | symbol, parameterIndex: number): void;\n\n (target: Function): void;\n\n /**\n * Type of this in parameter\n * @param type\n */\n Type(type: Type<any>): this;\n\n /**\n *\n * @param name\n */\n Name(name: string): this;\n\n /**\n *\n * @param description\n */\n Description(description: string): this;\n\n /**\n *\n * @param required\n */\n Required(required?: boolean): this;\n\n /**\n * Add pattern constraint. Only available for OPENAPI.\n * @param pattern\n */\n Pattern(pattern: string | RegExp): this;\n\n /**\n * Add custom schema.\n * @param schema\n */\n Schema(schema: Partial<JsonSchemaObject | JsonSchema>): this;\n}\n\n/**\n * Add a input parameter.\n *\n * ::: warning\n * Don't use decorator with Ts.ED application to decorate parameters. Use @@BodyParams@@, @@PathParams@@, etc... instead.\n * But you can use this decorator on Method, to add extra in parameters like Authorization header.\n *\n * ```typescript\n * @Controller(\"/\")\n * class MyController {\n * @Get(\"/\")\n * @In(\"header\").Type(String).Name(\"Authorization\").Required()\n * method() {\n * }\n * }\n * ```\n * :::\n *\n * @param inType\n * @decorator\n * @swagger\n * @schema\n * @input\n * @operation\n */\nexport function In(inType: JsonParameterTypes | string): InChainedDecorators {\n const jsonParameter = new JsonParameter();\n const schema: any = {};\n\n const decorator = (target: any, propertyKey?: string | symbol, index?: PropertyDescriptor | number) => {\n const store = JsonEntityStore.from(target, propertyKey, index);\n\n switch (store.decoratorType) {\n case DecoratorTypes.PARAM:\n (store as JsonParameterStore).parameter.in(inType);\n break;\n case DecoratorTypes.METHOD:\n jsonParameter.in(inType);\n (store as JsonMethodStore).operation.addParameter(-1, jsonParameter);\n\n jsonParameter.schema(JsonSchema.from(schema));\n break;\n\n case DecoratorTypes.CLASS:\n decorateMethodsOf(target, decorator);\n break;\n\n default:\n throw new UnsupportedDecoratorType(In, [target, propertyKey, index]);\n }\n };\n\n decorator.Type = (type: Type<any>) => {\n schema.type = type;\n\n return decorator;\n };\n\n decorator.Name = (name: string) => {\n jsonParameter.name(name);\n\n return decorator;\n };\n\n decorator.Description = (description: string) => {\n jsonParameter.description(description);\n\n return decorator;\n };\n\n decorator.Required = (required: boolean = true) => {\n jsonParameter.required(required);\n\n return decorator;\n };\n\n decorator.Pattern = (pattern: string | RegExp) => {\n return decorator.Schema({pattern: pattern.toString()});\n };\n\n decorator.Schema = (_schema: any) => {\n Object.assign(schema, _schema.toJSON ? _schema.toJSON() : _schema);\n\n return decorator;\n };\n\n return decorator;\n}\n"],"names":["In","inType","jsonParameter","JsonParameter","schema","decorator","target","propertyKey","index","store","JsonEntityStore","DecoratorTypes","JsonSchema","decorateMethodsOf","UnsupportedDecoratorType","type","name","description","required","pattern","_schema"],"mappings":";;;;AA8EO,SAASA,EAAGC,GAA0D;AACrE,QAAAC,IAAgB,IAAIC,EAAc,GAClCC,IAAc,CAAC,GAEfC,IAAY,CAACC,GAAaC,GAA+BC,MAAwC;AACrG,UAAMC,IAAQC,EAAgB,KAAKJ,GAAQC,GAAaC,CAAK;AAE7D,YAAQC,EAAM,eAAe;AAAA,MAC3B,KAAKE,EAAe;AACjB,QAAAF,EAA6B,UAAU,GAAGR,CAAM;AACjD;AAAA,MACF,KAAKU,EAAe;AAClB,QAAAT,EAAc,GAAGD,CAAM,GACtBQ,EAA0B,UAAU,aAAa,IAAIP,CAAa,GAEnEA,EAAc,OAAOU,EAAW,KAAKR,CAAM,CAAC;AAC5C;AAAA,MAEF,KAAKO,EAAe;AAClB,QAAAE,EAAkBP,GAAQD,CAAS;AACnC;AAAA,MAEF;AACE,cAAM,IAAIS,EAAyBd,GAAI,CAACM,GAAQC,GAAaC,CAAK,CAAC;AAAA,IAAA;AAAA,EAEzE;AAEU,SAAAH,EAAA,OAAO,CAACU,OAChBX,EAAO,OAAOW,GAEPV,IAGCA,EAAA,OAAO,CAACW,OAChBd,EAAc,KAAKc,CAAI,GAEhBX,IAGCA,EAAA,cAAc,CAACY,OACvBf,EAAc,YAAYe,CAAW,GAE9BZ,IAGCA,EAAA,WAAW,CAACa,IAAoB,QACxChB,EAAc,SAASgB,CAAQ,GAExBb,IAGCA,EAAA,UAAU,CAACc,MACZd,EAAU,OAAO,EAAC,SAASc,EAAQ,SAAA,GAAW,GAG7Cd,EAAA,SAAS,CAACe,OAClB,OAAO,OAAOhB,GAAQgB,EAAQ,SAASA,EAAQ,WAAWA,CAAO,GAE1Df,IAGFA;AACT;"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { Metadata as m, useDecorators as l, useMethodDecorators as s } from "@tsed/core";
|
|
2
|
+
import { JsonParameterTypes as p } from "../../domain/JsonParameterTypes.js";
|
|
3
|
+
import { Name as f } from "../common/name.js";
|
|
4
|
+
import { Consumes as d } from "./consumes.js";
|
|
5
|
+
import { In as c } from "./in.js";
|
|
6
|
+
import { Returns as u } from "./returns.js";
|
|
7
|
+
function j(o) {
|
|
8
|
+
return (...e) => {
|
|
9
|
+
const [t, r, i] = e, n = m.getParamTypes(t, r)[i] === Array;
|
|
10
|
+
o = typeof o == "object" ? void 0 : o;
|
|
11
|
+
const a = [o, !n && "0"].filter(Boolean).join(".");
|
|
12
|
+
l(
|
|
13
|
+
c(p.FILES),
|
|
14
|
+
f(a),
|
|
15
|
+
s(
|
|
16
|
+
u(400).Description(
|
|
17
|
+
"<File too long | Too many parts | Too many files | Field name too long | Field value too long | Too many fields | Unexpected field> [fieldName] Example: File too long file1"
|
|
18
|
+
),
|
|
19
|
+
d("multipart/form-data")
|
|
20
|
+
)
|
|
21
|
+
)(...e);
|
|
22
|
+
};
|
|
23
|
+
}
|
|
24
|
+
export {
|
|
25
|
+
j as InFile
|
|
26
|
+
};
|
|
27
|
+
//# sourceMappingURL=inFile.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"inFile.js","sources":["../../../../src/decorators/operations/inFile.ts"],"sourcesContent":["import {DecoratorParameters, Metadata, useDecorators, useMethodDecorators} from \"@tsed/core\";\n\nimport {JsonParameterTypes} from \"../../domain/JsonParameterTypes.js\";\nimport {Name} from \"../common/name.js\";\nimport {Consumes} from \"./consumes.js\";\nimport {In} from \"./in.js\";\nimport {Returns} from \"./returns.js\";\n\n/**\n * Add a input file parameter.\n *\n * ::: warning\n * Don't use decorator with Ts.ED application to decorate parameters. Use @@BodyParams@@, @@PathParams@@, etc... instead.\n * But you can use this decorator on Method, to add extra in parameters like Authorization header.\n *\n * ```typescript\n * @Controller(\"/\")\n * class MyController {\n * @Post(\"/\")\n * method(@InFile(\"file1\") file: any) {\n * }\n * }\n * ```\n * :::\n *\n * @decorator\n * @swagger\n * @schema\n * @input\n * @operation\n * @param name\n */\nexport function InFile(name: string): ParameterDecorator {\n return (...args: DecoratorParameters): void => {\n const [target, propertyKey, index] = args;\n const multiple = Metadata.getParamTypes(target, propertyKey)[index as number] === Array;\n\n name = (typeof name === \"object\" ? undefined : name)!;\n\n const expression = [name, !multiple && \"0\"].filter(Boolean).join(\".\");\n\n const decorators = useDecorators(\n In(JsonParameterTypes.FILES),\n Name(expression),\n useMethodDecorators(\n Returns(400).Description(\n `<File too long | Too many parts | Too many files | Field name too long | Field value too long | Too many fields | Unexpected field> [fieldName] Example: File too long file1`\n ),\n Consumes(\"multipart/form-data\")\n )\n );\n\n decorators(...args);\n };\n}\n"],"names":["InFile","name","args","target","propertyKey","index","multiple","Metadata","expression","useDecorators","In","JsonParameterTypes","Name","useMethodDecorators","Returns","Consumes"],"mappings":";;;;;;AAgCO,SAASA,EAAOC,GAAkC;AACvD,SAAO,IAAIC,MAAoC;AAC7C,UAAM,CAACC,GAAQC,GAAaC,CAAK,IAAIH,GAC/BI,IAAWC,EAAS,cAAcJ,GAAQC,CAAW,EAAEC,CAAe,MAAM;AAE1E,IAAAJ,IAAA,OAAOA,KAAS,WAAW,SAAYA;AAEzC,UAAAO,IAAa,CAACP,GAAM,CAACK,KAAY,GAAG,EAAE,OAAO,OAAO,EAAE,KAAK,GAAG;AAapE,IAXmBG;AAAA,MACjBC,EAAGC,EAAmB,KAAK;AAAA,MAC3BC,EAAKJ,CAAU;AAAA,MACfK;AAAA,QACEC,EAAQ,GAAG,EAAE;AAAA,UACX;AAAA,QACF;AAAA,QACAC,EAAS,qBAAqB;AAAA,MAAA;AAAA,IAElC,EAEW,GAAGb,CAAI;AAAA,EACpB;AACF;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"location.js","sources":["../../../../src/decorators/operations/location.ts"],"sourcesContent":["import {JsonHeader} from \"../../interfaces/JsonOpenSpec.js\";\nimport {Returns} from \"./returns.js\";\n\n/**\n * Sets the response Location HTTP header to the specified path parameter.\n *\n * ```typescript\n * @Location('/foo/bar', {description: 'Location to the next step'})\n * @Location('http://example.com')\n * @Location('back')\n * private myMethod() {\n *\n * }\n * ```\n *\n * A path value of “back” has a special meaning, it refers to the URL specified in the `Referer` header of the request. If the `Referer` header was not specified, it refers to “/”.\n *\n * @param location\n * @param meta\n * @returns {Function}\n * @decorator\n * @operation\n */\nexport function Location(location: string, meta?: JsonHeader) {\n return Returns().Location(location, meta);\n}\n"],"names":["Location","location","meta","Returns"],"mappings":";AAuBgB,SAAAA,EAASC,GAAkBC,GAAmB;AAC5D,SAAOC,EAAQ,EAAE,SAASF,GAAUC,CAAI;AAC1C;"}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { OperationVerbs as n } from "../../constants/OperationVerbs.js";
|
|
2
|
+
import { DecoratorContext as s } from "../../domain/DecoratorContext.js";
|
|
3
|
+
import { mapOperationOptions as a } from "../../utils/mapOperationOptions.js";
|
|
4
|
+
class p extends s {
|
|
5
|
+
constructor() {
|
|
6
|
+
super(...arguments), this.methods = ["name", "description", "summary", "method", "id", "use", "useAfter", "useBefore"];
|
|
7
|
+
}
|
|
8
|
+
beforeInit() {
|
|
9
|
+
const e = this.get("path"), t = n[this.get("method")] || n.CUSTOM;
|
|
10
|
+
e && (this.operationPath = this.entity.operation.addOperationPath(t, e));
|
|
11
|
+
}
|
|
12
|
+
onMapKey(e, t) {
|
|
13
|
+
var o, i;
|
|
14
|
+
switch (e) {
|
|
15
|
+
case "name":
|
|
16
|
+
case "id":
|
|
17
|
+
this.entity.operation.operationId(t);
|
|
18
|
+
return;
|
|
19
|
+
case "summary":
|
|
20
|
+
(o = this.operationPath) == null || o.summary(t), this.entity.operation.summary(t);
|
|
21
|
+
return;
|
|
22
|
+
case "description":
|
|
23
|
+
(i = this.operationPath) == null || i.description(t), this.entity.operation.description(t);
|
|
24
|
+
return;
|
|
25
|
+
case "use":
|
|
26
|
+
this.entity.use(t);
|
|
27
|
+
return;
|
|
28
|
+
case "useAfter":
|
|
29
|
+
this.entity.after(t);
|
|
30
|
+
return;
|
|
31
|
+
case "useBefore":
|
|
32
|
+
this.entity.before(t);
|
|
33
|
+
return;
|
|
34
|
+
}
|
|
35
|
+
return super.onMapKey(e, t);
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
function u(...r) {
|
|
39
|
+
const e = a(r);
|
|
40
|
+
return new p(e).build();
|
|
41
|
+
}
|
|
42
|
+
export {
|
|
43
|
+
u as Operation
|
|
44
|
+
};
|
|
45
|
+
//# sourceMappingURL=operation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"operation.js","sources":["../../../../src/decorators/operations/operation.ts"],"sourcesContent":["import {OperationVerbs} from \"../../constants/OperationVerbs.js\";\nimport {DecoratorContext} from \"../../domain/DecoratorContext.js\";\nimport {JsonMethodStore} from \"../../domain/JsonMethodStore.js\";\nimport {JsonMethodPath, type JsonOperation} from \"../../domain/JsonOperation.js\";\nimport {mapOperationOptions} from \"../../utils/mapOperationOptions.js\";\n\nexport interface RouteChainedDecorators {\n <T>(target: Object, propertyKey: string | symbol, descriptor: TypedPropertyDescriptor<T>): TypedPropertyDescriptor<T> | void;\n\n /**\n * @param string\n * @constructor\n */\n Path(string: string): this;\n\n /**\n * Set the operation method\n * @param method\n */\n Method(method: OperationVerbs | string): this;\n\n /**\n * Set the operation id\n * @param id\n */\n Id(id: string): this;\n\n /**\n * Set the operation id\n * @param name\n */\n Name(name: string): this;\n\n /**\n *\n * @param description\n */\n Description(description: string): this;\n\n /**\n * Summary\n * @constructor\n * @param Summary\n */\n Summary(Summary: string): this;\n\n Use(...args: any[]): this;\n\n UseAfter(...args: any[]): this;\n\n UseBefore(...args: any[]): this;\n}\n\nclass OperationDecoratorContext extends DecoratorContext<RouteChainedDecorators> {\n readonly methods: string[] = [\"name\", \"description\", \"summary\", \"method\", \"id\", \"use\", \"useAfter\", \"useBefore\"];\n protected declare entity: JsonMethodStore;\n protected operationPath: JsonMethodPath;\n\n protected beforeInit() {\n const path: string = this.get(\"path\");\n const method: string = OperationVerbs[this.get(\"method\") as OperationVerbs] || OperationVerbs.CUSTOM;\n\n if (path) {\n this.operationPath = this.entity.operation.addOperationPath(method, path);\n }\n }\n\n protected onMapKey(key: string, value: any) {\n switch (key) {\n case \"name\":\n case \"id\":\n this.entity.operation.operationId(value);\n return;\n case \"summary\":\n this.operationPath?.summary(value);\n this.entity.operation.summary(value);\n return;\n case \"description\":\n this.operationPath?.description(value);\n this.entity.operation.description(value);\n\n return;\n case \"use\":\n this.entity.use(value);\n return;\n case \"useAfter\":\n this.entity.after(value);\n return;\n case \"useBefore\":\n this.entity.before(value);\n return;\n }\n\n return super.onMapKey(key, value);\n }\n}\n\n/**\n * Describe a new route with a method and path.\n *\n * ```typescript\n * @Controller('/')\n * export class Ctrl {\n *\n * @Route('GET', '/')\n * get() { }\n * }\n *\n * ```\n *\n * @returns {Function}\n * @param method\n * @param path\n * @param args\n * @decorator\n * @operation\n */\nexport function Operation(method: string, path: string, ...args: any[]): RouteChainedDecorators;\nexport function Operation(...args: any[]): RouteChainedDecorators;\nexport function Operation(...args: any[]): RouteChainedDecorators {\n const routeOptions = mapOperationOptions(args);\n\n const context = new OperationDecoratorContext(routeOptions);\n\n return context.build();\n}\n"],"names":["OperationDecoratorContext","DecoratorContext","path","method","OperationVerbs","key","value","_a","_b","Operation","args","routeOptions","mapOperationOptions"],"mappings":";;;AAqDA,MAAMA,UAAkCC,EAAyC;AAAA,EAAjF,cAAA;AAAA,UAAA,GAAA,SAAA,GACW,KAAA,UAAoB,CAAC,QAAQ,eAAe,WAAW,UAAU,MAAM,OAAO,YAAY,WAAW;AAAA,EAAA;AAAA,EAIpG,aAAa;AACf,UAAAC,IAAe,KAAK,IAAI,MAAM,GAC9BC,IAAiBC,EAAe,KAAK,IAAI,QAAQ,CAAmB,KAAKA,EAAe;AAE9F,IAAIF,MACF,KAAK,gBAAgB,KAAK,OAAO,UAAU,iBAAiBC,GAAQD,CAAI;AAAA,EAC1E;AAAA,EAGQ,SAASG,GAAaC,GAAY;;AAC1C,YAAQD,GAAK;AAAA,MACX,KAAK;AAAA,MACL,KAAK;AACE,aAAA,OAAO,UAAU,YAAYC,CAAK;AACvC;AAAA,MACF,KAAK;AACE,SAAAC,IAAA,KAAA,kBAAA,QAAAA,EAAe,QAAQD,IACvB,KAAA,OAAO,UAAU,QAAQA,CAAK;AACnC;AAAA,MACF,KAAK;AACE,SAAAE,IAAA,KAAA,kBAAA,QAAAA,EAAe,YAAYF,IAC3B,KAAA,OAAO,UAAU,YAAYA,CAAK;AAEvC;AAAA,MACF,KAAK;AACE,aAAA,OAAO,IAAIA,CAAK;AACrB;AAAA,MACF,KAAK;AACE,aAAA,OAAO,MAAMA,CAAK;AACvB;AAAA,MACF,KAAK;AACE,aAAA,OAAO,OAAOA,CAAK;AACxB;AAAA,IAAA;AAGG,WAAA,MAAM,SAASD,GAAKC,CAAK;AAAA,EAAA;AAEpC;AAwBO,SAASG,KAAaC,GAAqC;AAC1D,QAAAC,IAAeC,EAAoBF,CAAI;AAI7C,SAFgB,IAAIV,EAA0BW,CAAY,EAE3C,MAAM;AACvB;"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { DecoratorTypes as e, UnsupportedDecoratorType as n } from "@tsed/core";
|
|
2
|
+
import { JsonEntityFn as p } from "../common/jsonEntityFn.js";
|
|
3
|
+
function i(r) {
|
|
4
|
+
return p((o, t) => {
|
|
5
|
+
if (o.decoratorType !== e.METHOD)
|
|
6
|
+
throw new n(i, t);
|
|
7
|
+
o.operation.operationId(r);
|
|
8
|
+
});
|
|
9
|
+
}
|
|
10
|
+
export {
|
|
11
|
+
i as OperationId
|
|
12
|
+
};
|
|
13
|
+
//# sourceMappingURL=operationId.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"operationId.js","sources":["../../../../src/decorators/operations/operationId.ts"],"sourcesContent":["import {DecoratorTypes, UnsupportedDecoratorType} from \"@tsed/core\";\n\nimport {JsonEntityFn} from \"../common/jsonEntityFn.js\";\n\n/**\n * Set a swagger operationId explicitly.\n *\n * @param operationId\n * @decorator\n * @swagger\n * @schema\n * @operation\n */\nexport function OperationId(operationId: string): MethodDecorator {\n return JsonEntityFn((store, args) => {\n if (store.decoratorType !== DecoratorTypes.METHOD) {\n throw new UnsupportedDecoratorType(OperationId, args);\n }\n\n store.operation!.operationId(operationId);\n });\n}\n"],"names":["OperationId","operationId","JsonEntityFn","store","args","DecoratorTypes","UnsupportedDecoratorType"],"mappings":";;AAaO,SAASA,EAAYC,GAAsC;AACzD,SAAAC,EAAa,CAACC,GAAOC,MAAS;AAC/B,QAAAD,EAAM,kBAAkBE,EAAe;AACnC,YAAA,IAAIC,EAAyBN,GAAaI,CAAI;AAGhD,IAAAD,EAAA,UAAW,YAAYF,CAAW;AAAA,EAAA,CACzC;AACH;"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { DecoratorTypes as p, UnsupportedDecoratorType as n } from "@tsed/core";
|
|
2
|
+
import { JsonEntityFn as a } from "../common/jsonEntityFn.js";
|
|
3
|
+
function i(r, t = "/") {
|
|
4
|
+
return a((o, e) => {
|
|
5
|
+
if (o.decoratorType !== p.METHOD)
|
|
6
|
+
throw new n(i, e);
|
|
7
|
+
o.operation.addOperationPath(r.toUpperCase(), t);
|
|
8
|
+
});
|
|
9
|
+
}
|
|
10
|
+
export {
|
|
11
|
+
i as OperationPath
|
|
12
|
+
};
|
|
13
|
+
//# sourceMappingURL=operationPath.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"operationPath.js","sources":["../../../../src/decorators/operations/operationPath.ts"],"sourcesContent":["import {DecoratorTypes, UnsupportedDecoratorType} from \"@tsed/core\";\n\nimport {OperationVerbs} from \"../../constants/OperationVerbs.js\";\nimport {JsonEntityFn} from \"../common/jsonEntityFn.js\";\n\n/**\n * Declare new Operation with his path and http method.\n *\n * ::: warning\n * Don't use decorator with Ts.ED application.\n *\n * Use these decorators instead:\n *\n * <ApiList query=\"status.includes('decorator') && status.includes('httpMethod')\" />\n *\n * :::\n *\n * @param method\n * @param path\n * @decorator\n * @swagger\n * @schema\n * @operation\n */\nexport function OperationPath(method: OperationVerbs | string, path: string | RegExp = \"/\") {\n return JsonEntityFn((store, args) => {\n if (store.decoratorType !== DecoratorTypes.METHOD) {\n throw new UnsupportedDecoratorType(OperationPath, args);\n }\n\n store.operation!.addOperationPath(method.toUpperCase(), path);\n });\n}\n"],"names":["OperationPath","method","path","JsonEntityFn","store","args","DecoratorTypes","UnsupportedDecoratorType"],"mappings":";;AAwBgB,SAAAA,EAAcC,GAAiCC,IAAwB,KAAK;AACnF,SAAAC,EAAa,CAACC,GAAOC,MAAS;AAC/B,QAAAD,EAAM,kBAAkBE,EAAe;AACnC,YAAA,IAAIC,EAAyBP,GAAeK,CAAI;AAGxD,IAAAD,EAAM,UAAW,iBAAiBH,EAAO,YAAA,GAAeC,CAAI;AAAA,EAAA,CAC7D;AACH;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"partial.js","sources":["../../../../src/decorators/operations/partial.ts"],"sourcesContent":["import {Groups} from \"../common/groups.js\";\n\n/**\n * Apply Partial group strategy on the input model\n *\n * @decorator\n * @validation\n * @swagger\n * @schema\n * @input\n */\nexport function Partial(): ParameterDecorator {\n return Groups(\"partial\") as any;\n}\n"],"names":["Partial","Groups"],"mappings":";AAWO,SAASA,IAA8B;AAC5C,SAAOC,EAAO,SAAS;AACzB;"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { DecoratorTypes as e, UnsupportedDecoratorType as p } from "@tsed/core";
|
|
2
|
+
import { JsonEntityFn as n } from "../common/jsonEntityFn.js";
|
|
3
|
+
function a(r) {
|
|
4
|
+
return n((o, t) => {
|
|
5
|
+
if (o.decoratorType !== e.CLASS)
|
|
6
|
+
throw new p(a, t);
|
|
7
|
+
o.path = r;
|
|
8
|
+
});
|
|
9
|
+
}
|
|
10
|
+
export {
|
|
11
|
+
a as Path
|
|
12
|
+
};
|
|
13
|
+
//# sourceMappingURL=path.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"path.js","sources":["../../../../src/decorators/operations/path.ts"],"sourcesContent":["import {DecoratorTypes, UnsupportedDecoratorType} from \"@tsed/core\";\n\nimport {JsonEntityFn} from \"../common/jsonEntityFn.js\";\n\n/**\n * Set class path to expose all endpoints\n *\n * ::: warning\n * Don't use this decorator to change the path if you develop your application with Ts.ED.\n * :::\n *\n * @param path\n * @decorator\n * @swagger\n * @schema\n * @classDecorator\n * @operation\n */\nexport function Path(path: string): ClassDecorator {\n return JsonEntityFn((store, args) => {\n if (store.decoratorType !== DecoratorTypes.CLASS) {\n throw new UnsupportedDecoratorType(Path, args);\n }\n\n store.path = path;\n });\n}\n"],"names":["Path","path","JsonEntityFn","store","args","DecoratorTypes","UnsupportedDecoratorType"],"mappings":";;AAkBO,SAASA,EAAKC,GAA8B;AAC1C,SAAAC,EAAa,CAACC,GAAOC,MAAS;AAC/B,QAAAD,EAAM,kBAAkBE,EAAe;AACnC,YAAA,IAAIC,EAAyBN,GAAMI,CAAI;AAG/C,IAAAD,EAAM,OAAOF;AAAA,EAAA,CACd;AACH;"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { UnsupportedDecoratorType as c, DecoratorTypes as t, decorateMethodsOf as n } from "@tsed/core";
|
|
2
|
+
import { JsonEntityFn as p } from "../common/jsonEntityFn.js";
|
|
3
|
+
function a(...e) {
|
|
4
|
+
return p((o, r) => {
|
|
5
|
+
switch (o.decoratorType) {
|
|
6
|
+
case t.METHOD:
|
|
7
|
+
o.operation.produces(e);
|
|
8
|
+
break;
|
|
9
|
+
case t.CLASS:
|
|
10
|
+
n(r[0], a(...e));
|
|
11
|
+
break;
|
|
12
|
+
default:
|
|
13
|
+
throw new c(a, r);
|
|
14
|
+
}
|
|
15
|
+
});
|
|
16
|
+
}
|
|
17
|
+
export {
|
|
18
|
+
a as Produces
|
|
19
|
+
};
|
|
20
|
+
//# sourceMappingURL=produces.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"produces.js","sources":["../../../../src/decorators/operations/produces.ts"],"sourcesContent":["import {decorateMethodsOf, DecoratorTypes, UnsupportedDecoratorType} from \"@tsed/core\";\n\nimport {JsonEntityFn} from \"../common/jsonEntityFn.js\";\n\n/**\n * Add produces metadata on the decorated element.\n *\n * ## Examples\n * ### On method\n *\n * ```typescript\n * class Model {\n * @Produces(\"text/html\")\n * id: string;\n * }\n * ```\n *\n * ::: warning\n * For openspec v3 prefer `@Returns().ContentType()` usage (see @@Returns@@).\n * :::\n *\n * @param produces\n * @decorator\n * @swagger\n * @methodDecorator\n * @classDecorator\n * @operation\n * @response\n */\nexport function Produces(...produces: string[]): ClassDecorator & MethodDecorator {\n return JsonEntityFn((store, args) => {\n switch (store.decoratorType) {\n case DecoratorTypes.METHOD:\n store.operation!.produces(produces);\n break;\n case DecoratorTypes.CLASS:\n decorateMethodsOf(args[0], Produces(...produces));\n break;\n\n default:\n throw new UnsupportedDecoratorType(Produces, args);\n }\n });\n}\n"],"names":["Produces","produces","JsonEntityFn","store","args","DecoratorTypes","decorateMethodsOf","UnsupportedDecoratorType"],"mappings":";;AA6BO,SAASA,KAAYC,GAAsD;AACzE,SAAAC,EAAa,CAACC,GAAOC,MAAS;AACnC,YAAQD,EAAM,eAAe;AAAA,MAC3B,KAAKE,EAAe;AACZ,QAAAF,EAAA,UAAW,SAASF,CAAQ;AAClC;AAAA,MACF,KAAKI,EAAe;AAClB,QAAAC,EAAkBF,EAAK,CAAC,GAAGJ,EAAS,GAAGC,CAAQ,CAAC;AAChD;AAAA,MAEF;AACQ,cAAA,IAAIM,EAAyBP,GAAUI,CAAI;AAAA,IAAA;AAAA,EACrD,CACD;AACH;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"publish.js","sources":["../../../../src/decorators/operations/publish.ts"],"sourcesContent":["import {OperationVerbs} from \"../../constants/OperationVerbs.js\";\nimport {Operation} from \"./operation.js\";\n\nexport function Publish(event: string) {\n return Operation(OperationVerbs.PUBLISH, event);\n}\n"],"names":["Publish","event","Operation","OperationVerbs"],"mappings":";;AAGO,SAASA,EAAQC,GAAe;AAC9B,SAAAC,EAAUC,EAAe,SAASF,CAAK;AAChD;"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { isNumber as n, isString as s, useDecorators as c } from "@tsed/core";
|
|
2
|
+
import { JsonEntityFn as o } from "../common/jsonEntityFn.js";
|
|
3
|
+
import { Returns as f } from "./returns.js";
|
|
4
|
+
function b(...u) {
|
|
5
|
+
const { status: e, url: i, meta: m } = u.reduce(
|
|
6
|
+
(r, t) => n(t) ? (r.status = t, r) : s(t) ? (r.url = t, r) : (r.meta = t, r),
|
|
7
|
+
{ status: 302, url: "", meta: {} }
|
|
8
|
+
);
|
|
9
|
+
return c(
|
|
10
|
+
f(e).Location(i, m),
|
|
11
|
+
o((r) => {
|
|
12
|
+
var t;
|
|
13
|
+
(t = r.operation) == null || t.setRedirection(e);
|
|
14
|
+
})
|
|
15
|
+
);
|
|
16
|
+
}
|
|
17
|
+
export {
|
|
18
|
+
b as Redirect
|
|
19
|
+
};
|
|
20
|
+
//# sourceMappingURL=redirect.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"redirect.js","sources":["../../../../src/decorators/operations/redirect.ts"],"sourcesContent":["import {isNumber, isString, useDecorators} from \"@tsed/core\";\n\nimport {JsonHeader} from \"../../interfaces/JsonOpenSpec.js\";\nimport {JsonEntityFn} from \"../common/jsonEntityFn.js\";\nimport {Returns} from \"./returns.js\";\n\n/**\n * Redirects to the URL derived from the specified path, with specified status, a positive integer that corresponds to an HTTP status code . If not specified, status defaults to “302 “Found”.\n *\n * ```typescript\n * @Redirect('/foo/bar')\n * @Redirect(301, 'http://example.com').Type(Model)\n * private myMethod() {}\n * ```\n * Redirects can be a fully-qualified URL for redirecting to a different site:\n *\n * ```typescript\n * @Redirect('http://google.com');\n * private myMethod() {}\n * ```\n *\n * Redirects can be relative to the root of the host name. For example, if the application is on http://example.com/admin/post/new, the following would redirect to the URL http://example.com/admin:\n *\n * ```typescript\n * @Redirect('/admin');\n * ```\n * Redirects can be relative to the current URL. For example, from http://example.com/blog/admin/ (notice the trailing slash), the following would redirect to the URL http://example.com/blog/admin/post/new.\n *\n * ```typescript\n * @Redirect('post/new');\n * ```\n *\n * Redirecting to post/new from http://example.com/blog/admin (no trailing slash), will redirect to http://example.com/blog/post/new.\n *\n * If you found the above behavior confusing, think of path segments as directories (with trailing slashes) and files, it will start to make sense.\n *\n * Path-relative redirects are also possible. If you were on http://example.com/admin/post/new, the following would redirect to http//example.com/admin/post:\n *\n * ```typescript\n * @Redirect('..');\n * ``\n *\n * A back redirection redirects the request back to the referer, defaulting to / when the referer is missing.\n *\n * ```typescript\n * @Redirect('back');\n * ```\n *\n * @param url\n * @param meta\n * @decorator\n * @operation\n * @response\n * @headers\n */\nexport function Redirect(url: string, meta?: JsonHeader): MethodDecorator;\nexport function Redirect(status: number, url: string, meta?: JsonHeader): MethodDecorator;\nexport function Redirect(...args: any[]): MethodDecorator {\n const {status, url, meta} = args.reduce(\n (options: any, value: any) => {\n if (isNumber(value)) {\n options.status = value;\n return options;\n }\n\n if (isString(value)) {\n options.url = value;\n return options;\n }\n\n options.meta = value;\n return options;\n },\n {status: 302, url: \"\", meta: {}}\n );\n return useDecorators(\n Returns(status).Location(url, meta),\n JsonEntityFn((entity) => {\n entity.operation?.setRedirection(status);\n })\n );\n}\n"],"names":["Redirect","args","status","url","meta","options","value","isNumber","isString","useDecorators","Returns","JsonEntityFn","entity","_a"],"mappings":";;;AAyDO,SAASA,KAAYC,GAA8B;AACxD,QAAM,EAAC,QAAAC,GAAQ,KAAAC,GAAK,MAAAC,MAAQH,EAAK;AAAA,IAC/B,CAACI,GAAcC,MACTC,EAASD,CAAK,KAChBD,EAAQ,SAASC,GACVD,KAGLG,EAASF,CAAK,KAChBD,EAAQ,MAAMC,GACPD,MAGTA,EAAQ,OAAOC,GACRD;AAAA,IAET,EAAC,QAAQ,KAAK,KAAK,IAAI,MAAM,CAAE,EAAA;AAAA,EACjC;AACO,SAAAI;AAAA,IACLC,EAAQR,CAAM,EAAE,SAASC,GAAKC,CAAI;AAAA,IAClCO,EAAa,CAACC,MAAW;;AAChB,OAAAC,IAAAD,EAAA,cAAA,QAAAC,EAAW,eAAeX;AAAA,IAClC,CAAA;AAAA,EACH;AACF;"}
|