@annalib/anna-cognito-lib 0.3.2 → 0.4.0
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/esm2020/lib/anna-cognito-lib.module.mjs +19 -4
- package/esm2020/lib/components/forgot-password/forgot-password.component.mjs +22 -54
- package/esm2020/lib/components/login/login.component.mjs +9 -6
- package/esm2020/lib/components/powered-by-logo-template/powered-by-logo-template.component.mjs +15 -0
- package/esm2020/lib/components/set-new-password/set-new-password.component.mjs +8 -5
- package/esm2020/lib/components/surewaves-year-logo/surewaves-year-logo.component.mjs +15 -0
- package/esm2020/lib/components/verify-and-set-new-password/verify-and-set-new-password.component.mjs +7 -6
- package/esm2020/lib/components/version-and-term-policy/version-and-term-policy.component.mjs +18 -0
- package/esm2020/lib/config/auth-service.token.mjs +1 -1
- package/esm2020/lib/config/library.config.mjs +2 -1
- package/esm2020/lib/constants/loginConstant.mjs +1 -5
- package/esm2020/lib/models/auth.model.mjs +1 -7
- package/esm2020/lib/services/auth.service.mjs +7 -44
- package/esm2020/public-api.mjs +4 -1
- package/fesm2015/annalib-anna-cognito-lib.mjs +87 -113
- package/fesm2015/annalib-anna-cognito-lib.mjs.map +1 -1
- package/fesm2020/annalib-anna-cognito-lib.mjs +87 -113
- package/fesm2020/annalib-anna-cognito-lib.mjs.map +1 -1
- package/lib/anna-cognito-lib.module.d.ts +7 -4
- package/lib/components/forgot-password/forgot-password.component.d.ts +1 -7
- package/lib/components/powered-by-logo-template/powered-by-logo-template.component.d.ts +8 -0
- package/lib/components/surewaves-year-logo/surewaves-year-logo.component.d.ts +9 -0
- package/lib/components/version-and-term-policy/version-and-term-policy.component.d.ts +10 -0
- package/lib/config/auth-service.token.d.ts +0 -1
- package/lib/config/library.config.d.ts +1 -0
- package/lib/constants/loginConstant.d.ts +0 -4
- package/lib/models/auth.model.d.ts +0 -5
- package/lib/services/auth.service.d.ts +1 -8
- package/package.json +1 -1
- package/public-api.d.ts +3 -0
|
@@ -6,7 +6,6 @@ export interface IAuthService {
|
|
|
6
6
|
isLoggingIn: boolean;
|
|
7
7
|
onSuccessfulAuthenticatingUser(result: any): void;
|
|
8
8
|
isUsernameAvailable(username: string): Observable<any>;
|
|
9
|
-
getUserState(username: string): Observable<any>;
|
|
10
9
|
navigateBasedOnUserRole(loginUserData: any): void;
|
|
11
10
|
getPublicIp(): string;
|
|
12
11
|
sendRegenerationEmail(userCode: string): void;
|
|
@@ -17,9 +17,6 @@ export declare class LoginConstant {
|
|
|
17
17
|
static readonly userNamePasswordIncorrect = "Incorrect username or password";
|
|
18
18
|
static readonly userNotFound = "No registered user found";
|
|
19
19
|
static readonly loginAgain: string;
|
|
20
|
-
static readonly firstTimeLoginUserTempPasswordMsg = "You are logging in for the first time. Kindly use the temporary password provided in the welcome email, to login to your account. ";
|
|
21
|
-
static readonly tempPasswordExpiryError = "Temporary password has expired and must be reset by an administrator.";
|
|
22
|
-
static readonly tempPasswordOnExpiryErrorMsg = "Password has expired. A new password has been sent to your registered email. Kindly login again with new link and credentials.";
|
|
23
20
|
static readonly verifyAndSetNewPasswordheading: string;
|
|
24
21
|
static readonly verifyAndSetNewPasswordMessage: string;
|
|
25
22
|
static readonly pleaseEnterItBelow = ". Please enter it below.";
|
|
@@ -30,7 +27,6 @@ export declare class LoginConstant {
|
|
|
30
27
|
static readonly attemptLimitExceeded = "You have exceeded the maximum number of allowed attempts. Please try again after 15 minutes.";
|
|
31
28
|
static readonly attemptMessage = " of 5. The OTP entered is incorrect. Please try again with the right one.";
|
|
32
29
|
static readonly sessionExpired = "The session has expired. Please try again.";
|
|
33
|
-
static readonly sessionExpiredError = "Your session has expired. Please login again";
|
|
34
30
|
static readonly forgotPasswordHeading = "Forgot your password?";
|
|
35
31
|
static readonly forgotPasswordMessage = "Please enter your username.";
|
|
36
32
|
static readonly forgotPasswordButton: string;
|
|
@@ -5,14 +5,12 @@ import { UserPoolInformation } from "../models/auth.model";
|
|
|
5
5
|
import { AnnaLibAclService } from './acl.service';
|
|
6
6
|
import { LibraryConfig } from '../config/library.config';
|
|
7
7
|
import { IAuthService } from '../config/auth-service.token';
|
|
8
|
-
import { ToastrService } from 'ngx-toastr';
|
|
9
8
|
import * as i0 from "@angular/core";
|
|
10
9
|
export declare class AnnaLibAuthService {
|
|
11
10
|
private router;
|
|
12
11
|
aclService: AnnaLibAclService;
|
|
13
12
|
libraryConfig: LibraryConfig;
|
|
14
13
|
httpClient: HttpClient;
|
|
15
|
-
private toastr;
|
|
16
14
|
consumingProjectAuthService: IAuthService;
|
|
17
15
|
poolData: UserPoolInformation;
|
|
18
16
|
userPool: CognitoUserPool;
|
|
@@ -32,8 +30,7 @@ export declare class AnnaLibAuthService {
|
|
|
32
30
|
userName: any;
|
|
33
31
|
accessTokenTimerId: any;
|
|
34
32
|
IdToken: any;
|
|
35
|
-
|
|
36
|
-
constructor(router: Router, aclService: AnnaLibAclService, libraryConfig: LibraryConfig, httpClient: HttpClient, toastr: ToastrService, consumingProjectAuthService: IAuthService);
|
|
33
|
+
constructor(router: Router, aclService: AnnaLibAclService, libraryConfig: LibraryConfig, httpClient: HttpClient, consumingProjectAuthService: IAuthService);
|
|
37
34
|
ngOnInit(): void;
|
|
38
35
|
/***
|
|
39
36
|
1. takes user pool data (userPool ID and client ID)
|
|
@@ -53,10 +50,6 @@ export declare class AnnaLibAuthService {
|
|
|
53
50
|
verifyCode(verificationCode: string, newPassword: string): void;
|
|
54
51
|
forgotPasswordError(err: any, noOfAttempts: number): string;
|
|
55
52
|
getAllCognitoTokenAndGroups(token: CognitoUserSession): void;
|
|
56
|
-
expiryAllExistingCurrentSession(newPassword: string): void;
|
|
57
|
-
setUserDetails(username: string, newPassword: string): void;
|
|
58
|
-
onLoginInCogntioToGetAccessToken(): void;
|
|
59
|
-
onCallGlobalSignout(): void;
|
|
60
53
|
static ɵfac: i0.ɵɵFactoryDeclaration<AnnaLibAuthService, never>;
|
|
61
54
|
static ɵprov: i0.ɵɵInjectableDeclaration<AnnaLibAuthService>;
|
|
62
55
|
}
|
package/package.json
CHANGED
package/public-api.d.ts
CHANGED
|
@@ -4,6 +4,9 @@ export * from './lib/components/forgot-password/forgot-password.component';
|
|
|
4
4
|
export * from './lib/components/set-new-password/set-new-password.component';
|
|
5
5
|
export * from './lib/components/password-matching/password-matching.component';
|
|
6
6
|
export * from './lib/components/verify-and-set-new-password/verify-and-set-new-password.component';
|
|
7
|
+
export * from './lib/components/version-and-term-policy/version-and-term-policy.component';
|
|
8
|
+
export * from './lib/components/powered-by-logo-template/powered-by-logo-template.component';
|
|
9
|
+
export * from './lib/components/surewaves-year-logo/surewaves-year-logo.component';
|
|
7
10
|
export * from './lib/services/auth.service';
|
|
8
11
|
export * from './lib/services/acl.service';
|
|
9
12
|
export * from './lib/config/auth-service.token';
|