From edf49c40190a9740a1d0e822009b56ba0cad02e6 Mon Sep 17 00:00:00 2001 From: "konstantina.galouni" Date: Wed, 28 Feb 2024 17:42:58 +0200 Subject: [PATCH] [develop | DONE | CHANGED]: sdg-fos-suggest.component.ts: Added field "isOpen: boolean = false;" and check if isOpen to show modal content | resultLanding.component: Removed old unused code and old comments, updated and added more checks e.g. not load content of modals if they are not open. --- .../sdg-fos-suggest.component.ts | 53 ++--- .../result/resultLanding.component.html | 193 ++---------------- .../result/resultLanding.component.ts | 5 + 3 files changed, 48 insertions(+), 203 deletions(-) diff --git a/landingPages/landing-utils/sdg-fos-suggest/sdg-fos-suggest.component.ts b/landingPages/landing-utils/sdg-fos-suggest/sdg-fos-suggest.component.ts index 6c0d059a..3a547a27 100644 --- a/landingPages/landing-utils/sdg-fos-suggest/sdg-fos-suggest.component.ts +++ b/landingPages/landing-utils/sdg-fos-suggest/sdg-fos-suggest.component.ts @@ -15,34 +15,36 @@ import {StringUtils} from "../../../utils/string-utils.class"; template: ` - - -
-
- -
Thank you for your feedback.
-
Before sending us your options, would you like to leave us your e-mail to notify you about the reporting status?
-
- (Optional) + + + +
+
+ +
Thank you for your feedback.
+
Before sending us your options, would you like to leave us your e-mail to notify you about the reporting status?
+
+ (Optional) +
+
+ + +
+
+ +

Your feedback is successfully received and it will soon be reviewed by our graph experts!

+ +
+ -
- - -
- - -

Your feedback is successfully received and it will soon be reviewed by our graph experts!

- -
-
-
+
` }) @@ -62,6 +64,7 @@ export class SdgFosSuggestComponent { public sent: boolean = false; public error: boolean = false; subscriptions: Subscription[] = []; + isOpen: boolean = false; constructor(private emailService: EmailService, private fb: FormBuilder, private cdr: ChangeDetectorRef) {} diff --git a/landingPages/result/resultLanding.component.html b/landingPages/result/resultLanding.component.html index 1d64f1f3..3a2de7e2 100644 --- a/landingPages/result/resultLanding.component.html +++ b/landingPages/result/resultLanding.component.html @@ -4,8 +4,8 @@ [searchActionRoute]="properties.searchLinkToResults"> -
-
+
+
- - - -
@@ -166,54 +102,6 @@
- - -
- - - - - - - -
- - -
-
- -
-
@@ -232,48 +120,15 @@ [publiclyFunded]="resultLandingInfo.publiclyFunded" [projects]="resultLandingInfo.fundedByProjects"> - - -
- - -
- -
+ +
-
- - - - - -
-
- -
- -
-
-
-
-
+
- -
@@ -886,16 +719,18 @@ - + - + + + -
+
@@ -1327,6 +1162,7 @@
+ - + + \ No newline at end of file diff --git a/landingPages/result/resultLanding.component.ts b/landingPages/result/resultLanding.component.ts index f51645f3..d1eb7126 100644 --- a/landingPages/result/resultLanding.component.ts +++ b/landingPages/result/resultLanding.component.ts @@ -74,6 +74,8 @@ export class ResultLandingComponent { public linkToSearchPage: string = null; public citeThisClicked: boolean; + public addThisClicked: boolean; + public descriptionClicked: boolean; // Metrics tab variables public metricsClicked: boolean; @@ -864,6 +866,7 @@ export class ResultLandingComponent { } public openAddThisModal() { + this.addThisClicked = true; this.addThisModal.cancelButton = false; this.addThisModal.okButton = false; this.addThisModal.alertTitle = "Share this " + this.getTypeName() + " in your social networks"; @@ -1076,6 +1079,7 @@ export class ResultLandingComponent { this.sdgFosSuggest.subjectType="fos"; } this.cdr.detectChanges(); + this.sdgFosSuggest.isOpen = true; this.sdgFosSuggest.openSelectionModal(); } @@ -1090,6 +1094,7 @@ export class ResultLandingComponent { } public openDescriptionModal() { + this.descriptionClicked = true; this.descriptionModal.alertFooter = false; this.descriptionModal.alertTitle = "Abstract"; this.descriptionModal.open();