@resistdesign/voltra 3.0.0-alpha.3 → 3.0.0-alpha.30
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 +330 -7
- package/api/DBX/DBXAsserts.d.ts +95 -0
- package/api/DBX/DBXRequest.d.ts +5 -0
- package/api/DBX/DBXRuntime.d.ts +5 -0
- package/api/DBX/DBXScenarioConfig.d.ts +9 -0
- package/api/DBX/DBXSeed.d.ts +124 -0
- package/api/DBX/DBXTypes.d.ts +176 -0
- package/api/DBX/index.d.ts +8 -0
- package/api/DataAccessControl.d.ts +220 -0
- package/api/Indexing/API.d.ts +224 -0
- package/api/Indexing/Cursor.d.ts +101 -0
- package/api/Indexing/Handler/Config.d.ts +39 -0
- package/api/Indexing/Handler.d.ts +166 -0
- package/api/Indexing/Trace.d.ts +54 -0
- package/api/Indexing/Types.d.ts +204 -0
- package/api/Indexing/ddb/AwsSdkV3Adapter.d.ts +8 -0
- package/api/Indexing/ddb/Types.d.ts +169 -0
- package/api/Indexing/docId.d.ts +27 -0
- package/api/Indexing/exact/ExactDdb.d.ts +58 -0
- package/api/Indexing/exact/ExactIndex.d.ts +90 -0
- package/api/Indexing/exact/ExactS3.d.ts +41 -0
- package/api/Indexing/fieldQualification.d.ts +12 -0
- package/api/Indexing/fulltext/FullTextDdbBackend.d.ts +210 -0
- package/api/Indexing/fulltext/FullTextMemoryBackend.d.ts +93 -0
- package/api/Indexing/fulltext/Schema.d.ts +164 -0
- package/api/Indexing/hashUniversal.d.ts +13 -0
- package/api/Indexing/index.d.ts +45 -0
- package/api/Indexing/lossy/LossyDdb.d.ts +43 -0
- package/api/Indexing/lossy/LossyIndex.d.ts +72 -0
- package/api/Indexing/lossy/LossyS3.d.ts +40 -0
- package/api/Indexing/rel/Cursor.d.ts +25 -0
- package/api/Indexing/rel/Handlers.d.ts +143 -0
- package/api/Indexing/rel/RelationalDdb.d.ts +169 -0
- package/api/Indexing/rel/RelationalInMemoryBackend.d.ts +38 -0
- package/api/Indexing/rel/Types.d.ts +69 -0
- package/api/Indexing/structured/Cursor.d.ts +26 -0
- package/api/Indexing/structured/Handlers.d.ts +128 -0
- package/api/Indexing/structured/SearchStructured.d.ts +44 -0
- package/api/Indexing/structured/StructuredDdb.d.ts +166 -0
- package/api/Indexing/structured/StructuredDdbBackend.d.ts +109 -0
- package/api/Indexing/structured/StructuredInMemoryBackend.d.ts +34 -0
- package/api/Indexing/structured/StructuredInMemoryIndex.d.ts +58 -0
- package/api/Indexing/structured/StructuredStringLike.d.ts +25 -0
- package/api/Indexing/structured/StructuredWriter.d.ts +61 -0
- package/api/Indexing/structured/Types.d.ts +126 -0
- package/api/Indexing/structured/index.d.ts +9 -0
- package/api/Indexing/tokenize.d.ts +31 -0
- package/api/ORM/DACUtils.d.ts +270 -0
- package/api/ORM/ListItemUtils.d.ts +40 -0
- package/api/ORM/ORMRouteMap.d.ts +55 -0
- package/api/ORM/TypeInfoORMService.d.ts +555 -0
- package/api/ORM/drivers/DynamoDBDataItemDBDriver/ConfigTypes.d.ts +229 -0
- package/api/ORM/drivers/DynamoDBDataItemDBDriver.d.ts +89 -0
- package/api/ORM/drivers/InMemoryDataItemDBDriver/ConfigTypes.d.ts +4 -0
- package/api/ORM/drivers/InMemoryDataItemDBDriver.d.ts +55 -0
- package/api/ORM/drivers/InMemoryFileItemDBDriver/ConfigTypes.d.ts +13 -0
- package/api/ORM/drivers/InMemoryFileItemDBDriver.d.ts +98 -0
- package/api/ORM/drivers/InMemoryItemRelationshipDBDriver.d.ts +16 -0
- package/api/ORM/drivers/IndexingRelationshipDriver.d.ts +123 -0
- package/api/ORM/drivers/S3FileItemDBDriver/ConfigTypes.d.ts +322 -0
- package/api/ORM/drivers/S3FileItemDBDriver/S3FileDriver.d.ts +118 -0
- package/{src/api → api}/ORM/drivers/S3FileItemDBDriver.d.ts +27 -0
- package/api/ORM/drivers/common/SupportedTypeInfoORMDBDrivers.d.ts +36 -0
- package/{src/api → api}/ORM/drivers/common/Types.d.ts +120 -0
- package/api/ORM/drivers/common/index.d.ts +12 -0
- package/api/ORM/drivers/index.d.ts +22 -0
- package/api/ORM/index.d.ts +33 -0
- package/api/ORM/indexing/criteriaToStructuredWhere.d.ts +17 -0
- package/api/Router/AWS.d.ts +80 -0
- package/api/Router/Auth.d.ts +14 -0
- package/api/Router/CORS.d.ts +66 -0
- package/api/Router/Types.d.ts +138 -0
- package/api/Router/index.d.ts +89 -0
- package/api/index.d.ts +72 -0
- package/api/index.js +8827 -0
- package/app/forms/Engine.d.ts +20 -0
- package/app/forms/UI.d.ts +73 -0
- package/app/forms/core/createAutoField.d.ts +35 -0
- package/app/forms/core/createFormRenderer.d.ts +24 -0
- package/app/forms/core/getFieldKind.d.ts +14 -0
- package/app/forms/core/index.d.ts +16 -0
- package/app/forms/core/mergeSuites.d.ts +22 -0
- package/app/forms/core/resolveSuite.d.ts +14 -0
- package/app/forms/core/types.d.ts +169 -0
- package/app/forms/index.d.ts +15 -0
- package/app/forms/types.d.ts +156 -0
- package/app/helpers/styled.d.ts +3 -0
- package/app/index.d.ts +102 -0
- package/app/index.js +560 -0
- package/{src/app → app}/utils/ApplicationState.d.ts +115 -0
- package/{src/app → app}/utils/ApplicationStateLoader.d.ts +40 -0
- package/app/utils/Controller.d.ts +10 -0
- package/app/utils/Debug.d.ts +14 -0
- package/app/utils/EasyLayout.d.ts +89 -0
- package/app/utils/History.d.ts +165 -0
- package/app/utils/Route.d.ts +158 -0
- package/app/utils/RouteHistory.d.ts +26 -0
- package/app/utils/Service.d.ts +45 -0
- package/app/utils/TypeInfoORMAPIUtils.d.ts +94 -0
- package/app/utils/TypeInfoORMClient.d.ts +103 -0
- package/app/utils/UniversalRouteAdapter.d.ts +73 -0
- package/app/utils/easy-layout/computeAreaBounds.d.ts +5 -0
- package/app/utils/easy-layout/computeTracks.d.ts +16 -0
- package/app/utils/easy-layout/index.d.ts +5 -0
- package/app/utils/easy-layout/parseTemplate.d.ts +12 -0
- package/app/utils/easy-layout/types.d.ts +52 -0
- package/app/utils/easy-layout/validateAreas.d.ts +5 -0
- package/app/utils/index.d.ts +39 -0
- package/{src/common/TypeParsing → build}/TypeMapping.d.ts +8 -0
- package/build/TypeParsing.d.ts +10 -0
- package/build/index.d.ts +15 -0
- package/build/index.js +569 -0
- package/chunk-ATO2455Q.js +258 -0
- package/chunk-FQMZMCXU.js +71 -0
- package/chunk-G5CLUK4Y.js +621 -0
- package/chunk-GYWRAW3Y.js +78 -0
- package/chunk-HVY7POTD.js +22 -0
- package/chunk-I2KLQ2HA.js +19 -0
- package/chunk-IWRHGGGH.js +10 -0
- package/chunk-LGM75I6P.js +353 -0
- package/chunk-MUCSL3UR.js +1 -0
- package/chunk-WELZGQDJ.js +456 -0
- package/common/CommandLine/collectRequiredEnvironmentVariables.d.ts +9 -0
- package/common/CommandLine/index.d.ts +6 -0
- package/common/HelperTypes.d.ts +9 -0
- package/common/IdGeneration/getSimpleId.d.ts +8 -0
- package/{src/common → common}/ItemRelationshipInfoTypes.d.ts +19 -1
- package/common/ItemRelationships/ItemRelationshipValidation.d.ts +21 -0
- package/common/ItemRelationships/index.d.ts +6 -0
- package/common/Logging/Utils.d.ts +19 -0
- package/common/Routing.d.ts +67 -0
- package/common/SearchTypes.d.ts +248 -0
- package/common/SearchUtils.d.ts +55 -0
- package/{src/common → common}/SearchValidation.d.ts +10 -0
- package/{src/common → common}/StringTransformers.d.ts +11 -0
- package/common/Testing/CLI.d.ts +6 -0
- package/common/Testing/CLI.js +432 -0
- package/{src/common → common}/Testing/Types.d.ts +103 -4
- package/{src/common → common}/Testing/Utils.d.ts +65 -1
- package/common/Testing/index.d.ts +8 -0
- package/common/TypeInfoDataItemUtils.d.ts +39 -0
- package/common/TypeInfoORM/Types.d.ts +342 -0
- package/common/TypeInfoORM/index.d.ts +11 -0
- package/common/TypeParsing/Constants.d.ts +4 -0
- package/{src/common → common}/TypeParsing/ParsingUtils/Constants.d.ts +3 -0
- package/{src/common → common}/TypeParsing/ParsingUtils/checkType.d.ts +6 -0
- package/{src/common → common}/TypeParsing/ParsingUtils/checkUnionType.d.ts +6 -0
- package/common/TypeParsing/ParsingUtils/extractCommentTags.d.ts +8 -0
- package/common/TypeParsing/ParsingUtils/extractLiteralValues.d.ts +12 -0
- package/common/TypeParsing/ParsingUtils/extractTypeDetails.d.ts +14 -0
- package/common/TypeParsing/ParsingUtils/getPrimaryFieldForTypeInfo.d.ts +18 -0
- package/common/TypeParsing/ParsingUtils/getTypeInfo.d.ts +9 -0
- package/{src/common → common}/TypeParsing/ParsingUtils/getTypeInfoField.d.ts +6 -0
- package/common/TypeParsing/ParsingUtils/getTypeInfoFromAliasType.d.ts +11 -0
- package/common/TypeParsing/ParsingUtils/getTypeInfoFromFieldFilter.d.ts +12 -0
- package/common/TypeParsing/ParsingUtils/getTypeInfoFromTypeAlias.d.ts +11 -0
- package/common/TypeParsing/ParsingUtils/getTypeKeyword.d.ts +9 -0
- package/common/TypeParsing/ParsingUtils/getUnionOrIntersectionTypeInfo.d.ts +11 -0
- package/common/TypeParsing/ParsingUtils/getUnionOrLiteralStringValues.d.ts +8 -0
- package/{src/common → common}/TypeParsing/TypeInfo.d.ts +61 -1
- package/{src/common → common}/TypeParsing/Utils.d.ts +26 -0
- package/{src/common → common}/TypeParsing/Validation.d.ts +105 -0
- package/common/TypeParsing/index.d.ts +8 -0
- package/common/index.d.ts +50 -0
- package/common/index.js +36 -0
- package/{src/iac → iac}/SimpleCFT.d.ts +46 -2
- package/iac/index.d.ts +40 -0
- package/iac/index.js +2 -0
- package/iac/packs/auth/user-management.d.ts +82 -0
- package/iac/packs/auth.d.ts +88 -0
- package/iac/packs/build/utils.d.ts +289 -0
- package/iac/packs/build.d.ts +92 -0
- package/iac/packs/cdn.d.ts +33 -0
- package/iac/packs/cloud-function.d.ts +67 -0
- package/{src/iac → iac}/packs/database.d.ts +4 -1
- package/{src/iac → iac}/packs/dns.d.ts +22 -1
- package/iac/packs/file-storage.d.ts +46 -0
- package/iac/packs/gateway.d.ts +79 -0
- package/iac/packs/index.d.ts +60 -0
- package/iac/packs/index.js +1370 -0
- package/iac/packs/repo.d.ts +28 -0
- package/iac/packs/ssl-certificate.d.ts +28 -0
- package/{src/iac → iac}/types/Constants.d.ts +15 -0
- package/iac/types/Renderers.d.ts +96 -0
- package/iac/types/Types.d.ts +131 -0
- package/iac/types/Utils.d.ts +9 -0
- package/{src/iac → iac}/utils/index.d.ts +56 -5
- package/iac/utils/patch-utils.d.ts +66 -0
- package/iac-packs/index.d.ts +6 -0
- package/native/forms/UI.d.ts +67 -0
- package/native/forms/createNativeFormRenderer.d.ts +21 -0
- package/native/forms/index.d.ts +9 -0
- package/native/forms/primitives/index.d.ts +38 -0
- package/native/forms/suite.d.ts +15 -0
- package/native/index.d.ts +19 -0
- package/native/index.js +717 -0
- package/native/testing/react-native.d.ts +28 -0
- package/native/utils/EasyLayout.d.ts +88 -0
- package/native/utils/History.d.ts +102 -0
- package/native/utils/Route.d.ts +83 -0
- package/native/utils/index.d.ts +9 -0
- package/package.json +76 -44
- package/web/forms/UI.d.ts +68 -0
- package/web/forms/createWebFormRenderer.d.ts +21 -0
- package/web/forms/index.d.ts +9 -0
- package/web/forms/primitives/index.d.ts +21 -0
- package/web/forms/suite.d.ts +15 -0
- package/web/index.d.ts +15 -0
- package/web/index.js +547 -0
- package/web/utils/EasyLayout.d.ts +47 -0
- package/web/utils/Route.d.ts +14 -0
- package/web/utils/index.d.ts +6 -0
- package/src/api/DataAccessControl.d.ts +0 -85
- package/src/api/DataAccessControl.js +0 -159
- package/src/api/ORM/DACUtils.d.ts +0 -60
- package/src/api/ORM/DACUtils.js +0 -197
- package/src/api/ORM/ListItemUtils.d.ts +0 -7
- package/src/api/ORM/ListItemUtils.js +0 -22
- package/src/api/ORM/ORMRouteMap.d.ts +0 -19
- package/src/api/ORM/ORMRouteMap.js +0 -82
- package/src/api/ORM/TypeInfoORMService.d.ts +0 -103
- package/src/api/ORM/TypeInfoORMService.js +0 -581
- package/src/api/ORM/drivers/DynamoDBDataItemDBDriver/ConfigTypes.d.ts +0 -63
- package/src/api/ORM/drivers/DynamoDBDataItemDBDriver/ConfigTypes.js +0 -2
- package/src/api/ORM/drivers/DynamoDBDataItemDBDriver.d.ts +0 -36
- package/src/api/ORM/drivers/DynamoDBDataItemDBDriver.js +0 -282
- package/src/api/ORM/drivers/S3FileItemDBDriver/ConfigTypes.d.ts +0 -90
- package/src/api/ORM/drivers/S3FileItemDBDriver/ConfigTypes.js +0 -2
- package/src/api/ORM/drivers/S3FileItemDBDriver/S3FileDriver.d.ts +0 -45
- package/src/api/ORM/drivers/S3FileItemDBDriver/S3FileDriver.js +0 -127
- package/src/api/ORM/drivers/S3FileItemDBDriver.js +0 -182
- package/src/api/ORM/drivers/common/SupportedTypeInfoORMDBDrivers.d.ts +0 -12
- package/src/api/ORM/drivers/common/SupportedTypeInfoORMDBDrivers.js +0 -20
- package/src/api/ORM/drivers/common/Types.js +0 -14
- package/src/api/ORM/drivers/common/index.d.ts +0 -2
- package/src/api/ORM/drivers/common/index.js +0 -18
- package/src/api/ORM/drivers/index.d.ts +0 -3
- package/src/api/ORM/drivers/index.js +0 -19
- package/src/api/ORM/index.d.ts +0 -4
- package/src/api/ORM/index.js +0 -43
- package/src/api/Router/AWS.d.ts +0 -26
- package/src/api/Router/AWS.js +0 -76
- package/src/api/Router/Auth.d.ts +0 -2
- package/src/api/Router/Auth.js +0 -9
- package/src/api/Router/CORS.d.ts +0 -6
- package/src/api/Router/CORS.js +0 -27
- package/src/api/Router/Types.d.ts +0 -71
- package/src/api/Router/Types.js +0 -2
- package/src/api/Router/index.d.ts +0 -18
- package/src/api/Router/index.js +0 -145
- package/src/api/index.d.ts +0 -3
- package/src/api/index.js +0 -39
- package/src/app/index.d.ts +0 -1
- package/src/app/index.js +0 -37
- package/src/app/utils/ApplicationState.js +0 -86
- package/src/app/utils/ApplicationStateLoader.js +0 -57
- package/src/app/utils/Controller.d.ts +0 -4
- package/src/app/utils/Controller.js +0 -47
- package/src/app/utils/Debug.d.ts +0 -4
- package/src/app/utils/Debug.js +0 -30
- package/src/app/utils/EasyLayout.d.ts +0 -49
- package/src/app/utils/EasyLayout.js +0 -122
- package/src/app/utils/Route.d.ts +0 -28
- package/src/app/utils/Route.js +0 -102
- package/src/app/utils/Service.d.ts +0 -12
- package/src/app/utils/Service.js +0 -34
- package/src/app/utils/TypeInfoORMAPIUtils.d.ts +0 -20
- package/src/app/utils/TypeInfoORMAPIUtils.js +0 -62
- package/src/app/utils/TypeInfoORMClient.d.ts +0 -24
- package/src/app/utils/TypeInfoORMClient.js +0 -69
- package/src/app/utils/index.d.ts +0 -8
- package/src/app/utils/index.js +0 -24
- package/src/common/CommandLine/collectRequiredEnvironmentVariables.d.ts +0 -1
- package/src/common/CommandLine/collectRequiredEnvironmentVariables.js +0 -16
- package/src/common/HelperTypes.d.ts +0 -3
- package/src/common/HelperTypes.js +0 -2
- package/src/common/IdGeneration/getSimpleId.d.ts +0 -4
- package/src/common/IdGeneration/getSimpleId.js +0 -16
- package/src/common/IdGeneration/index.js +0 -17
- package/src/common/ItemRelationshipInfoTypes.js +0 -20
- package/src/common/ItemRelationships/ItemRelationshipValidation.d.ts +0 -10
- package/src/common/ItemRelationships/ItemRelationshipValidation.js +0 -43
- package/src/common/ItemRelationships/index.d.ts +0 -1
- package/src/common/ItemRelationships/index.js +0 -17
- package/src/common/Logging/Utils.d.ts +0 -10
- package/src/common/Logging/Utils.js +0 -33
- package/src/common/Logging/index.js +0 -17
- package/src/common/Routing.d.ts +0 -25
- package/src/common/Routing.js +0 -102
- package/src/common/SearchTypes.d.ts +0 -98
- package/src/common/SearchTypes.js +0 -39
- package/src/common/SearchUtils.d.ts +0 -22
- package/src/common/SearchUtils.js +0 -134
- package/src/common/SearchValidation.js +0 -90
- package/src/common/Storyboarding/Types.d.ts +0 -25
- package/src/common/Storyboarding/Types.js +0 -2
- package/src/common/StringTransformers.js +0 -36
- package/src/common/Testing/CLI.d.ts +0 -2
- package/src/common/Testing/CLI.js +0 -56
- package/src/common/Testing/Types.js +0 -19
- package/src/common/Testing/Utils.js +0 -334
- package/src/common/Testing/index.d.ts +0 -2
- package/src/common/Testing/index.js +0 -18
- package/src/common/TypeInfoDataItemUtils.d.ts +0 -10
- package/src/common/TypeInfoDataItemUtils.js +0 -55
- package/src/common/TypeInfoORM/Types.d.ts +0 -76
- package/src/common/TypeInfoORM/Types.js +0 -55
- package/src/common/TypeInfoORM/index.d.ts +0 -1
- package/src/common/TypeInfoORM/index.js +0 -17
- package/src/common/TypeParsing/Constants.d.ts +0 -1
- package/src/common/TypeParsing/Constants.js +0 -4
- package/src/common/TypeParsing/ParsingUtils/Constants.js +0 -8
- package/src/common/TypeParsing/ParsingUtils/checkType.js +0 -46
- package/src/common/TypeParsing/ParsingUtils/checkUnionType.js +0 -15
- package/src/common/TypeParsing/ParsingUtils/extractCommentTags.d.ts +0 -2
- package/src/common/TypeParsing/ParsingUtils/extractCommentTags.js +0 -105
- package/src/common/TypeParsing/ParsingUtils/extractLiteralValues.d.ts +0 -6
- package/src/common/TypeParsing/ParsingUtils/extractLiteralValues.js +0 -42
- package/src/common/TypeParsing/ParsingUtils/extractTypeDetails.d.ts +0 -8
- package/src/common/TypeParsing/ParsingUtils/extractTypeDetails.js +0 -14
- package/src/common/TypeParsing/ParsingUtils/getPrimaryFieldForTypeInfo.d.ts +0 -5
- package/src/common/TypeParsing/ParsingUtils/getPrimaryFieldForTypeInfo.js +0 -27
- package/src/common/TypeParsing/ParsingUtils/getTypeInfo.d.ts +0 -3
- package/src/common/TypeParsing/ParsingUtils/getTypeInfo.js +0 -27
- package/src/common/TypeParsing/ParsingUtils/getTypeInfoField.js +0 -44
- package/src/common/TypeParsing/ParsingUtils/getTypeInfoFromAliasType.d.ts +0 -4
- package/src/common/TypeParsing/ParsingUtils/getTypeInfoFromAliasType.js +0 -28
- package/src/common/TypeParsing/ParsingUtils/getTypeInfoFromFieldFilter.d.ts +0 -4
- package/src/common/TypeParsing/ParsingUtils/getTypeInfoFromFieldFilter.js +0 -105
- package/src/common/TypeParsing/ParsingUtils/getTypeInfoFromTypeAlias.d.ts +0 -4
- package/src/common/TypeParsing/ParsingUtils/getTypeInfoFromTypeAlias.js +0 -20
- package/src/common/TypeParsing/ParsingUtils/getTypeKeyword.d.ts +0 -3
- package/src/common/TypeParsing/ParsingUtils/getTypeKeyword.js +0 -17
- package/src/common/TypeParsing/ParsingUtils/getUnionOrIntersectionTypeInfo.d.ts +0 -4
- package/src/common/TypeParsing/ParsingUtils/getUnionOrIntersectionTypeInfo.js +0 -49
- package/src/common/TypeParsing/ParsingUtils/getUnionOrLiteralStringValues.d.ts +0 -2
- package/src/common/TypeParsing/ParsingUtils/getUnionOrLiteralStringValues.js +0 -24
- package/src/common/TypeParsing/TypeInfo.js +0 -13
- package/src/common/TypeParsing/TypeMapping.js +0 -32
- package/src/common/TypeParsing/TypeParsing.d.ts +0 -5
- package/src/common/TypeParsing/TypeParsing.js +0 -39
- package/src/common/TypeParsing/Utils.js +0 -94
- package/src/common/TypeParsing/Validation.js +0 -340
- package/src/common/TypeParsing/index.d.ts +0 -5
- package/src/common/TypeParsing/index.js +0 -44
- package/src/common/index.d.ts +0 -11
- package/src/common/index.js +0 -47
- package/src/iac/SimpleCFT.js +0 -82
- package/src/iac/index.d.ts +0 -9
- package/src/iac/index.js +0 -48
- package/src/iac/packs/auth/user-management.d.ts +0 -14
- package/src/iac/packs/auth/user-management.js +0 -302
- package/src/iac/packs/auth.d.ts +0 -19
- package/src/iac/packs/auth.js +0 -47
- package/src/iac/packs/build/utils.d.ts +0 -100
- package/src/iac/packs/build/utils.js +0 -23
- package/src/iac/packs/build.d.ts +0 -29
- package/src/iac/packs/build.js +0 -217
- package/src/iac/packs/cdn.d.ts +0 -12
- package/src/iac/packs/cdn.js +0 -126
- package/src/iac/packs/cloud-function.d.ts +0 -17
- package/src/iac/packs/cloud-function.js +0 -69
- package/src/iac/packs/database.js +0 -27
- package/src/iac/packs/dns.js +0 -26
- package/src/iac/packs/file-storage.d.ts +0 -14
- package/src/iac/packs/file-storage.js +0 -71
- package/src/iac/packs/gateway.d.ts +0 -27
- package/src/iac/packs/gateway.js +0 -342
- package/src/iac/packs/index.d.ts +0 -11
- package/src/iac/packs/index.js +0 -27
- package/src/iac/packs/repo.d.ts +0 -10
- package/src/iac/packs/repo.js +0 -34
- package/src/iac/packs/ssl-certificate.d.ts +0 -10
- package/src/iac/packs/ssl-certificate.js +0 -36
- package/src/iac/types/CloudFormationResourceSpecification.d.ts +0 -2
- package/src/iac/types/Constants.js +0 -20
- package/src/iac/types/IaCTypes.js +0 -14
- package/src/iac/types/Renderers.d.ts +0 -12
- package/src/iac/types/Renderers.js +0 -112
- package/src/iac/types/Types.d.ts +0 -37
- package/src/iac/types/Types.js +0 -2
- package/src/iac/types/Utils.d.ts +0 -2
- package/src/iac/types/Utils.js +0 -60
- package/src/iac/types/generate.js +0 -31
- package/src/iac/utils/index.js +0 -105
- package/src/iac/utils/patch-utils.d.ts +0 -15
- package/src/iac/utils/patch-utils.js +0 -62
- package/src/index.d.ts +0 -178
- package/src/index.js +0 -214
- /package/{src/common → common}/IdGeneration/index.d.ts +0 -0
- /package/{src/common → common}/Logging/index.d.ts +0 -0
- /package/{src/iac → iac}/types/IaCTypes.d.ts +0 -0
- /package/{src/iac → iac}/types/generate.d.ts +0 -0
package/app/index.js
ADDED
|
@@ -0,0 +1,560 @@
|
|
|
1
|
+
import '../chunk-MUCSL3UR.js';
|
|
2
|
+
export { createEasyLayout, getEasyLayoutTemplateDetails, getPascalCaseAreaName } from '../chunk-FQMZMCXU.js';
|
|
3
|
+
export { Route, RouteContext, RouteContextConsumer, RouteContextProvider, RouteProvider, buildHistoryPath, buildQueryString, buildRoutePath, canUseBrowserHistory, computeTrackPixels, createBrowserRouteAdapter, createHistoryBackHandler, createManualRouteAdapter, createMemoryHistory, createNativeRouteAdapter, createRouteAdapterFromHistory, createUniversalAdapter, parseHistoryPath, useRouteContext } from '../chunk-G5CLUK4Y.js';
|
|
4
|
+
export { AutoForm, AutoFormView, computeAreaBounds, createAutoField, createFormRenderer, getFieldKind, parseTemplate, resolveSuite, useFormEngine, validateAreas } from '../chunk-WELZGQDJ.js';
|
|
5
|
+
import '../chunk-HVY7POTD.js';
|
|
6
|
+
import '../chunk-IWRHGGGH.js';
|
|
7
|
+
import { mergeStringPaths, PATH_DELIMITER } from '../chunk-GYWRAW3Y.js';
|
|
8
|
+
import '../chunk-I2KLQ2HA.js';
|
|
9
|
+
import { createContext, useContext, useRef, useMemo, useCallback, useState, useEffect } from 'react';
|
|
10
|
+
import { jsx } from 'react/jsx-runtime';
|
|
11
|
+
|
|
12
|
+
var getApplicationStateIdentifier = (subStateIdMap) => subStateIdMap ? subStateIdMap : {};
|
|
13
|
+
var getApplicationStateModified = (identifier, modificationState) => !!modificationState.get(identifier);
|
|
14
|
+
var getApplicationStateValue = (identifier, applicationState) => applicationState.get(identifier);
|
|
15
|
+
var setApplicationStateModified = (identifier, value, modificationState) => new Map(modificationState).set(identifier, value);
|
|
16
|
+
var setApplicationStateValue = (identifier, value, applicationState) => new Map(applicationState).set(identifier, value);
|
|
17
|
+
var getApplicationStateValueStructure = (idStructure, applicationState) => Object.keys(idStructure).reduce(
|
|
18
|
+
(acc, k) => ({
|
|
19
|
+
...acc,
|
|
20
|
+
[k]: getApplicationStateValue(idStructure[k], applicationState)
|
|
21
|
+
}),
|
|
22
|
+
{}
|
|
23
|
+
);
|
|
24
|
+
var ApplicationStateContext = createContext({
|
|
25
|
+
modified: /* @__PURE__ */ new Map(),
|
|
26
|
+
value: /* @__PURE__ */ new Map(),
|
|
27
|
+
onChange: () => {
|
|
28
|
+
},
|
|
29
|
+
setModified: () => {
|
|
30
|
+
}
|
|
31
|
+
});
|
|
32
|
+
var { Provider } = ApplicationStateContext;
|
|
33
|
+
var useApplicationStateValue = (identifier) => {
|
|
34
|
+
const {
|
|
35
|
+
modified: modificationState,
|
|
36
|
+
value: applicationState,
|
|
37
|
+
onChange: setApplicationState,
|
|
38
|
+
setModified: setModificationState
|
|
39
|
+
} = useContext(ApplicationStateContext);
|
|
40
|
+
const appStateRef = useRef(applicationState);
|
|
41
|
+
appStateRef.current = applicationState;
|
|
42
|
+
const modified = useMemo(
|
|
43
|
+
() => getApplicationStateModified(identifier, modificationState),
|
|
44
|
+
[identifier, modificationState]
|
|
45
|
+
);
|
|
46
|
+
const value = useMemo(
|
|
47
|
+
() => getApplicationStateValue(identifier, applicationState),
|
|
48
|
+
[identifier, applicationState]
|
|
49
|
+
);
|
|
50
|
+
const setModified = useCallback(
|
|
51
|
+
(isModified) => {
|
|
52
|
+
setModificationState(
|
|
53
|
+
setApplicationStateModified(identifier, isModified, modificationState)
|
|
54
|
+
);
|
|
55
|
+
},
|
|
56
|
+
[identifier, setModificationState]
|
|
57
|
+
);
|
|
58
|
+
const onChange = useCallback(
|
|
59
|
+
(newValue) => {
|
|
60
|
+
setApplicationState(
|
|
61
|
+
setApplicationStateValue(identifier, newValue, appStateRef.current)
|
|
62
|
+
);
|
|
63
|
+
setModified(true);
|
|
64
|
+
},
|
|
65
|
+
[identifier, setApplicationState]
|
|
66
|
+
);
|
|
67
|
+
const controller = useMemo(
|
|
68
|
+
() => ({
|
|
69
|
+
modified,
|
|
70
|
+
value,
|
|
71
|
+
onChange,
|
|
72
|
+
setModified
|
|
73
|
+
}),
|
|
74
|
+
[modified, onChange, setModified, value]
|
|
75
|
+
);
|
|
76
|
+
return controller;
|
|
77
|
+
};
|
|
78
|
+
var useApplicationStateValueStructure = (idStructure) => {
|
|
79
|
+
const { value: applicationState, onChange: setApplicationState } = useContext(
|
|
80
|
+
ApplicationStateContext
|
|
81
|
+
);
|
|
82
|
+
const valueStructure = useMemo(
|
|
83
|
+
() => getApplicationStateValueStructure(idStructure, applicationState),
|
|
84
|
+
[applicationState, idStructure]
|
|
85
|
+
);
|
|
86
|
+
const onChangeStructure = useMemo(
|
|
87
|
+
() => Object.keys(idStructure).reduce(
|
|
88
|
+
(acc, k) => ({
|
|
89
|
+
...acc,
|
|
90
|
+
[k]: (newValue) => {
|
|
91
|
+
setApplicationState(
|
|
92
|
+
setApplicationStateValue(
|
|
93
|
+
idStructure[k],
|
|
94
|
+
newValue,
|
|
95
|
+
applicationState
|
|
96
|
+
)
|
|
97
|
+
);
|
|
98
|
+
}
|
|
99
|
+
}),
|
|
100
|
+
{}
|
|
101
|
+
),
|
|
102
|
+
[applicationState, idStructure, setApplicationState]
|
|
103
|
+
);
|
|
104
|
+
const controller = useMemo(
|
|
105
|
+
() => ({
|
|
106
|
+
valueStructure,
|
|
107
|
+
onChangeStructure
|
|
108
|
+
}),
|
|
109
|
+
[onChangeStructure, valueStructure]
|
|
110
|
+
);
|
|
111
|
+
return controller;
|
|
112
|
+
};
|
|
113
|
+
var ApplicationStateProvider = ({
|
|
114
|
+
children
|
|
115
|
+
}) => {
|
|
116
|
+
const [modified, setModified] = useState(
|
|
117
|
+
/* @__PURE__ */ new Map()
|
|
118
|
+
);
|
|
119
|
+
const [value, setValue] = useState(/* @__PURE__ */ new Map());
|
|
120
|
+
const controller = useMemo(
|
|
121
|
+
() => ({
|
|
122
|
+
modified,
|
|
123
|
+
value,
|
|
124
|
+
onChange: setValue,
|
|
125
|
+
setModified
|
|
126
|
+
}),
|
|
127
|
+
[modified, value]
|
|
128
|
+
);
|
|
129
|
+
return /* @__PURE__ */ jsx(Provider, { value: controller, children });
|
|
130
|
+
};
|
|
131
|
+
|
|
132
|
+
// src/app/utils/Service.ts
|
|
133
|
+
var getFullUrl = (protocol, domain, basePath = "", path = "", port) => {
|
|
134
|
+
const portString = !!port ? `:${port}` : "";
|
|
135
|
+
const fullPath = mergeStringPaths(
|
|
136
|
+
basePath,
|
|
137
|
+
path,
|
|
138
|
+
PATH_DELIMITER,
|
|
139
|
+
false,
|
|
140
|
+
false,
|
|
141
|
+
false
|
|
142
|
+
);
|
|
143
|
+
return `${protocol}://${domain}${portString}${fullPath}`;
|
|
144
|
+
};
|
|
145
|
+
var sendServiceRequest = async (config, path = "", args = []) => {
|
|
146
|
+
const { protocol, domain, port, basePath = "", authorization = "" } = config;
|
|
147
|
+
const fullUrl = getFullUrl(protocol, domain, basePath, path, port);
|
|
148
|
+
const requestHeaders = {
|
|
149
|
+
"Content-Type": "application/json",
|
|
150
|
+
...!!authorization ? {
|
|
151
|
+
Authorization: `Bearer ${authorization}`
|
|
152
|
+
} : {}
|
|
153
|
+
};
|
|
154
|
+
const response = await fetch(fullUrl, {
|
|
155
|
+
headers: requestHeaders,
|
|
156
|
+
credentials: "same-origin",
|
|
157
|
+
method: "POST",
|
|
158
|
+
body: JSON.stringify(args)
|
|
159
|
+
});
|
|
160
|
+
const { ok: responseIsOk } = response;
|
|
161
|
+
const data = await response.json();
|
|
162
|
+
if (responseIsOk) {
|
|
163
|
+
return data;
|
|
164
|
+
} else {
|
|
165
|
+
throw data;
|
|
166
|
+
}
|
|
167
|
+
};
|
|
168
|
+
var useApplicationStateLoader = (config) => {
|
|
169
|
+
const {
|
|
170
|
+
identifier,
|
|
171
|
+
remoteProcedureCall,
|
|
172
|
+
resetOnError = false,
|
|
173
|
+
onLoadComplete,
|
|
174
|
+
manual = false
|
|
175
|
+
} = config;
|
|
176
|
+
const { args = [] } = remoteProcedureCall;
|
|
177
|
+
const argsRef = useRef(args);
|
|
178
|
+
argsRef.current = args;
|
|
179
|
+
const [cacheValidity, setCacheValidity] = useState({});
|
|
180
|
+
const [loading, setLoading] = useState(false);
|
|
181
|
+
const [latestError, setLatestError] = useState();
|
|
182
|
+
const { onChange, setModified } = useApplicationStateValue(identifier);
|
|
183
|
+
const invalidate = useCallback(() => {
|
|
184
|
+
setCacheValidity({});
|
|
185
|
+
}, []);
|
|
186
|
+
const makeRemoteProcedureCall = useCallback(
|
|
187
|
+
async (...directArgs) => {
|
|
188
|
+
let success;
|
|
189
|
+
setLoading(true);
|
|
190
|
+
setLatestError(void 0);
|
|
191
|
+
try {
|
|
192
|
+
const { serviceConfig, path } = remoteProcedureCall;
|
|
193
|
+
const result = await sendServiceRequest(
|
|
194
|
+
serviceConfig,
|
|
195
|
+
path,
|
|
196
|
+
directArgs
|
|
197
|
+
);
|
|
198
|
+
success = true;
|
|
199
|
+
onChange(result);
|
|
200
|
+
setModified(false);
|
|
201
|
+
} catch (error) {
|
|
202
|
+
success = false;
|
|
203
|
+
setLatestError(error);
|
|
204
|
+
if (resetOnError) {
|
|
205
|
+
onChange(void 0);
|
|
206
|
+
setModified(false);
|
|
207
|
+
}
|
|
208
|
+
}
|
|
209
|
+
setLoading(false);
|
|
210
|
+
onLoadComplete?.(success);
|
|
211
|
+
},
|
|
212
|
+
[remoteProcedureCall, onChange, setModified, resetOnError, onLoadComplete]
|
|
213
|
+
);
|
|
214
|
+
const appStateLoader = useMemo(
|
|
215
|
+
() => ({
|
|
216
|
+
loading,
|
|
217
|
+
latestError,
|
|
218
|
+
invalidate,
|
|
219
|
+
makeRemoteProcedureCall
|
|
220
|
+
}),
|
|
221
|
+
[loading, latestError, invalidate, makeRemoteProcedureCall]
|
|
222
|
+
);
|
|
223
|
+
useEffect(() => {
|
|
224
|
+
if (!manual && argsRef.current) {
|
|
225
|
+
makeRemoteProcedureCall(...argsRef.current);
|
|
226
|
+
}
|
|
227
|
+
}, [cacheValidity, manual, makeRemoteProcedureCall]);
|
|
228
|
+
return appStateLoader;
|
|
229
|
+
};
|
|
230
|
+
var getKeyValueWithoutError = (obj, key) => {
|
|
231
|
+
try {
|
|
232
|
+
return obj[key];
|
|
233
|
+
} catch (e) {
|
|
234
|
+
return void 0;
|
|
235
|
+
}
|
|
236
|
+
};
|
|
237
|
+
var useController = (parentValue, key, onParentValueChange, isArrayIndex = false) => {
|
|
238
|
+
const [value, setValue] = useState(getKeyValueWithoutError(parentValue, key));
|
|
239
|
+
const onChange = useCallback(
|
|
240
|
+
(value2) => {
|
|
241
|
+
try {
|
|
242
|
+
setValue(value2);
|
|
243
|
+
if (isArrayIndex) {
|
|
244
|
+
const newArray = [...parentValue];
|
|
245
|
+
newArray[key] = value2;
|
|
246
|
+
onParentValueChange(newArray);
|
|
247
|
+
} else {
|
|
248
|
+
onParentValueChange({
|
|
249
|
+
...parentValue,
|
|
250
|
+
[key]: value2
|
|
251
|
+
});
|
|
252
|
+
}
|
|
253
|
+
} catch (e) {
|
|
254
|
+
}
|
|
255
|
+
},
|
|
256
|
+
[parentValue, key, onParentValueChange, isArrayIndex]
|
|
257
|
+
);
|
|
258
|
+
useEffect(() => {
|
|
259
|
+
try {
|
|
260
|
+
setValue(getKeyValueWithoutError(parentValue, key));
|
|
261
|
+
} catch (e) {
|
|
262
|
+
setValue(void 0);
|
|
263
|
+
}
|
|
264
|
+
}, [parentValue, key]);
|
|
265
|
+
return [value, onChange];
|
|
266
|
+
};
|
|
267
|
+
var getChangedDependencyIndexes = (prevDeps, nextDeps) => nextDeps.map((dep, i) => dep !== prevDeps[i] ? i : null).filter((dep) => dep !== null);
|
|
268
|
+
var useDebugDependencies = (dependencies) => {
|
|
269
|
+
const firstRender = useRef(true);
|
|
270
|
+
const prevDeps = useRef(dependencies);
|
|
271
|
+
useEffect(() => {
|
|
272
|
+
if (firstRender.current) {
|
|
273
|
+
firstRender.current = false;
|
|
274
|
+
return;
|
|
275
|
+
}
|
|
276
|
+
const changedDeps = getChangedDependencyIndexes(
|
|
277
|
+
prevDeps.current,
|
|
278
|
+
dependencies
|
|
279
|
+
);
|
|
280
|
+
if (changedDeps.length > 0) {
|
|
281
|
+
console.log("Changed dependencies:", changedDeps);
|
|
282
|
+
}
|
|
283
|
+
prevDeps.current = dependencies;
|
|
284
|
+
}, dependencies);
|
|
285
|
+
};
|
|
286
|
+
|
|
287
|
+
// src/common/IdGeneration/getSimpleId.ts
|
|
288
|
+
var LAST_HAST_ID = 0;
|
|
289
|
+
var textEncoder = new TextEncoder();
|
|
290
|
+
var bytesToBinaryString = (bytes) => {
|
|
291
|
+
let out = "";
|
|
292
|
+
for (let i = 0; i < bytes.length; i++) {
|
|
293
|
+
out += String.fromCharCode(bytes[i]);
|
|
294
|
+
}
|
|
295
|
+
return out;
|
|
296
|
+
};
|
|
297
|
+
var getBase64EncodedString = (input) => {
|
|
298
|
+
const bytes = textEncoder.encode(input);
|
|
299
|
+
let base64 = "";
|
|
300
|
+
if (typeof globalThis.btoa === "function") {
|
|
301
|
+
const binary = bytesToBinaryString(bytes);
|
|
302
|
+
base64 = globalThis.btoa(binary);
|
|
303
|
+
} else {
|
|
304
|
+
const anyGlobal = globalThis;
|
|
305
|
+
if (typeof anyGlobal.Buffer === "function") {
|
|
306
|
+
base64 = anyGlobal.Buffer.from(bytes).toString("base64");
|
|
307
|
+
} else {
|
|
308
|
+
throw new Error("No base64 encoder available (need btoa or Buffer).");
|
|
309
|
+
}
|
|
310
|
+
}
|
|
311
|
+
return base64;
|
|
312
|
+
};
|
|
313
|
+
var getSimpleId = () => {
|
|
314
|
+
const hashId = LAST_HAST_ID++;
|
|
315
|
+
const base64Datetime = getBase64EncodedString(
|
|
316
|
+
(/* @__PURE__ */ new Date()).toISOString()
|
|
317
|
+
);
|
|
318
|
+
const rand1 = Math.random().toString(36).substring(2, 15);
|
|
319
|
+
const rand2 = Math.random().toString(36).substring(2, 15);
|
|
320
|
+
return `${hashId}-${base64Datetime}-${rand1}-${rand2}`;
|
|
321
|
+
};
|
|
322
|
+
|
|
323
|
+
// src/app/utils/TypeInfoORMAPIUtils.ts
|
|
324
|
+
var handleRequest = async (requestId, args, typeInfoORMAPI, methodName, onRequestStateChange) => {
|
|
325
|
+
onRequestStateChange(methodName, requestId, { loading: true });
|
|
326
|
+
try {
|
|
327
|
+
const requestMethod = typeInfoORMAPI[methodName];
|
|
328
|
+
const result = await requestMethod(...args);
|
|
329
|
+
onRequestStateChange(methodName, requestId, {
|
|
330
|
+
loading: false,
|
|
331
|
+
data: result
|
|
332
|
+
});
|
|
333
|
+
} catch (error) {
|
|
334
|
+
onRequestStateChange(methodName, requestId, {
|
|
335
|
+
loading: false,
|
|
336
|
+
error: typeof error === "object" && error !== null && "message" in error ? error.message : void 0
|
|
337
|
+
});
|
|
338
|
+
}
|
|
339
|
+
};
|
|
340
|
+
var requestHandlerFactory = (typeInfoORMAPI, methodName, onRequestStateChange) => (...args) => {
|
|
341
|
+
const requestId = getSimpleId();
|
|
342
|
+
handleRequest(
|
|
343
|
+
requestId,
|
|
344
|
+
args,
|
|
345
|
+
typeInfoORMAPI,
|
|
346
|
+
methodName,
|
|
347
|
+
onRequestStateChange
|
|
348
|
+
);
|
|
349
|
+
return requestId;
|
|
350
|
+
};
|
|
351
|
+
var useTypeInfoORMAPI = (typeInfoORMAPI) => {
|
|
352
|
+
const [state, setState] = useState({});
|
|
353
|
+
const onRequestStateChange = useCallback(
|
|
354
|
+
(methodName, requestId, { loading, data, error }) => {
|
|
355
|
+
setState(
|
|
356
|
+
({
|
|
357
|
+
[methodName]: {
|
|
358
|
+
activeRequests: prevActiveRequests = [],
|
|
359
|
+
data: prevData,
|
|
360
|
+
error: prevError
|
|
361
|
+
} = {},
|
|
362
|
+
...prevState
|
|
363
|
+
}) => {
|
|
364
|
+
const newActiveRequests = loading ? [...prevActiveRequests, requestId] : prevActiveRequests.filter((id) => id !== requestId);
|
|
365
|
+
const currentlyLoading = newActiveRequests.length > 0;
|
|
366
|
+
return {
|
|
367
|
+
...prevState,
|
|
368
|
+
[methodName]: {
|
|
369
|
+
activeRequests: newActiveRequests,
|
|
370
|
+
loading: currentlyLoading,
|
|
371
|
+
data: currentlyLoading ? void 0 : data ?? prevData,
|
|
372
|
+
error: currentlyLoading ? void 0 : error ?? prevError
|
|
373
|
+
}
|
|
374
|
+
};
|
|
375
|
+
}
|
|
376
|
+
);
|
|
377
|
+
},
|
|
378
|
+
[]
|
|
379
|
+
);
|
|
380
|
+
const api = useMemo(() => {
|
|
381
|
+
const apiBase = {};
|
|
382
|
+
for (const aM in typeInfoORMAPI) {
|
|
383
|
+
const methodName = aM;
|
|
384
|
+
apiBase[methodName] = requestHandlerFactory(
|
|
385
|
+
typeInfoORMAPI,
|
|
386
|
+
methodName,
|
|
387
|
+
onRequestStateChange
|
|
388
|
+
);
|
|
389
|
+
}
|
|
390
|
+
return apiBase;
|
|
391
|
+
}, [typeInfoORMAPI, onRequestStateChange]);
|
|
392
|
+
return {
|
|
393
|
+
state,
|
|
394
|
+
api
|
|
395
|
+
};
|
|
396
|
+
};
|
|
397
|
+
|
|
398
|
+
// src/app/utils/TypeInfoORMClient.ts
|
|
399
|
+
var TypeInfoORMClient = class {
|
|
400
|
+
/**
|
|
401
|
+
* Create a client for TypeInfoORM routes.
|
|
402
|
+
*
|
|
403
|
+
* @param config - Service configuration for the API routes.
|
|
404
|
+
*/
|
|
405
|
+
constructor(config) {
|
|
406
|
+
this.config = config;
|
|
407
|
+
}
|
|
408
|
+
/**
|
|
409
|
+
* Dispatch a request to the configured service.
|
|
410
|
+
*
|
|
411
|
+
* @param path - Route path for the ORM method.
|
|
412
|
+
* @param args - Arguments to send in the request body.
|
|
413
|
+
* @returns Parsed response payload.
|
|
414
|
+
*/
|
|
415
|
+
makeRequest = async (path, args) => {
|
|
416
|
+
const cleanedArgs = [...args];
|
|
417
|
+
while (cleanedArgs.length > 0 && typeof cleanedArgs[cleanedArgs.length - 1] === "undefined") {
|
|
418
|
+
cleanedArgs.pop();
|
|
419
|
+
}
|
|
420
|
+
const result = await sendServiceRequest(this.config, path, cleanedArgs);
|
|
421
|
+
return result;
|
|
422
|
+
};
|
|
423
|
+
/**
|
|
424
|
+
* Create an item of the provided type.
|
|
425
|
+
*
|
|
426
|
+
* @param typeName - TypeInfo type name.
|
|
427
|
+
* @param item - Item payload to persist.
|
|
428
|
+
* @returns The created item result.
|
|
429
|
+
*/
|
|
430
|
+
create = async (typeName, item) => {
|
|
431
|
+
return await this.makeRequest("create" /* CREATE */, [
|
|
432
|
+
typeName,
|
|
433
|
+
item
|
|
434
|
+
]);
|
|
435
|
+
};
|
|
436
|
+
/**
|
|
437
|
+
* Read an item by its primary field value.
|
|
438
|
+
*
|
|
439
|
+
* @param typeName - TypeInfo type name.
|
|
440
|
+
* @param primaryFieldValue - Primary field value to lookup.
|
|
441
|
+
* @returns The retrieved item, if found.
|
|
442
|
+
*/
|
|
443
|
+
read = async (typeName, primaryFieldValue, selectedFields) => {
|
|
444
|
+
return await this.makeRequest("read" /* READ */, [
|
|
445
|
+
typeName,
|
|
446
|
+
primaryFieldValue,
|
|
447
|
+
selectedFields
|
|
448
|
+
]);
|
|
449
|
+
};
|
|
450
|
+
/**
|
|
451
|
+
* Update an item by replacing it with the provided payload.
|
|
452
|
+
*
|
|
453
|
+
* @param typeName - TypeInfo type name.
|
|
454
|
+
* @param item - Updated item payload.
|
|
455
|
+
* @returns Whether the update succeeded.
|
|
456
|
+
*/
|
|
457
|
+
update = async (typeName, item) => {
|
|
458
|
+
return await this.makeRequest("update" /* UPDATE */, [
|
|
459
|
+
typeName,
|
|
460
|
+
item
|
|
461
|
+
]);
|
|
462
|
+
};
|
|
463
|
+
/**
|
|
464
|
+
* Delete an item by its primary field value.
|
|
465
|
+
*
|
|
466
|
+
* @param typeName - TypeInfo type name.
|
|
467
|
+
* @param primaryFieldValue - Primary field value to delete.
|
|
468
|
+
* @returns Whether the delete succeeded.
|
|
469
|
+
*/
|
|
470
|
+
delete = async (typeName, primaryFieldValue) => {
|
|
471
|
+
return await this.makeRequest("delete" /* DELETE */, [
|
|
472
|
+
typeName,
|
|
473
|
+
primaryFieldValue
|
|
474
|
+
]);
|
|
475
|
+
};
|
|
476
|
+
/**
|
|
477
|
+
* List items for a given type.
|
|
478
|
+
*
|
|
479
|
+
* @param typeName - TypeInfo type name.
|
|
480
|
+
* @param config - List configuration including filters and paging.
|
|
481
|
+
* @param selectedFields - Optional fields to project.
|
|
482
|
+
* @returns List results for the query.
|
|
483
|
+
*/
|
|
484
|
+
list = async (typeName, config, selectedFields) => {
|
|
485
|
+
return await this.makeRequest("list" /* LIST */, [
|
|
486
|
+
typeName,
|
|
487
|
+
config,
|
|
488
|
+
selectedFields
|
|
489
|
+
]);
|
|
490
|
+
};
|
|
491
|
+
/**
|
|
492
|
+
* Create a relationship between items.
|
|
493
|
+
*
|
|
494
|
+
* @param relationshipItem - Relationship payload.
|
|
495
|
+
* @returns Whether the relationship was created.
|
|
496
|
+
*/
|
|
497
|
+
createRelationship = async (relationshipItem) => {
|
|
498
|
+
return await this.makeRequest(
|
|
499
|
+
"create-relationship" /* CREATE_RELATIONSHIP */,
|
|
500
|
+
[relationshipItem]
|
|
501
|
+
);
|
|
502
|
+
};
|
|
503
|
+
/**
|
|
504
|
+
* Delete a relationship between items.
|
|
505
|
+
*
|
|
506
|
+
* @param relationshipItem - Relationship payload.
|
|
507
|
+
* @returns Results describing the deletion.
|
|
508
|
+
*/
|
|
509
|
+
deleteRelationship = async (relationshipItem) => {
|
|
510
|
+
return await this.makeRequest(
|
|
511
|
+
"delete-relationship" /* DELETE_RELATIONSHIP */,
|
|
512
|
+
[relationshipItem]
|
|
513
|
+
);
|
|
514
|
+
};
|
|
515
|
+
/**
|
|
516
|
+
* List relationship records matching the query.
|
|
517
|
+
*
|
|
518
|
+
* @param config - Relationship list query configuration.
|
|
519
|
+
* @returns Relationship list results.
|
|
520
|
+
*/
|
|
521
|
+
listRelationships = async (config) => {
|
|
522
|
+
return await this.makeRequest("list-relationships" /* LIST_RELATIONSHIPS */, [
|
|
523
|
+
config
|
|
524
|
+
]);
|
|
525
|
+
};
|
|
526
|
+
/**
|
|
527
|
+
* List related items for a relationship query.
|
|
528
|
+
*
|
|
529
|
+
* @param config - Relationship list query configuration.
|
|
530
|
+
* @param selectedFields - Optional fields to project on related items.
|
|
531
|
+
* @returns Related item list results.
|
|
532
|
+
*/
|
|
533
|
+
listRelatedItems = async (config, selectedFields) => {
|
|
534
|
+
return await this.makeRequest("list-related-items" /* LIST_RELATED_ITEMS */, [
|
|
535
|
+
config,
|
|
536
|
+
selectedFields
|
|
537
|
+
]);
|
|
538
|
+
};
|
|
539
|
+
};
|
|
540
|
+
|
|
541
|
+
// src/app/forms/core/mergeSuites.ts
|
|
542
|
+
var mergeSuites = (base, overrides) => {
|
|
543
|
+
return {
|
|
544
|
+
renderers: {
|
|
545
|
+
...base.renderers ?? {},
|
|
546
|
+
...overrides.renderers ?? {}
|
|
547
|
+
},
|
|
548
|
+
primitives: {
|
|
549
|
+
...base.primitives ?? {},
|
|
550
|
+
...overrides.primitives ?? {}
|
|
551
|
+
}
|
|
552
|
+
};
|
|
553
|
+
};
|
|
554
|
+
var withRendererOverride = (kind, renderer) => ({
|
|
555
|
+
renderers: {
|
|
556
|
+
[kind]: renderer
|
|
557
|
+
}
|
|
558
|
+
});
|
|
559
|
+
|
|
560
|
+
export { ApplicationStateContext, ApplicationStateProvider, TypeInfoORMClient, getApplicationStateIdentifier, getApplicationStateModified, getApplicationStateValue, getApplicationStateValueStructure, getChangedDependencyIndexes, getFullUrl, handleRequest, mergeSuites, requestHandlerFactory, sendServiceRequest, setApplicationStateModified, setApplicationStateValue, useApplicationStateLoader, useApplicationStateValue, useApplicationStateValueStructure, useController, useDebugDependencies, useTypeInfoORMAPI, withRendererOverride };
|