From 655483b8e2f01d9faf5845771c5d60805acbc9bb Mon Sep 17 00:00:00 2001 From: "k.triantafyllou" Date: Thu, 3 Aug 2023 13:11:19 +0300 Subject: [PATCH] Dateset Edtitor: Scroll to top in Main info. Add checkVisibility in recursion of progress bar status calculation. Increase time of selected entry in tableofcontents --- .../app/ui/dataset/dataset-wizard/dataset-wizard.component.ts | 1 + .../form-progress-indication.component.ts | 4 ++-- .../tableOfContentsMaterial/table-of-contents.ts | 2 +- dmp-frontend/src/assets/config/config.json | 2 +- 4 files changed, 5 insertions(+), 4 deletions(-) diff --git a/dmp-frontend/src/app/ui/dataset/dataset-wizard/dataset-wizard.component.ts b/dmp-frontend/src/app/ui/dataset/dataset-wizard/dataset-wizard.component.ts index 8f33c15d8..7e6de2aa8 100644 --- a/dmp-frontend/src/app/ui/dataset/dataset-wizard/dataset-wizard.component.ts +++ b/dmp-frontend/src/app/ui/dataset/dataset-wizard/dataset-wizard.component.ts @@ -1239,6 +1239,7 @@ export class DatasetWizardComponent extends CheckDeactivateBaseComponent impleme this.step = index + (selected.type === ToCEntryType.FieldSet?1:0.5); } else { this.step = 0; + this.resetScroll(); } } } diff --git a/dmp-frontend/src/app/ui/misc/dataset-description-form/components/form-progress-indication/form-progress-indication.component.ts b/dmp-frontend/src/app/ui/misc/dataset-description-form/components/form-progress-indication/form-progress-indication.component.ts index 732b71e8d..dd3cfa289 100644 --- a/dmp-frontend/src/app/ui/misc/dataset-description-form/components/form-progress-indication/form-progress-indication.component.ts +++ b/dmp-frontend/src/app/ui/misc/dataset-description-form/components/form-progress-indication/form-progress-indication.component.ts @@ -179,12 +179,12 @@ export class FormProgressIndicationComponent extends BaseComponent implements On if(!checkVisibility || (!formControl.get('id')?.value || this.visibilityRulesService.checkElementVisibility(formControl.get('id').value))) { Object.keys(formControl.controls).forEach(item => { const control = formControl.get(item); - valueCurrent = valueCurrent + this.countFormControlsRequiredFieldsForTotal(control); + valueCurrent = valueCurrent + this.countFormControlsRequiredFieldsForTotal(control, checkVisibility); }); } } else if (formControl instanceof FormArray) { formControl.controls.forEach(item => { - valueCurrent = valueCurrent + this.countFormControlsRequiredFieldsForTotal(item); + valueCurrent = valueCurrent + this.countFormControlsRequiredFieldsForTotal(item, checkVisibility); }); } return valueCurrent; diff --git a/dmp-frontend/src/app/ui/misc/dataset-description-form/tableOfContentsMaterial/table-of-contents.ts b/dmp-frontend/src/app/ui/misc/dataset-description-form/tableOfContentsMaterial/table-of-contents.ts index 7188b965c..cfdeffefa 100644 --- a/dmp-frontend/src/app/ui/misc/dataset-description-form/tableOfContentsMaterial/table-of-contents.ts +++ b/dmp-frontend/src/app/ui/misc/dataset-description-form/tableOfContentsMaterial/table-of-contents.ts @@ -449,7 +449,7 @@ export class TableOfContents extends BaseComponent implements OnInit, OnChanges this.entrySelected.emit({entry: entry, execute: execute}); setTimeout(() => { this.isSelecting = false; - }, 200); + }, 600); } } diff --git a/dmp-frontend/src/assets/config/config.json b/dmp-frontend/src/assets/config/config.json index 3b2190325..87c1adf67 100644 --- a/dmp-frontend/src/assets/config/config.json +++ b/dmp-frontend/src/assets/config/config.json @@ -53,7 +53,7 @@ "loginProviders": { "enabled": [1, 2, 3, 4, 5, 6, 7, 8], "facebookConfiguration": { "clientId": "" }, - "googleConfiguration": { "clientId": "" }, + "googleConfiguration": { "clientId": "524432312250-sc9qsmtmbvlv05r44onl6l93ia3k9deo.apps.googleusercontent.com" }, "linkedInConfiguration": { "clientId": "", "oauthUrl": "https://www.linkedin.com/oauth/v2/authorization",