this._togglz.getTogglz().pipe(first())), tap((togglz) => { - if (togglz.messages['NEW_RECORD_HEADER_WITH_SUMMARY'] === 'true') { - this.newRecordHeaderWithSummaryTogglz = true - } if (togglz.messages['ORCID_ANGULAR_HELP_HERO'] === 'true') { if ( !this.publicOrcid && diff --git a/src/app/register2/components/backend-error/backend-error.component.ts b/src/app/register2/components/backend-error/backend-error.component.ts index ee8ab31c66..fc457bde7c 100644 --- a/src/app/register2/components/backend-error/backend-error.component.ts +++ b/src/app/register2/components/backend-error/backend-error.component.ts @@ -4,7 +4,6 @@ import { take } from 'rxjs/operators' import { PlatformInfoService } from 'src/app/cdk/platform-info' import { ApplicationRoutes } from 'src/app/constants' import { RegisterBackendErrors } from 'src/app/types/register.local' -import { TogglzService } from '../../../core/togglz/togglz.service' @Component({ selector: 'app-backend-error', templateUrl: './backend-error.component.html', @@ -16,7 +15,6 @@ export class BackendErrorComponent implements OnInit { _errorCode: string @Input() nextButtonWasClicked = false @Input() showEmailAlreadyExistUntilNextButtonWasClicked = false - registrationTogglz = false @Input() set errorCode(errorCode: string) { @@ -33,14 +31,9 @@ export class BackendErrorComponent implements OnInit { unrecognizedError = false constructor( private _platformInfo: PlatformInfoService, - private _router: Router, - private _togglz: TogglzService + private _router: Router ) {} ngOnInit() { - this._togglz - .getStateOf('REGISTRATION_2_0') - .pipe(take(1)) - .subscribe((value) => (this.registrationTogglz = value)) if (!(this.errorCode in RegisterBackendErrors)) { this.unrecognizedError = true } diff --git a/src/app/register2/components/step-a/step-a.component.html b/src/app/register2/components/step-a/step-a.component.html index 7ef359ca78..4d18982117 100644 --- a/src/app/register2/components/step-a/step-a.component.html +++ b/src/app/register2/components/step-a/step-a.component.html @@ -21,20 +21,9 @@

-

+

Step 1 of 5 - Names and emails

-

- Step 1 of 4 - Names and emails -

diff --git a/src/app/register2/components/step-a/step-a.component.ts b/src/app/register2/components/step-a/step-a.component.ts index b9a657cde7..40e5870d80 100644 --- a/src/app/register2/components/step-a/step-a.component.ts +++ b/src/app/register2/components/step-a/step-a.component.ts @@ -27,7 +27,6 @@ import { BaseStepDirective } from '../BaseStep' export class StepAComponent extends BaseStepDirective implements AfterViewInit { @ViewChild('firstInput') firstInput: ElementRef - @Input() togglzregistration21: boolean @Input() reactivation: ReactivationLocal nextButtonWasClicked: boolean diff --git a/src/app/register2/components/step-b/step-b.component.html b/src/app/register2/components/step-b/step-b.component.html index a4f13e5967..169dbafa7a 100644 --- a/src/app/register2/components/step-b/step-b.component.html +++ b/src/app/register2/components/step-b/step-b.component.html @@ -21,20 +21,9 @@

-

+

Step 2 of 5 - Password

-

- Step 2 of 4 - Password -

diff --git a/src/app/register2/components/step-b/step-b.component.ts b/src/app/register2/components/step-b/step-b.component.ts index 782f7ff963..7a74c962a6 100644 --- a/src/app/register2/components/step-b/step-b.component.ts +++ b/src/app/register2/components/step-b/step-b.component.ts @@ -15,7 +15,6 @@ import { BaseStepDirective } from '../BaseStep' export class StepBComponent extends BaseStepDirective { @Input() personalData @Input() reactivation: ReactivationLocal - @Input() togglzregistration21: boolean nextButtonWasClicked = false diff --git a/src/app/register2/components/step-c/step-c.component.html b/src/app/register2/components/step-c/step-c.component.html index c7772a6951..644a256f0c 100644 --- a/src/app/register2/components/step-c/step-c.component.html +++ b/src/app/register2/components/step-c/step-c.component.html @@ -27,20 +27,9 @@

-

+

Step 4 of 5 - Visibility

-

- Step 3 of 4 - Visibility -

diff --git a/src/app/register2/components/step-c/step-c.component.ts b/src/app/register2/components/step-c/step-c.component.ts index 991b0787c3..4060b11ccd 100644 --- a/src/app/register2/components/step-c/step-c.component.ts +++ b/src/app/register2/components/step-c/step-c.component.ts @@ -15,7 +15,6 @@ import { BaseStepDirective } from '../BaseStep' export class StepCComponent extends BaseStepDirective { @Input() loading @Input() reactivation: ReactivationLocal - @Input() togglzregistration21: boolean constructor() { super() diff --git a/src/app/register2/components/step-d/step-d.component.html b/src/app/register2/components/step-d/step-d.component.html index 01f09eb1f9..afbf43998e 100644 --- a/src/app/register2/components/step-d/step-d.component.html +++ b/src/app/register2/components/step-d/step-d.component.html @@ -27,20 +27,9 @@

-

+

Step 5 of 5 - Terms and conditions

-

- Step 4 of 4 - Terms and conditions -

diff --git a/src/app/register2/components/step-d/step-d.component.ts b/src/app/register2/components/step-d/step-d.component.ts index 20cf6ec58f..8f18e56db3 100644 --- a/src/app/register2/components/step-d/step-d.component.ts +++ b/src/app/register2/components/step-d/step-d.component.ts @@ -15,7 +15,6 @@ import { BaseStepDirective } from '../BaseStep' export class StepDComponent extends BaseStepDirective { @Input() loading @Input() reactivation: ReactivationLocal - @Input() togglzregistration21: boolean nextButtonWasClicked = false diff --git a/src/app/register2/pages/register/register2.component.html b/src/app/register2/pages/register/register2.component.html index 765f6c37df..4c0247616c 100644 --- a/src/app/register2/pages/register/register2.component.html +++ b/src/app/register2/pages/register/register2.component.html @@ -27,7 +27,6 @@ [(formGroup)]="FormGroupStepA" [reactivation]="reactivation" #stepComponentA - [togglzregistration21]="registration21" > @@ -39,11 +38,9 @@ [(formGroup)]="FormGroupStepB" [personalData]="personalData" [reactivation]="reactivation" - [togglzregistration21]="registration21" > @@ -64,7 +61,6 @@ [(formGroup)]="FormGroupStepC" [loading]="loading" [reactivation]="reactivation" - [togglzregistration21]="registration21" > @@ -72,7 +68,6 @@ >Visibility and terms { this.platform = platform @@ -95,9 +92,6 @@ export class Register2Component implements OnInit, AfterViewInit { }) } ngOnInit() { - this._togglz.getStateOf('REGISTRATION_2_1').subscribe((value) => { - this.registration21 = value - }) this._register.getRegisterForm().subscribe() this.FormGroupStepA = this._formBuilder.group({ diff --git a/src/app/sign-in/components/errors/print-errors/print-errors.component.html b/src/app/sign-in/components/errors/print-errors/print-errors.component.html index a97d1a30f2..acd8979050 100644 --- a/src/app/sign-in/components/errors/print-errors/print-errors.component.html +++ b/src/app/sign-in/components/errors/print-errors/print-errors.component.html @@ -1,176 +1,133 @@ - - - error - - Incorrect username and/or password - - - - error - - This account is deprecated. Please refer to account: - - {{ orcidPrimaryDeprecated }} - - - error - - The ORCID record exists but has not been claimed. Would you like to - - resend the claim email? +
+ error - - - error - - Invalid ORCID iD, please - - contact support - - - -
+
+
- error -
-
-
-

- - - The email address - - - The Orcid iD - - {{ email }} - is already associated with +

+ + + The email address + + + The Orcid iD + + {{ email }} + is already associated with + + an unclaimed + + a deactivated + + ORCID record. + + + You cannot sign in to ORCID with this email address until you have + claimed the record. an unclaimed + i18n="@@ngOrcid.signin.cannotSignInToOrcidWithId" + *ngIf="!isEmail" + > + You cannot sign in to ORCID with this iD until you have claimed + the record. + + a deactivated + i18n="@@ngOrcid.signin.needToReactivateAccount" + *ngIf="isEmail" + > + You will need to reactivate the account before you can sign in + with this email address. - ORCID record. - - - You cannot sign in to ORCID with this email address until you - have claimed the record. - - - You cannot sign in to ORCID with this iD until you have claimed - the record. - - - - - You will need to reactivate the account before you can sign in - with this email address. - - - You will need to reactivate the account before you can sign in - with this iD. - - - - - - This ORCID account has been deprecated. The active account is  {{ orcidPrimaryDeprecated }} - -

-
- -
-

- - To start reactivation please enter an email address associated with - this account in the 'Email or ORCID iD' field above. - -

-
+ You will need to reactivate the account before you can sign in + with this iD. + +
+ + + + This ORCID account has been deprecated. The active account is  {{ orcidPrimaryDeprecated }} + +

+
-
-

- - If you no longer have access to any of the email addresses - associated with the deactivated account please - - contact the support team -

-
+
+

+ + To start reactivation please enter an email address associated with + this account in the 'Email or ORCID iD' field above. + +

+
-
+
+

+ + If you no longer have access to any of the email addresses associated + with the deactivated account please + - Claim your ORCID recordcontact the support team - - - Reactivate the ORCID record associated with this email address - - - Reactivate the ORCID record associated with this iD - - - +

+ + + Reactivate the ORCID record associated with this iD + + + + Sign in to the active ORCID account
-
+
diff --git a/src/app/sign-in/components/errors/print-errors/print-errors.component.ts b/src/app/sign-in/components/errors/print-errors/print-errors.component.ts index 8ee868de03..0d0d6e5c5a 100644 --- a/src/app/sign-in/components/errors/print-errors/print-errors.component.ts +++ b/src/app/sign-in/components/errors/print-errors/print-errors.component.ts @@ -27,7 +27,6 @@ export class PrintErrorsComponent implements OnInit { @Input() showInvalidUser: boolean @Input() orcidPrimaryDeprecated: string @Input() email: string - @Input() signInUpdatesV1Togglz: boolean @Output() signInActiveAccount = new EventEmitter() @Output() deactivatedAccount = new EventEmitter() diff --git a/src/app/sign-in/components/form-sign-in/form-sign-in.component.html b/src/app/sign-in/components/form-sign-in/form-sign-in.component.html index d4af05f8f6..db7b832b6f 100644 --- a/src/app/sign-in/components/form-sign-in/form-sign-in.component.html +++ b/src/app/sign-in/components/form-sign-in/form-sign-in.component.html @@ -1,240 +1,137 @@ - - - - Email or 16-digit ORCID iD - + +
+ Email  or  ORCID iD + + - example@email.com or 0000-0001-2345-6789 - + + For example: joe@institution.edu or 0000-1234-5678-9101 + - Email or 16-digit ORCID iD is required - + Please enter your email address or your ORCID iD + - Use the format example@email.com or 0000-0001-2345-6789 - - + Please enter a valid email address or ORCID iD, for example: + joe@institution.edu or 0000-1234-5678-9101 + - + +
+
+ - Password + >Password + + - - - Passwords must be 256 characters or less. Please - - - reset your password - - - to sign in. - - - - - - -
- Email  or  ORCID iD - - - - - For example: joe@institution.edu or 0000-1234-5678-9101 - - - Please enter your email address or your ORCID iD - - - Please enter a valid email address or ORCID iD, for example: - joe@institution.edu or 0000-1234-5678-9101 - - - - -
-
- Password - - - - -
+
+
+ error +
+
- error -
-
-
-

- Your password is more than 256 characters long. - You cannot sign in to this ORCID account until you have reset - your password. -

-
-
- + Your password is more than 256 characters long. - Reset your passwordYou cannot sign in to this ORCID account until you have reset + your password. -
+

+
+
- - +
+ - - - - Forgot your password or ORCID ID? -
-
- - Don't have an ORCID iD yet? - - Register now - -
-
diff --git a/src/app/sign-in/components/form-sign-in/form-sign-in.component.ts b/src/app/sign-in/components/form-sign-in/form-sign-in.component.ts index 1693643870..26df8dc973 100644 --- a/src/app/sign-in/components/form-sign-in/form-sign-in.component.ts +++ b/src/app/sign-in/components/form-sign-in/form-sign-in.component.ts @@ -1,5 +1,4 @@ import { - AfterViewInit, ChangeDetectorRef, Component, ElementRef, @@ -21,7 +20,6 @@ import { catchError, first, map, takeUntil, tap } from 'rxjs/operators' import { ApplicationRoutes, isRedirectToTheAuthorizationPage, - isValidOrcidFormat, } from 'src/app/constants' import { UserService } from 'src/app/core' import { OauthParameters, RequestInfoForm } from 'src/app/types' @@ -52,11 +50,10 @@ import { SnackbarService } from 'src/app/cdk/snackbar/snackbar.service' ], preserveWhitespaces: true, }) -export class FormSignInComponent implements OnInit, AfterViewInit, OnDestroy { +export class FormSignInComponent implements OnInit, OnDestroy { @ViewChild('firstInput') firstInput: ElementRef @Input() signInType: TypeSignIn @Input() signInData: SignInData - @Input() signInUpdatesV1Togglz: boolean @Output() isOauthError = new EventEmitter() @Output() show2FAEmitter = new EventEmitter() @Output() loading = new EventEmitter() @@ -180,13 +177,6 @@ export class FormSignInComponent implements OnInit, AfterViewInit, OnDestroy { this.$destroy.complete() } - ngAfterViewInit(): void { - if (!this.signInUpdatesV1Togglz) { - this.firstInput.nativeElement.focus() - this.cd.detectChanges() - } - } - onSubmit() { this.addUsernameValidation() diff --git a/src/app/sign-in/components/social/social.component.html b/src/app/sign-in/components/social/social.component.html index 6753d4a648..bbe6b8c7eb 100644 --- a/src/app/sign-in/components/social/social.component.html +++ b/src/app/sign-in/components/social/social.component.html @@ -2,33 +2,18 @@ mat-raised-button id="access-through-your-institution-button" (click)="accessThroughInstitution()" - class="mat-button-wrap-text-with-icon mobile-fixed-width mat-elevation-z0" + class="mat-button-wrap-text-with-icon mobile-fixed-width mat-elevation-z0 institutional" [ngClass]="{ - institution: !signInUpdatesV1Togglz, - institutional: signInUpdatesV1Togglz, - mobile: signInUpdatesV1Togglz && !platform.columns12 + mobile: !platform.columns12 }" type="button" [attr.aria-label]="labelInstitutionalButton" > Institutional - - Access through your institution - - + Sign in through your institution @@ -40,7 +25,6 @@ class="google mat-button-wrap-text-with-icon mobile-fixed-width mat-elevation-z0" type="submit" [attr.aria-label]="labelGoogleButton" - [ngClass]="{ google: signInUpdatesV1Togglz }" > Google @@ -48,23 +32,3 @@ -
- - - -
diff --git a/src/app/sign-in/components/social/social.component.ts b/src/app/sign-in/components/social/social.component.ts index a5b34d7154..95b668d525 100644 --- a/src/app/sign-in/components/social/social.component.ts +++ b/src/app/sign-in/components/social/social.component.ts @@ -15,8 +15,6 @@ import { SignInService } from '../../../core/sign-in/sign-in.service' styleUrls: ['./social.component.scss', './social.component.scss-theme.scss'], }) export class SocialComponent implements OnInit { - @Input() signInUpdatesV1Togglz: boolean - platform: PlatformInfo baseUri: string csrf: string diff --git a/src/app/sign-in/pages/sign-in/sign-in.component.html b/src/app/sign-in/pages/sign-in/sign-in.component.html index 727e781c97..0dfb5e1dee 100644 --- a/src/app/sign-in/pages/sign-in/sign-in.component.html +++ b/src/app/sign-in/pages/sign-in/sign-in.component.html @@ -1,78 +1,12 @@
-
- - - - -
- -
- Sign in to ORCID -
-
- - - - - -

or

- -
- -
- - -
-
- + { - this.loadingTogglz = false - this.signInUpdatesV1Togglz = value - }) - combineLatest([this._userInfo.getUserSession(), this._platformInfo.get()]) .pipe(first()) .subscribe(([session, platform]) => {