@venizia/ignis 0.2.0-4 → 0.2.0-41
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/dist/base/applications/base.d.ts +19 -13
- package/dist/base/applications/base.d.ts.map +1 -1
- package/dist/base/applications/base.js +85 -65
- package/dist/base/applications/base.js.map +1 -1
- package/dist/base/applications/boot-steps.d.ts +13 -0
- package/dist/base/applications/boot-steps.d.ts.map +1 -0
- package/dist/base/applications/boot-steps.js +23 -0
- package/dist/base/applications/boot-steps.js.map +1 -0
- package/dist/base/applications/common/index.d.ts +2 -0
- package/dist/base/applications/common/index.d.ts.map +1 -0
- package/dist/base/applications/common/index.js +18 -0
- package/dist/base/applications/common/index.js.map +1 -0
- package/dist/base/applications/{types.d.ts → common/types.d.ts} +11 -0
- package/dist/base/applications/common/types.d.ts.map +1 -0
- package/dist/base/applications/common/types.js.map +1 -0
- package/dist/base/applications/index.d.ts +2 -1
- package/dist/base/applications/index.d.ts.map +1 -1
- package/dist/base/applications/index.js +2 -1
- package/dist/base/applications/index.js.map +1 -1
- package/dist/base/applications/server.d.ts +4 -2
- package/dist/base/applications/server.d.ts.map +1 -1
- package/dist/base/applications/server.js +25 -2
- package/dist/base/applications/server.js.map +1 -1
- package/dist/base/controllers/grpc/adapter.d.ts +2 -1
- package/dist/base/controllers/grpc/adapter.d.ts.map +1 -1
- package/dist/base/controllers/grpc/adapter.js +4 -3
- package/dist/base/controllers/grpc/adapter.js.map +1 -1
- package/dist/base/middlewares/app-error/app-error.middleware.d.ts +3 -2
- package/dist/base/middlewares/app-error/app-error.middleware.d.ts.map +1 -1
- package/dist/base/middlewares/app-error/app-error.middleware.js +4 -3
- package/dist/base/middlewares/app-error/app-error.middleware.js.map +1 -1
- package/dist/base/middlewares/request-spy/request-spy.middleware.d.ts.map +1 -1
- package/dist/base/middlewares/request-spy/request-spy.middleware.js +2 -1
- package/dist/base/middlewares/request-spy/request-spy.middleware.js.map +1 -1
- package/dist/common/constants.d.ts.map +1 -1
- package/dist/common/constants.js +2 -1
- package/dist/common/constants.js.map +1 -1
- package/dist/common/environments.d.ts +31 -10
- package/dist/common/environments.d.ts.map +1 -1
- package/dist/common/environments.js +33 -10
- package/dist/common/environments.js.map +1 -1
- package/dist/components/api-reference/component.js +2 -2
- package/dist/components/api-reference/component.js.map +1 -1
- package/dist/components/api-reference/index.d.ts +1 -1
- package/dist/components/api-reference/index.d.ts.map +1 -1
- package/dist/components/api-reference/index.js +1 -1
- package/dist/components/api-reference/index.js.map +1 -1
- package/dist/components/api-reference/ui/factory.d.ts +14 -0
- package/dist/components/api-reference/ui/factory.d.ts.map +1 -0
- package/dist/components/api-reference/{ui-factory.js → ui/factory.js} +12 -25
- package/dist/components/api-reference/ui/factory.js.map +1 -0
- package/dist/components/api-reference/ui/index.d.ts +4 -0
- package/dist/components/api-reference/ui/index.d.ts.map +1 -0
- package/dist/components/api-reference/ui/index.js +20 -0
- package/dist/components/api-reference/ui/index.js.map +1 -0
- package/dist/components/api-reference/ui/scalar.d.ts +8 -0
- package/dist/components/api-reference/ui/scalar.d.ts.map +1 -0
- package/dist/components/api-reference/ui/scalar.js +28 -0
- package/dist/components/api-reference/ui/scalar.js.map +1 -0
- package/dist/components/api-reference/ui/swagger.d.ts +8 -0
- package/dist/components/api-reference/ui/swagger.d.ts.map +1 -0
- package/dist/components/api-reference/ui/swagger.js +28 -0
- package/dist/components/api-reference/ui/swagger.js.map +1 -0
- package/dist/components/auth/authenticate/controllers/factory.d.ts +33 -2
- package/dist/components/auth/authenticate/controllers/factory.d.ts.map +1 -1
- package/dist/components/auth/authenticate/services/service/verifier.service.d.ts.map +1 -1
- package/dist/components/auth/authenticate/services/service/verifier.service.js +10 -6
- package/dist/components/auth/authenticate/services/service/verifier.service.js.map +1 -1
- package/dist/components/auth/authenticate/strategies/index.d.ts +1 -1
- package/dist/components/auth/authenticate/strategies/index.d.ts.map +1 -1
- package/dist/components/auth/authenticate/strategies/index.js +1 -1
- package/dist/components/auth/authenticate/strategies/index.js.map +1 -1
- package/dist/components/auth/authenticate/strategies/jwks/index.d.ts +3 -0
- package/dist/components/auth/authenticate/strategies/jwks/index.d.ts.map +1 -0
- package/dist/components/auth/authenticate/strategies/jwks/index.js +19 -0
- package/dist/components/auth/authenticate/strategies/jwks/index.js.map +1 -0
- package/dist/components/auth/authenticate/strategies/jwks/issuer.d.ts +13 -0
- package/dist/components/auth/authenticate/strategies/jwks/issuer.d.ts.map +1 -0
- package/dist/components/auth/authenticate/strategies/{jwks.strategy.js → jwks/issuer.js} +4 -27
- package/dist/components/auth/authenticate/strategies/jwks/issuer.js.map +1 -0
- package/dist/components/auth/authenticate/strategies/{jwks.strategy.d.ts → jwks/verifier.d.ts} +2 -10
- package/dist/components/auth/authenticate/strategies/jwks/verifier.d.ts.map +1 -0
- package/dist/components/auth/authenticate/strategies/jwks/verifier.js +45 -0
- package/dist/components/auth/authenticate/strategies/jwks/verifier.js.map +1 -0
- package/dist/components/auth/authorize/adapters/base-filtered.d.ts +1 -1
- package/dist/components/auth/authorize/adapters/base-filtered.d.ts.map +1 -1
- package/dist/components/auth/authorize/adapters/base-filtered.js +5 -8
- package/dist/components/auth/authorize/adapters/base-filtered.js.map +1 -1
- package/dist/components/auth/authorize/adapters/common/index.d.ts +2 -0
- package/dist/components/auth/authorize/adapters/common/index.d.ts.map +1 -0
- package/dist/components/auth/authorize/adapters/common/index.js +18 -0
- package/dist/components/auth/authorize/adapters/common/index.js.map +1 -0
- package/dist/components/auth/authorize/adapters/{types.d.ts → common/types.d.ts} +1 -1
- package/dist/components/auth/authorize/adapters/common/types.d.ts.map +1 -0
- package/dist/components/auth/authorize/adapters/common/types.js.map +1 -0
- package/dist/components/auth/authorize/adapters/connector.d.ts +10 -0
- package/dist/components/auth/authorize/adapters/connector.d.ts.map +1 -0
- package/dist/components/auth/authorize/adapters/connector.js +20 -0
- package/dist/components/auth/authorize/adapters/connector.js.map +1 -0
- package/dist/components/auth/authorize/adapters/custom-grant-expander.d.ts +52 -0
- package/dist/components/auth/authorize/adapters/custom-grant-expander.d.ts.map +1 -0
- package/dist/components/auth/authorize/adapters/custom-grant-expander.js +111 -0
- package/dist/components/auth/authorize/adapters/custom-grant-expander.js.map +1 -0
- package/dist/components/auth/authorize/adapters/index.d.ts +4 -2
- package/dist/components/auth/authorize/adapters/index.d.ts.map +1 -1
- package/dist/components/auth/authorize/adapters/index.js +4 -2
- package/dist/components/auth/authorize/adapters/index.js.map +1 -1
- package/dist/components/auth/authorize/adapters/scoped-casbin/adapter.d.ts +93 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/adapter.d.ts.map +1 -0
- package/dist/components/auth/authorize/adapters/{scoped-casbin.adapter.js → scoped-casbin/adapter.js} +95 -97
- package/dist/components/auth/authorize/adapters/scoped-casbin/adapter.js.map +1 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/common/constants.d.ts +2 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/common/constants.d.ts.map +1 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/common/constants.js +5 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/common/constants.js.map +1 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/common/index.d.ts +3 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/common/index.d.ts.map +1 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/common/index.js +19 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/common/index.js.map +1 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/common/types.d.ts +50 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/common/types.d.ts.map +1 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/common/types.js +3 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/common/types.js.map +1 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/index.d.ts +4 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/index.d.ts.map +1 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/index.js +19 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/index.js.map +1 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/policy-edges.d.ts +17 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/policy-edges.d.ts.map +1 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/policy-edges.js +11 -0
- package/dist/components/auth/authorize/adapters/scoped-casbin/policy-edges.js.map +1 -0
- package/dist/components/auth/authorize/component.d.ts.map +1 -1
- package/dist/components/auth/authorize/component.js +3 -0
- package/dist/components/auth/authorize/component.js.map +1 -1
- package/dist/components/auth/authorize/enforcers/casbin.enforcer.d.ts +7 -36
- package/dist/components/auth/authorize/enforcers/casbin.enforcer.d.ts.map +1 -1
- package/dist/components/auth/authorize/enforcers/casbin.enforcer.js +48 -117
- package/dist/components/auth/authorize/enforcers/casbin.enforcer.js.map +1 -1
- package/dist/components/auth/authorize/enforcers/index.d.ts +2 -1
- package/dist/components/auth/authorize/enforcers/index.d.ts.map +1 -1
- package/dist/components/auth/authorize/enforcers/index.js +2 -1
- package/dist/components/auth/authorize/enforcers/index.js.map +1 -1
- package/dist/components/auth/authorize/enforcers/policy-line-codec.d.ts +26 -0
- package/dist/components/auth/authorize/enforcers/policy-line-codec.d.ts.map +1 -0
- package/dist/components/auth/authorize/enforcers/policy-line-codec.js +57 -0
- package/dist/components/auth/authorize/enforcers/policy-line-codec.js.map +1 -0
- package/dist/components/auth/authorize/enforcers/user-policy-line-cache.d.ts +46 -0
- package/dist/components/auth/authorize/enforcers/user-policy-line-cache.d.ts.map +1 -0
- package/dist/components/auth/authorize/enforcers/user-policy-line-cache.js +98 -0
- package/dist/components/auth/authorize/enforcers/user-policy-line-cache.js.map +1 -0
- package/dist/components/auth/authorize/index.d.ts +1 -0
- package/dist/components/auth/authorize/index.d.ts.map +1 -1
- package/dist/components/auth/authorize/index.js +1 -0
- package/dist/components/auth/authorize/index.js.map +1 -1
- package/dist/components/auth/authorize/role-managers/base.d.ts +34 -0
- package/dist/components/auth/authorize/role-managers/base.d.ts.map +1 -0
- package/dist/components/auth/authorize/role-managers/base.js +76 -0
- package/dist/components/auth/authorize/role-managers/base.js.map +1 -0
- package/dist/components/auth/authorize/role-managers/domain-hierarchy.d.ts +28 -0
- package/dist/components/auth/authorize/role-managers/domain-hierarchy.d.ts.map +1 -0
- package/dist/components/auth/authorize/role-managers/domain-hierarchy.js +77 -0
- package/dist/components/auth/authorize/role-managers/domain-hierarchy.js.map +1 -0
- package/dist/components/auth/authorize/role-managers/index.d.ts +5 -0
- package/dist/components/auth/authorize/role-managers/index.d.ts.map +1 -0
- package/dist/components/auth/authorize/role-managers/index.js +21 -0
- package/dist/components/auth/authorize/role-managers/index.js.map +1 -0
- package/dist/components/auth/authorize/role-managers/membership.d.ts +21 -0
- package/dist/components/auth/authorize/role-managers/membership.d.ts.map +1 -0
- package/dist/components/auth/authorize/role-managers/membership.js +69 -0
- package/dist/components/auth/authorize/role-managers/membership.js.map +1 -0
- package/dist/components/auth/authorize/{enforcers/resource-role-manager.d.ts → role-managers/resource.d.ts} +3 -9
- package/dist/components/auth/authorize/role-managers/resource.d.ts.map +1 -0
- package/dist/components/auth/authorize/{enforcers/resource-role-manager.js → role-managers/resource.js} +9 -21
- package/dist/components/auth/authorize/role-managers/resource.js.map +1 -0
- package/dist/components/auth/models/entities/policy-definition.model.d.ts +49 -14
- package/dist/components/auth/models/entities/policy-definition.model.d.ts.map +1 -1
- package/dist/components/auth/models/entities/policy-definition.model.js +45 -11
- package/dist/components/auth/models/entities/policy-definition.model.js.map +1 -1
- package/dist/components/auth/models/entities/user.model.d.ts +2 -2
- package/dist/components/health-check/common/constants.d.ts +5 -0
- package/dist/components/health-check/common/constants.d.ts.map +1 -0
- package/dist/components/health-check/common/constants.js +9 -0
- package/dist/components/health-check/common/constants.js.map +1 -0
- package/dist/components/health-check/common/index.d.ts +1 -0
- package/dist/components/health-check/common/index.d.ts.map +1 -1
- package/dist/components/health-check/common/index.js +1 -0
- package/dist/components/health-check/common/index.js.map +1 -1
- package/dist/components/health-check/common/keys.d.ts +2 -0
- package/dist/components/health-check/common/keys.d.ts.map +1 -1
- package/dist/components/health-check/common/keys.js +2 -0
- package/dist/components/health-check/common/keys.js.map +1 -1
- package/dist/components/health-check/common/rest-paths.d.ts +1 -0
- package/dist/components/health-check/common/rest-paths.d.ts.map +1 -1
- package/dist/components/health-check/common/rest-paths.js +1 -0
- package/dist/components/health-check/common/rest-paths.js.map +1 -1
- package/dist/components/health-check/common/types.d.ts +22 -0
- package/dist/components/health-check/common/types.d.ts.map +1 -1
- package/dist/components/health-check/component.d.ts +9 -3
- package/dist/components/health-check/component.d.ts.map +1 -1
- package/dist/components/health-check/component.js +38 -1
- package/dist/components/health-check/component.js.map +1 -1
- package/dist/components/health-check/controller.d.ts +10 -2
- package/dist/components/health-check/controller.d.ts.map +1 -1
- package/dist/components/health-check/controller.js +79 -13
- package/dist/components/health-check/controller.js.map +1 -1
- package/dist/components/health-check/index.d.ts +1 -0
- package/dist/components/health-check/index.d.ts.map +1 -1
- package/dist/components/health-check/index.js +1 -0
- package/dist/components/health-check/index.js.map +1 -1
- package/dist/components/health-check/reporter.d.ts +98 -0
- package/dist/components/health-check/reporter.d.ts.map +1 -0
- package/dist/components/health-check/reporter.js +138 -0
- package/dist/components/health-check/reporter.js.map +1 -0
- package/dist/components/mail/common/constants.d.ts +8 -0
- package/dist/components/mail/common/constants.d.ts.map +1 -1
- package/dist/components/mail/common/constants.js +9 -1
- package/dist/components/mail/common/constants.js.map +1 -1
- package/dist/components/mail/common/types/index.d.ts +6 -0
- package/dist/components/mail/common/types/index.d.ts.map +1 -0
- package/dist/components/mail/common/types/index.js +22 -0
- package/dist/components/mail/common/types/index.js.map +1 -0
- package/dist/components/mail/common/types/message.d.ts +49 -0
- package/dist/components/mail/common/types/message.d.ts.map +1 -0
- package/dist/components/mail/common/types/message.js +3 -0
- package/dist/components/mail/common/types/message.js.map +1 -0
- package/dist/components/mail/common/types/options.d.ts +65 -0
- package/dist/components/mail/common/types/options.d.ts.map +1 -0
- package/dist/components/mail/common/types/options.js +3 -0
- package/dist/components/mail/common/types/options.js.map +1 -0
- package/dist/components/mail/common/types/queue.d.ts +53 -0
- package/dist/components/mail/common/types/queue.d.ts.map +1 -0
- package/dist/components/mail/common/types/queue.js +3 -0
- package/dist/components/mail/common/types/queue.js.map +1 -0
- package/dist/components/mail/common/types/template.d.ts +33 -0
- package/dist/components/mail/common/types/template.d.ts.map +1 -0
- package/dist/components/mail/common/types/template.js +3 -0
- package/dist/components/mail/common/types/template.js.map +1 -0
- package/dist/components/mail/common/types/verification.d.ts +26 -0
- package/dist/components/mail/common/types/verification.d.ts.map +1 -0
- package/dist/components/mail/common/types/verification.js +3 -0
- package/dist/components/mail/common/types/verification.js.map +1 -0
- package/dist/components/mail/component.d.ts +4 -1
- package/dist/components/mail/component.d.ts.map +1 -1
- package/dist/components/mail/component.js +12 -0
- package/dist/components/mail/component.js.map +1 -1
- package/dist/components/mail/helpers/transporters/amazon-ses-transporter.helper.d.ts +19 -0
- package/dist/components/mail/helpers/transporters/amazon-ses-transporter.helper.d.ts.map +1 -0
- package/dist/components/mail/helpers/transporters/amazon-ses-transporter.helper.js +111 -0
- package/dist/components/mail/helpers/transporters/amazon-ses-transporter.helper.js.map +1 -0
- package/dist/components/mail/helpers/transporters/index.d.ts +2 -1
- package/dist/components/mail/helpers/transporters/index.d.ts.map +1 -1
- package/dist/components/mail/helpers/transporters/index.js +2 -1
- package/dist/components/mail/helpers/transporters/index.js.map +1 -1
- package/dist/components/mail/providers/mail-transporter.provider.d.ts +2 -0
- package/dist/components/mail/providers/mail-transporter.provider.d.ts.map +1 -1
- package/dist/components/mail/providers/mail-transporter.provider.js +17 -0
- package/dist/components/mail/providers/mail-transporter.provider.js.map +1 -1
- package/dist/components/mail/services/generators/index.d.ts +4 -0
- package/dist/components/mail/services/generators/index.d.ts.map +1 -0
- package/dist/components/mail/services/generators/index.js +20 -0
- package/dist/components/mail/services/generators/index.js.map +1 -0
- package/dist/components/mail/services/generators/numeric-code.d.ts +7 -0
- package/dist/components/mail/services/generators/numeric-code.d.ts.map +1 -0
- package/dist/components/mail/services/generators/numeric-code.js +20 -0
- package/dist/components/mail/services/generators/numeric-code.js.map +1 -0
- package/dist/components/mail/services/generators/random-token.d.ts +7 -0
- package/dist/components/mail/services/generators/random-token.d.ts.map +1 -0
- package/dist/components/mail/services/generators/random-token.js +18 -0
- package/dist/components/mail/services/generators/random-token.js.map +1 -0
- package/dist/components/mail/services/generators/verification-data.d.ts +9 -0
- package/dist/components/mail/services/generators/verification-data.d.ts.map +1 -0
- package/dist/components/mail/services/{generator.service.js → generators/verification-data.js} +10 -25
- package/dist/components/mail/services/generators/verification-data.js.map +1 -0
- package/dist/components/mail/services/index.d.ts +1 -1
- package/dist/components/mail/services/index.d.ts.map +1 -1
- package/dist/components/mail/services/index.js +1 -1
- package/dist/components/mail/services/index.js.map +1 -1
- package/dist/components/mail/utilities/address.utility.d.ts +9 -0
- package/dist/components/mail/utilities/address.utility.d.ts.map +1 -0
- package/dist/components/mail/utilities/address.utility.js +36 -0
- package/dist/components/mail/utilities/address.utility.js.map +1 -0
- package/dist/components/mail/utilities/index.d.ts +2 -0
- package/dist/components/mail/utilities/index.d.ts.map +1 -1
- package/dist/components/mail/utilities/index.js +2 -0
- package/dist/components/mail/utilities/index.js.map +1 -1
- package/dist/components/mail/utilities/mime.utility.d.ts +19 -0
- package/dist/components/mail/utilities/mime.utility.d.ts.map +1 -0
- package/dist/components/mail/utilities/mime.utility.js +412 -0
- package/dist/components/mail/utilities/mime.utility.js.map +1 -0
- package/dist/components/static-asset/common/commit-token.d.ts +23 -0
- package/dist/components/static-asset/common/commit-token.d.ts.map +1 -0
- package/dist/components/static-asset/common/commit-token.js +40 -0
- package/dist/components/static-asset/common/commit-token.js.map +1 -0
- package/dist/components/static-asset/common/constants.d.ts +13 -1
- package/dist/components/static-asset/common/constants.d.ts.map +1 -1
- package/dist/components/static-asset/common/constants.js +29 -2
- package/dist/components/static-asset/common/constants.js.map +1 -1
- package/dist/components/static-asset/common/errors.d.ts +34 -0
- package/dist/components/static-asset/common/errors.d.ts.map +1 -1
- package/dist/components/static-asset/common/errors.js +28 -0
- package/dist/components/static-asset/common/errors.js.map +1 -1
- package/dist/components/static-asset/common/index.d.ts +1 -0
- package/dist/components/static-asset/common/index.d.ts.map +1 -1
- package/dist/components/static-asset/common/index.js +1 -0
- package/dist/components/static-asset/common/index.js.map +1 -1
- package/dist/components/static-asset/common/keys.d.ts +1 -0
- package/dist/components/static-asset/common/keys.d.ts.map +1 -1
- package/dist/components/static-asset/common/keys.js +1 -0
- package/dist/components/static-asset/common/keys.js.map +1 -1
- package/dist/components/static-asset/common/types.d.ts +87 -30
- package/dist/components/static-asset/common/types.d.ts.map +1 -1
- package/dist/components/static-asset/component.d.ts +4 -1
- package/dist/components/static-asset/component.d.ts.map +1 -1
- package/dist/components/static-asset/component.js +19 -9
- package/dist/components/static-asset/component.js.map +1 -1
- package/dist/components/static-asset/controller/base.definition.d.ts +27 -554
- package/dist/components/static-asset/controller/base.definition.d.ts.map +1 -1
- package/dist/components/static-asset/controller/base.definition.js +250 -285
- package/dist/components/static-asset/controller/base.definition.js.map +1 -1
- package/dist/components/static-asset/controller/factory.d.ts +68 -6
- package/dist/components/static-asset/controller/factory.d.ts.map +1 -1
- package/dist/components/static-asset/controller/factory.js +561 -138
- package/dist/components/static-asset/controller/factory.js.map +1 -1
- package/dist/components/static-asset/index.d.ts +1 -0
- package/dist/components/static-asset/index.d.ts.map +1 -1
- package/dist/components/static-asset/index.js +1 -0
- package/dist/components/static-asset/index.js.map +1 -1
- package/dist/components/static-asset/ingest.d.ts +58 -0
- package/dist/components/static-asset/ingest.d.ts.map +1 -0
- package/dist/components/static-asset/ingest.js +82 -0
- package/dist/components/static-asset/ingest.js.map +1 -0
- package/dist/components/static-asset/models/base.model.d.ts +44 -6
- package/dist/components/static-asset/models/base.model.d.ts.map +1 -1
- package/dist/components/static-asset/models/base.model.js +7 -1
- package/dist/components/static-asset/models/base.model.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/package.json +27 -23
- package/dist/base/applications/types.d.ts.map +0 -1
- package/dist/base/applications/types.js.map +0 -1
- package/dist/components/api-reference/ui-factory.d.ts +0 -21
- package/dist/components/api-reference/ui-factory.d.ts.map +0 -1
- package/dist/components/api-reference/ui-factory.js.map +0 -1
- package/dist/components/auth/authenticate/strategies/jwks.strategy.d.ts.map +0 -1
- package/dist/components/auth/authenticate/strategies/jwks.strategy.js.map +0 -1
- package/dist/components/auth/authorize/adapters/scoped-casbin.adapter.d.ts +0 -121
- package/dist/components/auth/authorize/adapters/scoped-casbin.adapter.d.ts.map +0 -1
- package/dist/components/auth/authorize/adapters/scoped-casbin.adapter.js.map +0 -1
- package/dist/components/auth/authorize/adapters/types.d.ts.map +0 -1
- package/dist/components/auth/authorize/adapters/types.js.map +0 -1
- package/dist/components/auth/authorize/enforcers/resource-role-manager.d.ts.map +0 -1
- package/dist/components/auth/authorize/enforcers/resource-role-manager.js.map +0 -1
- package/dist/components/mail/common/types.d.ts +0 -201
- package/dist/components/mail/common/types.d.ts.map +0 -1
- package/dist/components/mail/common/types.js +0 -10
- package/dist/components/mail/common/types.js.map +0 -1
- package/dist/components/mail/services/generator.service.d.ts +0 -14
- package/dist/components/mail/services/generator.service.d.ts.map +0 -1
- package/dist/components/mail/services/generator.service.js.map +0 -1
- /package/dist/base/applications/{types.js → common/types.js} +0 -0
- /package/dist/components/auth/authorize/adapters/{types.js → common/types.js} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"server.js","sourceRoot":"","sources":["../../../src/base/applications/server.ts"],"names":[],"mappings":";;;;;;AAAA,wDAAsE;AACtE,sDAAuD;AACvD,0DAA+D;AAE/D,0DAA6B;
|
|
1
|
+
{"version":3,"file":"server.js","sourceRoot":"","sources":["../../../src/base/applications/server.ts"],"names":[],"mappings":";;;;;;AAAA,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AAC;gBACzB,yJAAyJ;gBACzJ,MAAM,IAAI,OAAO,CAAO,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE;oBAC1C,QAAQ,CAAC,KAAK,CAAC,CAAC,KAAa,EAAE,EAAE;wBAC/B,IAAI,KAAK,EAAE,CAAC;4BACV,MAAM,CAAC,KAAK,CAAC,CAAC;4BACd,OAAO;wBACT,CAAC;wBAED,OAAO,EAAE,CAAC;oBACZ,CAAC,CAAC,CAAC;gBACL,CAAC,CAAC,CAAC;gBACH,MAAM;YACR,CAAC;YACD,OAAO,CAAC,CAAC,CAAC;gBACR,MAAM,IAAA,eAAQ,EAAC;oBACb,OAAO,EAAE,uDAAuD;iBACjE,CAAC,CAAC;YACL,CAAC;QACH,CAAC;QAED,IAAI,CAAC,cAAc,GAAG,SAAS,CAAC;QAChC,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC;IACzD,CAAC;CACF;AAjPD,8CAiPC"}
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import type { ConnectRouter } from '@connectrpc/connect';
|
|
2
|
+
import { BaseHelper } from '@venizia/ignis-helpers/core';
|
|
2
3
|
import type { Env, Schema } from 'hono';
|
|
3
4
|
import type { AbstractGrpcController } from './abstract';
|
|
4
5
|
import type { IConnectAdapterResult, IConnectRpcModule } from './common/types';
|
|
5
6
|
/** Bridges IGNIS gRPC controllers with ConnectRPC: loads the peer deps via createRequire, wraps handlers into ConnectRPC's signature, dispatches through a Hono middleware, and isolates request-scoped context with AsyncLocalStorage. */
|
|
6
|
-
export declare class GrpcRequestAdapter<RouteEnv extends Env = Env, RouteSchema extends Schema = {}, BasePath extends string = '/', ServiceType = Parameters<ConnectRouter['service']>[0], ConfigurableOptions extends object = {}> {
|
|
7
|
+
export declare class GrpcRequestAdapter<RouteEnv extends Env = Env, RouteSchema extends Schema = {}, BasePath extends string = '/', ServiceType = Parameters<ConnectRouter['service']>[0], ConfigurableOptions extends object = {}> extends BaseHelper {
|
|
7
8
|
private createConnectRouter;
|
|
8
9
|
private protocol;
|
|
9
10
|
private controller;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"adapter.d.ts","sourceRoot":"","sources":["../../../../src/base/controllers/grpc/adapter.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAkB,MAAM,qBAAqB,CAAC;
|
|
1
|
+
{"version":3,"file":"adapter.d.ts","sourceRoot":"","sources":["../../../../src/base/controllers/grpc/adapter.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAkB,MAAM,qBAAqB,CAAC;AAOzE,OAAO,EAAE,UAAU,EAAY,MAAM,6BAA6B,CAAC;AAGnE,OAAO,KAAK,EAAE,GAAG,EAA4B,MAAM,EAAE,MAAM,MAAM,CAAC;AAKlE,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,YAAY,CAAC;AACzD,OAAO,KAAK,EAAE,qBAAqB,EAAE,iBAAiB,EAAoB,MAAM,gBAAgB,CAAC;AASjG,2OAA2O;AAC3O,qBAAa,kBAAkB,CAC7B,QAAQ,SAAS,GAAG,GAAG,GAAG,EAC1B,WAAW,SAAS,MAAM,GAAG,EAAE,EAC/B,QAAQ,SAAS,MAAM,GAAG,GAAG,EAC7B,WAAW,GAAG,UAAU,CAAC,aAAa,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,EACrD,mBAAmB,SAAS,MAAM,GAAG,EAAE,CACvC,SAAQ,UAAU;IAClB,OAAO,CAAC,mBAAmB,CAAoD;IAC/E,OAAO,CAAC,QAAQ,CAGd;IAEF,OAAO,CAAC,UAAU,CAMhB;IACF,OAAO,CAAC,YAAY,CAAC,CAAY;IAEjC,OAAO;IAkCP,gGAAgG;IAChG,OAAO,CAAC,oBAAoB;IA8B5B,yHAAyH;IACzH,OAAO,CAAC,eAAe;IAQvB,oFAAoF;IACpF,OAAO,CAAC,eAAe;IA8DvB,4EAA4E;WAC/D,KAAK,CAChB,QAAQ,SAAS,GAAG,GAAG,GAAG,EAC1B,WAAW,SAAS,MAAM,GAAG,EAAE,EAC/B,QAAQ,SAAS,MAAM,GAAG,GAAG,EAC7B,WAAW,GAAG,UAAU,CAAC,aAAa,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,EACrD,mBAAmB,SAAS,MAAM,GAAG,EAAE,EACvC,IAAI,EAAE;QACN,UAAU,EAAE,sBAAsB,CAChC,QAAQ,EACR,WAAW,EACX,QAAQ,EACR,WAAW,EACX,mBAAmB,CACpB,CAAC;QACF,YAAY,CAAC,EAAE,OAAO,EAAE,CAAC;QACzB,MAAM,CAAC,EAAE,iBAAiB,CAAC;KAC5B,GAAG,OAAO,CAAC,qBAAqB,CAAC,QAAQ,EAAE,QAAQ,CAAC,CAAC;CAsDvD"}
|
|
@@ -12,8 +12,9 @@ const node_module_1 = require("node:module");
|
|
|
12
12
|
const node_path_1 = __importDefault(require("node:path"));
|
|
13
13
|
const CONNECT_RPC_MODULES = ['@connectrpc/connect'];
|
|
14
14
|
/** Bridges IGNIS gRPC controllers with ConnectRPC: loads the peer deps via createRequire, wraps handlers into ConnectRPC's signature, dispatches through a Hono middleware, and isolates request-scoped context with AsyncLocalStorage. */
|
|
15
|
-
class GrpcRequestAdapter {
|
|
15
|
+
class GrpcRequestAdapter extends core_1.BaseHelper {
|
|
16
16
|
constructor(opts) {
|
|
17
|
+
super({ scope: GrpcRequestAdapter.name });
|
|
17
18
|
this.controller = opts.controller;
|
|
18
19
|
this.interceptors = opts.interceptors;
|
|
19
20
|
if (opts.module) {
|
|
@@ -21,8 +22,8 @@ class GrpcRequestAdapter {
|
|
|
21
22
|
this.protocol = opts.module.protocol;
|
|
22
23
|
return;
|
|
23
24
|
}
|
|
24
|
-
/** Resolves peer deps
|
|
25
|
-
const appRequire = (0, node_module_1.createRequire)(node_path_1.default.join(
|
|
25
|
+
/** Resolves peer deps under the application's project root at runtime - nothing to resolve against in a compiled binary, which is what `module` is for. */
|
|
26
|
+
const appRequire = (0, node_module_1.createRequire)(node_path_1.default.join(ignis_helpers_1.ModuleUtility.getProjectRoot(), 'node_modules'));
|
|
26
27
|
this.createConnectRouter = appRequire('@connectrpc/connect').createConnectRouter;
|
|
27
28
|
const proto = appRequire('@connectrpc/connect/protocol');
|
|
28
29
|
this.protocol = {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"adapter.js","sourceRoot":"","sources":["../../../../src/base/controllers/grpc/adapter.ts"],"names":[],"mappings":";;;;;;AAOA,
|
|
1
|
+
{"version":3,"file":"adapter.js","sourceRoot":"","sources":["../../../../src/base/controllers/grpc/adapter.ts"],"names":[],"mappings":";;;;;;AAOA,sDAAmE;AACnE,0DAA2D;AAC3D,0DAAuD;AAEvD,uDAAqD;AACrD,6CAA4C;AAC5C,0DAA6B;AAK7B,MAAM,mBAAmB,GAAG,CAAC,qBAAqB,CAAC,CAAC;AAOpD,2OAA2O;AAC3O,MAAa,kBAMX,SAAQ,iBAAU;IAgBlB,YAAoB,IAUnB;QACC,KAAK,CAAC,EAAE,KAAK,EAAE,kBAAkB,CAAC,IAAI,EAAE,CAAC,CAAC;QAE1C,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,UAAU,CAAC;QAClC,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC,YAAY,CAAC;QAEtC,IAAI,IAAI,CAAC,MAAM,EAAE,CAAC;YAChB,IAAI,CAAC,mBAAmB,GAAG,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,mBAAmB,CAAC;YACnE,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC;YACrC,OAAO;QACT,CAAC;QAED,2JAA2J;QAC3J,MAAM,UAAU,GAAG,IAAA,2BAAa,EAAC,mBAAI,CAAC,IAAI,CAAC,6BAAa,CAAC,cAAc,EAAE,EAAE,cAAc,CAAC,CAAC,CAAC;QAE5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AAO,CAAC,UAAU,CAAC,QAAQ,CAAC,OAAO,CAAC,KAAK,EAAE,EAAE,CAAC;oBAC9C,OAAO,CAAC,UAAU,CAAC,IAAI;iBACxB,CAAC,IAAI,CAAC,EAAE,CAAC;gBACV,OAAO;aACR,CAAC;SACH,CAAC;IACJ,CAAC;CACF;AAtOD,gDAsOC"}
|
|
@@ -3,8 +3,9 @@ import type { ILogger } from '@venizia/ignis-helpers/core';
|
|
|
3
3
|
import type { TErrorLogFormatter } from '@venizia/ignis-kernel';
|
|
4
4
|
/**
|
|
5
5
|
* The server-side error handler: everything it does lives on {@link BaseAppErrorMiddleware}, which
|
|
6
|
-
* is browser-pure. This supplies the two host reads as OPTIONS - `
|
|
7
|
-
* `
|
|
6
|
+
* is browser-pure. This supplies the two host reads as OPTIONS - the ambient `NODE_ENV` through
|
|
7
|
+
* `Environment.ambient` (a read `bun build` cannot fold into a literal), and `ErrorPrettier`, which
|
|
8
|
+
* reaches `node:util` and so cannot sit in the kernel.
|
|
8
9
|
*
|
|
9
10
|
* A class only so the name `AppErrorMiddleware` keeps resolving for existing consumers; it overrides
|
|
10
11
|
* nothing. New code can pass the same two options to `BaseAppErrorMiddleware` directly.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"app-error.middleware.d.ts","sourceRoot":"","sources":["../../../../src/base/middlewares/app-error/app-error.middleware.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AAC/D,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,6BAA6B,CAAC;AAC3D,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAEhE
|
|
1
|
+
{"version":3,"file":"app-error.middleware.d.ts","sourceRoot":"","sources":["../../../../src/base/middlewares/app-error/app-error.middleware.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AAC/D,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,6BAA6B,CAAC;AAC3D,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAEhE;;;;;;;;GAQG;AACH,qBAAa,kBAAmB,SAAQ,sBAAsB;gBAChD,IAAI,CAAC,EAAE;QACjB,MAAM,CAAC,EAAE,OAAO,CAAC;QACjB,OAAO,CAAC,EAAE,MAAM,CAAC;QACjB,sBAAsB,CAAC,EAAE,MAAM,CAAC;QAChC,qBAAqB,CAAC,EAAE,MAAM,CAAC;QAC/B,WAAW,CAAC,EAAE,MAAM,MAAM,GAAG,SAAS,CAAC;QACvC,WAAW,CAAC,EAAE,kBAAkB,CAAC;KAClC;CASF"}
|
|
@@ -5,8 +5,9 @@ const ignis_helpers_1 = require("@venizia/ignis-helpers");
|
|
|
5
5
|
const ignis_kernel_1 = require("@venizia/ignis-kernel");
|
|
6
6
|
/**
|
|
7
7
|
* The server-side error handler: everything it does lives on {@link BaseAppErrorMiddleware}, which
|
|
8
|
-
* is browser-pure. This supplies the two host reads as OPTIONS - `
|
|
9
|
-
* `
|
|
8
|
+
* is browser-pure. This supplies the two host reads as OPTIONS - the ambient `NODE_ENV` through
|
|
9
|
+
* `Environment.ambient` (a read `bun build` cannot fold into a literal), and `ErrorPrettier`, which
|
|
10
|
+
* reaches `node:util` and so cannot sit in the kernel.
|
|
10
11
|
*
|
|
11
12
|
* A class only so the name `AppErrorMiddleware` keeps resolving for existing consumers; it overrides
|
|
12
13
|
* nothing. New code can pass the same two options to `BaseAppErrorMiddleware` directly.
|
|
@@ -17,7 +18,7 @@ class AppErrorMiddleware extends ignis_kernel_1.BaseAppErrorMiddleware {
|
|
|
17
18
|
...opts,
|
|
18
19
|
// Present, so an unresolved name here is a real misconfiguration and keeps its error line - a
|
|
19
20
|
// node host always HAS an ambient environment, even when it is not set.
|
|
20
|
-
environment: opts?.environment ?? (() =>
|
|
21
|
+
environment: opts?.environment ?? (() => ignis_helpers_1.Environment.ambient),
|
|
21
22
|
formatError: opts?.formatError ?? (formatOpts => ignis_helpers_1.ErrorPrettier.format(formatOpts)),
|
|
22
23
|
});
|
|
23
24
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"app-error.middleware.js","sourceRoot":"","sources":["../../../../src/base/middlewares/app-error/app-error.middleware.ts"],"names":[],"mappings":";;;AAAA,
|
|
1
|
+
{"version":3,"file":"app-error.middleware.js","sourceRoot":"","sources":["../../../../src/base/middlewares/app-error/app-error.middleware.ts"],"names":[],"mappings":";;;AAAA,0DAAoE;AACpE,wDAA+D;AAI/D;;;;;;;;GAQG;AACH,MAAa,kBAAmB,SAAQ,qCAAsB;IAC5D,YAAY,IAOX;QACC,KAAK,CAAC;YACJ,GAAG,IAAI;YACP,8FAA8F;YAC9F,wEAAwE;YACxE,WAAW,EAAE,IAAI,EAAE,WAAW,IAAI,CAAC,GAAG,EAAE,CAAC,2BAAW,CAAC,OAAO,CAAC;YAC7D,WAAW,EAAE,IAAI,EAAE,WAAW,IAAI,CAAC,UAAU,CAAC,EAAE,CAAC,6BAAa,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC;SACnF,CAAC,CAAC;IACL,CAAC;CACF;AAjBD,gDAiBC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"request-spy.middleware.d.ts","sourceRoot":"","sources":["../../../../src/base/middlewares/request-spy/request-spy.middleware.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"request-spy.middleware.d.ts","sourceRoot":"","sources":["../../../../src/base/middlewares/request-spy/request-spy.middleware.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAA8B,MAAM,6BAA6B,CAAC;AAErF,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,0BAA0B,CAAC;AAE1D,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AACpD,OAAO,EAAiC,KAAK,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAErF,sKAAsK;AACtK,qBAAa,oBAAqB,SAAQ,UAAW,YAAW,SAAS,CAAC,iBAAiB,CAAC;IAC1F,MAAM,CAAC,QAAQ,CAAC,cAAc,eAAkB;IAEhD,OAAO,CAAC,WAAW,CAAU;IAE7B;;;;;;;;;OASG;;IAOH,wDAAwD;IAClD,SAAS,CAAC,IAAI,EAAE;QAAE,GAAG,EAAE,QAAQ,CAAC,KAAK,CAAC,CAAA;KAAE,GAAG,OAAO,CAAC,OAAO,CAAC;IAyCjE,wEAAwE;IACxE,KAAK;CAmDN"}
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.RequestSpyMiddleware = void 0;
|
|
4
4
|
const network_utility_1 = require("../../../utilities/network.utility");
|
|
5
|
+
const ignis_helpers_1 = require("@venizia/ignis-helpers");
|
|
5
6
|
const core_1 = require("@venizia/ignis-helpers/core");
|
|
6
7
|
const common_1 = require("@venizia/ignis-helpers/common");
|
|
7
8
|
const factory_1 = require("hono/factory");
|
|
@@ -21,7 +22,7 @@ class RequestSpyMiddleware extends core_1.BaseHelper {
|
|
|
21
22
|
*/
|
|
22
23
|
constructor() {
|
|
23
24
|
super({ scope: 'SpyMW' });
|
|
24
|
-
const env =
|
|
25
|
+
const env = ignis_helpers_1.Environment.ambient?.toLowerCase();
|
|
25
26
|
this.isDebugMode = !!env && core_1.EnvironmentNames.DEVELOPMENT_ENVS.has(env);
|
|
26
27
|
}
|
|
27
28
|
/** Parses request body based on Content-Type header. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"request-spy.middleware.js","sourceRoot":"","sources":["../../../../src/base/middlewares/request-spy/request-spy.middleware.ts"],"names":[],"mappings":";;;AAAA,iEAA6D;AAC7D,sDAAqF;AACrF,0DAAqD;AAErD,0CAAgD;AAEhD,wDAAqF;AAErF,sKAAsK;AACtK,MAAa,oBAAqB,SAAQ,iBAAU;aAClC,mBAAc,GAAG,6BAAc,CAAC;IAIhD;;;;;;;;;OASG;IACH;QACE,KAAK,CAAC,EAAE,KAAK,EAAE,OAAO,EAAE,CAAC,CAAC;QAC1B,MAAM,GAAG,GAAG,
|
|
1
|
+
{"version":3,"file":"request-spy.middleware.js","sourceRoot":"","sources":["../../../../src/base/middlewares/request-spy/request-spy.middleware.ts"],"names":[],"mappings":";;;AAAA,iEAA6D;AAC7D,0DAAqD;AACrD,sDAAqF;AACrF,0DAAqD;AAErD,0CAAgD;AAEhD,wDAAqF;AAErF,sKAAsK;AACtK,MAAa,oBAAqB,SAAQ,iBAAU;aAClC,mBAAc,GAAG,6BAAc,CAAC;IAIhD;;;;;;;;;OASG;IACH;QACE,KAAK,CAAC,EAAE,KAAK,EAAE,OAAO,EAAE,CAAC,CAAC;QAC1B,MAAM,GAAG,GAAG,2BAAW,CAAC,OAAO,EAAE,WAAW,EAAE,CAAC;QAC/C,IAAI,CAAC,WAAW,GAAG,CAAC,CAAC,GAAG,IAAI,uBAAgB,CAAC,gBAAgB,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;IACzE,CAAC;IAED,wDAAwD;IACxD,KAAK,CAAC,SAAS,CAAC,IAA8B;QAC5C,MAAM,WAAW,GAAG,IAAI,CAAC,GAAG,CAAC,MAAM,CAAC,aAAI,CAAC,OAAO,CAAC,YAAY,CAAC,CAAC;QAE/D,IAAI,CAAC,WAAW,EAAE,CAAC;YACjB,OAAO,IAAI,CAAC;QACd,CAAC;QAED,yMAAyM;QACzM,MAAM,aAAa,GAAG,IAAI,CAAC,GAAG,CAAC,MAAM,CAAC,aAAI,CAAC,OAAO,CAAC,cAAc,CAAC,CAAC;QACnE,IAAI,aAAa,KAAK,GAAG,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC;YAChD,OAAO,IAAI,CAAC;QACd,CAAC;QAED,IAAI,CAAC;YACH,IAAI,WAAW,CAAC,QAAQ,CAAC,aAAI,CAAC,YAAY,CAAC,gBAAgB,CAAC,EAAE,CAAC;gBAC7D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,"file":"constants.d.ts","sourceRoot":"","sources":["../../src/common/constants.ts"],"names":[],"mappings":"AAEA,kCAAkC;AAClC,qBAAa,GAAG;IACd,MAAM,CAAC,QAAQ,CAAC,gBAAgB,SACkC;IAElE,MAAM,CAAC,QAAQ,CAAC,mBAAmB,MAAM;IACzC,MAAM,CAAC,QAAQ,CAAC,oBAAoB,KAAK;IAEzC,MAAM,CAAC,QAAQ,CAAC,WAAW,gBAAgB;IAC3C,MAAM,CAAC,QAAQ,CAAC,SAAS,YAAY;IACrC,MAAM,CAAC,QAAQ,CAAC,QAAQ,WAAW;CACpC"}
|
package/dist/common/constants.js
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.App = void 0;
|
|
4
|
+
const core_1 = require("@venizia/ignis-helpers/core");
|
|
4
5
|
/** Application-wide constants. */
|
|
5
6
|
class App {
|
|
6
|
-
static { this.APPLICATION_NAME = process.env.APP_ENV_APPLICATION_NAME ?? 'APP'; }
|
|
7
|
+
static { this.APPLICATION_NAME = (0, core_1.blankToUndefined)(process.env.APP_ENV_APPLICATION_NAME) ?? 'APP'; }
|
|
7
8
|
static { this.DEFAULT_QUERY_LIMIT = 50; }
|
|
8
9
|
static { this.DEFAULT_QUERY_OFFSET = 0; }
|
|
9
10
|
static { this.DS_POSTGRES = 'postgresql'; }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/common/constants.ts"],"names":[],"mappings":";;;AAAA,kCAAkC;AAClC,MAAa,GAAG;aACE,qBAAgB,
|
|
1
|
+
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/common/constants.ts"],"names":[],"mappings":";;;AAAA,sDAA+D;AAE/D,kCAAkC;AAClC,MAAa,GAAG;aACE,qBAAgB,GAC9B,IAAA,uBAAgB,EAAC,OAAO,CAAC,GAAG,CAAC,wBAAwB,CAAC,IAAI,KAAK,CAAC;aAElD,wBAAmB,GAAG,EAAE,CAAC;aACzB,yBAAoB,GAAG,CAAC,CAAC;aAEzB,gBAAW,GAAG,YAAY,CAAC;aAC3B,cAAS,GAAG,QAAQ,CAAC;aACrB,aAAQ,GAAG,OAAO,CAAC;;AATrC,kBAUC"}
|
|
@@ -1,20 +1,41 @@
|
|
|
1
|
-
/**
|
|
1
|
+
/**
|
|
2
|
+
* Environment variable names.
|
|
3
|
+
*
|
|
4
|
+
* The two groups mean different things and the split is load-bearing: a name in the second group
|
|
5
|
+
* is a CONVENTION an application reads for itself, and setting it changes nothing in IGNIS. Every
|
|
6
|
+
* name here was once presented as framework configuration, which is how a deployment came to set
|
|
7
|
+
* `APP_ENV_APPLICATION_DS_MIGRATION` against a framework that read `APP_ENV_DS_MIGRATION` - and
|
|
8
|
+
* neither name selected anything, so both are gone.
|
|
9
|
+
*
|
|
10
|
+
* A name earns its place by having a reader. `APP_ENV_OAUTH2_VIEW_FOLDER` and
|
|
11
|
+
* `APP_ENV_DATASOURCE_NAME` had none in either IGNIS or its consumers, only entries in `.env` files
|
|
12
|
+
* nobody consulted, so they went the same way. Before adding one here, know who reads it.
|
|
13
|
+
*
|
|
14
|
+
* Two framework variables are deliberately ABSENT from this class, and adding them would be a trap:
|
|
15
|
+
* `APPLICATION_ENV_PREFIX` and `ALLOW_EMPTY_ENV_VALUE`. Neither carries the `APP_ENV` prefix, so
|
|
16
|
+
* `applicationEnvironment` never holds them - a read through `AppEnvs.get()` would answer `undefined`
|
|
17
|
+
* forever. `APPLICATION_ENV_PREFIX` could not go through it in any case: it is what builds the
|
|
18
|
+
* filter. Both are bootstrap variables and are read straight off `process.env`, which is the one
|
|
19
|
+
* legitimate exception to "do not read process.env directly". Neither has to be declared or set:
|
|
20
|
+
* the prefix defaults to `APP_ENV`, and empty values are allowed unless you set
|
|
21
|
+
* `ALLOW_EMPTY_ENV_VALUE` to `false` or `0`.
|
|
22
|
+
*/
|
|
2
23
|
export declare class EnvironmentKeys {
|
|
24
|
+
/** `AppConstants.APPLICATION_NAME` and the startup banner. */
|
|
3
25
|
static readonly APP_ENV_APPLICATION_NAME = "APP_ENV_APPLICATION_NAME";
|
|
26
|
+
/** `DateUtility`'s default zone and the startup banner. */
|
|
4
27
|
static readonly APP_ENV_APPLICATION_TIMEZONE = "APP_ENV_APPLICATION_TIMEZONE";
|
|
5
|
-
|
|
6
|
-
static readonly APP_ENV_JWT_SECRET = "APP_ENV_JWT_SECRET";
|
|
7
|
-
static readonly APP_ENV_JWT_EXPIRES_IN = "APP_ENV_JWT_EXPIRES_IN";
|
|
28
|
+
/** Set it to enable rotating file logs; unset means console. Also the startup banner. */
|
|
8
29
|
static readonly APP_ENV_LOGGER_FOLDER_PATH = "APP_ENV_LOGGER_FOLDER_PATH";
|
|
9
|
-
|
|
10
|
-
static readonly APP_ENV_APPLICATION_DS_MIGRATION = "APP_ENV_APPLICATION_DS_MIGRATION";
|
|
11
|
-
static readonly APP_ENV_APPLICATION_DS_AUTHORIZE = "APP_ENV_APPLICATION_DS_AUTHORIZE";
|
|
12
|
-
static readonly APP_ENV_APPLICATION_DS_OAUTH2 = "APP_ENV_APPLICATION_DS_OAUTH2";
|
|
13
|
-
static readonly APP_ENV_OAUTH2_VIEW_FOLDER = "APP_ENV_OAUTH2_VIEW_FOLDER";
|
|
30
|
+
/** Fallback host when `IApplicationConfigs.host` is absent. */
|
|
14
31
|
static readonly APP_ENV_SERVER_HOST = "APP_ENV_SERVER_HOST";
|
|
32
|
+
/** Fallback port when `IApplicationConfigs.port` is absent. */
|
|
15
33
|
static readonly APP_ENV_SERVER_PORT = "APP_ENV_SERVER_PORT";
|
|
34
|
+
static readonly APP_ENV_APPLICATION_SECRET = "APP_ENV_APPLICATION_SECRET";
|
|
35
|
+
static readonly APP_ENV_APPLICATION_ROLES = "APP_ENV_APPLICATION_ROLES";
|
|
36
|
+
static readonly APP_ENV_JWT_SECRET = "APP_ENV_JWT_SECRET";
|
|
37
|
+
static readonly APP_ENV_JWT_EXPIRES_IN = "APP_ENV_JWT_EXPIRES_IN";
|
|
16
38
|
static readonly APP_ENV_SERVER_BASE_PATH = "APP_ENV_SERVER_BASE_PATH";
|
|
17
|
-
static readonly APP_ENV_DATASOURCE_NAME = "APP_ENV_DATASOURCE_NAME";
|
|
18
39
|
static readonly APP_ENV_POSTGRES_HOST = "APP_ENV_POSTGRES_HOST";
|
|
19
40
|
static readonly APP_ENV_POSTGRES_PORT = "APP_ENV_POSTGRES_PORT";
|
|
20
41
|
static readonly APP_ENV_POSTGRES_USERNAME = "APP_ENV_POSTGRES_USERNAME";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"environments.d.ts","sourceRoot":"","sources":["../../src/common/environments.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"environments.d.ts","sourceRoot":"","sources":["../../src/common/environments.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,qBAAa,eAAe;IAG1B,8DAA8D;IAC9D,MAAM,CAAC,QAAQ,CAAC,wBAAwB,8BAA8B;IACtE,2DAA2D;IAC3D,MAAM,CAAC,QAAQ,CAAC,4BAA4B,kCAAkC;IAC9E,yFAAyF;IACzF,MAAM,CAAC,QAAQ,CAAC,0BAA0B,gCAAgC;IAC1E,+DAA+D;IAC/D,MAAM,CAAC,QAAQ,CAAC,mBAAmB,yBAAyB;IAC5D,+DAA+D;IAC/D,MAAM,CAAC,QAAQ,CAAC,mBAAmB,yBAAyB;IAI5D,MAAM,CAAC,QAAQ,CAAC,0BAA0B,gCAAgC;IAC1E,MAAM,CAAC,QAAQ,CAAC,yBAAyB,+BAA+B;IAExE,MAAM,CAAC,QAAQ,CAAC,kBAAkB,wBAAwB;IAC1D,MAAM,CAAC,QAAQ,CAAC,sBAAsB,4BAA4B;IAElE,MAAM,CAAC,QAAQ,CAAC,wBAAwB,8BAA8B;IAEtE,MAAM,CAAC,QAAQ,CAAC,qBAAqB,2BAA2B;IAChE,MAAM,CAAC,QAAQ,CAAC,qBAAqB,2BAA2B;IAChE,MAAM,CAAC,QAAQ,CAAC,yBAAyB,+BAA+B;IACxE,MAAM,CAAC,QAAQ,CAAC,yBAAyB,+BAA+B;IACxE,MAAM,CAAC,QAAQ,CAAC,yBAAyB,+BAA+B;CACzE"}
|
|
@@ -1,23 +1,46 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.EnvironmentKeys = void 0;
|
|
4
|
-
/**
|
|
4
|
+
/**
|
|
5
|
+
* Environment variable names.
|
|
6
|
+
*
|
|
7
|
+
* The two groups mean different things and the split is load-bearing: a name in the second group
|
|
8
|
+
* is a CONVENTION an application reads for itself, and setting it changes nothing in IGNIS. Every
|
|
9
|
+
* name here was once presented as framework configuration, which is how a deployment came to set
|
|
10
|
+
* `APP_ENV_APPLICATION_DS_MIGRATION` against a framework that read `APP_ENV_DS_MIGRATION` - and
|
|
11
|
+
* neither name selected anything, so both are gone.
|
|
12
|
+
*
|
|
13
|
+
* A name earns its place by having a reader. `APP_ENV_OAUTH2_VIEW_FOLDER` and
|
|
14
|
+
* `APP_ENV_DATASOURCE_NAME` had none in either IGNIS or its consumers, only entries in `.env` files
|
|
15
|
+
* nobody consulted, so they went the same way. Before adding one here, know who reads it.
|
|
16
|
+
*
|
|
17
|
+
* Two framework variables are deliberately ABSENT from this class, and adding them would be a trap:
|
|
18
|
+
* `APPLICATION_ENV_PREFIX` and `ALLOW_EMPTY_ENV_VALUE`. Neither carries the `APP_ENV` prefix, so
|
|
19
|
+
* `applicationEnvironment` never holds them - a read through `AppEnvs.get()` would answer `undefined`
|
|
20
|
+
* forever. `APPLICATION_ENV_PREFIX` could not go through it in any case: it is what builds the
|
|
21
|
+
* filter. Both are bootstrap variables and are read straight off `process.env`, which is the one
|
|
22
|
+
* legitimate exception to "do not read process.env directly". Neither has to be declared or set:
|
|
23
|
+
* the prefix defaults to `APP_ENV`, and empty values are allowed unless you set
|
|
24
|
+
* `ALLOW_EMPTY_ENV_VALUE` to `false` or `0`.
|
|
25
|
+
*/
|
|
5
26
|
class EnvironmentKeys {
|
|
27
|
+
// --- Read by the framework -------------------------------------------------------------------
|
|
28
|
+
/** `AppConstants.APPLICATION_NAME` and the startup banner. */
|
|
6
29
|
static { this.APP_ENV_APPLICATION_NAME = 'APP_ENV_APPLICATION_NAME'; }
|
|
30
|
+
/** `DateUtility`'s default zone and the startup banner. */
|
|
7
31
|
static { this.APP_ENV_APPLICATION_TIMEZONE = 'APP_ENV_APPLICATION_TIMEZONE'; }
|
|
8
|
-
|
|
9
|
-
static { this.APP_ENV_JWT_SECRET = 'APP_ENV_JWT_SECRET'; }
|
|
10
|
-
static { this.APP_ENV_JWT_EXPIRES_IN = 'APP_ENV_JWT_EXPIRES_IN'; }
|
|
32
|
+
/** Set it to enable rotating file logs; unset means console. Also the startup banner. */
|
|
11
33
|
static { this.APP_ENV_LOGGER_FOLDER_PATH = 'APP_ENV_LOGGER_FOLDER_PATH'; }
|
|
12
|
-
|
|
13
|
-
static { this.APP_ENV_APPLICATION_DS_MIGRATION = 'APP_ENV_APPLICATION_DS_MIGRATION'; }
|
|
14
|
-
static { this.APP_ENV_APPLICATION_DS_AUTHORIZE = 'APP_ENV_APPLICATION_DS_AUTHORIZE'; }
|
|
15
|
-
static { this.APP_ENV_APPLICATION_DS_OAUTH2 = 'APP_ENV_APPLICATION_DS_OAUTH2'; }
|
|
16
|
-
static { this.APP_ENV_OAUTH2_VIEW_FOLDER = 'APP_ENV_OAUTH2_VIEW_FOLDER'; }
|
|
34
|
+
/** Fallback host when `IApplicationConfigs.host` is absent. */
|
|
17
35
|
static { this.APP_ENV_SERVER_HOST = 'APP_ENV_SERVER_HOST'; }
|
|
36
|
+
/** Fallback port when `IApplicationConfigs.port` is absent. */
|
|
18
37
|
static { this.APP_ENV_SERVER_PORT = 'APP_ENV_SERVER_PORT'; }
|
|
38
|
+
// --- Convention only: nothing in IGNIS reads these ---------------------------------------------
|
|
39
|
+
static { this.APP_ENV_APPLICATION_SECRET = 'APP_ENV_APPLICATION_SECRET'; }
|
|
40
|
+
static { this.APP_ENV_APPLICATION_ROLES = 'APP_ENV_APPLICATION_ROLES'; }
|
|
41
|
+
static { this.APP_ENV_JWT_SECRET = 'APP_ENV_JWT_SECRET'; }
|
|
42
|
+
static { this.APP_ENV_JWT_EXPIRES_IN = 'APP_ENV_JWT_EXPIRES_IN'; }
|
|
19
43
|
static { this.APP_ENV_SERVER_BASE_PATH = 'APP_ENV_SERVER_BASE_PATH'; }
|
|
20
|
-
static { this.APP_ENV_DATASOURCE_NAME = 'APP_ENV_DATASOURCE_NAME'; }
|
|
21
44
|
static { this.APP_ENV_POSTGRES_HOST = 'APP_ENV_POSTGRES_HOST'; }
|
|
22
45
|
static { this.APP_ENV_POSTGRES_PORT = 'APP_ENV_POSTGRES_PORT'; }
|
|
23
46
|
static { this.APP_ENV_POSTGRES_USERNAME = 'APP_ENV_POSTGRES_USERNAME'; }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"environments.js","sourceRoot":"","sources":["../../src/common/environments.ts"],"names":[],"mappings":";;;AAAA
|
|
1
|
+
{"version":3,"file":"environments.js","sourceRoot":"","sources":["../../src/common/environments.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,MAAa,eAAe;IAC1B,gGAAgG;IAEhG,8DAA8D;aAC9C,6BAAwB,GAAG,0BAA0B,CAAC;IACtE,2DAA2D;aAC3C,iCAA4B,GAAG,8BAA8B,CAAC;IAC9E,yFAAyF;aACzE,+BAA0B,GAAG,4BAA4B,CAAC;IAC1E,+DAA+D;aAC/C,wBAAmB,GAAG,qBAAqB,CAAC;IAC5D,+DAA+D;aAC/C,wBAAmB,GAAG,qBAAqB,CAAC;IAE5D,kGAAkG;aAElF,+BAA0B,GAAG,4BAA4B,CAAC;aAC1D,8BAAyB,GAAG,2BAA2B,CAAC;aAExD,uBAAkB,GAAG,oBAAoB,CAAC;aAC1C,2BAAsB,GAAG,wBAAwB,CAAC;aAElD,6BAAwB,GAAG,0BAA0B,CAAC;aAEtD,0BAAqB,GAAG,uBAAuB,CAAC;aAChD,0BAAqB,GAAG,uBAAuB,CAAC;aAChD,8BAAyB,GAAG,2BAA2B,CAAC;aACxD,8BAAyB,GAAG,2BAA2B,CAAC;aACxD,8BAAyB,GAAG,2BAA2B,CAAC;;AA5B1E,0CA6BC"}
|
|
@@ -21,7 +21,7 @@ const ignis_kernel_1 = require("@venizia/ignis-kernel");
|
|
|
21
21
|
const auth_1 = require("../auth");
|
|
22
22
|
const ignis_kernel_2 = require("@venizia/ignis-kernel");
|
|
23
23
|
const common_1 = require("./common");
|
|
24
|
-
const
|
|
24
|
+
const ui_1 = require("./ui");
|
|
25
25
|
const DEFAULT_API_REFERENCE_OPTIONS = {
|
|
26
26
|
restOptions: {
|
|
27
27
|
base: { path: '/doc' },
|
|
@@ -96,7 +96,7 @@ let ApiReferenceComponent = ApiReferenceComponent_1 = class ApiReferenceComponen
|
|
|
96
96
|
const uiPath = joinRestPath([restOptions.base.path, restOptions.ui.path]);
|
|
97
97
|
rootRouter.doc(docPath, explorer);
|
|
98
98
|
const uiType = restOptions.ui.type ?? common_1.DocumentUITypes.SWAGGER;
|
|
99
|
-
const uiProviderFactory =
|
|
99
|
+
const uiProviderFactory = ui_1.UIProviderFactory.getInstance();
|
|
100
100
|
// A custom provider registered on the factory is honoured; only unknown types are rejected.
|
|
101
101
|
if (!uiProviderFactory.isBound(uiType)) {
|
|
102
102
|
if (!common_1.DocumentUITypes.isValid(uiType)) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"component.js","sourceRoot":"","sources":["../../../src/components/api-reference/component.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,sDAAsD;AACtD,8CAAyC;AAGzC,sDAAuD;AACvD,wDAA6E;AAE7E,kCAAyC;AACzC,wDAAyD;AACzD,qCAA0F;AAC1F,
|
|
1
|
+
{"version":3,"file":"component.js","sourceRoot":"","sources":["../../../src/components/api-reference/component.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,sDAAsD;AACtD,8CAAyC;AAGzC,sDAAuD;AACvD,wDAA6E;AAE7E,kCAAyC;AACzC,wDAAyD;AACzD,qCAA0F;AAC1F,6BAAyC;AAEzC,MAAM,6BAA6B,GAAyB;IAC1D,WAAW,EAAE;QACX,IAAI,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE;QACtB,GAAG,EAAE,EAAE,IAAI,EAAE,eAAe,EAAE;QAC9B,EAAE,EAAE,EAAE,IAAI,EAAE,WAAW,EAAE,IAAI,EAAE,QAAQ,EAAE;KAC1C;IACD,QAAQ,EAAE;QACR,OAAO,EAAE,OAAO;QAChB,IAAI,EAAE;YACJ,KAAK,EAAE,mBAAmB;YAC1B,OAAO,EAAE,OAAO;YAChB,WAAW,EAAE,oCAAoC;SAClD;KACF;CACF,CAAC;AAEF,gGAAgG;AAChG,MAAM,YAAY,GAAG,CAAC,QAAmC,EAAU,EAAE;IACnE,MAAM,MAAM,GAAG,QAAQ;SACpB,MAAM,CAAC,CAAC,OAAO,EAAqB,EAAE,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;SACxD,IAAI,CAAC,GAAG,CAAC;SACT,OAAO,CAAC,MAAM,EAAE,GAAG,CAAC;SACpB,OAAO,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC;IAEtB,OAAO,MAAM,CAAC,UAAU,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,MAAM,EAAE,CAAC;AACxD,CAAC,CAAC;AAEF,IAAa,qBAAqB,6BAAlC,MAAa,qBAAsB,SAAQ,4BAAa;IACtD,YAC8D,WAA4B;QAExF,KAAK,CAAC;YACJ,KAAK,EAAE,uBAAqB,CAAC,IAAI;YACjC,WAAW,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,SAAS,EAAE,WA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U,CAAC,eAAe,CAAC,iBAAiB,CAAC,iBAAiB,EAAE,IAAI,EAAE,MAAiB,CAAC,CAAC;QAC3F,CAAC;IACH,CAAC;CACF,CAAA;AA9GY,sDAAqB;gCAArB,qBAAqB;IAE7B,WAAA,IAAA,iBAAM,EAAC,EAAE,GAAG,EAAE,2BAAY,CAAC,oBAAoB,EAAE,CAAC,CAAA;qCAAsB,8BAAe;GAF/E,qBAAqB,CA8GjC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/api-reference/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/api-reference/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,MAAM,CAAC"}
|
|
@@ -16,5 +16,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
__exportStar(require("./common"), exports);
|
|
18
18
|
__exportStar(require("./component"), exports);
|
|
19
|
-
__exportStar(require("./ui
|
|
19
|
+
__exportStar(require("./ui"), exports);
|
|
20
20
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/api-reference/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,2CAAyB;AACzB,8CAA4B;AAC5B
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/api-reference/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,2CAAyB;AACzB,8CAA4B;AAC5B,uCAAqB"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { IGetProviderParams, IUIProvider } from '../common';
|
|
2
|
+
import { MemoryStorageHelper } from '@venizia/ignis-helpers';
|
|
3
|
+
export declare class UIProviderFactory extends MemoryStorageHelper<{
|
|
4
|
+
[key: string | symbol]: IUIProvider;
|
|
5
|
+
}> {
|
|
6
|
+
private static instance;
|
|
7
|
+
static getInstance(): UIProviderFactory;
|
|
8
|
+
getProvider({ type }: IGetProviderParams): IUIProvider;
|
|
9
|
+
register(opts: {
|
|
10
|
+
type: string;
|
|
11
|
+
}): void;
|
|
12
|
+
getRegisteredProviders(): (string | number | symbol)[];
|
|
13
|
+
}
|
|
14
|
+
//# sourceMappingURL=factory.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"factory.d.ts","sourceRoot":"","sources":["../../../../src/components/api-reference/ui/factory.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AAGjE,OAAO,EAAE,mBAAmB,EAAE,MAAM,wBAAwB,CAAC;AAI7D,qBAAa,iBAAkB,SAAQ,mBAAmB,CAAC;IACzD,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,WAAW,CAAC;CACrC,CAAC;IACA,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAoB;IAE3C,MAAM,CAAC,WAAW;IASlB,WAAW,CAAC,EAAE,IAAI,EAAE,EAAE,kBAAkB,GAAG,WAAW;IAYtD,QAAQ,CAAC,IAAI,EAAE;QAAE,IAAI,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI;IAyBtC,sBAAsB;CAGvB"}
|
|
@@ -1,25 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.UIProviderFactory =
|
|
4
|
-
const common_1 = require("
|
|
3
|
+
exports.UIProviderFactory = void 0;
|
|
4
|
+
const common_1 = require("../common");
|
|
5
5
|
const core_1 = require("@venizia/ignis-helpers/core");
|
|
6
6
|
const ignis_helpers_1 = require("@venizia/ignis-helpers");
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
const { swaggerUI } = await import('@hono/swagger-ui');
|
|
10
|
-
const { title, url, ...customConfig } = config;
|
|
11
|
-
return swaggerUI({ title, url, ...customConfig })(context, next);
|
|
12
|
-
}
|
|
13
|
-
}
|
|
14
|
-
exports.SwaggerUIProvider = SwaggerUIProvider;
|
|
15
|
-
class ScalarUIProvider {
|
|
16
|
-
async render(context, config, next) {
|
|
17
|
-
const { Scalar } = await import('@scalar/hono-api-reference');
|
|
18
|
-
const { title, url, ...customConfig } = config;
|
|
19
|
-
return Scalar({ url, pageTitle: title, ...customConfig })(context, next);
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
exports.ScalarUIProvider = ScalarUIProvider;
|
|
7
|
+
const scalar_1 = require("./scalar");
|
|
8
|
+
const swagger_1 = require("./swagger");
|
|
23
9
|
class UIProviderFactory extends ignis_helpers_1.MemoryStorageHelper {
|
|
24
10
|
static getInstance() {
|
|
25
11
|
if (!UIProviderFactory.instance) {
|
|
@@ -27,14 +13,15 @@ class UIProviderFactory extends ignis_helpers_1.MemoryStorageHelper {
|
|
|
27
13
|
}
|
|
28
14
|
return UIProviderFactory.instance;
|
|
29
15
|
}
|
|
16
|
+
// One lookup, not a `isBound` probe followed by a second `get` of the same key.
|
|
30
17
|
getProvider({ type }) {
|
|
31
|
-
|
|
32
|
-
|
|
18
|
+
const provider = this.get(type);
|
|
19
|
+
if (!provider) {
|
|
33
20
|
throw (0, core_1.getError)({
|
|
34
|
-
message: `[UIProviderFactory][getProvider] Unknown UI Provider | type: ${type} | available: ${
|
|
21
|
+
message: `[UIProviderFactory][getProvider] Unknown UI Provider | type: ${type} | available: ${this.keys().join(', ')}`,
|
|
35
22
|
});
|
|
36
23
|
}
|
|
37
|
-
return
|
|
24
|
+
return provider;
|
|
38
25
|
}
|
|
39
26
|
register(opts) {
|
|
40
27
|
if (this.isBound(opts.type)) {
|
|
@@ -45,11 +32,11 @@ class UIProviderFactory extends ignis_helpers_1.MemoryStorageHelper {
|
|
|
45
32
|
}
|
|
46
33
|
switch (opts.type) {
|
|
47
34
|
case common_1.DocumentUITypes.SWAGGER: {
|
|
48
|
-
this.set(opts.type, new SwaggerUIProvider());
|
|
35
|
+
this.set(opts.type, new swagger_1.SwaggerUIProvider());
|
|
49
36
|
return;
|
|
50
37
|
}
|
|
51
38
|
case common_1.DocumentUITypes.SCALAR: {
|
|
52
|
-
this.set(opts.type, new ScalarUIProvider());
|
|
39
|
+
this.set(opts.type, new scalar_1.ScalarUIProvider());
|
|
53
40
|
return;
|
|
54
41
|
}
|
|
55
42
|
default: {
|
|
@@ -64,4 +51,4 @@ class UIProviderFactory extends ignis_helpers_1.MemoryStorageHelper {
|
|
|
64
51
|
}
|
|
65
52
|
}
|
|
66
53
|
exports.UIProviderFactory = UIProviderFactory;
|
|
67
|
-
//# sourceMappingURL=
|
|
54
|
+
//# sourceMappingURL=factory.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"factory.js","sourceRoot":"","sources":["../../../../src/components/api-reference/ui/factory.ts"],"names":[],"mappings":";;;AACA,sCAA4C;AAC5C,sDAAuD;AACvD,0DAA6D;AAC7D,qCAA4C;AAC5C,uCAA8C;AAE9C,MAAa,iBAAkB,SAAQ,mCAErC;IAGA,MAAM,CAAC,WAAW;QAChB,IAAI,CAAC,iBAAiB,CAAC,QAAQ,EAAE,CAAC;YAChC,iBAAiB,CAAC,QAAQ,GAAG,IAAI,iBAAiB,EAAE,CAAC;QACvD,CAAC;QAED,OAAO,iBAAiB,CAAC,QAAQ,CAAC;IACpC,CAAC;IAED,gFAAgF;IAChF,WAAW,CAAC,EAAE,IAAI,EAAsB;QACtC,MAAM,QAAQ,GAAG,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;QAEhC,IAAI,CAAC,QAAQ,EAAE,CAAC;YACd,MAAM,IAAA,eAAQ,EAAC;gBACb,OAAO,EAAE,gEAAgE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AACzB,cAAc,WAAW,CAAC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./swagger"), exports);
|
|
18
|
+
__exportStar(require("./scalar"), exports);
|
|
19
|
+
__exportStar(require("./factory"), exports);
|
|
20
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/components/api-reference/ui/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,4CAA0B;AAC1B,2CAAyB;AACzB,4CAA0B"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { Context, Next } from 'hono';
|
|
2
|
+
import type { IUIConfig, IUIProvider } from '../common';
|
|
3
|
+
import { BaseHelper } from '@venizia/ignis-helpers/core';
|
|
4
|
+
export declare class ScalarUIProvider extends BaseHelper implements IUIProvider {
|
|
5
|
+
constructor();
|
|
6
|
+
render(context: Context, config: IUIConfig, next: Next): Promise<Response | void>;
|
|
7
|
+
}
|
|
8
|
+
//# sourceMappingURL=scalar.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"scalar.d.ts","sourceRoot":"","sources":["../../../../src/components/api-reference/ui/scalar.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAC1C,OAAO,KAAK,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AACxD,OAAO,EAAE,UAAU,EAAY,MAAM,6BAA6B,CAAC;AAEnE,qBAAa,gBAAiB,SAAQ,UAAW,YAAW,WAAW;;IAK/D,MAAM,CAAC,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,SAAS,EAAE,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,QAAQ,GAAG,IAAI,CAAC;CAoBxF"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ScalarUIProvider = void 0;
|
|
4
|
+
const core_1 = require("@venizia/ignis-helpers/core");
|
|
5
|
+
class ScalarUIProvider extends core_1.BaseHelper {
|
|
6
|
+
constructor() {
|
|
7
|
+
super({ scope: ScalarUIProvider.name });
|
|
8
|
+
}
|
|
9
|
+
async render(context, config, next) {
|
|
10
|
+
let scalarModule;
|
|
11
|
+
try {
|
|
12
|
+
scalarModule = await import('@scalar/hono-api-reference');
|
|
13
|
+
}
|
|
14
|
+
catch (error) {
|
|
15
|
+
this.logger
|
|
16
|
+
.for(this.render.name)
|
|
17
|
+
.error("Failed to load '@scalar/hono-api-reference' | Error: %s", error);
|
|
18
|
+
throw (0, core_1.getError)({
|
|
19
|
+
message: "[ScalarUIProvider][render] '@scalar/hono-api-reference' is required to render the Scalar UI. Please install it",
|
|
20
|
+
});
|
|
21
|
+
}
|
|
22
|
+
const { Scalar } = scalarModule;
|
|
23
|
+
const { title, url, ...customConfig } = config;
|
|
24
|
+
return Scalar({ url, pageTitle: title, ...customConfig })(context, next);
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
exports.ScalarUIProvider = ScalarUIProvider;
|
|
28
|
+
//# sourceMappingURL=scalar.js.map
|