Skip to content

Commit

Permalink
Merge branch 'main' into lmendoza/deep-worktype-menu
Browse files Browse the repository at this point in the history
  • Loading branch information
leomendoza123 committed Jan 3, 2025
2 parents fcf2578 + 4ece34e commit b66149d
Show file tree
Hide file tree
Showing 20 changed files with 159 additions and 160 deletions.
32 changes: 32 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,35 @@
## v2.109.11 - 2024-12-24

[Full Changelog](https://github.com/ORCID/orcid-angular/compare/v2.109.10...v2.109.11)

## v2.109.10 - 2024-12-17

[Full Changelog](https://github.com/ORCID/orcid-angular/compare/v2.109.9...v2.109.10)

## v2.109.9 - 2024-12-17

[Full Changelog](https://github.com/ORCID/orcid-angular/compare/v2.109.8...v2.109.9)

## v2.109.8 - 2024-12-16

[Full Changelog](https://github.com/ORCID/orcid-angular/compare/v2.109.7...v2.109.8)

## v2.109.7 - 2024-12-16

[Full Changelog](https://github.com/ORCID/orcid-angular/compare/v2.109.6...v2.109.7)

## v2.109.6 - 2024-12-12

[Full Changelog](https://github.com/ORCID/orcid-angular/compare/v2.109.5...v2.109.6)

## v2.109.5 - 2024-12-12

[Full Changelog](https://github.com/ORCID/orcid-angular/compare/v2.109.4...v2.109.5)

## v2.109.4 - 2024-12-11

[Full Changelog](https://github.com/ORCID/orcid-angular/compare/v2.109.3...v2.109.4)

## v2.109.3 - 2024-12-09

[Full Changelog](https://github.com/ORCID/orcid-angular/compare/v2.109.2...v2.109.3)
Expand Down
20 changes: 10 additions & 10 deletions documentation.json

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -98,24 +98,12 @@
Deactivate ORCID account
</button>
</div>
<div
*ngIf="deactivatedEmail"
class="info margin-bottom-16"
[ngClass]="{
'orc-font-body-small': !isMobile,
'orc-font-small-print': isMobile
}"
>
<div>
<mat-icon class="large-material-icon">info</mat-icon>
<app-alert-message *ngIf="deactivatedEmail">
<div content>
<ng-container i18n="@@account.andEmailDeactivateWasSend">
An account deactivation email has been sent to
</ng-container>
<strong> {{ deactivatedEmail }} </strong>
</div>
<div class="col l11 m6 s3">
<div>
<ng-container i18n="@@account.andEmailDeactivateWasSend">
An account deactivation email has been sent to
</ng-container>
<strong> {{ deactivatedEmail }} </strong>
</div>
</div>
</div>
</app-alert-message>
</app-settings-panels-data>
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,7 @@ ul {
margin-top: 16px;
}

.info {
padding: 16px;
app-alert-message {
margin-top: 16px;
margin-bottom: 16px;
border: solid 2px;
border-radius: 4px;
display: flex;

p {
margin: 0;
}
margin-bottom: 8px;
}
Original file line number Diff line number Diff line change
Expand Up @@ -7,20 +7,6 @@
$warn: map-get($theme, accent);
$foreground: map-get($theme, foreground);
$background: map-get($theme, background);

.info {
border-color: mat.get-color-from-palette(
$foreground,
'state-notice-dark'
) !important;

mat-icon {
color: mat.get-color-from-palette(
$foreground,
'state-notice-dark'
) !important;
}
}
}

@include settings-defaults-email-frequency($orcid-app-theme);
9 changes: 4 additions & 5 deletions src/app/cdk/alert-message/alert-message.component.scss
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,13 @@
}

.content {
::ng-deep {
> :first-child {
margin-top: 8px;
}
}
line-height: 21px !important;
}

.title:not(:empty) + .content:not(:empty) {
margin-top: 8px;
}

.alert-container {
border: solid 2px;
border-radius: 4px;
Expand Down
8 changes: 1 addition & 7 deletions src/app/cdk/panel/panel/panel.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -290,15 +290,9 @@ export class PanelComponent implements OnInit {
.subscribe()
break
case 'peer-review':
const peerReviewPutCodes = []
if (this.elements) {
this.elements.putCodes.forEach((putCode) => {
peerReviewPutCodes.push(putCode)
})
}
this._peerReviewService
.updateVisibility(
peerReviewPutCodes.join(),
this.elements.groupIdValue,
visibility,
this.elements?.groupId
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -315,9 +315,8 @@ <h2 class="orc-font-body-large" i18n="@@side-bar.emailAddressesUppercase">
[name]="orcidEmailValidation"
[isEmailOrDomain]="true"
[date]="
domain.createdDate
!domain.generatedByScript && domain.createdDate
| monthDayYearDateToString
| verificationDateCutoff
"
[isLastItem]="true"
>
Expand Down
16 changes: 13 additions & 3 deletions src/app/cdk/side-bar/modals/modal-email/modal-email.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -486,7 +486,11 @@ export class ModalEmailComponent implements OnInit, OnDestroy {

if (domain) {
const remainingEmailsHaveDomain = this.emails.find((email) =>
email ? email.verified && email.value.split('@')[1] === domain : false
email
? email.verified &&
(email.value.split('@')[1].endsWith('.' + domain) ||
email.value.split('@')[1] === domain)
: false
)
if (!remainingEmailsHaveDomain) {
this.verifiedDomains = this.verifiedDomains.filter(
Expand Down Expand Up @@ -579,7 +583,10 @@ export class ModalEmailComponent implements OnInit, OnDestroy {
if (controlKey.startsWith('emailInput')) {
const control = this.emailsForm.get(controlKey).value

if (control.email.split('@')[1] === domain) {
if (
control.email.split('@')[1].endsWith('.' + domain) ||
control.email.split('@')[1] === domain
) {
visibilities.push(control.visibility)
}
}
Expand Down Expand Up @@ -612,7 +619,10 @@ export class ModalEmailComponent implements OnInit, OnDestroy {
Object.keys(this.emailsForm.controls).forEach((controlKey) => {
if (controlKey.startsWith('emailInput')) {
const control = this.emailsForm.get(controlKey)
if (control.value.email.split('@')[1] === domain) {
if (
control.value.email.split('@')[1].endsWith('.' + domain) ||
control.value.email.split('@')[1] === domain
) {
if (this.isEmailVerified(control.value.email)) {
visibilities.push(control.value.visibility)
}
Expand Down
3 changes: 1 addition & 2 deletions src/app/cdk/side-bar/side-bar/side-bar.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -192,9 +192,8 @@ <h4 header i18n="@@side-bar.verifiedEmailDomains">
[name]="orcidEmailValidation"
[isEmailOrDomain]="true"
[date]="
domain.createdDate
!domain.generatedByScript && domain.createdDate
| monthDayYearDateToString
| verificationDateCutoff
"
[isLastItem]="true"
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,9 +76,10 @@ <h3 title class="orc-font-body" i18n="@@side-bar.pleaseVerify">
</div>
</ng-container>
</app-alert-message>
<app-alert-message *ngIf="emailVerified" type="success">
<h3 title class="orc-font-body" i18n="@@myOrcidAlerts.emailVerified">
Thank you for verifying your email
</h3>
</app-alert-message>
</ng-container>

<app-alert-message *ngIf="emailVerified" type="success">
<h3 title class="orc-font-body" i18n="@@myOrcidAlerts.emailVerified">
Thank you for verifying your email
</h3>
</app-alert-message>
5 changes: 3 additions & 2 deletions src/app/core/record-peer-review/record-peer-review.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -122,12 +122,13 @@ export class RecordPeerReviewService {
groupId?: any
): Observable<any> {
return this._http
.get(
.post(
environment.API_WEB +
'peer-reviews/' +
putCode +
'/visibility/' +
visibility
visibility,
null
)
.pipe(
retry(3),
Expand Down
5 changes: 4 additions & 1 deletion src/app/core/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,10 @@ export const setProfessionalEmails = (
): EmailsEndpoint => {
emails?.emailDomains?.forEach((domain) => {
emails?.emails?.forEach((email) => {
if (email?.value?.includes(domain?.value)) {
if (
email?.value?.split('@')[1].endsWith('.' + domain?.value) ||
email?.value?.split('@')[1] === domain?.value
) {
email.professionalEmail = true
}
})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -490,7 +490,10 @@ <h3 class="orc-font-body" i18n="@@developerTools.exampleCode">
</ng-container>
</ng-container>

<app-terms-of-use (developerToolsEnable)="ngOnInit()"></app-terms-of-use>
<app-terms-of-use
*ngIf="!developerToolsEnable && !this.loadingUserDevTolsState"
(developerToolsEnable)="ngOnInit()"
></app-terms-of-use>
</main>
</div>
</div>
10 changes: 5 additions & 5 deletions src/app/record/components/work-form/work-form/work-type-menu.ts
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,10 @@ export const WorkTypeMenu: DeepSelectMenu[] = [
label: WorkTypesLabels[WorkTypes.newspaperArticle],
value: WorkTypes.newspaperArticle,
},
/// No value for: Talk, interview, podcast or speech
{
label: WorkTypesLabels[WorkTypes.lectureSpeech],
value: WorkTypes.lectureSpeech,
},
{ label: WorkTypesLabels[WorkTypes.website], value: WorkTypes.website },
{
divider: true,
Expand Down Expand Up @@ -281,10 +284,7 @@ export const WorkTypeMenu: DeepSelectMenu[] = [
value: WorkCategories.teachingAndSupervision,
description: $localize`:@@works.teachingDescription:Working with students`,
content: [
{
label: WorkTypesLabels[WorkTypes.lectureSpeech],
value: WorkTypes.lectureSpeech, /// RENAME from "lecture/speech" to "speech"
},
// No value for: Speech ??
/// No value for: Teaching material ??
{
value: WorkTypes.supervisedStudentPublication,
Expand Down
Loading

0 comments on commit b66149d

Please sign in to comment.