@daffodil/auth 0.47.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +14 -0
- package/daffodil-auth.d.ts +5 -0
- package/driver/daffodil-auth-driver.d.ts +5 -0
- package/driver/errors/authentication-failed.d.ts +6 -0
- package/driver/errors/codes.enum.d.ts +6 -0
- package/driver/errors/invalid-api-response.d.ts +6 -0
- package/driver/errors/map.d.ts +13 -0
- package/driver/errors/public_api.d.ts +6 -0
- package/driver/errors/registration-failed.d.ts +9 -0
- package/driver/errors/unauthorized.d.ts +6 -0
- package/driver/in-memory/backend/auth.service.d.ts +22 -0
- package/driver/in-memory/daffodil-auth-driver-in-memory.d.ts +5 -0
- package/driver/in-memory/drivers/auth/auth.service.d.ts +15 -0
- package/driver/in-memory/drivers/auth-driver.module.d.ts +9 -0
- package/driver/in-memory/drivers/login/login.service.d.ts +17 -0
- package/driver/in-memory/drivers/public_api.d.ts +4 -0
- package/driver/in-memory/drivers/register/register.service.d.ts +19 -0
- package/driver/in-memory/drivers/reset-password/service.d.ts +20 -0
- package/driver/in-memory/index.d.ts +1 -0
- package/driver/in-memory/models/db-customer.type.d.ts +8 -0
- package/driver/in-memory/package.json +10 -0
- package/driver/in-memory/public_api.d.ts +2 -0
- package/driver/index.d.ts +1 -0
- package/driver/interfaces/auth-service.interface.d.ts +9 -0
- package/driver/interfaces/login-service.interface.d.ts +16 -0
- package/driver/interfaces/public_api.d.ts +4 -0
- package/driver/interfaces/register-service.interface.d.ts +19 -0
- package/driver/interfaces/reset-password-service.interface.d.ts +18 -0
- package/driver/magento/apollo-bearer-token-link-generator.d.ts +16 -0
- package/driver/magento/auth-driver.module.d.ts +9 -0
- package/driver/magento/auth.service.d.ts +14 -0
- package/driver/magento/daffodil-auth-driver-magento.d.ts +5 -0
- package/driver/magento/errors/codes.d.ts +5 -0
- package/driver/magento/errors/map.d.ts +2 -0
- package/driver/magento/errors/transform.d.ts +1 -0
- package/driver/magento/index.d.ts +1 -0
- package/driver/magento/login.service.d.ts +18 -0
- package/driver/magento/models/public_api.d.ts +4 -0
- package/driver/magento/models/response/auth.d.ts +3 -0
- package/driver/magento/models/response/register.type.d.ts +7 -0
- package/driver/magento/models/response/reset-password.type.d.ts +3 -0
- package/driver/magento/models/response/send-reset-email.type.d.ts +3 -0
- package/driver/magento/package.json +10 -0
- package/driver/magento/public_api.d.ts +8 -0
- package/driver/magento/queries/check-token.d.ts +1 -0
- package/driver/magento/queries/create-customer.d.ts +1 -0
- package/driver/magento/queries/generate-token.d.ts +1 -0
- package/driver/magento/queries/public_api.d.ts +7 -0
- package/driver/magento/queries/reset-password.d.ts +1 -0
- package/driver/magento/queries/responses/check-token-response.d.ts +5 -0
- package/driver/magento/queries/responses/generate-token-response.d.ts +4 -0
- package/driver/magento/queries/responses/public_api.d.ts +3 -0
- package/driver/magento/queries/responses/revoke-customer-token-response.d.ts +5 -0
- package/driver/magento/queries/revoke-customer-token.d.ts +1 -0
- package/driver/magento/queries/send-reset-email.d.ts +1 -0
- package/driver/magento/register.service.d.ts +18 -0
- package/driver/magento/reset-password.service.d.ts +19 -0
- package/driver/magento/transforms/auth-transformer.service.d.ts +16 -0
- package/driver/magento/validators/check-token.d.ts +3 -0
- package/driver/magento/validators/generate-token.d.ts +3 -0
- package/driver/magento/validators/public_api.d.ts +5 -0
- package/driver/magento/validators/reset-password.d.ts +3 -0
- package/driver/magento/validators/revoke-token.d.ts +3 -0
- package/driver/magento/validators/send-reset-email.d.ts +3 -0
- package/driver/package.json +10 -0
- package/driver/public_api.d.ts +2 -0
- package/driver/testing/daffodil-auth-driver-testing.d.ts +5 -0
- package/driver/testing/drivers/auth/auth.service.d.ts +11 -0
- package/driver/testing/drivers/auth-driver.module.d.ts +9 -0
- package/driver/testing/drivers/login/login.service.d.ts +16 -0
- package/driver/testing/drivers/public_api.d.ts +4 -0
- package/driver/testing/drivers/register/register.service.d.ts +16 -0
- package/driver/testing/drivers/reset-password/service.d.ts +17 -0
- package/driver/testing/index.d.ts +1 -0
- package/driver/testing/package.json +10 -0
- package/driver/testing/public_api.d.ts +1 -0
- package/esm2020/daffodil-auth.mjs +5 -0
- package/esm2020/driver/daffodil-auth-driver.mjs +5 -0
- package/esm2020/driver/errors/authentication-failed.mjs +10 -0
- package/esm2020/driver/errors/codes.enum.mjs +8 -0
- package/esm2020/driver/errors/invalid-api-response.mjs +10 -0
- package/esm2020/driver/errors/map.mjs +15 -0
- package/esm2020/driver/errors/public_api.mjs +7 -0
- package/esm2020/driver/errors/registration-failed.mjs +13 -0
- package/esm2020/driver/errors/unauthorized.mjs +10 -0
- package/esm2020/driver/in-memory/backend/auth.service.mjs +109 -0
- package/esm2020/driver/in-memory/daffodil-auth-driver-in-memory.mjs +5 -0
- package/esm2020/driver/in-memory/drivers/auth/auth.service.mjs +26 -0
- package/esm2020/driver/in-memory/drivers/auth-driver.module.mjs +47 -0
- package/esm2020/driver/in-memory/drivers/login/login.service.mjs +30 -0
- package/esm2020/driver/in-memory/drivers/public_api.mjs +5 -0
- package/esm2020/driver/in-memory/drivers/register/register.service.mjs +32 -0
- package/esm2020/driver/in-memory/drivers/reset-password/service.mjs +35 -0
- package/esm2020/driver/in-memory/index.mjs +2 -0
- package/esm2020/driver/in-memory/models/db-customer.type.mjs +2 -0
- package/esm2020/driver/in-memory/public_api.mjs +3 -0
- package/esm2020/driver/index.mjs +2 -0
- package/esm2020/driver/interfaces/auth-service.interface.mjs +3 -0
- package/esm2020/driver/interfaces/login-service.interface.mjs +3 -0
- package/esm2020/driver/interfaces/public_api.mjs +5 -0
- package/esm2020/driver/interfaces/register-service.interface.mjs +3 -0
- package/esm2020/driver/interfaces/reset-password-service.interface.mjs +3 -0
- package/esm2020/driver/magento/apollo-bearer-token-link-generator.mjs +38 -0
- package/esm2020/driver/magento/auth-driver.module.mjs +47 -0
- package/esm2020/driver/magento/auth.service.mjs +29 -0
- package/esm2020/driver/magento/daffodil-auth-driver-magento.mjs +5 -0
- package/esm2020/driver/magento/errors/codes.mjs +7 -0
- package/esm2020/driver/magento/errors/map.mjs +9 -0
- package/esm2020/driver/magento/errors/transform.mjs +4 -0
- package/esm2020/driver/magento/index.mjs +2 -0
- package/esm2020/driver/magento/login.service.mjs +41 -0
- package/esm2020/driver/magento/models/public_api.mjs +2 -0
- package/esm2020/driver/magento/models/response/auth.mjs +2 -0
- package/esm2020/driver/magento/models/response/register.type.mjs +2 -0
- package/esm2020/driver/magento/models/response/reset-password.type.mjs +2 -0
- package/esm2020/driver/magento/models/response/send-reset-email.type.mjs +2 -0
- package/esm2020/driver/magento/public_api.mjs +9 -0
- package/esm2020/driver/magento/queries/check-token.mjs +9 -0
- package/esm2020/driver/magento/queries/create-customer.mjs +21 -0
- package/esm2020/driver/magento/queries/generate-token.mjs +12 -0
- package/esm2020/driver/magento/queries/public_api.mjs +8 -0
- package/esm2020/driver/magento/queries/reset-password.mjs +11 -0
- package/esm2020/driver/magento/queries/responses/check-token-response.mjs +2 -0
- package/esm2020/driver/magento/queries/responses/generate-token-response.mjs +2 -0
- package/esm2020/driver/magento/queries/responses/public_api.mjs +2 -0
- package/esm2020/driver/magento/queries/responses/revoke-customer-token-response.mjs +2 -0
- package/esm2020/driver/magento/queries/revoke-customer-token.mjs +9 -0
- package/esm2020/driver/magento/queries/send-reset-email.mjs +9 -0
- package/esm2020/driver/magento/register.service.mjs +48 -0
- package/esm2020/driver/magento/reset-password.service.mjs +50 -0
- package/esm2020/driver/magento/transforms/auth-transformer.service.mjs +26 -0
- package/esm2020/driver/magento/validators/check-token.mjs +10 -0
- package/esm2020/driver/magento/validators/generate-token.mjs +10 -0
- package/esm2020/driver/magento/validators/public_api.mjs +6 -0
- package/esm2020/driver/magento/validators/reset-password.mjs +10 -0
- package/esm2020/driver/magento/validators/revoke-token.mjs +10 -0
- package/esm2020/driver/magento/validators/send-reset-email.mjs +10 -0
- package/esm2020/driver/public_api.mjs +3 -0
- package/esm2020/driver/testing/daffodil-auth-driver-testing.mjs +5 -0
- package/esm2020/driver/testing/drivers/auth/auth.service.mjs +20 -0
- package/esm2020/driver/testing/drivers/auth-driver.module.mjs +47 -0
- package/esm2020/driver/testing/drivers/login/login.service.mjs +28 -0
- package/esm2020/driver/testing/drivers/public_api.mjs +5 -0
- package/esm2020/driver/testing/drivers/register/register.service.mjs +28 -0
- package/esm2020/driver/testing/drivers/reset-password/service.mjs +31 -0
- package/esm2020/driver/testing/index.mjs +2 -0
- package/esm2020/driver/testing/public_api.mjs +2 -0
- package/esm2020/index.mjs +2 -0
- package/esm2020/injection-tokens/error-matcher.token.mjs +8 -0
- package/esm2020/injection-tokens/public_api.mjs +2 -0
- package/esm2020/models/account-registration.mjs +2 -0
- package/esm2020/models/auth-token.mjs +2 -0
- package/esm2020/models/login-info.mjs +2 -0
- package/esm2020/models/public_api.mjs +2 -0
- package/esm2020/models/reset-password-info.type.mjs +2 -0
- package/esm2020/public_api.mjs +4 -0
- package/esm2020/routing/config/default.mjs +4 -0
- package/esm2020/routing/config/interface.mjs +2 -0
- package/esm2020/routing/config/public_api.mjs +3 -0
- package/esm2020/routing/config/token.mjs +9 -0
- package/esm2020/routing/daffodil-auth-routing.mjs +5 -0
- package/esm2020/routing/guards/guest-only-guard-redirect.token.mjs +3 -0
- package/esm2020/routing/guards/guest-only.guard.mjs +42 -0
- package/esm2020/routing/guards/member-only-guard-redirect.token.mjs +3 -0
- package/esm2020/routing/guards/member-only.guard.mjs +42 -0
- package/esm2020/routing/guards/public_api.mjs +6 -0
- package/esm2020/routing/guards/reset-password.guard.mjs +32 -0
- package/esm2020/routing/index.mjs +2 -0
- package/esm2020/routing/module.mjs +35 -0
- package/esm2020/routing/public_api.mjs +4 -0
- package/esm2020/state/actions/auth.actions.mjs +75 -0
- package/esm2020/state/actions/login.actions.mjs +70 -0
- package/esm2020/state/actions/public_api.mjs +5 -0
- package/esm2020/state/actions/register.actions.mjs +41 -0
- package/esm2020/state/actions/reset-password.actions.mjs +79 -0
- package/esm2020/state/auth-state.module.mjs +48 -0
- package/esm2020/state/config/default.mjs +5 -0
- package/esm2020/state/config/public_api.mjs +3 -0
- package/esm2020/state/config/token.mjs +8 -0
- package/esm2020/state/config/type.mjs +2 -0
- package/esm2020/state/daffodil-auth-state.mjs +5 -0
- package/esm2020/state/effects/auth.effects.mjs +45 -0
- package/esm2020/state/effects/login.effects.mjs +37 -0
- package/esm2020/state/effects/register.effects.mjs +31 -0
- package/esm2020/state/effects/reset-password.effects.mjs +32 -0
- package/esm2020/state/facades/auth/facade.interface.mjs +2 -0
- package/esm2020/state/facades/auth/facade.mjs +28 -0
- package/esm2020/state/facades/auth/public_api.mjs +2 -0
- package/esm2020/state/facades/login/facade.interface.mjs +2 -0
- package/esm2020/state/facades/login/facade.mjs +28 -0
- package/esm2020/state/facades/login/public_api.mjs +2 -0
- package/esm2020/state/facades/public_api.mjs +5 -0
- package/esm2020/state/facades/register/facade.interface.mjs +2 -0
- package/esm2020/state/facades/register/facade.mjs +28 -0
- package/esm2020/state/facades/register/public_api.mjs +2 -0
- package/esm2020/state/facades/reset-password/facade.interface.mjs +2 -0
- package/esm2020/state/facades/reset-password/facade.mjs +29 -0
- package/esm2020/state/facades/reset-password/public_api.mjs +2 -0
- package/esm2020/state/index.mjs +2 -0
- package/esm2020/state/public_api.mjs +7 -0
- package/esm2020/state/reducers/auth/auth-initial-state.mjs +5 -0
- package/esm2020/state/reducers/auth/auth-reducer-state.interface.mjs +2 -0
- package/esm2020/state/reducers/auth/auth.reducer.mjs +25 -0
- package/esm2020/state/reducers/auth/public_api.mjs +3 -0
- package/esm2020/state/reducers/auth-feature-state.interface.mjs +2 -0
- package/esm2020/state/reducers/auth-reducers.mjs +11 -0
- package/esm2020/state/reducers/auth-store-feature-key.mjs +2 -0
- package/esm2020/state/reducers/login/login-initial-state.mjs +5 -0
- package/esm2020/state/reducers/login/login-reducer-state.interface.mjs +2 -0
- package/esm2020/state/reducers/login/login.reducer.mjs +28 -0
- package/esm2020/state/reducers/login/public_api.mjs +3 -0
- package/esm2020/state/reducers/public_api.mjs +7 -0
- package/esm2020/state/reducers/register/public_api.mjs +3 -0
- package/esm2020/state/reducers/register/register-initial-state.mjs +5 -0
- package/esm2020/state/reducers/register/register-reducer-state.interface.mjs +2 -0
- package/esm2020/state/reducers/register/register.reducer.mjs +25 -0
- package/esm2020/state/reducers/reset-password/initial-state.mjs +6 -0
- package/esm2020/state/reducers/reset-password/public_api.mjs +3 -0
- package/esm2020/state/reducers/reset-password/reducer.mjs +33 -0
- package/esm2020/state/reducers/reset-password/state.interface.mjs +2 -0
- package/esm2020/state/selectors/auth/auth.selector.mjs +17 -0
- package/esm2020/state/selectors/auth-all.selector.mjs +16 -0
- package/esm2020/state/selectors/auth-feature.selector.mjs +10 -0
- package/esm2020/state/selectors/login/login.selector.mjs +17 -0
- package/esm2020/state/selectors/public_api.mjs +2 -0
- package/esm2020/state/selectors/register/register.selector.mjs +17 -0
- package/esm2020/state/selectors/reset-password/selector.mjs +19 -0
- package/esm2020/state/testing/auth-testing.module.mjs +29 -0
- package/esm2020/state/testing/daffodil-auth-state-testing.mjs +5 -0
- package/esm2020/state/testing/index.mjs +2 -0
- package/esm2020/state/testing/mock-auth-facade.mjs +21 -0
- package/esm2020/state/testing/mock-login-facade.mjs +21 -0
- package/esm2020/state/testing/mock-register-facade.mjs +21 -0
- package/esm2020/state/testing/mock-reset-password-facade.mjs +22 -0
- package/esm2020/state/testing/public_api.mjs +6 -0
- package/esm2020/storage/auth-storage.service.mjs +30 -0
- package/esm2020/testing/daffodil-auth-testing.mjs +5 -0
- package/esm2020/testing/factories/account-registration.factory.mjs +25 -0
- package/esm2020/testing/factories/auth-token.factory.mjs +24 -0
- package/esm2020/testing/factories/public_api.mjs +4 -0
- package/esm2020/testing/factories/reset-password-info.factory.mjs +26 -0
- package/esm2020/testing/index.mjs +2 -0
- package/esm2020/testing/public_api.mjs +2 -0
- package/fesm2015/daffodil-auth-driver-in-memory.mjs +258 -0
- package/fesm2015/daffodil-auth-driver-in-memory.mjs.map +1 -0
- package/fesm2015/daffodil-auth-driver-magento.mjs +363 -0
- package/fesm2015/daffodil-auth-driver-magento.mjs.map +1 -0
- package/fesm2015/daffodil-auth-driver-testing.mjs +141 -0
- package/fesm2015/daffodil-auth-driver-testing.mjs.map +1 -0
- package/fesm2015/daffodil-auth-driver.mjs +70 -0
- package/fesm2015/daffodil-auth-driver.mjs.map +1 -0
- package/fesm2015/daffodil-auth-routing.mjs +158 -0
- package/fesm2015/daffodil-auth-routing.mjs.map +1 -0
- package/fesm2015/daffodil-auth-state-testing.mjs +106 -0
- package/fesm2015/daffodil-auth-state-testing.mjs.map +1 -0
- package/fesm2015/daffodil-auth-state.mjs +700 -0
- package/fesm2015/daffodil-auth-state.mjs.map +1 -0
- package/fesm2015/daffodil-auth-testing.mjs +74 -0
- package/fesm2015/daffodil-auth-testing.mjs.map +1 -0
- package/fesm2015/daffodil-auth.mjs +46 -0
- package/fesm2015/daffodil-auth.mjs.map +1 -0
- package/fesm2020/daffodil-auth-driver-in-memory.mjs +258 -0
- package/fesm2020/daffodil-auth-driver-in-memory.mjs.map +1 -0
- package/fesm2020/daffodil-auth-driver-magento.mjs +366 -0
- package/fesm2020/daffodil-auth-driver-magento.mjs.map +1 -0
- package/fesm2020/daffodil-auth-driver-testing.mjs +141 -0
- package/fesm2020/daffodil-auth-driver-testing.mjs.map +1 -0
- package/fesm2020/daffodil-auth-driver.mjs +70 -0
- package/fesm2020/daffodil-auth-driver.mjs.map +1 -0
- package/fesm2020/daffodil-auth-routing.mjs +152 -0
- package/fesm2020/daffodil-auth-routing.mjs.map +1 -0
- package/fesm2020/daffodil-auth-state-testing.mjs +106 -0
- package/fesm2020/daffodil-auth-state-testing.mjs.map +1 -0
- package/fesm2020/daffodil-auth-state.mjs +741 -0
- package/fesm2020/daffodil-auth-state.mjs.map +1 -0
- package/fesm2020/daffodil-auth-testing.mjs +74 -0
- package/fesm2020/daffodil-auth-testing.mjs.map +1 -0
- package/fesm2020/daffodil-auth.mjs +44 -0
- package/fesm2020/daffodil-auth.mjs.map +1 -0
- package/index.d.ts +1 -0
- package/injection-tokens/error-matcher.token.d.ts +7 -0
- package/injection-tokens/public_api.d.ts +1 -0
- package/models/account-registration.d.ts +2 -0
- package/models/auth-token.d.ts +3 -0
- package/models/login-info.d.ts +4 -0
- package/models/public_api.d.ts +4 -0
- package/models/reset-password-info.type.d.ts +14 -0
- package/package.json +115 -0
- package/public_api.d.ts +3 -0
- package/routing/config/default.d.ts +2 -0
- package/routing/config/interface.d.ts +9 -0
- package/routing/config/public_api.d.ts +3 -0
- package/routing/config/token.d.ts +6 -0
- package/routing/daffodil-auth-routing.d.ts +5 -0
- package/routing/guards/guest-only-guard-redirect.token.d.ts +2 -0
- package/routing/guards/guest-only.guard.d.ts +16 -0
- package/routing/guards/member-only-guard-redirect.token.d.ts +2 -0
- package/routing/guards/member-only.guard.d.ts +16 -0
- package/routing/guards/public_api.d.ts +5 -0
- package/routing/guards/reset-password.guard.d.ts +13 -0
- package/routing/index.d.ts +1 -0
- package/routing/module.d.ts +9 -0
- package/routing/package.json +10 -0
- package/routing/public_api.d.ts +3 -0
- package/state/actions/auth.actions.d.ts +62 -0
- package/state/actions/login.actions.d.ts +64 -0
- package/state/actions/public_api.d.ts +4 -0
- package/state/actions/register.actions.d.ts +40 -0
- package/state/actions/reset-password.actions.d.ts +72 -0
- package/state/auth-state.module.d.ts +11 -0
- package/state/config/default.d.ts +2 -0
- package/state/config/public_api.d.ts +3 -0
- package/state/config/token.d.ts +4 -0
- package/state/config/type.d.ts +7 -0
- package/state/daffodil-auth-state.d.ts +5 -0
- package/state/effects/auth.effects.d.ts +21 -0
- package/state/effects/login.effects.d.ts +19 -0
- package/state/effects/register.effects.d.ts +16 -0
- package/state/effects/reset-password.effects.d.ts +18 -0
- package/state/facades/auth/facade.d.ts +19 -0
- package/state/facades/auth/facade.interface.d.ts +8 -0
- package/state/facades/auth/public_api.d.ts +2 -0
- package/state/facades/login/facade.d.ts +18 -0
- package/state/facades/login/facade.interface.d.ts +8 -0
- package/state/facades/login/public_api.d.ts +2 -0
- package/state/facades/public_api.d.ts +4 -0
- package/state/facades/register/facade.d.ts +18 -0
- package/state/facades/register/facade.interface.d.ts +8 -0
- package/state/facades/register/public_api.d.ts +2 -0
- package/state/facades/reset-password/facade.d.ts +20 -0
- package/state/facades/reset-password/facade.interface.d.ts +10 -0
- package/state/facades/reset-password/public_api.d.ts +2 -0
- package/state/index.d.ts +1 -0
- package/state/package.json +10 -0
- package/state/public_api.d.ts +6 -0
- package/state/reducers/auth/auth-initial-state.d.ts +2 -0
- package/state/reducers/auth/auth-reducer-state.interface.d.ts +5 -0
- package/state/reducers/auth/auth.reducer.d.ts +3 -0
- package/state/reducers/auth/public_api.d.ts +3 -0
- package/state/reducers/auth-feature-state.interface.d.ts +14 -0
- package/state/reducers/auth-reducers.d.ts +3 -0
- package/state/reducers/auth-store-feature-key.d.ts +1 -0
- package/state/reducers/login/login-initial-state.d.ts +2 -0
- package/state/reducers/login/login-reducer-state.interface.d.ts +5 -0
- package/state/reducers/login/login.reducer.d.ts +4 -0
- package/state/reducers/login/public_api.d.ts +3 -0
- package/state/reducers/public_api.d.ts +7 -0
- package/state/reducers/register/public_api.d.ts +3 -0
- package/state/reducers/register/register-initial-state.d.ts +2 -0
- package/state/reducers/register/register-reducer-state.interface.d.ts +5 -0
- package/state/reducers/register/register.reducer.d.ts +4 -0
- package/state/reducers/reset-password/initial-state.d.ts +2 -0
- package/state/reducers/reset-password/public_api.d.ts +3 -0
- package/state/reducers/reset-password/reducer.d.ts +4 -0
- package/state/reducers/reset-password/state.interface.d.ts +7 -0
- package/state/selectors/auth/auth.selector.d.ts +10 -0
- package/state/selectors/auth-all.selector.d.ts +10 -0
- package/state/selectors/auth-feature.selector.d.ts +6 -0
- package/state/selectors/login/login.selector.d.ts +9 -0
- package/state/selectors/public_api.d.ts +1 -0
- package/state/selectors/register/register.selector.d.ts +10 -0
- package/state/selectors/reset-password/selector.d.ts +11 -0
- package/state/testing/auth-testing.module.d.ts +6 -0
- package/state/testing/daffodil-auth-state-testing.d.ts +5 -0
- package/state/testing/index.d.ts +1 -0
- package/state/testing/mock-auth-facade.d.ts +15 -0
- package/state/testing/mock-login-facade.d.ts +15 -0
- package/state/testing/mock-register-facade.d.ts +15 -0
- package/state/testing/mock-reset-password-facade.d.ts +16 -0
- package/state/testing/package.json +10 -0
- package/state/testing/public_api.d.ts +5 -0
- package/storage/auth-storage.service.d.ts +12 -0
- package/testing/daffodil-auth-testing.d.ts +5 -0
- package/testing/factories/account-registration.factory.d.ts +12 -0
- package/testing/factories/auth-token.factory.d.ts +11 -0
- package/testing/factories/public_api.d.ts +3 -0
- package/testing/factories/reset-password-info.factory.d.ts +13 -0
- package/testing/index.d.ts +1 -0
- package/testing/package.json +10 -0
- package/testing/public_api.d.ts +1 -0
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import { Action } from '@ngrx/store';
|
|
2
|
+
import { DaffStateError } from '@daffodil/core/state';
|
|
3
|
+
export declare enum DaffAuthActionTypes {
|
|
4
|
+
AuthGuardCheckAction = "[@daffodil/auth] Auth Guard Check Action",
|
|
5
|
+
AuthGuardCheckCompletionAction = "[@daffodil/auth] Auth Guard Check Completion Action",
|
|
6
|
+
AuthStorageFailureAction = "[@daffodil/auth] Auth Storage Failure Action",
|
|
7
|
+
AuthCheckAction = "[@daffodil/auth] Auth Check Action",
|
|
8
|
+
AuthCheckSuccessAction = "[@daffodil/auth] Auth Check Success Action",
|
|
9
|
+
AuthCheckFailureAction = "[@daffodil/auth] Auth Check Failure Action",
|
|
10
|
+
AuthCompleteAction = "[@daffodil/auth] Auth Complete Action"
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* An action triggered by guards to initialize an auth check request.
|
|
14
|
+
*/
|
|
15
|
+
export declare class DaffAuthGuardCheck implements Action {
|
|
16
|
+
readonly type = DaffAuthActionTypes.AuthGuardCheckAction;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* An action triggered on the completion of a guard token check.
|
|
20
|
+
*/
|
|
21
|
+
export declare class DaffAuthGuardCheckCompletion implements Action {
|
|
22
|
+
result: boolean;
|
|
23
|
+
readonly type = DaffAuthActionTypes.AuthGuardCheckCompletionAction;
|
|
24
|
+
constructor(result: boolean);
|
|
25
|
+
}
|
|
26
|
+
export declare class DaffAuthStorageFailure implements Action {
|
|
27
|
+
errorMessage: DaffStateError;
|
|
28
|
+
readonly type = DaffAuthActionTypes.AuthStorageFailureAction;
|
|
29
|
+
constructor(errorMessage: DaffStateError);
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* An action triggered to initialize an auth check request.
|
|
33
|
+
*/
|
|
34
|
+
export declare class DaffAuthCheck implements Action {
|
|
35
|
+
readonly type = DaffAuthActionTypes.AuthCheckAction;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* An action triggered upon a successful auth check.
|
|
39
|
+
*
|
|
40
|
+
* @param token - the customer access token
|
|
41
|
+
*/
|
|
42
|
+
export declare class DaffAuthCheckSuccess implements Action {
|
|
43
|
+
readonly type = DaffAuthActionTypes.AuthCheckSuccessAction;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* An action triggered upon a failed auth check request.
|
|
47
|
+
*
|
|
48
|
+
* @param errorMessage - an error message
|
|
49
|
+
*/
|
|
50
|
+
export declare class DaffAuthCheckFailure implements Action {
|
|
51
|
+
errorMessage: DaffStateError;
|
|
52
|
+
readonly type = DaffAuthActionTypes.AuthCheckFailureAction;
|
|
53
|
+
constructor(errorMessage: DaffStateError);
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* An action triggered when the user authentication flow is completed.
|
|
57
|
+
* The auth token is in storage at this point.
|
|
58
|
+
*/
|
|
59
|
+
export declare class DaffAuthComplete implements Action {
|
|
60
|
+
readonly type = DaffAuthActionTypes.AuthCompleteAction;
|
|
61
|
+
}
|
|
62
|
+
export declare type DaffAuthActions = DaffAuthGuardCheckCompletion | DaffAuthGuardCheck | DaffAuthStorageFailure | DaffAuthCheck | DaffAuthCheckSuccess | DaffAuthCheckFailure | DaffAuthComplete;
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { Action } from '@ngrx/store';
|
|
2
|
+
import { DaffLoginInfo, DaffAuthToken } from '@daffodil/auth';
|
|
3
|
+
import { DaffStateError } from '@daffodil/core/state';
|
|
4
|
+
export declare enum DaffAuthLoginActionTypes {
|
|
5
|
+
LoginAction = "[@daffodil/auth] Login Action",
|
|
6
|
+
LoginSuccessAction = "[@daffodil/auth] Login Success Action",
|
|
7
|
+
LoginFailureAction = "[@daffodil/auth] Login Failure Action",
|
|
8
|
+
LogoutAction = "[@daffodil/auth] Logout Action",
|
|
9
|
+
LogoutSuccessAction = "[@daffodil/auth] Logout Success Action",
|
|
10
|
+
LogoutFailureAction = "[@daffodil/auth] Logout Failure Action"
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* An action triggered to initialize a auth login request.
|
|
14
|
+
*/
|
|
15
|
+
export declare class DaffAuthLogin<T extends DaffLoginInfo = DaffLoginInfo> implements Action {
|
|
16
|
+
loginInfo: T;
|
|
17
|
+
readonly type = DaffAuthLoginActionTypes.LoginAction;
|
|
18
|
+
constructor(loginInfo: T);
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* An action triggered upon a successful auth login.
|
|
22
|
+
*
|
|
23
|
+
* @param token - the customer access token
|
|
24
|
+
*/
|
|
25
|
+
export declare class DaffAuthLoginSuccess<T extends DaffAuthToken = DaffAuthToken> implements Action {
|
|
26
|
+
auth: T;
|
|
27
|
+
readonly type = DaffAuthLoginActionTypes.LoginSuccessAction;
|
|
28
|
+
constructor(auth: T);
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* An action triggered upon a failed auth login request.
|
|
32
|
+
*
|
|
33
|
+
* @param errorMessage - an error message
|
|
34
|
+
*/
|
|
35
|
+
export declare class DaffAuthLoginFailure implements Action {
|
|
36
|
+
errorMessage: DaffStateError;
|
|
37
|
+
readonly type = DaffAuthLoginActionTypes.LoginFailureAction;
|
|
38
|
+
constructor(errorMessage: DaffStateError);
|
|
39
|
+
}
|
|
40
|
+
/**
|
|
41
|
+
* An action triggered to initialize a logout request.
|
|
42
|
+
*/
|
|
43
|
+
export declare class DaffAuthLogout implements Action {
|
|
44
|
+
readonly type = DaffAuthLoginActionTypes.LogoutAction;
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* An action triggered upon a successful logout.
|
|
48
|
+
*
|
|
49
|
+
* @param token - the customer access token
|
|
50
|
+
*/
|
|
51
|
+
export declare class DaffAuthLogoutSuccess implements Action {
|
|
52
|
+
readonly type = DaffAuthLoginActionTypes.LogoutSuccessAction;
|
|
53
|
+
}
|
|
54
|
+
/**
|
|
55
|
+
* An action triggered upon a failed logout request.
|
|
56
|
+
*
|
|
57
|
+
* @param errorMessage - an error message
|
|
58
|
+
*/
|
|
59
|
+
export declare class DaffAuthLogoutFailure implements Action {
|
|
60
|
+
errorMessage: DaffStateError;
|
|
61
|
+
readonly type = DaffAuthLoginActionTypes.LogoutFailureAction;
|
|
62
|
+
constructor(errorMessage: DaffStateError);
|
|
63
|
+
}
|
|
64
|
+
export declare type DaffAuthLoginActions<T extends DaffLoginInfo = DaffLoginInfo, U extends DaffAuthToken = DaffAuthToken> = DaffAuthLogin<T> | DaffAuthLoginSuccess<U> | DaffAuthLoginFailure | DaffAuthLogout | DaffAuthLogoutSuccess | DaffAuthLogoutFailure;
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { Action } from '@ngrx/store';
|
|
2
|
+
import { DaffAccountRegistration } from '@daffodil/auth';
|
|
3
|
+
import { DaffStateError } from '@daffodil/core/state';
|
|
4
|
+
export declare enum DaffAuthRegisterActionTypes {
|
|
5
|
+
RegisterAction = "[@daffodil/auth] Register Action",
|
|
6
|
+
RegisterSuccessAction = "[@daffodil/auth] Register Success Action",
|
|
7
|
+
RegisterFailureAction = "[@daffodil/auth] Register Failure Action"
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* An action triggered to initialize a auth register request.
|
|
11
|
+
*
|
|
12
|
+
* @param registration
|
|
13
|
+
*/
|
|
14
|
+
export declare class DaffAuthRegister<T extends DaffAccountRegistration = DaffAccountRegistration> implements Action {
|
|
15
|
+
registration: T;
|
|
16
|
+
autoLogin: boolean;
|
|
17
|
+
readonly type = DaffAuthRegisterActionTypes.RegisterAction;
|
|
18
|
+
constructor(registration: T, autoLogin?: boolean);
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* An action triggered upon a successful auth register request.
|
|
22
|
+
*
|
|
23
|
+
* @param token - the customer access token
|
|
24
|
+
*/
|
|
25
|
+
export declare class DaffAuthRegisterSuccess implements Action {
|
|
26
|
+
token?: string;
|
|
27
|
+
readonly type = DaffAuthRegisterActionTypes.RegisterSuccessAction;
|
|
28
|
+
constructor(token?: string);
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* An action triggered upon a failed auth request.
|
|
32
|
+
*
|
|
33
|
+
* @param errorMessage - an error message
|
|
34
|
+
*/
|
|
35
|
+
export declare class DaffAuthRegisterFailure implements Action {
|
|
36
|
+
errorMessage: DaffStateError;
|
|
37
|
+
readonly type = DaffAuthRegisterActionTypes.RegisterFailureAction;
|
|
38
|
+
constructor(errorMessage: DaffStateError);
|
|
39
|
+
}
|
|
40
|
+
export declare type DaffAuthRegisterActions<T extends DaffAccountRegistration = DaffAccountRegistration> = DaffAuthRegister<T> | DaffAuthRegisterSuccess | DaffAuthRegisterFailure;
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
import { Action } from '@ngrx/store';
|
|
2
|
+
import { DaffAuthResetPasswordInfo } from '@daffodil/auth';
|
|
3
|
+
import { DaffStateError } from '@daffodil/core/state';
|
|
4
|
+
export declare enum DaffAuthResetPasswordActionTypes {
|
|
5
|
+
SendResetEmailAction = "[@daffodil/auth] Send Reset Email Action",
|
|
6
|
+
SendResetEmailSuccessAction = "[@daffodil/auth] Send Reset Email Success Action",
|
|
7
|
+
SendResetEmailFailureAction = "[@daffodil/auth] Send Reset Email Failure Action",
|
|
8
|
+
ResetPasswordAction = "[@daffodil/auth] Reset Password Action",
|
|
9
|
+
ResetPasswordSuccessAction = "[@daffodil/auth] Reset Password Success Action",
|
|
10
|
+
ResetPasswordFailureAction = "[@daffodil/auth] Reset Password Failure Action",
|
|
11
|
+
ResetPasswordLandingAction = "[@daffodil/auth] Reset Password Landing Action"
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* An action triggered to send the specified customer an email to reset their password.
|
|
15
|
+
*/
|
|
16
|
+
export declare class DaffSendResetEmail implements Action {
|
|
17
|
+
email: string;
|
|
18
|
+
readonly type = DaffAuthResetPasswordActionTypes.SendResetEmailAction;
|
|
19
|
+
constructor(email: string);
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* An action triggered upon a successfully sent reset password email.
|
|
23
|
+
*/
|
|
24
|
+
export declare class DaffSendResetEmailSuccess implements Action {
|
|
25
|
+
readonly type = DaffAuthResetPasswordActionTypes.SendResetEmailSuccessAction;
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* An action triggered upon a failure to send the reset password email.
|
|
29
|
+
*
|
|
30
|
+
* @param errorMessage - an error message
|
|
31
|
+
*/
|
|
32
|
+
export declare class DaffSendResetEmailFailure implements Action {
|
|
33
|
+
errorMessage: DaffStateError;
|
|
34
|
+
readonly type = DaffAuthResetPasswordActionTypes.SendResetEmailFailureAction;
|
|
35
|
+
constructor(errorMessage: DaffStateError);
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* An action triggered to initialize a logout request.
|
|
39
|
+
*/
|
|
40
|
+
export declare class DaffResetPassword<T extends DaffAuthResetPasswordInfo = DaffAuthResetPasswordInfo> implements Action {
|
|
41
|
+
info: T;
|
|
42
|
+
autoLogin: boolean;
|
|
43
|
+
readonly type = DaffAuthResetPasswordActionTypes.ResetPasswordAction;
|
|
44
|
+
constructor(info: T, autoLogin?: boolean);
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* An action triggered upon a successful logout.
|
|
48
|
+
*/
|
|
49
|
+
export declare class DaffResetPasswordSuccess implements Action {
|
|
50
|
+
readonly type = DaffAuthResetPasswordActionTypes.ResetPasswordSuccessAction;
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
* An action triggered upon a failed logout request.
|
|
54
|
+
*
|
|
55
|
+
* @param errorMessage - an error message
|
|
56
|
+
*/
|
|
57
|
+
export declare class DaffResetPasswordFailure implements Action {
|
|
58
|
+
errorMessage: DaffStateError;
|
|
59
|
+
readonly type = DaffAuthResetPasswordActionTypes.ResetPasswordFailureAction;
|
|
60
|
+
constructor(errorMessage: DaffStateError);
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* An action triggered upon the user navigating to the reset password page from the link in their email.
|
|
64
|
+
*
|
|
65
|
+
* @param token - The token with which the password can be reset
|
|
66
|
+
*/
|
|
67
|
+
export declare class DaffResetPasswordLanding implements Action {
|
|
68
|
+
token: DaffAuthResetPasswordInfo['token'];
|
|
69
|
+
readonly type = DaffAuthResetPasswordActionTypes.ResetPasswordLandingAction;
|
|
70
|
+
constructor(token: DaffAuthResetPasswordInfo['token']);
|
|
71
|
+
}
|
|
72
|
+
export declare type DaffAuthResetPasswordActions<T extends DaffAuthResetPasswordInfo = DaffAuthResetPasswordInfo> = DaffSendResetEmail | DaffSendResetEmailSuccess | DaffSendResetEmailFailure | DaffResetPassword<T> | DaffResetPasswordSuccess | DaffResetPasswordFailure | DaffResetPasswordLanding;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ModuleWithProviders } from '@angular/core';
|
|
2
|
+
import { DaffAuthStateConfig } from './config/public_api';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
import * as i1 from "@ngrx/store";
|
|
5
|
+
import * as i2 from "@ngrx/effects";
|
|
6
|
+
export declare class DaffAuthStateModule {
|
|
7
|
+
static withConfig(config: DaffAuthStateConfig): ModuleWithProviders<DaffAuthStateModule>;
|
|
8
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DaffAuthStateModule, never>;
|
|
9
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<DaffAuthStateModule, never, [typeof i1.StoreFeatureModule, typeof i2.EffectsFeatureModule], never>;
|
|
10
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<DaffAuthStateModule>;
|
|
11
|
+
}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { InjectionToken, ValueProvider } from '@angular/core';
|
|
2
|
+
import { DaffAuthStateConfig } from './type';
|
|
3
|
+
export declare const DAFF_AUTH_STATE_CONFIG: InjectionToken<DaffAuthStateConfig>;
|
|
4
|
+
export declare const provideDaffAuthStateConfig: (config: DaffAuthStateConfig) => ValueProvider;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Actions } from '@ngrx/effects';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import { DaffAuthStorageService } from '@daffodil/auth';
|
|
4
|
+
import { DaffAuthServiceInterface } from '@daffodil/auth/driver';
|
|
5
|
+
import { ErrorTransformer } from '@daffodil/core/state';
|
|
6
|
+
import { DaffAuthCheckSuccess, DaffAuthCheckFailure, DaffAuthCheck, DaffAuthGuardCheckCompletion } from '../actions/public_api';
|
|
7
|
+
import { DaffAuthStateConfig } from '../config/public_api';
|
|
8
|
+
import * as i0 from "@angular/core";
|
|
9
|
+
export declare class DaffAuthEffects {
|
|
10
|
+
private actions$;
|
|
11
|
+
private authDriver;
|
|
12
|
+
private errorMatcher;
|
|
13
|
+
private storage;
|
|
14
|
+
private config;
|
|
15
|
+
constructor(actions$: Actions, authDriver: DaffAuthServiceInterface, errorMatcher: ErrorTransformer, storage: DaffAuthStorageService, config: DaffAuthStateConfig);
|
|
16
|
+
check$: Observable<DaffAuthCheckSuccess | DaffAuthCheckFailure>;
|
|
17
|
+
guardCheck$: Observable<DaffAuthGuardCheckCompletion>;
|
|
18
|
+
authCheckInterval$: Observable<DaffAuthCheck> & import("@ngrx/effects").CreateEffectMetadata;
|
|
19
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DaffAuthEffects, never>;
|
|
20
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<DaffAuthEffects>;
|
|
21
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Actions } from '@ngrx/effects';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import { DaffLoginInfo, DaffAuthToken, DaffAuthStorageService } from '@daffodil/auth';
|
|
4
|
+
import { DaffLoginServiceInterface } from '@daffodil/auth/driver';
|
|
5
|
+
import { ErrorTransformer } from '@daffodil/core/state';
|
|
6
|
+
import { DaffAuthLoginSuccess, DaffAuthLoginFailure, DaffAuthLogoutSuccess, DaffAuthLogoutFailure, DaffAuthStorageFailure, DaffAuthComplete } from '../actions/public_api';
|
|
7
|
+
import * as i0 from "@angular/core";
|
|
8
|
+
export declare class DaffAuthLoginEffects<T extends DaffLoginInfo = DaffLoginInfo, U extends DaffAuthToken = DaffAuthToken> {
|
|
9
|
+
private actions$;
|
|
10
|
+
private loginDriver;
|
|
11
|
+
private errorMatcher;
|
|
12
|
+
private storage;
|
|
13
|
+
constructor(actions$: Actions, loginDriver: DaffLoginServiceInterface<T, U>, errorMatcher: ErrorTransformer, storage: DaffAuthStorageService);
|
|
14
|
+
login$: Observable<DaffAuthLoginSuccess<U> | DaffAuthLoginFailure>;
|
|
15
|
+
logout$: Observable<DaffAuthLogoutSuccess | DaffAuthLogoutFailure>;
|
|
16
|
+
storeAuthToken$: Observable<DaffAuthStorageFailure | DaffAuthComplete> & import("@ngrx/effects").CreateEffectMetadata;
|
|
17
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DaffAuthLoginEffects<any, any>, never>;
|
|
18
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<DaffAuthLoginEffects<any, any>>;
|
|
19
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Actions } from '@ngrx/effects';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import { DaffAccountRegistration, DaffAuthStorageService } from '@daffodil/auth';
|
|
4
|
+
import { DaffRegisterServiceInterface } from '@daffodil/auth/driver';
|
|
5
|
+
import { ErrorTransformer } from '@daffodil/core/state';
|
|
6
|
+
import * as i0 from "@angular/core";
|
|
7
|
+
export declare class DaffAuthRegisterEffects<T extends DaffAccountRegistration = DaffAccountRegistration> {
|
|
8
|
+
private actions$;
|
|
9
|
+
private registerDriver;
|
|
10
|
+
private errorMatcher;
|
|
11
|
+
private storage;
|
|
12
|
+
constructor(actions$: Actions, registerDriver: DaffRegisterServiceInterface<T>, errorMatcher: ErrorTransformer, storage: DaffAuthStorageService);
|
|
13
|
+
register$: Observable<any>;
|
|
14
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DaffAuthRegisterEffects<any>, never>;
|
|
15
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<DaffAuthRegisterEffects<any>>;
|
|
16
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Actions } from '@ngrx/effects';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import { DaffAuthResetPasswordInfo, DaffAuthStorageService } from '@daffodil/auth';
|
|
4
|
+
import { DaffResetPasswordServiceInterface } from '@daffodil/auth/driver';
|
|
5
|
+
import { ErrorTransformer } from '@daffodil/core/state';
|
|
6
|
+
import { DaffResetPasswordSuccess, DaffResetPasswordFailure, DaffAuthComplete } from '../actions/public_api';
|
|
7
|
+
import * as i0 from "@angular/core";
|
|
8
|
+
export declare class DaffAuthResetPasswordEffects<T extends DaffAuthResetPasswordInfo = DaffAuthResetPasswordInfo> {
|
|
9
|
+
private actions$;
|
|
10
|
+
private driver;
|
|
11
|
+
private errorMatcher;
|
|
12
|
+
private storage;
|
|
13
|
+
constructor(actions$: Actions, driver: DaffResetPasswordServiceInterface<T>, errorMatcher: ErrorTransformer, storage: DaffAuthStorageService);
|
|
14
|
+
sendResetEmail$: Observable<any>;
|
|
15
|
+
resetPassword$: Observable<DaffAuthComplete | DaffResetPasswordSuccess | DaffResetPasswordFailure> & import("@ngrx/effects").CreateEffectMetadata;
|
|
16
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DaffAuthResetPasswordEffects<any>, never>;
|
|
17
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<DaffAuthResetPasswordEffects<any>>;
|
|
18
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Action, Store } from '@ngrx/store';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import { DaffAuthToken } from '@daffodil/auth';
|
|
4
|
+
import { DaffStateError } from '@daffodil/core/state';
|
|
5
|
+
import { DaffAuthFeatureState } from '../../reducers/public_api';
|
|
6
|
+
import { DaffAuthFacadeInterface } from './facade.interface';
|
|
7
|
+
import * as i0 from "@angular/core";
|
|
8
|
+
/**
|
|
9
|
+
* @inheritdoc
|
|
10
|
+
*/
|
|
11
|
+
export declare class DaffAuthFacade<T extends DaffAuthToken = DaffAuthToken> implements DaffAuthFacadeInterface {
|
|
12
|
+
private store;
|
|
13
|
+
loading$: Observable<boolean>;
|
|
14
|
+
errors$: Observable<DaffStateError[]>;
|
|
15
|
+
constructor(store: Store<DaffAuthFeatureState>);
|
|
16
|
+
dispatch(action: Action): void;
|
|
17
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DaffAuthFacade<any>, never>;
|
|
18
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<DaffAuthFacade<any>>;
|
|
19
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Action } from '@ngrx/store';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import { DaffStoreFacade, DaffStateError } from '@daffodil/core/state';
|
|
4
|
+
export interface DaffAuthFacadeInterface extends DaffStoreFacade<Action> {
|
|
5
|
+
loading$: Observable<boolean>;
|
|
6
|
+
errors$: Observable<DaffStateError[]>;
|
|
7
|
+
dispatch(action: Action): void;
|
|
8
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Action, Store } from '@ngrx/store';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import { DaffStateError } from '@daffodil/core/state';
|
|
4
|
+
import { DaffAuthFeatureState } from '../../reducers/public_api';
|
|
5
|
+
import { DaffAuthLoginFacadeInterface } from './facade.interface';
|
|
6
|
+
import * as i0 from "@angular/core";
|
|
7
|
+
/**
|
|
8
|
+
* @inheritdoc
|
|
9
|
+
*/
|
|
10
|
+
export declare class DaffAuthLoginFacade implements DaffAuthLoginFacadeInterface {
|
|
11
|
+
private store;
|
|
12
|
+
loading$: Observable<boolean>;
|
|
13
|
+
errors$: Observable<DaffStateError[]>;
|
|
14
|
+
constructor(store: Store<DaffAuthFeatureState>);
|
|
15
|
+
dispatch(action: Action): void;
|
|
16
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DaffAuthLoginFacade, never>;
|
|
17
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<DaffAuthLoginFacade>;
|
|
18
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Action } from '@ngrx/store';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import { DaffStoreFacade, DaffStateError } from '@daffodil/core/state';
|
|
4
|
+
export interface DaffAuthLoginFacadeInterface extends DaffStoreFacade<Action> {
|
|
5
|
+
loading$: Observable<boolean>;
|
|
6
|
+
errors$: Observable<DaffStateError[]>;
|
|
7
|
+
dispatch(action: Action): void;
|
|
8
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Action, Store } from '@ngrx/store';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import { DaffStateError } from '@daffodil/core/state';
|
|
4
|
+
import { DaffAuthFeatureState } from '../../reducers/public_api';
|
|
5
|
+
import { DaffAuthRegisterFacadeInterface } from './facade.interface';
|
|
6
|
+
import * as i0 from "@angular/core";
|
|
7
|
+
/**
|
|
8
|
+
* @inheritdoc
|
|
9
|
+
*/
|
|
10
|
+
export declare class DaffAuthRegisterFacade implements DaffAuthRegisterFacadeInterface {
|
|
11
|
+
private store;
|
|
12
|
+
loading$: Observable<boolean>;
|
|
13
|
+
errors$: Observable<DaffStateError[]>;
|
|
14
|
+
constructor(store: Store<DaffAuthFeatureState>);
|
|
15
|
+
dispatch(action: Action): void;
|
|
16
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DaffAuthRegisterFacade, never>;
|
|
17
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<DaffAuthRegisterFacade>;
|
|
18
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Action } from '@ngrx/store';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import { DaffStoreFacade, DaffStateError } from '@daffodil/core/state';
|
|
4
|
+
export interface DaffAuthRegisterFacadeInterface extends DaffStoreFacade<Action> {
|
|
5
|
+
loading$: Observable<boolean>;
|
|
6
|
+
errors$: Observable<DaffStateError[]>;
|
|
7
|
+
dispatch(action: Action): void;
|
|
8
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { Action, Store } from '@ngrx/store';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import { DaffAuthResetPasswordInfo } from '@daffodil/auth';
|
|
4
|
+
import { DaffStateError } from '@daffodil/core/state';
|
|
5
|
+
import { DaffAuthFeatureState } from '../../reducers/public_api';
|
|
6
|
+
import { DaffAuthResetPasswordFacadeInterface } from './facade.interface';
|
|
7
|
+
import * as i0 from "@angular/core";
|
|
8
|
+
/**
|
|
9
|
+
* @inheritdoc
|
|
10
|
+
*/
|
|
11
|
+
export declare class DaffAuthResetPasswordFacade implements DaffAuthResetPasswordFacadeInterface {
|
|
12
|
+
private store;
|
|
13
|
+
token$: Observable<DaffAuthResetPasswordInfo['token']>;
|
|
14
|
+
loading$: Observable<boolean>;
|
|
15
|
+
errors$: Observable<DaffStateError[]>;
|
|
16
|
+
constructor(store: Store<DaffAuthFeatureState>);
|
|
17
|
+
dispatch(action: Action): void;
|
|
18
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DaffAuthResetPasswordFacade, never>;
|
|
19
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<DaffAuthResetPasswordFacade>;
|
|
20
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Action } from '@ngrx/store';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import { DaffAuthResetPasswordInfo } from '@daffodil/auth';
|
|
4
|
+
import { DaffStoreFacade, DaffStateError } from '@daffodil/core/state';
|
|
5
|
+
export interface DaffAuthResetPasswordFacadeInterface extends DaffStoreFacade<Action> {
|
|
6
|
+
token$: Observable<DaffAuthResetPasswordInfo['token']>;
|
|
7
|
+
loading$: Observable<boolean>;
|
|
8
|
+
errors$: Observable<DaffStateError[]>;
|
|
9
|
+
dispatch(action: Action): void;
|
|
10
|
+
}
|
package/state/index.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './public_api';
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@daffodil/auth/state",
|
|
3
|
+
"module": "../fesm2015/daffodil-auth-state.mjs",
|
|
4
|
+
"es2020": "../fesm2020/daffodil-auth-state.mjs",
|
|
5
|
+
"esm2020": "../esm2020/state/daffodil-auth-state.mjs",
|
|
6
|
+
"fesm2020": "../fesm2020/daffodil-auth-state.mjs",
|
|
7
|
+
"fesm2015": "../fesm2015/daffodil-auth-state.mjs",
|
|
8
|
+
"typings": "daffodil-auth-state.d.ts",
|
|
9
|
+
"sideEffects": false
|
|
10
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { DAFF_AUTH_STORE_FEATURE_KEY } from './auth-store-feature-key';
|
|
2
|
+
import { DaffAuthReducerState } from './auth/public_api';
|
|
3
|
+
import { DaffAuthLoginReducerState } from './login/public_api';
|
|
4
|
+
import { DaffAuthRegisterReducerState } from './register/public_api';
|
|
5
|
+
import { DaffAuthResetPasswordReducerState } from './reset-password/public_api';
|
|
6
|
+
export interface DaffAuthFeatureState {
|
|
7
|
+
auth: DaffAuthReducerState;
|
|
8
|
+
login: DaffAuthLoginReducerState;
|
|
9
|
+
register: DaffAuthRegisterReducerState;
|
|
10
|
+
resetPassword: DaffAuthResetPasswordReducerState;
|
|
11
|
+
}
|
|
12
|
+
export interface DaffAuthStateRootSlice {
|
|
13
|
+
[DAFF_AUTH_STORE_FEATURE_KEY]: DaffAuthFeatureState;
|
|
14
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const DAFF_AUTH_STORE_FEATURE_KEY = "daffAuth";
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { DaffLoginInfo, DaffAuthToken } from '@daffodil/auth';
|
|
2
|
+
import { DaffAuthLoginActions } from '../../actions/public_api';
|
|
3
|
+
import { DaffAuthLoginReducerState } from './login-reducer-state.interface';
|
|
4
|
+
export declare function daffAuthLoginReducer<T extends DaffLoginInfo, U extends DaffAuthToken>(state: DaffAuthLoginReducerState, action: DaffAuthLoginActions<T, U>): DaffAuthLoginReducerState;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export * from './auth/public_api';
|
|
2
|
+
export * from './login/public_api';
|
|
3
|
+
export * from './register/public_api';
|
|
4
|
+
export * from './reset-password/public_api';
|
|
5
|
+
export { DAFF_AUTH_STORE_FEATURE_KEY } from './auth-store-feature-key';
|
|
6
|
+
export { daffAuthReducers } from './auth-reducers';
|
|
7
|
+
export { DaffAuthFeatureState, DaffAuthStateRootSlice, } from './auth-feature-state.interface';
|