@webiny/project 6.6.0-alpha.1 → 6.6.0-alpha.11
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/ProjectSdk.d.ts +8 -19
- package/ProjectSdk.js +1 -28
- package/ProjectSdk.js.map +1 -1
- package/abstractions/features/hooks/index.d.ts +0 -8
- package/abstractions/features/hooks/index.js +0 -8
- package/abstractions/features/index.d.ts +0 -8
- package/abstractions/features/index.js +0 -8
- package/abstractions/models/IAppModel.d.ts +0 -2
- package/abstractions/models/IProjectModel.d.ts +0 -2
- package/abstractions/services/InitHostingSdkService.d.ts +21 -0
- package/abstractions/services/InitHostingSdkService.js +5 -0
- package/abstractions/services/InitHostingSdkService.js.map +1 -0
- package/abstractions/services/ProjectInfoService/ProjectInfoService.d.ts +6 -6
- package/abstractions/services/ProjectInfoService/ProjectInfoService.js.map +1 -1
- package/abstractions/services/ProjectInfoService/index.d.ts +0 -1
- package/abstractions/services/ProjectInfoService/index.js +0 -1
- package/abstractions/services/index.d.ts +1 -13
- package/abstractions/services/index.js +1 -13
- package/components/FeatureFlag.d.ts +9 -4
- package/components/FeatureFlag.js +6 -7
- package/components/FeatureFlag.js.map +1 -1
- package/createProjectSdkContainer.js +23 -12
- package/createProjectSdkContainer.js.map +1 -1
- package/decorators/GetFeatureFlagsWithLicense.js +1 -0
- package/decorators/GetFeatureFlagsWithLicense.js.map +1 -1
- package/decorators/index.d.ts +0 -6
- package/decorators/index.js +0 -6
- package/defineExtension/createExtensionReactComponent.js +9 -1
- package/defineExtension/createExtensionReactComponent.js.map +1 -1
- package/defineExtension/types.d.ts +7 -2
- package/exports/infra/admin.d.ts +0 -2
- package/exports/infra/admin.js +0 -2
- package/exports/infra/api.d.ts +0 -2
- package/exports/infra/api.js +0 -2
- package/exports/infra/core.d.ts +0 -2
- package/exports/infra/core.js +0 -2
- package/exports/infra.d.ts +0 -2
- package/exports/infra.js +0 -2
- package/extensions/AdminApiUrl.js +2 -1
- package/extensions/AdminApiUrl.js.map +1 -1
- package/extensions/AdminBuildParam.js +5 -5
- package/extensions/AdminBuildParam.js.map +1 -1
- package/extensions/AdminExtension.d.ts +1 -1
- package/extensions/AdminExtension.js +6 -5
- package/extensions/AdminExtension.js.map +1 -1
- package/extensions/AdminWebsocketsUrl.d.ts +1 -1
- package/extensions/AdminWebsocketsUrl.js +2 -1
- package/extensions/AdminWebsocketsUrl.js.map +1 -1
- package/extensions/ApiBuildParam.js +11 -10
- package/extensions/ApiBuildParam.js.map +1 -1
- package/extensions/ApiExtension.d.ts +1 -1
- package/extensions/ApiExtension.js +8 -5
- package/extensions/ApiExtension.js.map +1 -1
- package/extensions/BugReporter.d.ts +6 -0
- package/extensions/BugReporter.js +34 -0
- package/extensions/BugReporter.js.map +1 -0
- package/extensions/DatabaseSetup.js +2 -1
- package/extensions/DatabaseSetup.js.map +1 -1
- package/extensions/EnvVar.js +2 -1
- package/extensions/EnvVar.js.map +1 -1
- package/extensions/ExtensionDefinitions.js +2 -1
- package/extensions/ExtensionDefinitions.js.map +1 -1
- package/extensions/FeatureFlags.d.ts +7 -1
- package/extensions/FeatureFlags.js +12 -2
- package/extensions/FeatureFlags.js.map +1 -1
- package/extensions/{pulumi/ProductionEnvironments.js → ProductionEnvironments.js} +4 -3
- package/extensions/ProductionEnvironments.js.map +1 -0
- package/extensions/Project/WcpInjectTelemetryClientAfterBuild.js.map +1 -1
- package/extensions/Project/showConfigChangeNotice.d.ts +1 -1
- package/extensions/Project/showConfigChangeNotice.js.map +1 -1
- package/extensions/ProjectDecorator.js +2 -1
- package/extensions/ProjectDecorator.js.map +1 -1
- package/extensions/ProjectId.js +2 -1
- package/extensions/ProjectId.js.map +1 -1
- package/extensions/ProjectImplementation.js +2 -1
- package/extensions/ProjectImplementation.js.map +1 -1
- package/extensions/Telemetry.js +2 -1
- package/extensions/Telemetry.js.map +1 -1
- package/extensions/api/BackgroundTasks.d.ts +4 -0
- package/extensions/api/BackgroundTasks.js +25 -0
- package/extensions/api/BackgroundTasks.js.map +1 -0
- package/extensions/api/Cms/ModelFieldCompression.d.ts +4 -0
- package/extensions/api/Cms/ModelFieldCompression.js +25 -0
- package/extensions/api/Cms/ModelFieldCompression.js.map +1 -0
- package/extensions/api/Mailer/Smtp.d.ts +8 -0
- package/extensions/api/Mailer/Smtp.js +22 -0
- package/extensions/api/Mailer/Smtp.js.map +1 -0
- package/extensions/api/Mailer/Smtp.test.js +127 -0
- package/extensions/api/Mailer/Smtp.test.js.map +1 -0
- package/extensions/api/Mailer/SmtpParamsSchema.d.ts +9 -0
- package/extensions/api/Mailer/SmtpParamsSchema.js +17 -0
- package/extensions/api/Mailer/SmtpParamsSchema.js.map +1 -0
- package/extensions/api/Route/ApiRoute.d.ts +23 -0
- package/extensions/api/Route/ApiRoute.js +92 -0
- package/extensions/api/Route/ApiRoute.js.map +1 -0
- package/extensions/api/Route/index.d.ts +2 -0
- package/extensions/api/Route/index.js +2 -0
- package/extensions/api/Route/routePath.d.ts +20 -0
- package/extensions/api/Route/routePath.js +10 -0
- package/extensions/api/Route/routePath.js.map +1 -0
- package/extensions/api/index.d.ts +5 -0
- package/extensions/api/index.js +5 -0
- package/extensions/hasDefaultExport.d.ts +2 -0
- package/extensions/hasDefaultExport.js +17 -0
- package/extensions/hasDefaultExport.js.map +1 -0
- package/extensions/hooks/AdminAfterBuild.js +2 -1
- package/extensions/hooks/AdminAfterBuild.js.map +1 -1
- package/extensions/hooks/AdminBeforeBuild.js +2 -1
- package/extensions/hooks/AdminBeforeBuild.js.map +1 -1
- package/extensions/hooks/AdminBeforeWatch.js +2 -1
- package/extensions/hooks/AdminBeforeWatch.js.map +1 -1
- package/extensions/hooks/AfterBuild.js +2 -1
- package/extensions/hooks/AfterBuild.js.map +1 -1
- package/extensions/hooks/ApiAfterBuild.js +2 -1
- package/extensions/hooks/ApiAfterBuild.js.map +1 -1
- package/extensions/hooks/ApiBeforeBuild.js +2 -1
- package/extensions/hooks/ApiBeforeBuild.js.map +1 -1
- package/extensions/hooks/ApiBeforeWatch.js +2 -1
- package/extensions/hooks/ApiBeforeWatch.js.map +1 -1
- package/extensions/hooks/BeforeBuild.js +2 -1
- package/extensions/hooks/BeforeBuild.js.map +1 -1
- package/extensions/hooks/BeforeWatch.js +2 -1
- package/extensions/hooks/BeforeWatch.js.map +1 -1
- package/extensions/hooks/CoreAfterBuild.js +2 -1
- package/extensions/hooks/CoreAfterBuild.js.map +1 -1
- package/extensions/hooks/CoreBeforeBuild.js +2 -1
- package/extensions/hooks/CoreBeforeBuild.js.map +1 -1
- package/extensions/hooks/CoreBeforeWatch.js +2 -1
- package/extensions/hooks/CoreBeforeWatch.js.map +1 -1
- package/extensions/hooks/index.d.ts +0 -8
- package/extensions/hooks/index.js +0 -8
- package/extensions/hosting/assertHostingType.d.ts +13 -0
- package/extensions/hosting/assertHostingType.js +12 -0
- package/extensions/hosting/assertHostingType.js.map +1 -0
- package/extensions/hosting/extensionImplementations.d.ts +13 -0
- package/extensions/hosting/extensionImplementations.js +4 -0
- package/extensions/hosting/extensionImplementations.js.map +1 -0
- package/extensions/hosting/getExtensionImplementation.d.ts +1 -0
- package/extensions/hosting/getExtensionImplementation.js +9 -0
- package/extensions/hosting/getExtensionImplementation.js.map +1 -0
- package/extensions/hosting/hostingType.d.ts +2 -0
- package/extensions/hosting/hostingType.js +0 -0
- package/extensions/hosting/index.d.ts +4 -0
- package/extensions/hosting/index.js +4 -0
- package/extensions/hosting/registerExtensionImplementation.d.ts +12 -0
- package/extensions/hosting/registerExtensionImplementation.js +13 -0
- package/extensions/hosting/registerExtensionImplementation.js.map +1 -0
- package/extensions/index.d.ts +26 -39
- package/extensions/index.js +10 -21
- package/extensions/index.js.map +1 -1
- package/extensions/infra/Env.js +5 -0
- package/extensions/infra/Env.js.map +1 -1
- package/features/GetProductionEnvironments/GetProductionEnvironments.js +1 -1
- package/features/GetProductionEnvironments/GetProductionEnvironments.js.map +1 -1
- package/features/Serve/Serve.d.ts +1 -1
- package/features/Serve/Serve.js.map +1 -1
- package/features/Watch/watchers/worker.js +3 -0
- package/features/Watch/watchers/worker.js.map +1 -1
- package/features/hooks/index.d.ts +0 -8
- package/features/hooks/index.js +0 -8
- package/features/index.d.ts +0 -8
- package/features/index.js +0 -8
- package/index.d.ts +0 -4
- package/index.js +1 -5
- package/index.js.map +1 -1
- package/models/AppModel.js +1 -2
- package/models/AppModel.js.map +1 -1
- package/models/ProjectModel.js +0 -2
- package/models/ProjectModel.js.map +1 -1
- package/package.json +29 -34
- package/services/GetAppService/GetAppService.js +1 -3
- package/services/GetAppService/GetAppService.js.map +1 -1
- package/services/GetProjectConfigService/ConfigRenderErrorBoundary.d.ts +15 -0
- package/services/GetProjectConfigService/ConfigRenderErrorBoundary.js +23 -0
- package/services/GetProjectConfigService/ConfigRenderErrorBoundary.js.map +1 -0
- package/services/GetProjectConfigService/EnvContext.d.ts +3 -2
- package/services/GetProjectConfigService/EnvContext.js +4 -6
- package/services/GetProjectConfigService/EnvContext.js.map +1 -1
- package/services/GetProjectConfigService/GetProjectConfigService.js +14 -11
- package/services/GetProjectConfigService/GetProjectConfigService.js.map +1 -1
- package/services/GetProjectConfigService/LicenseDecoratedFeatureFlags.js +1 -0
- package/services/GetProjectConfigService/LicenseDecoratedFeatureFlags.js.map +1 -1
- package/services/GetProjectConfigService/WcpProjectLicenseContext.d.ts +1 -0
- package/services/GetProjectConfigService/WcpProjectLicenseContext.js +1 -0
- package/services/GetProjectConfigService/WcpProjectLicenseContext.js.map +1 -1
- package/services/GetProjectConfigService/getRenderCacheKey.d.ts +1 -0
- package/services/GetProjectConfigService/getRenderCacheKey.js +13 -0
- package/services/GetProjectConfigService/getRenderCacheKey.js.map +1 -0
- package/services/GetProjectConfigService/nullRenderer.d.ts +4 -0
- package/services/GetProjectConfigService/nullRenderer.js +83 -0
- package/services/GetProjectConfigService/nullRenderer.js.map +1 -0
- package/services/GetProjectConfigService/renderConfig.d.ts +3 -12
- package/services/GetProjectConfigService/renderConfig.js +10 -35
- package/services/GetProjectConfigService/renderConfig.js.map +1 -1
- package/services/GetProjectConfigService/renderExtensions.d.ts +8 -0
- package/services/GetProjectConfigService/renderExtensions.js +52 -0
- package/services/GetProjectConfigService/renderExtensions.js.map +1 -0
- package/services/GetProjectService/GetProjectService.js +0 -2
- package/services/GetProjectService/GetProjectService.js.map +1 -1
- package/services/InitProjectSdkService/InitProjectSdkService.d.ts +6 -2
- package/services/InitProjectSdkService/InitProjectSdkService.js +22 -19
- package/services/InitProjectSdkService/InitProjectSdkService.js.map +1 -1
- package/services/InitProjectSdkService/applyWcpEnvVars.js +27 -9
- package/services/InitProjectSdkService/applyWcpEnvVars.js.map +1 -1
- package/services/InitProjectSdkService/registerHooks.js +4 -16
- package/services/InitProjectSdkService/registerHooks.js.map +1 -1
- package/services/ProjectInfoService/ProjectInfoService.d.ts +7 -3
- package/services/ProjectInfoService/ProjectInfoService.js +3 -11
- package/services/ProjectInfoService/ProjectInfoService.js.map +1 -1
- package/services/ProjectInfoService/index.d.ts +0 -1
- package/services/ProjectInfoService/index.js +0 -1
- package/services/ValidateProjectConfigService/ValidateProjectConfigService.js +10 -7
- package/services/ValidateProjectConfigService/ValidateProjectConfigService.js.map +1 -1
- package/services/WcpService/GetProjectEnvironment.js +16 -5
- package/services/WcpService/GetProjectEnvironment.js.map +1 -1
- package/services/WcpService/WcpGqlClient.js +2 -2
- package/services/WcpService/WcpGqlClient.js.map +1 -1
- package/services/WcpService/fetchProjectEnvironmentByApiKey.d.ts +8 -0
- package/services/WcpService/fetchProjectEnvironmentByApiKey.js +21 -0
- package/services/WcpService/fetchProjectEnvironmentByApiKey.js.map +1 -0
- package/services/index.d.ts +0 -12
- package/services/index.js +0 -12
- package/utils/ExtensionSrcResolver.js +2 -2
- package/utils/ExtensionSrcResolver.js.map +1 -1
- package/utils/apiRuntimeEnv.d.ts +2 -2
- package/utils/apiRuntimeEnv.js.map +1 -1
- package/utils/env/index.d.ts +0 -1
- package/utils/env/index.js +0 -1
- package/utils/index.d.ts +2 -0
- package/utils/index.js +2 -0
- package/utils/registerSrcExtensions.d.ts +13 -0
- package/utils/registerSrcExtensions.js +10 -0
- package/utils/registerSrcExtensions.js.map +1 -0
- package/utils/trace/TraceRecorder.d.ts +17 -0
- package/utils/trace/TraceRecorder.js +51 -0
- package/utils/trace/TraceRecorder.js.map +1 -0
- package/utils/trace/formatTraceReport.d.ts +2 -0
- package/utils/trace/formatTraceReport.js +53 -0
- package/utils/trace/formatTraceReport.js.map +1 -0
- package/utils/trace/index.d.ts +6 -0
- package/utils/trace/index.js +6 -0
- package/utils/trace/isTraceRequested.d.ts +1 -0
- package/utils/trace/isTraceRequested.js +12 -0
- package/utils/trace/isTraceRequested.js.map +1 -0
- package/utils/trace/startTrace.d.ts +1 -0
- package/utils/trace/startTrace.js +19 -0
- package/utils/trace/startTrace.js.map +1 -0
- package/utils/trace/trace.d.ts +1 -0
- package/utils/trace/trace.js +13 -0
- package/utils/trace/trace.js.map +1 -0
- package/utils/trace/traceAsync.d.ts +1 -0
- package/utils/trace/traceAsync.js +13 -0
- package/utils/trace/traceAsync.js.map +1 -0
- package/abstractions/features/DeployApp.d.ts +0 -20
- package/abstractions/features/DeployApp.js +0 -5
- package/abstractions/features/DeployApp.js.map +0 -1
- package/abstractions/features/DestroyApp.d.ts +0 -18
- package/abstractions/features/DestroyApp.js +0 -5
- package/abstractions/features/DestroyApp.js.map +0 -1
- package/abstractions/features/ExportStack.d.ts +0 -18
- package/abstractions/features/ExportStack.js +0 -5
- package/abstractions/features/ExportStack.js.map +0 -1
- package/abstractions/features/GetAppOutput.d.ts +0 -18
- package/abstractions/features/GetAppOutput.js +0 -5
- package/abstractions/features/GetAppOutput.js.map +0 -1
- package/abstractions/features/GetAppStackOutput.d.ts +0 -21
- package/abstractions/features/GetAppStackOutput.js +0 -5
- package/abstractions/features/GetAppStackOutput.js.map +0 -1
- package/abstractions/features/GetPulumiResourceNamePrefix.d.ts +0 -7
- package/abstractions/features/GetPulumiResourceNamePrefix.js +0 -5
- package/abstractions/features/GetPulumiResourceNamePrefix.js.map +0 -1
- package/abstractions/features/RefreshApp.d.ts +0 -18
- package/abstractions/features/RefreshApp.js +0 -5
- package/abstractions/features/RefreshApp.js.map +0 -1
- package/abstractions/features/RunPulumiCommand.d.ts +0 -19
- package/abstractions/features/RunPulumiCommand.js +0 -5
- package/abstractions/features/RunPulumiCommand.js.map +0 -1
- package/abstractions/features/hooks/AdminAfterDeploy.d.ts +0 -9
- package/abstractions/features/hooks/AdminAfterDeploy.js +0 -5
- package/abstractions/features/hooks/AdminAfterDeploy.js.map +0 -1
- package/abstractions/features/hooks/AdminBeforeDeploy.d.ts +0 -9
- package/abstractions/features/hooks/AdminBeforeDeploy.js +0 -5
- package/abstractions/features/hooks/AdminBeforeDeploy.js.map +0 -1
- package/abstractions/features/hooks/AfterDeploy.d.ts +0 -9
- package/abstractions/features/hooks/AfterDeploy.js +0 -5
- package/abstractions/features/hooks/AfterDeploy.js.map +0 -1
- package/abstractions/features/hooks/ApiAfterDeploy.d.ts +0 -9
- package/abstractions/features/hooks/ApiAfterDeploy.js +0 -5
- package/abstractions/features/hooks/ApiAfterDeploy.js.map +0 -1
- package/abstractions/features/hooks/ApiBeforeDeploy.d.ts +0 -9
- package/abstractions/features/hooks/ApiBeforeDeploy.js +0 -5
- package/abstractions/features/hooks/ApiBeforeDeploy.js.map +0 -1
- package/abstractions/features/hooks/BeforeDeploy.d.ts +0 -9
- package/abstractions/features/hooks/BeforeDeploy.js +0 -5
- package/abstractions/features/hooks/BeforeDeploy.js.map +0 -1
- package/abstractions/features/hooks/CoreAfterDeploy.d.ts +0 -9
- package/abstractions/features/hooks/CoreAfterDeploy.js +0 -5
- package/abstractions/features/hooks/CoreAfterDeploy.js.map +0 -1
- package/abstractions/features/hooks/CoreBeforeDeploy.d.ts +0 -9
- package/abstractions/features/hooks/CoreBeforeDeploy.js +0 -5
- package/abstractions/features/hooks/CoreBeforeDeploy.js.map +0 -1
- package/abstractions/services/GetPulumiService.d.ts +0 -14
- package/abstractions/services/GetPulumiService.js +0 -5
- package/abstractions/services/GetPulumiService.js.map +0 -1
- package/abstractions/services/IsRemotePulumiBackendService.d.ts +0 -7
- package/abstractions/services/IsRemotePulumiBackendService.js +0 -5
- package/abstractions/services/IsRemotePulumiBackendService.js.map +0 -1
- package/abstractions/services/ListAppLambdaFunctionsService.d.ts +0 -23
- package/abstractions/services/ListAppLambdaFunctionsService.js +0 -5
- package/abstractions/services/ListAppLambdaFunctionsService.js.map +0 -1
- package/abstractions/services/ListDeployedEnvironmentsService.d.ts +0 -12
- package/abstractions/services/ListDeployedEnvironmentsService.js +0 -5
- package/abstractions/services/ListDeployedEnvironmentsService.js.map +0 -1
- package/abstractions/services/ProjectInfoService/GetPulumiVersionService.d.ts +0 -12
- package/abstractions/services/ProjectInfoService/GetPulumiVersionService.js +0 -5
- package/abstractions/services/ProjectInfoService/GetPulumiVersionService.js.map +0 -1
- package/abstractions/services/PulumiExportService.d.ts +0 -13
- package/abstractions/services/PulumiExportService.js +0 -6
- package/abstractions/services/PulumiExportService.js.map +0 -1
- package/abstractions/services/PulumiGetConfigPassphraseService.d.ts +0 -7
- package/abstractions/services/PulumiGetConfigPassphraseService.js +0 -5
- package/abstractions/services/PulumiGetConfigPassphraseService.js.map +0 -1
- package/abstractions/services/PulumiGetSecretsProviderService.d.ts +0 -7
- package/abstractions/services/PulumiGetSecretsProviderService.js +0 -5
- package/abstractions/services/PulumiGetSecretsProviderService.js.map +0 -1
- package/abstractions/services/PulumiGetStackOutputService.d.ts +0 -13
- package/abstractions/services/PulumiGetStackOutputService.js +0 -5
- package/abstractions/services/PulumiGetStackOutputService.js.map +0 -1
- package/abstractions/services/PulumiImportService.d.ts +0 -8
- package/abstractions/services/PulumiImportService.js +0 -5
- package/abstractions/services/PulumiImportService.js.map +0 -1
- package/abstractions/services/PulumiLoginService.d.ts +0 -16
- package/abstractions/services/PulumiLoginService.js +0 -5
- package/abstractions/services/PulumiLoginService.js.map +0 -1
- package/abstractions/services/PulumiSelectStackService.d.ts +0 -10
- package/abstractions/services/PulumiSelectStackService.js +0 -5
- package/abstractions/services/PulumiSelectStackService.js.map +0 -1
- package/abstractions/services/StackOutputCacheService.d.ts +0 -10
- package/abstractions/services/StackOutputCacheService.js +0 -5
- package/abstractions/services/StackOutputCacheService.js.map +0 -1
- package/abstractions/services/WatchedLambdaFunctionsService.d.ts +0 -28
- package/abstractions/services/WatchedLambdaFunctionsService.js +0 -5
- package/abstractions/services/WatchedLambdaFunctionsService.js.map +0 -1
- package/decorators/DeployAppClearWatchedLambdaFunctions.d.ts +0 -17
- package/decorators/DeployAppClearWatchedLambdaFunctions.js +0 -32
- package/decorators/DeployAppClearWatchedLambdaFunctions.js.map +0 -1
- package/decorators/DeployAppRefreshStackOutputCache.d.ts +0 -17
- package/decorators/DeployAppRefreshStackOutputCache.js +0 -32
- package/decorators/DeployAppRefreshStackOutputCache.js.map +0 -1
- package/decorators/DeployAppWithHooks.d.ts +0 -17
- package/decorators/DeployAppWithHooks.js +0 -58
- package/decorators/DeployAppWithHooks.js.map +0 -1
- package/decorators/DeployAppWithWatchedLambdaReplacement.d.ts +0 -17
- package/decorators/DeployAppWithWatchedLambdaReplacement.js +0 -39
- package/decorators/DeployAppWithWatchedLambdaReplacement.js.map +0 -1
- package/decorators/DestroyAppClearStackOutputCache.d.ts +0 -25
- package/decorators/DestroyAppClearStackOutputCache.js +0 -29
- package/decorators/DestroyAppClearStackOutputCache.js.map +0 -1
- package/decorators/GetPulumiServiceWithDownloadInfo.d.ts +0 -11
- package/decorators/GetPulumiServiceWithDownloadInfo.js +0 -27
- package/decorators/GetPulumiServiceWithDownloadInfo.js.map +0 -1
- package/extensions/ApiMaxBundleSize.d.ts +0 -4
- package/extensions/ApiMaxBundleSize.js +0 -23
- package/extensions/ApiMaxBundleSize.js.map +0 -1
- package/extensions/hooks/AdminAfterDeploy.d.ts +0 -4
- package/extensions/hooks/AdminAfterDeploy.js +0 -22
- package/extensions/hooks/AdminAfterDeploy.js.map +0 -1
- package/extensions/hooks/AdminBeforeDeploy.d.ts +0 -4
- package/extensions/hooks/AdminBeforeDeploy.js +0 -22
- package/extensions/hooks/AdminBeforeDeploy.js.map +0 -1
- package/extensions/hooks/AfterDeploy.d.ts +0 -4
- package/extensions/hooks/AfterDeploy.js +0 -21
- package/extensions/hooks/AfterDeploy.js.map +0 -1
- package/extensions/hooks/ApiAfterDeploy.d.ts +0 -4
- package/extensions/hooks/ApiAfterDeploy.js +0 -22
- package/extensions/hooks/ApiAfterDeploy.js.map +0 -1
- package/extensions/hooks/ApiBeforeDeploy.d.ts +0 -4
- package/extensions/hooks/ApiBeforeDeploy.js +0 -22
- package/extensions/hooks/ApiBeforeDeploy.js.map +0 -1
- package/extensions/hooks/BeforeDeploy.d.ts +0 -4
- package/extensions/hooks/BeforeDeploy.js +0 -21
- package/extensions/hooks/BeforeDeploy.js.map +0 -1
- package/extensions/hooks/CoreAfterDeploy.d.ts +0 -4
- package/extensions/hooks/CoreAfterDeploy.js +0 -22
- package/extensions/hooks/CoreAfterDeploy.js.map +0 -1
- package/extensions/hooks/CoreBeforeDeploy.d.ts +0 -4
- package/extensions/hooks/CoreBeforeDeploy.js +0 -22
- package/extensions/hooks/CoreBeforeDeploy.js.map +0 -1
- package/extensions/infra/Encryption.d.ts +0 -10
- package/extensions/infra/Encryption.js +0 -36
- package/extensions/infra/Encryption.js.map +0 -1
- package/extensions/infra/Hashing.d.ts +0 -5
- package/extensions/infra/Hashing.js +0 -27
- package/extensions/infra/Hashing.js.map +0 -1
- package/extensions/pulumi/AdminStackOutputValue.d.ts +0 -5
- package/extensions/pulumi/AdminStackOutputValue.js +0 -18
- package/extensions/pulumi/AdminStackOutputValue.js.map +0 -1
- package/extensions/pulumi/ApiStackOutputValue.d.ts +0 -5
- package/extensions/pulumi/ApiStackOutputValue.js +0 -18
- package/extensions/pulumi/ApiStackOutputValue.js.map +0 -1
- package/extensions/pulumi/CoreStackOutputValue.d.ts +0 -5
- package/extensions/pulumi/CoreStackOutputValue.js +0 -18
- package/extensions/pulumi/CoreStackOutputValue.js.map +0 -1
- package/extensions/pulumi/ProductionEnvironments.js.map +0 -1
- package/extensions/pulumi/PulumiResourceNamePrefix.d.ts +0 -4
- package/extensions/pulumi/PulumiResourceNamePrefix.js +0 -15
- package/extensions/pulumi/PulumiResourceNamePrefix.js.map +0 -1
- package/extensions/pulumi/index.d.ts +0 -5
- package/extensions/pulumi/index.js +0 -5
- package/features/DeployApp/DeployApp.d.ts +0 -14
- package/features/DeployApp/DeployApp.js +0 -86
- package/features/DeployApp/DeployApp.js.map +0 -1
- package/features/DeployApp/index.d.ts +0 -1
- package/features/DeployApp/index.js +0 -1
- package/features/DestroyApp/DestroyApp.d.ts +0 -14
- package/features/DestroyApp/DestroyApp.js +0 -66
- package/features/DestroyApp/DestroyApp.js.map +0 -1
- package/features/DestroyApp/index.d.ts +0 -1
- package/features/DestroyApp/index.js +0 -1
- package/features/ExportStack/ExportStack.d.ts +0 -9
- package/features/ExportStack/ExportStack.js +0 -26
- package/features/ExportStack/ExportStack.js.map +0 -1
- package/features/ExportStack/index.d.ts +0 -1
- package/features/ExportStack/index.js +0 -1
- package/features/GetAppOutput/GetAppOutput.d.ts +0 -12
- package/features/GetAppOutput/GetAppOutput.js +0 -51
- package/features/GetAppOutput/GetAppOutput.js.map +0 -1
- package/features/GetAppOutput/index.d.ts +0 -1
- package/features/GetAppOutput/index.js +0 -1
- package/features/GetAppStackOutput/GetAppStackOutput.d.ts +0 -10
- package/features/GetAppStackOutput/GetAppStackOutput.js +0 -26
- package/features/GetAppStackOutput/GetAppStackOutput.js.map +0 -1
- package/features/GetAppStackOutput/index.d.ts +0 -1
- package/features/GetAppStackOutput/index.js +0 -1
- package/features/GetPulumiResourceNamePrefix/GetPulumiResourceNamePrefix.d.ts +0 -7
- package/features/GetPulumiResourceNamePrefix/GetPulumiResourceNamePrefix.js +0 -25
- package/features/GetPulumiResourceNamePrefix/GetPulumiResourceNamePrefix.js.map +0 -1
- package/features/GetPulumiResourceNamePrefix/index.d.ts +0 -1
- package/features/GetPulumiResourceNamePrefix/index.js +0 -1
- package/features/RefreshApp/RefreshApp.d.ts +0 -13
- package/features/RefreshApp/RefreshApp.js +0 -64
- package/features/RefreshApp/RefreshApp.js.map +0 -1
- package/features/RefreshApp/index.d.ts +0 -1
- package/features/RefreshApp/index.js +0 -1
- package/features/RunPulumiCommand/RunPulumiCommand.d.ts +0 -13
- package/features/RunPulumiCommand/RunPulumiCommand.js +0 -61
- package/features/RunPulumiCommand/RunPulumiCommand.js.map +0 -1
- package/features/RunPulumiCommand/index.d.ts +0 -1
- package/features/RunPulumiCommand/index.js +0 -1
- package/features/Watch/handler/handler.zip +0 -0
- package/features/Watch/initInvocationForwarding.d.ts +0 -9
- package/features/Watch/initInvocationForwarding.js +0 -91
- package/features/Watch/initInvocationForwarding.js.map +0 -1
- package/features/Watch/localInvocationWorker.js +0 -31
- package/features/Watch/localInvocationWorker.js.map +0 -1
- package/features/hooks/AdminAfterDeploy/AdminBeforeBuild.d.ts +0 -7
- package/features/hooks/AdminAfterDeploy/AdminBeforeBuild.js +0 -25
- package/features/hooks/AdminAfterDeploy/AdminBeforeBuild.js.map +0 -1
- package/features/hooks/AdminAfterDeploy/index.d.ts +0 -1
- package/features/hooks/AdminAfterDeploy/index.js +0 -1
- package/features/hooks/AdminBeforeDeploy/AdminBeforeDeploy.d.ts +0 -7
- package/features/hooks/AdminBeforeDeploy/AdminBeforeDeploy.js +0 -25
- package/features/hooks/AdminBeforeDeploy/AdminBeforeDeploy.js.map +0 -1
- package/features/hooks/AdminBeforeDeploy/index.d.ts +0 -1
- package/features/hooks/AdminBeforeDeploy/index.js +0 -1
- package/features/hooks/AfterDeploy/AfterDeploy.d.ts +0 -7
- package/features/hooks/AfterDeploy/AfterDeploy.js +0 -25
- package/features/hooks/AfterDeploy/AfterDeploy.js.map +0 -1
- package/features/hooks/AfterDeploy/index.d.ts +0 -1
- package/features/hooks/AfterDeploy/index.js +0 -1
- package/features/hooks/ApiAfterDeploy/ApiBeforeBuild.d.ts +0 -7
- package/features/hooks/ApiAfterDeploy/ApiBeforeBuild.js +0 -25
- package/features/hooks/ApiAfterDeploy/ApiBeforeBuild.js.map +0 -1
- package/features/hooks/ApiAfterDeploy/index.d.ts +0 -1
- package/features/hooks/ApiAfterDeploy/index.js +0 -1
- package/features/hooks/ApiBeforeDeploy/ApiBeforeDeploy.d.ts +0 -7
- package/features/hooks/ApiBeforeDeploy/ApiBeforeDeploy.js +0 -25
- package/features/hooks/ApiBeforeDeploy/ApiBeforeDeploy.js.map +0 -1
- package/features/hooks/ApiBeforeDeploy/index.d.ts +0 -1
- package/features/hooks/ApiBeforeDeploy/index.js +0 -1
- package/features/hooks/BeforeDeploy/BeforeDeploy.d.ts +0 -7
- package/features/hooks/BeforeDeploy/BeforeDeploy.js +0 -25
- package/features/hooks/BeforeDeploy/BeforeDeploy.js.map +0 -1
- package/features/hooks/BeforeDeploy/index.d.ts +0 -1
- package/features/hooks/BeforeDeploy/index.js +0 -1
- package/features/hooks/CoreAfterDeploy/CoreBeforeBuild.d.ts +0 -7
- package/features/hooks/CoreAfterDeploy/CoreBeforeBuild.js +0 -25
- package/features/hooks/CoreAfterDeploy/CoreBeforeBuild.js.map +0 -1
- package/features/hooks/CoreAfterDeploy/index.d.ts +0 -1
- package/features/hooks/CoreAfterDeploy/index.js +0 -1
- package/features/hooks/CoreBeforeDeploy/CoreBeforeDeploy.d.ts +0 -7
- package/features/hooks/CoreBeforeDeploy/CoreBeforeDeploy.js +0 -25
- package/features/hooks/CoreBeforeDeploy/CoreBeforeDeploy.js.map +0 -1
- package/features/hooks/CoreBeforeDeploy/index.d.ts +0 -1
- package/features/hooks/CoreBeforeDeploy/index.js +0 -1
- package/rslib-runtime.js +0 -14
- package/rslib-runtime.js.map +0 -1
- package/services/GetProjectConfigService/renderConfigWorker.d.ts +0 -1
- package/services/GetProjectConfigService/renderConfigWorker.js +0 -64
- package/services/GetProjectConfigService/renderConfigWorker.js.map +0 -1
- package/services/InitProjectSdkService/registerPulumiExtensions.d.ts +0 -4
- package/services/InitProjectSdkService/registerPulumiExtensions.js +0 -16
- package/services/InitProjectSdkService/registerPulumiExtensions.js.map +0 -1
- package/services/IsRemotePulumiBackendService/IsRemotePulumiBackendService.d.ts +0 -14
- package/services/IsRemotePulumiBackendService/IsRemotePulumiBackendService.js +0 -15
- package/services/IsRemotePulumiBackendService/IsRemotePulumiBackendService.js.map +0 -1
- package/services/IsRemotePulumiBackendService/index.d.ts +0 -1
- package/services/IsRemotePulumiBackendService/index.js +0 -1
- package/services/ListAppLambdaFunctionsService/ListAppLambdaFunctionsService.d.ts +0 -18
- package/services/ListAppLambdaFunctionsService/ListAppLambdaFunctionsService.js +0 -61
- package/services/ListAppLambdaFunctionsService/ListAppLambdaFunctionsService.js.map +0 -1
- package/services/ListAppLambdaFunctionsService/index.d.ts +0 -1
- package/services/ListAppLambdaFunctionsService/index.js +0 -1
- package/services/ListDeployedEnvironmentsService/ListDeployedEnvironmentsService.d.ts +0 -7
- package/services/ListDeployedEnvironmentsService/ListDeployedEnvironmentsService.js +0 -30
- package/services/ListDeployedEnvironmentsService/ListDeployedEnvironmentsService.js.map +0 -1
- package/services/ListDeployedEnvironmentsService/index.d.ts +0 -1
- package/services/ListDeployedEnvironmentsService/index.js +0 -1
- package/services/ProjectInfoService/GetPulumiVersionService.d.ts +0 -5
- package/services/ProjectInfoService/GetPulumiVersionService.js +0 -46
- package/services/ProjectInfoService/GetPulumiVersionService.js.map +0 -1
- package/services/PulumiExportService/PulumiExportService.d.ts +0 -13
- package/services/PulumiExportService/PulumiExportService.js +0 -50
- package/services/PulumiExportService/PulumiExportService.js.map +0 -1
- package/services/PulumiExportService/index.d.ts +0 -1
- package/services/PulumiExportService/index.js +0 -1
- package/services/PulumiGetConfigPassphraseService/PulumiGetConfigPassphraseService.d.ts +0 -5
- package/services/PulumiGetConfigPassphraseService/PulumiGetConfigPassphraseService.js +0 -15
- package/services/PulumiGetConfigPassphraseService/PulumiGetConfigPassphraseService.js.map +0 -1
- package/services/PulumiGetConfigPassphraseService/index.d.ts +0 -1
- package/services/PulumiGetConfigPassphraseService/index.js +0 -1
- package/services/PulumiGetSecretsProviderService/PulumiGetSecretsProviderService.d.ts +0 -5
- package/services/PulumiGetSecretsProviderService/PulumiGetSecretsProviderService.js +0 -15
- package/services/PulumiGetSecretsProviderService/PulumiGetSecretsProviderService.js.map +0 -1
- package/services/PulumiGetSecretsProviderService/index.d.ts +0 -1
- package/services/PulumiGetSecretsProviderService/index.js +0 -1
- package/services/PulumiGetStackOutputService/PulumiGetStackOutputService.d.ts +0 -12
- package/services/PulumiGetStackOutputService/PulumiGetStackOutputService.js +0 -64
- package/services/PulumiGetStackOutputService/PulumiGetStackOutputService.js.map +0 -1
- package/services/PulumiGetStackOutputService/index.d.ts +0 -1
- package/services/PulumiGetStackOutputService/index.js +0 -1
- package/services/PulumiGetStackOutputService/mapStackOutput.d.ts +0 -1
- package/services/PulumiGetStackOutputService/mapStackOutput.js +0 -22
- package/services/PulumiGetStackOutputService/mapStackOutput.js.map +0 -1
- package/services/PulumiImportService/PulumiImportService.d.ts +0 -10
- package/services/PulumiImportService/PulumiImportService.js +0 -60
- package/services/PulumiImportService/PulumiImportService.js.map +0 -1
- package/services/PulumiImportService/index.d.ts +0 -1
- package/services/PulumiImportService/index.js +0 -1
- package/services/PulumiLoginService/PulumiLoginService.d.ts +0 -10
- package/services/PulumiLoginService/PulumiLoginService.js +0 -54
- package/services/PulumiLoginService/PulumiLoginService.js.map +0 -1
- package/services/PulumiLoginService/index.d.ts +0 -1
- package/services/PulumiLoginService/index.js +0 -1
- package/services/PulumiSelectStackService/PulumiSelectStackService.d.ts +0 -15
- package/services/PulumiSelectStackService/PulumiSelectStackService.js +0 -102
- package/services/PulumiSelectStackService/PulumiSelectStackService.js.map +0 -1
- package/services/PulumiSelectStackService/index.d.ts +0 -1
- package/services/PulumiSelectStackService/index.js +0 -1
- package/services/StackOutputCacheService/StackOutputCacheService.d.ts +0 -18
- package/services/StackOutputCacheService/StackOutputCacheService.js +0 -89
- package/services/StackOutputCacheService/StackOutputCacheService.js.map +0 -1
- package/services/StackOutputCacheService/index.d.ts +0 -1
- package/services/StackOutputCacheService/index.js +0 -1
- package/services/WatchedLambdaFunctionsService/WatchedLambdaFunctionsService.d.ts +0 -13
- package/services/WatchedLambdaFunctionsService/WatchedLambdaFunctionsService.js +0 -54
- package/services/WatchedLambdaFunctionsService/WatchedLambdaFunctionsService.js.map +0 -1
- package/services/WatchedLambdaFunctionsService/index.d.ts +0 -1
- package/services/WatchedLambdaFunctionsService/index.js +0 -1
- package/utils/env/withPulumiConfigPassphrase.d.ts +0 -1
- package/utils/env/withPulumiConfigPassphrase.js +0 -7
- package/utils/env/withPulumiConfigPassphrase.js.map +0 -1
- /package/extensions/{pulumi/ProductionEnvironments.d.ts → ProductionEnvironments.d.ts} +0 -0
- /package/{features/Watch/localInvocationWorker.d.ts → extensions/api/Mailer/Smtp.test.d.ts} +0 -0
|
@@ -5,7 +5,8 @@ import { z } from "zod";
|
|
|
5
5
|
const BeforeBuild_BeforeBuild = defineExtension({
|
|
6
6
|
type: "Project/BeforeBuild",
|
|
7
7
|
tags: {
|
|
8
|
-
runtimeContext: "project"
|
|
8
|
+
runtimeContext: "project",
|
|
9
|
+
hosting: "all"
|
|
9
10
|
},
|
|
10
11
|
description: "Add custom logic to be executed before the PROJECT build process.",
|
|
11
12
|
multiple: true,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"extensions/hooks/BeforeBuild.js","sources":["../../../src/extensions/hooks/BeforeBuild.ts"],"sourcesContent":["import { defineExtension } from \"~/defineExtension/index.js\";\nimport { zodSrcPath } from \"~/defineExtension/zodTypes/zodSrcPath.js\";\nimport { BeforeBuild as BeforeBuildAbstraction } from \"~/abstractions/index.js\";\nimport { z } from \"zod\";\n\nexport const BeforeBuild = defineExtension({\n type: \"Project/BeforeBuild\",\n tags: { runtimeContext: \"project\" },\n description: \"Add custom logic to be executed before the PROJECT build process.\",\n multiple: true,\n paramsSchema: ({ project }) => {\n return z.object({\n src: zodSrcPath({ project, abstraction: BeforeBuildAbstraction })\n });\n }\n});\n"],"names":["BeforeBuild","defineExtension","project","z","zodSrcPath","BeforeBuildAbstraction"],"mappings":";;;;AAKO,MAAMA,0BAAcC,gBAAgB;IACvC,MAAM;IACN,MAAM;QAAE,gBAAgB;
|
|
1
|
+
{"version":3,"file":"extensions/hooks/BeforeBuild.js","sources":["../../../src/extensions/hooks/BeforeBuild.ts"],"sourcesContent":["import { defineExtension } from \"~/defineExtension/index.js\";\nimport { zodSrcPath } from \"~/defineExtension/zodTypes/zodSrcPath.js\";\nimport { BeforeBuild as BeforeBuildAbstraction } from \"~/abstractions/index.js\";\nimport { z } from \"zod\";\n\nexport const BeforeBuild = defineExtension({\n type: \"Project/BeforeBuild\",\n tags: { runtimeContext: \"project\", hosting: \"all\" },\n description: \"Add custom logic to be executed before the PROJECT build process.\",\n multiple: true,\n paramsSchema: ({ project }) => {\n return z.object({\n src: zodSrcPath({ project, abstraction: BeforeBuildAbstraction })\n });\n }\n});\n"],"names":["BeforeBuild","defineExtension","project","z","zodSrcPath","BeforeBuildAbstraction"],"mappings":";;;;AAKO,MAAMA,0BAAcC,gBAAgB;IACvC,MAAM;IACN,MAAM;QAAE,gBAAgB;QAAW,SAAS;IAAM;IAClD,aAAa;IACb,UAAU;IACV,cAAc,CAAC,EAAEC,OAAO,EAAE,GACfC,EAAE,MAAM,CAAC;YACZ,KAAKC,WAAW;gBAAEF;gBAAS,aAAaG;YAAuB;QACnE;AAER"}
|
|
@@ -5,7 +5,8 @@ import { z } from "zod";
|
|
|
5
5
|
const BeforeWatch_BeforeWatch = defineExtension({
|
|
6
6
|
type: "Project/BeforeWatch",
|
|
7
7
|
tags: {
|
|
8
|
-
runtimeContext: "project"
|
|
8
|
+
runtimeContext: "project",
|
|
9
|
+
hosting: "all"
|
|
9
10
|
},
|
|
10
11
|
description: "Add custom logic to be executed before the project watch process.",
|
|
11
12
|
multiple: true,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"extensions/hooks/BeforeWatch.js","sources":["../../../src/extensions/hooks/BeforeWatch.ts"],"sourcesContent":["import { defineExtension } from \"~/defineExtension/index.js\";\nimport { zodSrcPath } from \"~/defineExtension/zodTypes/zodSrcPath.js\";\nimport { BeforeWatch as BeforeWatchAbstraction } from \"~/abstractions/index.js\";\nimport { z } from \"zod\";\n\nexport const BeforeWatch = defineExtension({\n type: \"Project/BeforeWatch\",\n tags: { runtimeContext: \"project\" },\n description: \"Add custom logic to be executed before the project watch process.\",\n multiple: true,\n paramsSchema: ({ project }) => {\n return z.object({\n src: zodSrcPath({ project, abstraction: BeforeWatchAbstraction })\n });\n }\n});\n"],"names":["BeforeWatch","defineExtension","project","z","zodSrcPath","BeforeWatchAbstraction"],"mappings":";;;;AAKO,MAAMA,0BAAcC,gBAAgB;IACvC,MAAM;IACN,MAAM;QAAE,gBAAgB;
|
|
1
|
+
{"version":3,"file":"extensions/hooks/BeforeWatch.js","sources":["../../../src/extensions/hooks/BeforeWatch.ts"],"sourcesContent":["import { defineExtension } from \"~/defineExtension/index.js\";\nimport { zodSrcPath } from \"~/defineExtension/zodTypes/zodSrcPath.js\";\nimport { BeforeWatch as BeforeWatchAbstraction } from \"~/abstractions/index.js\";\nimport { z } from \"zod\";\n\nexport const BeforeWatch = defineExtension({\n type: \"Project/BeforeWatch\",\n tags: { runtimeContext: \"project\", hosting: \"all\" },\n description: \"Add custom logic to be executed before the project watch process.\",\n multiple: true,\n paramsSchema: ({ project }) => {\n return z.object({\n src: zodSrcPath({ project, abstraction: BeforeWatchAbstraction })\n });\n }\n});\n"],"names":["BeforeWatch","defineExtension","project","z","zodSrcPath","BeforeWatchAbstraction"],"mappings":";;;;AAKO,MAAMA,0BAAcC,gBAAgB;IACvC,MAAM;IACN,MAAM;QAAE,gBAAgB;QAAW,SAAS;IAAM;IAClD,aAAa;IACb,UAAU;IACV,cAAc,CAAC,EAAEC,OAAO,EAAE,GACfC,EAAE,MAAM,CAAC;YACZ,KAAKC,WAAW;gBAAEF;gBAAS,aAAaG;YAAuB;QACnE;AAER"}
|
|
@@ -6,7 +6,8 @@ const CoreAfterBuild_CoreAfterBuild = defineExtension({
|
|
|
6
6
|
type: "Core/AfterBuild",
|
|
7
7
|
tags: {
|
|
8
8
|
runtimeContext: "project",
|
|
9
|
-
application: "core"
|
|
9
|
+
application: "core",
|
|
10
|
+
hosting: "aws"
|
|
10
11
|
},
|
|
11
12
|
description: "Add custom logic to be executed after the CORE build process.",
|
|
12
13
|
multiple: true,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"extensions/hooks/CoreAfterBuild.js","sources":["../../../src/extensions/hooks/CoreAfterBuild.ts"],"sourcesContent":["import { defineExtension } from \"~/defineExtension/index.js\";\nimport { zodSrcPath } from \"~/defineExtension/zodTypes/zodSrcPath.js\";\nimport { CoreAfterBuild as CoreAfterBuildAbstraction } from \"~/abstractions/index.js\";\nimport { z } from \"zod\";\n\nexport const CoreAfterBuild = defineExtension({\n type: \"Core/AfterBuild\",\n tags: { runtimeContext: \"project\", application: \"core\" },\n description: \"Add custom logic to be executed after the CORE build process.\",\n multiple: true,\n paramsSchema: ({ project }) => {\n return z.object({\n src: zodSrcPath({ project, abstraction: CoreAfterBuildAbstraction })\n });\n }\n});\n"],"names":["CoreAfterBuild","defineExtension","project","z","zodSrcPath","CoreAfterBuildAbstraction"],"mappings":";;;;AAKO,MAAMA,gCAAiBC,gBAAgB;IAC1C,MAAM;IACN,MAAM;QAAE,gBAAgB;QAAW,aAAa;
|
|
1
|
+
{"version":3,"file":"extensions/hooks/CoreAfterBuild.js","sources":["../../../src/extensions/hooks/CoreAfterBuild.ts"],"sourcesContent":["import { defineExtension } from \"~/defineExtension/index.js\";\nimport { zodSrcPath } from \"~/defineExtension/zodTypes/zodSrcPath.js\";\nimport { CoreAfterBuild as CoreAfterBuildAbstraction } from \"~/abstractions/index.js\";\nimport { z } from \"zod\";\n\nexport const CoreAfterBuild = defineExtension({\n type: \"Core/AfterBuild\",\n tags: { runtimeContext: \"project\", application: \"core\", hosting: \"aws\" },\n description: \"Add custom logic to be executed after the CORE build process.\",\n multiple: true,\n paramsSchema: ({ project }) => {\n return z.object({\n src: zodSrcPath({ project, abstraction: CoreAfterBuildAbstraction })\n });\n }\n});\n"],"names":["CoreAfterBuild","defineExtension","project","z","zodSrcPath","CoreAfterBuildAbstraction"],"mappings":";;;;AAKO,MAAMA,gCAAiBC,gBAAgB;IAC1C,MAAM;IACN,MAAM;QAAE,gBAAgB;QAAW,aAAa;QAAQ,SAAS;IAAM;IACvE,aAAa;IACb,UAAU;IACV,cAAc,CAAC,EAAEC,OAAO,EAAE,GACfC,EAAE,MAAM,CAAC;YACZ,KAAKC,WAAW;gBAAEF;gBAAS,aAAaG;YAA0B;QACtE;AAER"}
|
|
@@ -6,7 +6,8 @@ const CoreBeforeBuild_CoreBeforeBuild = defineExtension({
|
|
|
6
6
|
type: "Core/BeforeBuild",
|
|
7
7
|
tags: {
|
|
8
8
|
runtimeContext: "project",
|
|
9
|
-
application: "core"
|
|
9
|
+
application: "core",
|
|
10
|
+
hosting: "aws"
|
|
10
11
|
},
|
|
11
12
|
description: "Add custom logic to be executed before the CORE build process.",
|
|
12
13
|
multiple: true,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"extensions/hooks/CoreBeforeBuild.js","sources":["../../../src/extensions/hooks/CoreBeforeBuild.ts"],"sourcesContent":["import { defineExtension } from \"~/defineExtension/index.js\";\nimport { zodSrcPath } from \"~/defineExtension/zodTypes/zodSrcPath.js\";\nimport { CoreBeforeBuild as CoreBeforeBuildAbstraction } from \"~/abstractions/index.js\";\nimport { z } from \"zod\";\n\nexport const CoreBeforeBuild = defineExtension({\n type: \"Core/BeforeBuild\",\n tags: { runtimeContext: \"project\", application: \"core\" },\n description: \"Add custom logic to be executed before the CORE build process.\",\n multiple: true,\n paramsSchema: ({ project }) => {\n return z.object({\n src: zodSrcPath({ project, abstraction: CoreBeforeBuildAbstraction })\n });\n }\n});\n"],"names":["CoreBeforeBuild","defineExtension","project","z","zodSrcPath","CoreBeforeBuildAbstraction"],"mappings":";;;;AAKO,MAAMA,kCAAkBC,gBAAgB;IAC3C,MAAM;IACN,MAAM;QAAE,gBAAgB;QAAW,aAAa;
|
|
1
|
+
{"version":3,"file":"extensions/hooks/CoreBeforeBuild.js","sources":["../../../src/extensions/hooks/CoreBeforeBuild.ts"],"sourcesContent":["import { defineExtension } from \"~/defineExtension/index.js\";\nimport { zodSrcPath } from \"~/defineExtension/zodTypes/zodSrcPath.js\";\nimport { CoreBeforeBuild as CoreBeforeBuildAbstraction } from \"~/abstractions/index.js\";\nimport { z } from \"zod\";\n\nexport const CoreBeforeBuild = defineExtension({\n type: \"Core/BeforeBuild\",\n tags: { runtimeContext: \"project\", application: \"core\", hosting: \"aws\" },\n description: \"Add custom logic to be executed before the CORE build process.\",\n multiple: true,\n paramsSchema: ({ project }) => {\n return z.object({\n src: zodSrcPath({ project, abstraction: CoreBeforeBuildAbstraction })\n });\n }\n});\n"],"names":["CoreBeforeBuild","defineExtension","project","z","zodSrcPath","CoreBeforeBuildAbstraction"],"mappings":";;;;AAKO,MAAMA,kCAAkBC,gBAAgB;IAC3C,MAAM;IACN,MAAM;QAAE,gBAAgB;QAAW,aAAa;QAAQ,SAAS;IAAM;IACvE,aAAa;IACb,UAAU;IACV,cAAc,CAAC,EAAEC,OAAO,EAAE,GACfC,EAAE,MAAM,CAAC;YACZ,KAAKC,WAAW;gBAAEF;gBAAS,aAAaG;YAA2B;QACvE;AAER"}
|
|
@@ -6,7 +6,8 @@ const CoreBeforeWatch_CoreBeforeWatch = defineExtension({
|
|
|
6
6
|
type: "Core/BeforeWatch",
|
|
7
7
|
tags: {
|
|
8
8
|
runtimeContext: "project",
|
|
9
|
-
application: "core"
|
|
9
|
+
application: "core",
|
|
10
|
+
hosting: "aws"
|
|
10
11
|
},
|
|
11
12
|
description: "Add custom logic to be executed before the CORE watch process.",
|
|
12
13
|
multiple: true,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"extensions/hooks/CoreBeforeWatch.js","sources":["../../../src/extensions/hooks/CoreBeforeWatch.ts"],"sourcesContent":["import { defineExtension } from \"~/defineExtension/index.js\";\nimport { zodSrcPath } from \"~/defineExtension/zodTypes/zodSrcPath.js\";\nimport { CoreBeforeWatch as CoreBeforeWatchAbstraction } from \"~/abstractions/index.js\";\nimport { z } from \"zod\";\n\nexport const CoreBeforeWatch = defineExtension({\n type: \"Core/BeforeWatch\",\n tags: { runtimeContext: \"project\", application: \"core\" },\n description: \"Add custom logic to be executed before the CORE watch process.\",\n multiple: true,\n paramsSchema: ({ project }) => {\n return z.object({\n src: zodSrcPath({ project, abstraction: CoreBeforeWatchAbstraction })\n });\n }\n});\n"],"names":["CoreBeforeWatch","defineExtension","project","z","zodSrcPath","CoreBeforeWatchAbstraction"],"mappings":";;;;AAKO,MAAMA,kCAAkBC,gBAAgB;IAC3C,MAAM;IACN,MAAM;QAAE,gBAAgB;QAAW,aAAa;
|
|
1
|
+
{"version":3,"file":"extensions/hooks/CoreBeforeWatch.js","sources":["../../../src/extensions/hooks/CoreBeforeWatch.ts"],"sourcesContent":["import { defineExtension } from \"~/defineExtension/index.js\";\nimport { zodSrcPath } from \"~/defineExtension/zodTypes/zodSrcPath.js\";\nimport { CoreBeforeWatch as CoreBeforeWatchAbstraction } from \"~/abstractions/index.js\";\nimport { z } from \"zod\";\n\nexport const CoreBeforeWatch = defineExtension({\n type: \"Core/BeforeWatch\",\n tags: { runtimeContext: \"project\", application: \"core\", hosting: \"aws\" },\n description: \"Add custom logic to be executed before the CORE watch process.\",\n multiple: true,\n paramsSchema: ({ project }) => {\n return z.object({\n src: zodSrcPath({ project, abstraction: CoreBeforeWatchAbstraction })\n });\n }\n});\n"],"names":["CoreBeforeWatch","defineExtension","project","z","zodSrcPath","CoreBeforeWatchAbstraction"],"mappings":";;;;AAKO,MAAMA,kCAAkBC,gBAAgB;IAC3C,MAAM;IACN,MAAM;QAAE,gBAAgB;QAAW,aAAa;QAAQ,SAAS;IAAM;IACvE,aAAa;IACb,UAAU;IACV,cAAc,CAAC,EAAEC,OAAO,EAAE,GACfC,EAAE,MAAM,CAAC;YACZ,KAAKC,WAAW;gBAAEF;gBAAS,aAAaG;YAA2B;QACvE;AAER"}
|
|
@@ -1,20 +1,12 @@
|
|
|
1
1
|
export * from "./AdminAfterBuild.js";
|
|
2
|
-
export * from "./AdminAfterDeploy.js";
|
|
3
2
|
export * from "./AdminBeforeBuild.js";
|
|
4
|
-
export * from "./AdminBeforeDeploy.js";
|
|
5
3
|
export * from "./AdminBeforeWatch.js";
|
|
6
4
|
export * from "./AfterBuild.js";
|
|
7
|
-
export * from "./AfterDeploy.js";
|
|
8
5
|
export * from "./ApiAfterBuild.js";
|
|
9
|
-
export * from "./ApiAfterDeploy.js";
|
|
10
6
|
export * from "./ApiBeforeBuild.js";
|
|
11
|
-
export * from "./ApiBeforeDeploy.js";
|
|
12
7
|
export * from "./ApiBeforeWatch.js";
|
|
13
8
|
export * from "./BeforeBuild.js";
|
|
14
|
-
export * from "./BeforeDeploy.js";
|
|
15
9
|
export * from "./BeforeWatch.js";
|
|
16
10
|
export * from "./CoreAfterBuild.js";
|
|
17
|
-
export * from "./CoreAfterDeploy.js";
|
|
18
11
|
export * from "./CoreBeforeBuild.js";
|
|
19
|
-
export * from "./CoreBeforeDeploy.js";
|
|
20
12
|
export * from "./CoreBeforeWatch.js";
|
|
@@ -1,20 +1,12 @@
|
|
|
1
1
|
export * from "./AdminAfterBuild.js";
|
|
2
|
-
export * from "./AdminAfterDeploy.js";
|
|
3
2
|
export * from "./AdminBeforeBuild.js";
|
|
4
|
-
export * from "./AdminBeforeDeploy.js";
|
|
5
3
|
export * from "./AdminBeforeWatch.js";
|
|
6
4
|
export * from "./AfterBuild.js";
|
|
7
|
-
export * from "./AfterDeploy.js";
|
|
8
5
|
export * from "./ApiAfterBuild.js";
|
|
9
|
-
export * from "./ApiAfterDeploy.js";
|
|
10
6
|
export * from "./ApiBeforeBuild.js";
|
|
11
|
-
export * from "./ApiBeforeDeploy.js";
|
|
12
7
|
export * from "./ApiBeforeWatch.js";
|
|
13
8
|
export * from "./BeforeBuild.js";
|
|
14
|
-
export * from "./BeforeDeploy.js";
|
|
15
9
|
export * from "./BeforeWatch.js";
|
|
16
10
|
export * from "./CoreAfterBuild.js";
|
|
17
|
-
export * from "./CoreAfterDeploy.js";
|
|
18
11
|
export * from "./CoreBeforeBuild.js";
|
|
19
|
-
export * from "./CoreBeforeDeploy.js";
|
|
20
12
|
export * from "./CoreBeforeWatch.js";
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { ExtensionHosting } from "./hostingType.js";
|
|
2
|
+
/**
|
|
3
|
+
* Throws if the project's hosting type is not the one an extension is for.
|
|
4
|
+
*
|
|
5
|
+
* `webiny/extensions` exposes one set of namespaces for every project, so `Infra.Vpc` can be
|
|
6
|
+
* imported in a standalone project and `Infra.Sqlite` in an AWS one. Rendering either in the
|
|
7
|
+
* wrong project throws, instead of the extension being skipped because the hosting package never
|
|
8
|
+
* registered its definition.
|
|
9
|
+
*
|
|
10
|
+
* The current hosting type comes from `WEBINY_HOSTING_TYPE`, which the `webiny` bin of
|
|
11
|
+
* `@webiny/cli-aws` and `@webiny/cli-standalone` sets. When it isn't set, nothing is checked.
|
|
12
|
+
*/
|
|
13
|
+
export declare const assertHostingType: (name: string, hosting: ExtensionHosting) => void;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
const HOSTING_TYPE_LABELS = {
|
|
2
|
+
aws: "AWS",
|
|
3
|
+
standalone: "standalone"
|
|
4
|
+
};
|
|
5
|
+
const assertHostingType = (name, hosting)=>{
|
|
6
|
+
const current = process.env.WEBINY_HOSTING_TYPE;
|
|
7
|
+
if ("all" === hosting || !current || current === hosting) return;
|
|
8
|
+
throw new Error(`"${name}" is only available in ${HOSTING_TYPE_LABELS[hosting]} projects. This project's hosting type is "${current}".`);
|
|
9
|
+
};
|
|
10
|
+
export { assertHostingType };
|
|
11
|
+
|
|
12
|
+
//# sourceMappingURL=assertHostingType.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"extensions/hosting/assertHostingType.js","sources":["../../../src/extensions/hosting/assertHostingType.ts"],"sourcesContent":["import type { ExtensionHosting } from \"./hostingType.js\";\nimport type { HostingType } from \"./hostingType.js\";\n\nconst HOSTING_TYPE_LABELS: Record<HostingType, string> = {\n aws: \"AWS\",\n standalone: \"standalone\"\n};\n\n/**\n * Throws if the project's hosting type is not the one an extension is for.\n *\n * `webiny/extensions` exposes one set of namespaces for every project, so `Infra.Vpc` can be\n * imported in a standalone project and `Infra.Sqlite` in an AWS one. Rendering either in the\n * wrong project throws, instead of the extension being skipped because the hosting package never\n * registered its definition.\n *\n * The current hosting type comes from `WEBINY_HOSTING_TYPE`, which the `webiny` bin of\n * `@webiny/cli-aws` and `@webiny/cli-standalone` sets. When it isn't set, nothing is checked.\n */\nexport const assertHostingType = (name: string, hosting: ExtensionHosting) => {\n const current = process.env.WEBINY_HOSTING_TYPE;\n if (hosting === \"all\" || !current || current === hosting) {\n return;\n }\n\n throw new Error(\n `\"${name}\" is only available in ${HOSTING_TYPE_LABELS[hosting]} projects. This project's hosting type is \"${current}\".`\n );\n};\n"],"names":["HOSTING_TYPE_LABELS","assertHostingType","name","hosting","current","process","Error"],"mappings":"AAGA,MAAMA,sBAAmD;IACrD,KAAK;IACL,YAAY;AAChB;AAaO,MAAMC,oBAAoB,CAACC,MAAcC;IAC5C,MAAMC,UAAUC,QAAQ,GAAG,CAAC,mBAAmB;IAC/C,IAAIF,AAAY,UAAZA,WAAqB,CAACC,WAAWA,YAAYD,SAC7C;IAGJ,MAAM,IAAIG,MACN,CAAC,CAAC,EAAEJ,KAAK,uBAAuB,EAAEF,mBAAmB,CAACG,QAAQ,CAAC,2CAA2C,EAAEC,QAAQ,EAAE,CAAC;AAE/H"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type React from "react";
|
|
2
|
+
/**
|
|
3
|
+
* Some extensions need code from a hosting package when they render. For example,
|
|
4
|
+
* `Infra.OpenSearch` renders infrastructure hooks that live in `@webiny/project-aws`, which the
|
|
5
|
+
* shared namespaces can't depend on. The hosting package registers its component for the extension
|
|
6
|
+
* type (`registerExtensionImplementation`), and every component created with `defineExtension` for
|
|
7
|
+
* that type renders the registered one in projects of that hosting type
|
|
8
|
+
* (`getExtensionImplementation`).
|
|
9
|
+
*
|
|
10
|
+
* Keyed by hosting type and extension type: a type can have a registered implementation in one
|
|
11
|
+
* hosting type and none in the other, e.g. `Project/OpenSearch` in AWS only.
|
|
12
|
+
*/
|
|
13
|
+
export declare const extensionImplementations: Map<string, React.ComponentType<any>>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"extensions/hosting/extensionImplementations.js","sources":["../../../src/extensions/hosting/extensionImplementations.ts"],"sourcesContent":["import type React from \"react\";\n\n/**\n * Some extensions need code from a hosting package when they render. For example,\n * `Infra.OpenSearch` renders infrastructure hooks that live in `@webiny/project-aws`, which the\n * shared namespaces can't depend on. The hosting package registers its component for the extension\n * type (`registerExtensionImplementation`), and every component created with `defineExtension` for\n * that type renders the registered one in projects of that hosting type\n * (`getExtensionImplementation`).\n *\n * Keyed by hosting type and extension type: a type can have a registered implementation in one\n * hosting type and none in the other, e.g. `Project/OpenSearch` in AWS only.\n */\nexport const extensionImplementations = new Map<string, React.ComponentType<any>>();\n"],"names":["extensionImplementations","Map"],"mappings":"AAaO,MAAMA,2BAA2B,IAAIC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const getExtensionImplementation: (type: string) => import("react").ComponentType<any> | undefined;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { extensionImplementations } from "./extensionImplementations.js";
|
|
2
|
+
const getExtensionImplementation = (type)=>{
|
|
3
|
+
const hostingType = process.env.WEBINY_HOSTING_TYPE;
|
|
4
|
+
if (!hostingType) return;
|
|
5
|
+
return extensionImplementations.get(`${hostingType}:${type}`);
|
|
6
|
+
};
|
|
7
|
+
export { getExtensionImplementation };
|
|
8
|
+
|
|
9
|
+
//# sourceMappingURL=getExtensionImplementation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"extensions/hosting/getExtensionImplementation.js","sources":["../../../src/extensions/hosting/getExtensionImplementation.ts"],"sourcesContent":["import { extensionImplementations } from \"./extensionImplementations.js\";\n\nexport const getExtensionImplementation = (type: string) => {\n const hostingType = process.env.WEBINY_HOSTING_TYPE;\n if (!hostingType) {\n return undefined;\n }\n return extensionImplementations.get(`${hostingType}:${type}`);\n};\n"],"names":["getExtensionImplementation","type","hostingType","process","extensionImplementations"],"mappings":";AAEO,MAAMA,6BAA6B,CAACC;IACvC,MAAMC,cAAcC,QAAQ,GAAG,CAAC,mBAAmB;IACnD,IAAI,CAACD,aACD;IAEJ,OAAOE,yBAAyB,GAAG,CAAC,GAAGF,YAAY,CAAC,EAAED,MAAM;AAChE"}
|
|
File without changes
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type React from "react";
|
|
2
|
+
import type { HostingType } from "./hostingType.js";
|
|
3
|
+
type ExtensionComponent = React.ComponentType<any> & {
|
|
4
|
+
def?: {
|
|
5
|
+
type: string;
|
|
6
|
+
};
|
|
7
|
+
};
|
|
8
|
+
/**
|
|
9
|
+
* Returns a function that removes the registration again.
|
|
10
|
+
*/
|
|
11
|
+
export declare const registerExtensionImplementation: (hostingType: HostingType, spec: ExtensionComponent, implementation: React.ComponentType<any>) => () => void;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { extensionImplementations } from "./extensionImplementations.js";
|
|
2
|
+
const registerExtensionImplementation = (hostingType, spec, implementation)=>{
|
|
3
|
+
const type = spec.def?.type;
|
|
4
|
+
if (!type) throw new Error('Only components created with "defineExtension" can have a registered implementation.');
|
|
5
|
+
const key = `${hostingType}:${type}`;
|
|
6
|
+
extensionImplementations.set(key, implementation);
|
|
7
|
+
return ()=>{
|
|
8
|
+
extensionImplementations["delete"](key);
|
|
9
|
+
};
|
|
10
|
+
};
|
|
11
|
+
export { registerExtensionImplementation };
|
|
12
|
+
|
|
13
|
+
//# sourceMappingURL=registerExtensionImplementation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"extensions/hosting/registerExtensionImplementation.js","sources":["../../../src/extensions/hosting/registerExtensionImplementation.ts"],"sourcesContent":["import type React from \"react\";\nimport type { HostingType } from \"./hostingType.js\";\nimport { extensionImplementations } from \"./extensionImplementations.js\";\n\ntype ExtensionComponent = React.ComponentType<any> & { def?: { type: string } };\n\n/**\n * Returns a function that removes the registration again.\n */\nexport const registerExtensionImplementation = (\n hostingType: HostingType,\n spec: ExtensionComponent,\n implementation: React.ComponentType<any>\n) => {\n const type = spec.def?.type;\n if (!type) {\n throw new Error(\n `Only components created with \"defineExtension\" can have a registered implementation.`\n );\n }\n const key = `${hostingType}:${type}`;\n extensionImplementations.set(key, implementation);\n\n return () => {\n extensionImplementations.delete(key);\n };\n};\n"],"names":["registerExtensionImplementation","hostingType","spec","implementation","type","Error","key","extensionImplementations"],"mappings":";AASO,MAAMA,kCAAkC,CAC3CC,aACAC,MACAC;IAEA,MAAMC,OAAOF,KAAK,GAAG,EAAE;IACvB,IAAI,CAACE,MACD,MAAM,IAAIC,MACN;IAGR,MAAMC,MAAM,GAAGL,YAAY,CAAC,EAAEG,MAAM;IACpCG,yBAAyB,GAAG,CAACD,KAAKH;IAElC,OAAO;QACHI,wBAAwB,CAAxBA,SAA+B,CAACD;IACpC;AACJ"}
|
package/extensions/index.d.ts
CHANGED
|
@@ -6,17 +6,15 @@ import { Telemetry } from "./Telemetry.js";
|
|
|
6
6
|
import { EnvVar } from "./EnvVar.js";
|
|
7
7
|
import { DatabaseSetup } from "./DatabaseSetup.js";
|
|
8
8
|
import { FeatureFlags } from "./FeatureFlags.js";
|
|
9
|
+
import { BugReporter } from "./BugReporter.js";
|
|
9
10
|
import { BuildParam } from "./ApiBuildParam.js";
|
|
10
11
|
import { AdminBuildParam } from "./AdminBuildParam.js";
|
|
11
12
|
import { AdminApiUrl } from "./AdminApiUrl.js";
|
|
12
13
|
import { AdminWebsocketsUrl } from "./AdminWebsocketsUrl.js";
|
|
13
14
|
import { AdminExtension } from "./AdminExtension.js";
|
|
14
15
|
import { ApiExtension } from "./ApiExtension.js";
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import { Hashing } from "./infra/Hashing.js";
|
|
18
|
-
import { AdminAfterBuild, AdminAfterDeploy, AdminBeforeBuild, AdminBeforeDeploy, AdminBeforeWatch, AfterBuild, AfterDeploy, BeforeDeploy, BeforeWatch, ApiAfterBuild, ApiAfterDeploy, ApiBeforeBuild, ApiBeforeDeploy, ApiBeforeWatch, BeforeBuild, CoreAfterBuild, CoreAfterDeploy, CoreBeforeBuild, CoreBeforeDeploy, CoreBeforeWatch } from "./hooks/index.js";
|
|
19
|
-
import { ProductionEnvironments, PulumiResourceNamePrefix, CoreStackOutputValue, ApiStackOutputValue, AdminStackOutputValue } from "./pulumi/index.js";
|
|
16
|
+
import { AdminAfterBuild, AdminBeforeBuild, AdminBeforeWatch, AfterBuild, BeforeWatch, ApiAfterBuild, ApiBeforeBuild, ApiBeforeWatch, BeforeBuild, CoreAfterBuild, CoreBeforeBuild, CoreBeforeWatch } from "./hooks/index.js";
|
|
17
|
+
import { ProductionEnvironments } from "./ProductionEnvironments.js";
|
|
20
18
|
export { Telemetry };
|
|
21
19
|
export { ProjectId };
|
|
22
20
|
export { ProjectDecorator };
|
|
@@ -24,6 +22,7 @@ export { ProjectImplementation };
|
|
|
24
22
|
export { ExtensionDefinitions };
|
|
25
23
|
export { EnvVar };
|
|
26
24
|
export { FeatureFlags };
|
|
25
|
+
export { BugReporter };
|
|
27
26
|
export { DatabaseSetup };
|
|
28
27
|
export { BuildParam };
|
|
29
28
|
export { AdminBuildParam };
|
|
@@ -31,42 +30,20 @@ export { AdminApiUrl };
|
|
|
31
30
|
export { AdminWebsocketsUrl };
|
|
32
31
|
export { AdminExtension };
|
|
33
32
|
export { ApiExtension };
|
|
34
|
-
export { ApiMaxBundleSize };
|
|
35
|
-
export { Encryption };
|
|
36
|
-
export { Hashing };
|
|
37
33
|
export { BeforeBuild };
|
|
38
|
-
export { BeforeDeploy };
|
|
39
34
|
export { BeforeWatch };
|
|
40
35
|
export { AfterBuild };
|
|
41
|
-
export { AfterDeploy };
|
|
42
36
|
export { AdminBeforeBuild };
|
|
43
|
-
export { AdminBeforeDeploy };
|
|
44
37
|
export { AdminBeforeWatch };
|
|
45
38
|
export { AdminAfterBuild };
|
|
46
|
-
export { AdminAfterDeploy };
|
|
47
39
|
export { ApiBeforeBuild };
|
|
48
|
-
export { ApiBeforeDeploy };
|
|
49
40
|
export { ApiBeforeWatch };
|
|
50
41
|
export { ApiAfterBuild };
|
|
51
|
-
export { ApiAfterDeploy };
|
|
52
42
|
export { CoreBeforeBuild };
|
|
53
|
-
export { CoreBeforeDeploy };
|
|
54
43
|
export { CoreBeforeWatch };
|
|
55
44
|
export { CoreAfterBuild };
|
|
56
|
-
export { CoreAfterDeploy };
|
|
57
|
-
export { PulumiResourceNamePrefix };
|
|
58
45
|
export { ProductionEnvironments };
|
|
59
|
-
export { CoreStackOutputValue };
|
|
60
|
-
export { ApiStackOutputValue };
|
|
61
|
-
export { AdminStackOutputValue };
|
|
62
46
|
export declare const definitions: (import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
63
|
-
key: import("zod").ZodString;
|
|
64
|
-
value: import("zod").ZodAny;
|
|
65
|
-
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
66
|
-
environments: import("zod").ZodArray<import("zod").ZodString>;
|
|
67
|
-
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
68
|
-
prefix: import("zod").ZodString;
|
|
69
|
-
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
70
47
|
enabled: import("zod").ZodDefault<import("zod").ZodBoolean>;
|
|
71
48
|
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
72
49
|
paramName: import("zod").ZodString;
|
|
@@ -74,6 +51,7 @@ export declare const definitions: (import("./index.js").ExtensionDefinitionModel
|
|
|
74
51
|
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
75
52
|
features: import("zod").ZodObject<{
|
|
76
53
|
multiTenancy: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
54
|
+
languages: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
77
55
|
advancedPublishingWorkflow: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
78
56
|
advancedAccessControlLayer: import("zod").ZodOptional<import("zod").ZodUnion<readonly [import("zod").ZodBoolean, import("zod").ZodObject<{
|
|
79
57
|
teams: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
@@ -95,6 +73,7 @@ export declare const definitions: (import("./index.js").ExtensionDefinitionModel
|
|
|
95
73
|
imageEnrichment: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
96
74
|
}, import("zod/v4/core").$strip>>;
|
|
97
75
|
lexicalGeneration: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
76
|
+
adminAssistant: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
98
77
|
cms: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
99
78
|
entryGeneration: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
100
79
|
entryComparison: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
@@ -102,8 +81,14 @@ export declare const definitions: (import("./index.js").ExtensionDefinitionModel
|
|
|
102
81
|
}, import("zod/v4/core").$strip>>;
|
|
103
82
|
}, import("zod/v4/core").$strip>]>>;
|
|
104
83
|
abTesting: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
105
|
-
|
|
84
|
+
collaboration: import("zod").ZodOptional<import("zod").ZodUnion<readonly [import("zod").ZodBoolean, import("zod").ZodObject<{
|
|
85
|
+
comments: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
86
|
+
activityLog: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
87
|
+
}, import("zod/v4/core").$strip>]>>;
|
|
88
|
+
webhooks: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
106
89
|
}, import("zod/v4/core").$strip>;
|
|
90
|
+
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
91
|
+
src: import("zod").ZodString;
|
|
107
92
|
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
108
93
|
id: import("zod").ZodString;
|
|
109
94
|
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
@@ -114,9 +99,11 @@ export declare const definitions: (import("./index.js").ExtensionDefinitionModel
|
|
|
114
99
|
varName: import("zod").ZodString;
|
|
115
100
|
value: import("zod").ZodString;
|
|
116
101
|
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
117
|
-
|
|
102
|
+
token: import("zod").ZodOptional<import("zod").ZodString>;
|
|
103
|
+
repository: import("zod").ZodOptional<import("zod").ZodString>;
|
|
104
|
+
labels: import("zod").ZodOptional<import("zod").ZodString>;
|
|
118
105
|
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
119
|
-
|
|
106
|
+
environments: import("zod").ZodArray<import("zod").ZodString>;
|
|
120
107
|
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
121
108
|
setupName: import("zod").ZodEnum<{
|
|
122
109
|
ddb: "ddb";
|
|
@@ -124,16 +111,16 @@ export declare const definitions: (import("./index.js").ExtensionDefinitionModel
|
|
|
124
111
|
"ddb+os": "ddb+os";
|
|
125
112
|
}>;
|
|
126
113
|
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
"aes-128-gcm": "aes-128-gcm";
|
|
131
|
-
"aes-192-gcm": "aes-192-gcm";
|
|
132
|
-
"aes-256-gcm": "aes-256-gcm";
|
|
133
|
-
}>>;
|
|
114
|
+
retentionDays: import("zod").ZodNumber;
|
|
115
|
+
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
116
|
+
enabled: import("zod").ZodBoolean;
|
|
134
117
|
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
135
|
-
|
|
136
|
-
|
|
118
|
+
host: import("zod").ZodString;
|
|
119
|
+
port: import("zod").ZodNumber;
|
|
120
|
+
user: import("zod").ZodString;
|
|
121
|
+
password: import("zod").ZodString;
|
|
122
|
+
from: import("zod").ZodString;
|
|
123
|
+
replyTo: import("zod").ZodOptional<import("zod").ZodString>;
|
|
137
124
|
}, import("zod/v4/core").$strip>>)[];
|
|
138
125
|
export { Project } from "./Project.js";
|
|
139
126
|
export * from "../defineExtension/index.js";
|
package/extensions/index.js
CHANGED
|
@@ -6,17 +6,16 @@ import { Telemetry } from "./Telemetry.js";
|
|
|
6
6
|
import { EnvVar } from "./EnvVar.js";
|
|
7
7
|
import { DatabaseSetup } from "./DatabaseSetup.js";
|
|
8
8
|
import { FeatureFlags } from "./FeatureFlags.js";
|
|
9
|
+
import { BugReporter } from "./BugReporter.js";
|
|
9
10
|
import { BuildParam } from "./ApiBuildParam.js";
|
|
10
11
|
import { AdminBuildParam } from "./AdminBuildParam.js";
|
|
11
12
|
import { AdminApiUrl } from "./AdminApiUrl.js";
|
|
12
13
|
import { AdminWebsocketsUrl } from "./AdminWebsocketsUrl.js";
|
|
13
14
|
import { AdminExtension } from "./AdminExtension.js";
|
|
14
15
|
import { ApiExtension } from "./ApiExtension.js";
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import { AdminAfterBuild, AdminAfterDeploy, AdminBeforeBuild, AdminBeforeDeploy, AdminBeforeWatch, AfterBuild, AfterDeploy, ApiAfterBuild, ApiAfterDeploy, ApiBeforeBuild, ApiBeforeDeploy, ApiBeforeWatch, BeforeBuild, BeforeDeploy, BeforeWatch, CoreAfterBuild, CoreAfterDeploy, CoreBeforeBuild, CoreBeforeDeploy, CoreBeforeWatch } from "./hooks/index.js";
|
|
19
|
-
import { AdminStackOutputValue, ApiStackOutputValue, CoreStackOutputValue, ProductionEnvironments, PulumiResourceNamePrefix } from "./pulumi/index.js";
|
|
16
|
+
import { ApiRoute, BackgroundTasks, ModelFieldCompression, Smtp } from "./api/index.js";
|
|
17
|
+
import { AdminAfterBuild, AdminBeforeBuild, AdminBeforeWatch, AfterBuild, ApiAfterBuild, ApiBeforeBuild, ApiBeforeWatch, BeforeBuild, BeforeWatch, CoreAfterBuild, CoreBeforeBuild, CoreBeforeWatch } from "./hooks/index.js";
|
|
18
|
+
import { ProductionEnvironments } from "./ProductionEnvironments.js";
|
|
20
19
|
export * from "../defineExtension/index.js";
|
|
21
20
|
const definitions = [
|
|
22
21
|
Telemetry.def,
|
|
@@ -26,31 +25,20 @@ const definitions = [
|
|
|
26
25
|
ExtensionDefinitions.def,
|
|
27
26
|
EnvVar.def,
|
|
28
27
|
FeatureFlags.def,
|
|
28
|
+
BugReporter.def,
|
|
29
29
|
AdminAfterBuild.def,
|
|
30
|
-
AdminAfterDeploy.def,
|
|
31
30
|
BeforeBuild.def,
|
|
32
|
-
BeforeDeploy.def,
|
|
33
31
|
BeforeWatch.def,
|
|
34
32
|
AfterBuild.def,
|
|
35
|
-
AfterDeploy.def,
|
|
36
33
|
AdminBeforeBuild.def,
|
|
37
|
-
AdminBeforeDeploy.def,
|
|
38
34
|
AdminBeforeWatch.def,
|
|
39
35
|
ApiAfterBuild.def,
|
|
40
|
-
ApiAfterDeploy.def,
|
|
41
36
|
ApiBeforeBuild.def,
|
|
42
|
-
ApiBeforeDeploy.def,
|
|
43
37
|
ApiBeforeWatch.def,
|
|
44
38
|
CoreAfterBuild.def,
|
|
45
|
-
CoreAfterDeploy.def,
|
|
46
39
|
CoreBeforeBuild.def,
|
|
47
|
-
CoreBeforeDeploy.def,
|
|
48
40
|
CoreBeforeWatch.def,
|
|
49
|
-
PulumiResourceNamePrefix.def,
|
|
50
41
|
ProductionEnvironments.def,
|
|
51
|
-
CoreStackOutputValue.def,
|
|
52
|
-
ApiStackOutputValue.def,
|
|
53
|
-
AdminStackOutputValue.def,
|
|
54
42
|
DatabaseSetup.def,
|
|
55
43
|
BuildParam.def,
|
|
56
44
|
AdminBuildParam.def,
|
|
@@ -58,11 +46,12 @@ const definitions = [
|
|
|
58
46
|
AdminWebsocketsUrl.def,
|
|
59
47
|
AdminExtension.def,
|
|
60
48
|
ApiExtension.def,
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
49
|
+
ApiRoute.def,
|
|
50
|
+
BackgroundTasks.def,
|
|
51
|
+
ModelFieldCompression.def,
|
|
52
|
+
Smtp.def
|
|
64
53
|
];
|
|
65
54
|
export { Project } from "./Project.js";
|
|
66
|
-
export { AdminAfterBuild,
|
|
55
|
+
export { AdminAfterBuild, AdminApiUrl, AdminBeforeBuild, AdminBeforeWatch, AdminBuildParam, AdminExtension, AdminWebsocketsUrl, AfterBuild, ApiAfterBuild, ApiBeforeBuild, ApiBeforeWatch, ApiExtension, BeforeBuild, BeforeWatch, BugReporter, BuildParam, CoreAfterBuild, CoreBeforeBuild, CoreBeforeWatch, DatabaseSetup, EnvVar, ExtensionDefinitions, FeatureFlags, ProductionEnvironments, ProjectDecorator, ProjectId, ProjectImplementation, Telemetry, definitions };
|
|
67
56
|
|
|
68
57
|
//# sourceMappingURL=index.js.map
|
package/extensions/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"extensions/index.js","sources":["../../src/extensions/index.ts"],"sourcesContent":["import { ExtensionDefinitions } from \"./ExtensionDefinitions.js\";\nimport { ProjectDecorator } from \"./ProjectDecorator.js\";\nimport { ProjectImplementation } from \"./ProjectImplementation.js\";\nimport { ProjectId } from \"./ProjectId.js\";\nimport { Telemetry } from \"./Telemetry.js\";\nimport { EnvVar } from \"./EnvVar.js\";\nimport { DatabaseSetup } from \"./DatabaseSetup.js\";\nimport { FeatureFlags } from \"./FeatureFlags.js\";\nimport { BuildParam } from \"./ApiBuildParam.js\";\nimport { AdminBuildParam } from \"./AdminBuildParam.js\";\nimport { AdminApiUrl } from \"./AdminApiUrl.js\";\nimport { AdminWebsocketsUrl } from \"./AdminWebsocketsUrl.js\";\nimport { AdminExtension } from \"./AdminExtension.js\";\nimport { ApiExtension } from \"./ApiExtension.js\";\nimport {
|
|
1
|
+
{"version":3,"file":"extensions/index.js","sources":["../../src/extensions/index.ts"],"sourcesContent":["import { ExtensionDefinitions } from \"./ExtensionDefinitions.js\";\nimport { ProjectDecorator } from \"./ProjectDecorator.js\";\nimport { ProjectImplementation } from \"./ProjectImplementation.js\";\nimport { ProjectId } from \"./ProjectId.js\";\nimport { Telemetry } from \"./Telemetry.js\";\nimport { EnvVar } from \"./EnvVar.js\";\nimport { DatabaseSetup } from \"./DatabaseSetup.js\";\nimport { FeatureFlags } from \"./FeatureFlags.js\";\nimport { BugReporter } from \"./BugReporter.js\";\nimport { BuildParam } from \"./ApiBuildParam.js\";\nimport { AdminBuildParam } from \"./AdminBuildParam.js\";\nimport { AdminApiUrl } from \"./AdminApiUrl.js\";\nimport { AdminWebsocketsUrl } from \"./AdminWebsocketsUrl.js\";\nimport { AdminExtension } from \"./AdminExtension.js\";\nimport { ApiExtension } from \"./ApiExtension.js\";\nimport { ApiRoute } from \"./api/index.js\";\nimport { BackgroundTasks } from \"./api/index.js\";\nimport { ModelFieldCompression } from \"./api/index.js\";\nimport { Smtp } from \"./api/index.js\";\n\n// Hooks.\nimport {\n AdminAfterBuild,\n AdminBeforeBuild,\n AdminBeforeWatch,\n AfterBuild,\n BeforeWatch,\n ApiAfterBuild,\n ApiBeforeBuild,\n ApiBeforeWatch,\n BeforeBuild,\n CoreAfterBuild,\n CoreBeforeBuild,\n CoreBeforeWatch\n} from \"./hooks/index.js\";\n\nimport { ProductionEnvironments } from \"./ProductionEnvironments.js\";\n\n// Exports.\nexport { Telemetry };\nexport { ProjectId };\nexport { ProjectDecorator };\nexport { ProjectImplementation };\nexport { ExtensionDefinitions };\nexport { EnvVar };\nexport { FeatureFlags };\nexport { BugReporter };\nexport { DatabaseSetup };\nexport { BuildParam };\nexport { AdminBuildParam };\nexport { AdminApiUrl };\nexport { AdminWebsocketsUrl };\nexport { AdminExtension };\nexport { ApiExtension };\n\n// Hooks.\nexport { BeforeBuild };\nexport { BeforeWatch };\nexport { AfterBuild };\nexport { AdminBeforeBuild };\nexport { AdminBeforeWatch };\nexport { AdminAfterBuild };\nexport { ApiBeforeBuild };\nexport { ApiBeforeWatch };\nexport { ApiAfterBuild };\nexport { CoreBeforeBuild };\nexport { CoreBeforeWatch };\nexport { CoreAfterBuild };\n\nexport { ProductionEnvironments };\n\n// Definitions (used internally). 👇\nexport const definitions = [\n Telemetry.def,\n ProjectId.def,\n ProjectDecorator.def,\n ProjectImplementation.def,\n ExtensionDefinitions.def,\n EnvVar.def,\n FeatureFlags.def,\n BugReporter.def,\n\n // Hooks.\n AdminAfterBuild.def,\n BeforeBuild.def,\n BeforeWatch.def,\n AfterBuild.def,\n AdminBeforeBuild.def,\n AdminBeforeWatch.def,\n ApiAfterBuild.def,\n ApiBeforeBuild.def,\n ApiBeforeWatch.def,\n CoreAfterBuild.def,\n CoreBeforeBuild.def,\n CoreBeforeWatch.def,\n\n ProductionEnvironments.def,\n DatabaseSetup.def,\n BuildParam.def,\n AdminBuildParam.def,\n AdminApiUrl.def,\n AdminWebsocketsUrl.def,\n AdminExtension.def,\n ApiExtension.def,\n ApiRoute.def,\n\n // Api settings that apply to every hosting type.\n BackgroundTasks.def,\n ModelFieldCompression.def,\n Smtp.def\n];\n\nexport { Project } from \"./Project.js\";\n\nexport * from \"../defineExtension/index.js\";\n"],"names":["definitions","Telemetry","ProjectId","ProjectDecorator","ProjectImplementation","ExtensionDefinitions","EnvVar","FeatureFlags","BugReporter","AdminAfterBuild","BeforeBuild","BeforeWatch","AfterBuild","AdminBeforeBuild","AdminBeforeWatch","ApiAfterBuild","ApiBeforeBuild","ApiBeforeWatch","CoreAfterBuild","CoreBeforeBuild","CoreBeforeWatch","ProductionEnvironments","DatabaseSetup","BuildParam","AdminBuildParam","AdminApiUrl","AdminWebsocketsUrl","AdminExtension","ApiExtension","ApiRoute","BackgroundTasks","ModelFieldCompression","Smtp"],"mappings":";;;;;;;;;;;;;;;;;;;AAwEO,MAAMA,cAAc;IACvBC,UAAU,GAAG;IACbC,UAAU,GAAG;IACbC,iBAAiB,GAAG;IACpBC,sBAAsB,GAAG;IACzBC,qBAAqB,GAAG;IACxBC,OAAO,GAAG;IACVC,aAAa,GAAG;IAChBC,YAAY,GAAG;IAGfC,gBAAgB,GAAG;IACnBC,YAAY,GAAG;IACfC,YAAY,GAAG;IACfC,WAAW,GAAG;IACdC,iBAAiB,GAAG;IACpBC,iBAAiB,GAAG;IACpBC,cAAc,GAAG;IACjBC,eAAe,GAAG;IAClBC,eAAe,GAAG;IAClBC,eAAe,GAAG;IAClBC,gBAAgB,GAAG;IACnBC,gBAAgB,GAAG;IAEnBC,uBAAuB,GAAG;IAC1BC,cAAc,GAAG;IACjBC,WAAW,GAAG;IACdC,gBAAgB,GAAG;IACnBC,YAAY,GAAG;IACfC,mBAAmB,GAAG;IACtBC,eAAe,GAAG;IAClBC,aAAa,GAAG;IAChBC,SAAS,GAAG;IAGZC,gBAAgB,GAAG;IACnBC,sBAAsB,GAAG;IACzBC,KAAK,GAAG;CACX"}
|
package/extensions/infra/Env.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import react from "react";
|
|
2
2
|
import { useEnv, useEnvContext, useRegion, useVariant } from "../../services/GetProjectConfigService/EnvContext.js";
|
|
3
3
|
import { useProductionEnvironments } from "../../services/GetProjectConfigService/ProductionEnvironmentsContext.js";
|
|
4
|
+
import { assertHostingType } from "../hosting/assertHostingType.js";
|
|
4
5
|
const matchesValue = (current, allowed)=>{
|
|
5
6
|
if (!current) return false;
|
|
6
7
|
const allowedArray = Array.isArray(allowed) ? allowed : [
|
|
@@ -9,6 +10,7 @@ const matchesValue = (current, allowed)=>{
|
|
|
9
10
|
return allowedArray.includes(current);
|
|
10
11
|
};
|
|
11
12
|
const EnvIs = ({ env, variant, region, children })=>{
|
|
13
|
+
assertHostingType("Infra.Env.Is", "aws");
|
|
12
14
|
const currentEnv = useEnv();
|
|
13
15
|
const currentVariant = useVariant();
|
|
14
16
|
const currentRegion = useRegion();
|
|
@@ -18,6 +20,7 @@ const EnvIs = ({ env, variant, region, children })=>{
|
|
|
18
20
|
return /*#__PURE__*/ react.createElement(react.Fragment, null, children);
|
|
19
21
|
};
|
|
20
22
|
const EnvIsNot = ({ env, variant, region, children })=>{
|
|
23
|
+
assertHostingType("Infra.Env.IsNot", "aws");
|
|
21
24
|
const currentEnv = useEnv();
|
|
22
25
|
const currentVariant = useVariant();
|
|
23
26
|
const currentRegion = useRegion();
|
|
@@ -27,12 +30,14 @@ const EnvIsNot = ({ env, variant, region, children })=>{
|
|
|
27
30
|
return /*#__PURE__*/ react.createElement(react.Fragment, null, children);
|
|
28
31
|
};
|
|
29
32
|
const EnvIsProd = ({ children })=>{
|
|
33
|
+
assertHostingType("Infra.Env.IsProd", "aws");
|
|
30
34
|
const env = useEnv();
|
|
31
35
|
const prodEnvs = useProductionEnvironments();
|
|
32
36
|
if (!prodEnvs.includes(env)) return null;
|
|
33
37
|
return /*#__PURE__*/ react.createElement(react.Fragment, null, children);
|
|
34
38
|
};
|
|
35
39
|
const EnvIsNotProd = ({ children })=>{
|
|
40
|
+
assertHostingType("Infra.Env.IsNotProd", "aws");
|
|
36
41
|
const env = useEnv();
|
|
37
42
|
const prodEnvs = useProductionEnvironments();
|
|
38
43
|
if (prodEnvs.includes(env)) return null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"extensions/infra/Env.js","sources":["../../../src/extensions/infra/Env.tsx"],"sourcesContent":["import React from \"react\";\nimport {\n useEnv,\n useVariant,\n useRegion,\n useEnvContext\n} from \"~/services/GetProjectConfigService/EnvContext.js\";\nimport { useProductionEnvironments } from \"~/services/GetProjectConfigService/ProductionEnvironmentsContext.js\";\n\nexport interface EnvIsProps {\n env?: string | string[];\n variant?: string | string[];\n region?: string | string[];\n children: React.ReactNode;\n}\n\n/**\n * Helper function to check if a value matches any of the allowed values\n */\nconst matchesValue = (current: string | undefined, allowed: string | string[]): boolean => {\n if (!current) {\n return false;\n }\n const allowedArray = Array.isArray(allowed) ? allowed : [allowed];\n return allowedArray.includes(current);\n};\n\n/**\n * Conditionally renders children based on the current environment, variant, or region.\n * Multiple conditions are AND-ed together.\n */\nexport const EnvIs: React.FC<EnvIsProps> = ({ env, variant, region, children }) => {\n const currentEnv = useEnv();\n const currentVariant = useVariant();\n const currentRegion = useRegion();\n\n // Check if env matches\n if (env !== undefined && !matchesValue(currentEnv, env)) {\n return null;\n }\n\n // Check if variant matches\n if (variant !== undefined && !matchesValue(currentVariant, variant)) {\n return null;\n }\n\n // Check if region matches\n if (region !== undefined && !matchesValue(currentRegion, region)) {\n return null;\n }\n\n return <>{children}</>;\n};\n\n/**\n * Conditionally renders children when the current environment, variant, or region does NOT match.\n * Multiple conditions are AND-ed together (renders when NONE of the conditions match).\n */\nexport const EnvIsNot: React.FC<EnvIsProps> = ({ env, variant, region, children }) => {\n const currentEnv = useEnv();\n const currentVariant = useVariant();\n const currentRegion = useRegion();\n\n // Check if env does NOT match\n if (env !== undefined && matchesValue(currentEnv, env)) {\n return null;\n }\n\n // Check if variant does NOT match\n if (variant !== undefined && matchesValue(currentVariant, variant)) {\n return null;\n }\n\n // Check if region does NOT match\n if (region !== undefined && matchesValue(currentRegion, region)) {\n return null;\n }\n\n return <>{children}</>;\n};\n\nexport const EnvIsProd: React.FC<{ children: React.ReactNode }> = ({ children }) => {\n const env = useEnv();\n const prodEnvs = useProductionEnvironments();\n if (!prodEnvs.includes(env)) {\n return null;\n }\n return <>{children}</>;\n};\n\nexport const EnvIsNotProd: React.FC<{ children: React.ReactNode }> = ({ children }) => {\n const env = useEnv();\n const prodEnvs = useProductionEnvironments();\n if (prodEnvs.includes(env)) {\n return null;\n }\n return <>{children}</>;\n};\n\n// Export hooks for direct use\nexport { useEnv, useVariant, useRegion, useEnvContext };\n"],"names":["matchesValue","current","allowed","allowedArray","Array","EnvIs","env","variant","region","children","currentEnv","useEnv","currentVariant","useVariant","currentRegion","useRegion","undefined","EnvIsNot","EnvIsProd","prodEnvs","useProductionEnvironments","EnvIsNotProd"],"mappings":"
|
|
1
|
+
{"version":3,"file":"extensions/infra/Env.js","sources":["../../../src/extensions/infra/Env.tsx"],"sourcesContent":["import React from \"react\";\nimport {\n useEnv,\n useVariant,\n useRegion,\n useEnvContext\n} from \"~/services/GetProjectConfigService/EnvContext.js\";\nimport { useProductionEnvironments } from \"~/services/GetProjectConfigService/ProductionEnvironmentsContext.js\";\nimport { assertHostingType } from \"~/extensions/hosting/assertHostingType.js\";\n\nexport interface EnvIsProps {\n env?: string | string[];\n variant?: string | string[];\n region?: string | string[];\n children: React.ReactNode;\n}\n\n/**\n * Helper function to check if a value matches any of the allowed values\n */\nconst matchesValue = (current: string | undefined, allowed: string | string[]): boolean => {\n if (!current) {\n return false;\n }\n const allowedArray = Array.isArray(allowed) ? allowed : [allowed];\n return allowedArray.includes(current);\n};\n\n/**\n * Conditionally renders children based on the current environment, variant, or region.\n * Multiple conditions are AND-ed together.\n */\nexport const EnvIs: React.FC<EnvIsProps> = ({ env, variant, region, children }) => {\n // Deploy environments only exist in AWS projects.\n assertHostingType(\"Infra.Env.Is\", \"aws\");\n const currentEnv = useEnv();\n const currentVariant = useVariant();\n const currentRegion = useRegion();\n\n // Check if env matches\n if (env !== undefined && !matchesValue(currentEnv, env)) {\n return null;\n }\n\n // Check if variant matches\n if (variant !== undefined && !matchesValue(currentVariant, variant)) {\n return null;\n }\n\n // Check if region matches\n if (region !== undefined && !matchesValue(currentRegion, region)) {\n return null;\n }\n\n return <>{children}</>;\n};\n\n/**\n * Conditionally renders children when the current environment, variant, or region does NOT match.\n * Multiple conditions are AND-ed together (renders when NONE of the conditions match).\n */\nexport const EnvIsNot: React.FC<EnvIsProps> = ({ env, variant, region, children }) => {\n assertHostingType(\"Infra.Env.IsNot\", \"aws\");\n const currentEnv = useEnv();\n const currentVariant = useVariant();\n const currentRegion = useRegion();\n\n // Check if env does NOT match\n if (env !== undefined && matchesValue(currentEnv, env)) {\n return null;\n }\n\n // Check if variant does NOT match\n if (variant !== undefined && matchesValue(currentVariant, variant)) {\n return null;\n }\n\n // Check if region does NOT match\n if (region !== undefined && matchesValue(currentRegion, region)) {\n return null;\n }\n\n return <>{children}</>;\n};\n\nexport const EnvIsProd: React.FC<{ children: React.ReactNode }> = ({ children }) => {\n assertHostingType(\"Infra.Env.IsProd\", \"aws\");\n const env = useEnv();\n const prodEnvs = useProductionEnvironments();\n if (!prodEnvs.includes(env)) {\n return null;\n }\n return <>{children}</>;\n};\n\nexport const EnvIsNotProd: React.FC<{ children: React.ReactNode }> = ({ children }) => {\n assertHostingType(\"Infra.Env.IsNotProd\", \"aws\");\n const env = useEnv();\n const prodEnvs = useProductionEnvironments();\n if (prodEnvs.includes(env)) {\n return null;\n }\n return <>{children}</>;\n};\n\n// Export hooks for direct use\nexport { useEnv, useVariant, useRegion, useEnvContext };\n"],"names":["matchesValue","current","allowed","allowedArray","Array","EnvIs","env","variant","region","children","assertHostingType","currentEnv","useEnv","currentVariant","useVariant","currentRegion","useRegion","undefined","EnvIsNot","EnvIsProd","prodEnvs","useProductionEnvironments","EnvIsNotProd"],"mappings":";;;;AAoBA,MAAMA,eAAe,CAACC,SAA6BC;IAC/C,IAAI,CAACD,SACD,OAAO;IAEX,MAAME,eAAeC,MAAM,OAAO,CAACF,WAAWA,UAAU;QAACA;KAAQ;IACjE,OAAOC,aAAa,QAAQ,CAACF;AACjC;AAMO,MAAMI,QAA8B,CAAC,EAAEC,GAAG,EAAEC,OAAO,EAAEC,MAAM,EAAEC,QAAQ,EAAE;IAE1EC,kBAAkB,gBAAgB;IAClC,MAAMC,aAAaC;IACnB,MAAMC,iBAAiBC;IACvB,MAAMC,gBAAgBC;IAGtB,IAAIV,AAAQW,WAARX,OAAqB,CAACN,aAAaW,YAAYL,MAC/C,OAAO;IAIX,IAAIC,AAAYU,WAAZV,WAAyB,CAACP,aAAaa,gBAAgBN,UACvD,OAAO;IAIX,IAAIC,AAAWS,WAAXT,UAAwB,CAACR,aAAae,eAAeP,SACrD,OAAO;IAGX,OAAO,WAAP,GAAO,0CAAGC;AACd;AAMO,MAAMS,WAAiC,CAAC,EAAEZ,GAAG,EAAEC,OAAO,EAAEC,MAAM,EAAEC,QAAQ,EAAE;IAC7EC,kBAAkB,mBAAmB;IACrC,MAAMC,aAAaC;IACnB,MAAMC,iBAAiBC;IACvB,MAAMC,gBAAgBC;IAGtB,IAAIV,AAAQW,WAARX,OAAqBN,aAAaW,YAAYL,MAC9C,OAAO;IAIX,IAAIC,AAAYU,WAAZV,WAAyBP,aAAaa,gBAAgBN,UACtD,OAAO;IAIX,IAAIC,AAAWS,WAAXT,UAAwBR,aAAae,eAAeP,SACpD,OAAO;IAGX,OAAO,WAAP,GAAO,0CAAGC;AACd;AAEO,MAAMU,YAAqD,CAAC,EAAEV,QAAQ,EAAE;IAC3EC,kBAAkB,oBAAoB;IACtC,MAAMJ,MAAMM;IACZ,MAAMQ,WAAWC;IACjB,IAAI,CAACD,SAAS,QAAQ,CAACd,MACnB,OAAO;IAEX,OAAO,WAAP,GAAO,0CAAGG;AACd;AAEO,MAAMa,eAAwD,CAAC,EAAEb,QAAQ,EAAE;IAC9EC,kBAAkB,uBAAuB;IACzC,MAAMJ,MAAMM;IACZ,MAAMQ,WAAWC;IACjB,IAAID,SAAS,QAAQ,CAACd,MAClB,OAAO;IAEX,OAAO,WAAP,GAAO,0CAAGG;AACd"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { createImplementation } from "@webiny/di";
|
|
2
2
|
import { GetProductionEnvironments, GetProjectConfigService } from "../../abstractions/index.js";
|
|
3
|
-
import { ProductionEnvironments } from "../../extensions/
|
|
3
|
+
import { ProductionEnvironments } from "../../extensions/ProductionEnvironments.js";
|
|
4
4
|
class DefaultGetProductionEnvironments {
|
|
5
5
|
constructor(getProjectConfigService){
|
|
6
6
|
this.getProjectConfigService = getProjectConfigService;
|