From b20fcfa219860a522f97e83572a3735e7aa172ce Mon Sep 17 00:00:00 2001 From: argirok Date: Tue, 5 Apr 2022 18:36:08 +0300 Subject: [PATCH] more layout changes for the linking (eg filters, icons, etc) --- .../claimProjectSearchForm.component.html | 14 ++++---- .../claimResultSearchForm.component.html | 14 ++++---- claims/claim-utils/claimResults.component.ts | 2 +- .../insertClaim/insertClaim.component.ts | 25 ++++++------- claims/linking/linkingGeneric.component.css | 0 claims/linking/linkingGeneric.component.html | 21 ++++++----- claims/linking/linkingGeneric.component.ts | 6 +--- .../ClaimEntityProjectMetadata.component.ts | 6 ++-- .../ClaimEntityResultMetadata.component.ts | 10 +++--- .../selected/ClaimEntityTitle.component.ts | 12 ++++--- .../selected/metadataPreview.component.html | 35 ++++++++++++------- .../selected/metadataPreview.module.ts | 17 ++++----- .../selected/selectedResults.component.html | 18 ++++++---- .../selected/selectedResults.component.ts | 3 +- sharedComponents/stepper/step.component.ts | 4 +-- 15 files changed, 98 insertions(+), 89 deletions(-) create mode 100644 claims/linking/linkingGeneric.component.css diff --git a/claims/claim-utils/claimProjectSearchForm.component.html b/claims/claim-utils/claimProjectSearchForm.component.html index 8c567946..d3fdcaa5 100644 --- a/claims/claim-utils/claimProjectSearchForm.component.html +++ b/claims/claim-utils/claimProjectSearchForm.component.html @@ -34,7 +34,7 @@
-
+ + <!– if no grid on the div above, remove it and move class 'selectedFilterLabel' on top span –> @@ -82,14 +82,14 @@
-
+
-->
- +
- +
-->
-
@@ -164,8 +164,8 @@
- +
-
+
diff --git a/claims/claim-utils/claimResults.component.ts b/claims/claim-utils/claimResults.component.ts index 1d68dba9..631f6a3f 100644 --- a/claims/claim-utils/claimResults.component.ts +++ b/claims/claim-utils/claimResults.component.ts @@ -10,7 +10,7 @@ declare var UIkit: any;
-
+
{{(!entity.result) ? entity.type : ((entity.result && entity.result.source == 'openaire') ? entity.type : (entity.result && entity.result.source + ' result'))}}
diff --git a/claims/linking/insertClaim/insertClaim.component.ts b/claims/linking/insertClaim/insertClaim.component.ts index ebd98c0b..55e4831d 100644 --- a/claims/linking/insertClaim/insertClaim.component.ts +++ b/claims/linking/insertClaim/insertClaim.component.ts @@ -20,9 +20,10 @@ import {Subscriber} from "rxjs"; selector: 'claim-insert', template: ` - -
- +
+ +

All the links you provided will be published in the OpenAIRE platform.
@@ -34,17 +35,11 @@ import {Subscriber} from "rxjs"; Do you confirm the information you provide is valid?

-
- + + CONFIRM LINKING + +
` @@ -91,7 +86,9 @@ export class ClaimInsertComponent { private errorInRecords = []; public insert() { - this.confirmOpen(); + if(this.claiming) { + this.confirmOpen(); + } } saveAndNavigate(){ localStorage.setItem(this.localStoragePrefix + "results", JSON.stringify(this.results)); diff --git a/claims/linking/linkingGeneric.component.css b/claims/linking/linkingGeneric.component.css new file mode 100644 index 00000000..e69de29b diff --git a/claims/linking/linkingGeneric.component.html b/claims/linking/linkingGeneric.component.html index 94e04283..3210daba 100644 --- a/claims/linking/linkingGeneric.component.html +++ b/claims/linking/linkingGeneric.component.html @@ -40,7 +40,7 @@
- +
-
+ style="z-index: 0" class="uk-card uk-card-default linkingBasket">
    @@ -119,11 +119,11 @@
+ [enableRemove]="false" type="source" > + [enableRemove]="true" type="source">
@@ -150,7 +150,7 @@ Basket reached the size limit. No more entities can be added.
+ [localStoragePrefix]="localStoragePrefix+'results'" type="target">
No entities to link with the sources. Start adding entities from the left panel. @@ -164,8 +164,8 @@
+ class=" nextStep uk-margin-small-top uk-padding-small " [class.active]="(sources.length)>0" [class.disabled]="(sources.length) == 0" + (click)="stepHasChanged('target') ">
STEP 2 - LINK SOURCES TO ENTITIES @@ -177,9 +177,8 @@
+ class=" nextStep uk-margin-small-top uk-padding-small " [class.active]="(results.length)>0" [class.disabled]="(results.length) == 0" + style="height:auto !important; " (click)="stepHasChanged('claim')">
STEP {{inlineEntity?'2':'3'}} - FINALISE AND FINISH diff --git a/claims/linking/linkingGeneric.component.ts b/claims/linking/linkingGeneric.component.ts index 747b1e36..5e736303 100644 --- a/claims/linking/linkingGeneric.component.ts +++ b/claims/linking/linkingGeneric.component.ts @@ -19,11 +19,7 @@ declare var UIkit:any; @Component({ selector: 'linking-generic', templateUrl: 'linkingGeneric.component.html', - styles:[ ` - - - - `] + styleUrls:[ 'linkingGeneric.component.css'] }) export class LinkingGenericComponent { diff --git a/claims/linking/selected/ClaimEntityProjectMetadata.component.ts b/claims/linking/selected/ClaimEntityProjectMetadata.component.ts index 5ac502af..3522238c 100644 --- a/claims/linking/selected/ClaimEntityProjectMetadata.component.ts +++ b/claims/linking/selected/ClaimEntityProjectMetadata.component.ts @@ -8,16 +8,16 @@ import {ClaimEntity} from '../../claim-utils/claimHelper.class';
- Funder: {{entity.project.funderName}} + Funder: {{entity.project.funderName}}
- GrandID: {{entity.project.code}} + GrandID: {{entity.project.code}}
Duration: {{(entity.project.startDate) ? entity.project.startDate : 'Unknown'}}{{'-' + ((entity.project.endDate) ? entity.project.endDate : 'Unknown')}} + class="uk-text-meta uk-margin-small-right">Duration: {{(entity.project.startDate) ? entity.project.startDate : 'Unknown'}}{{'-' + ((entity.project.endDate) ? entity.project.endDate : 'Unknown')}}
diff --git a/claims/linking/selected/ClaimEntityResultMetadata.component.ts b/claims/linking/selected/ClaimEntityResultMetadata.component.ts index a8be5cef..8f74c504 100644 --- a/claims/linking/selected/ClaimEntityResultMetadata.component.ts +++ b/claims/linking/selected/ClaimEntityResultMetadata.component.ts @@ -7,22 +7,22 @@ import {ClaimEntity} from '../../claim-utils/claimHelper.class'; `
- Authors: + Authors: {{sliceArray(entity.result.authors)}}
- Editors: + Editors: {{sliceArray(entity.result.editors)}}
Publisher: {{entity.result.publisher}} + class="uk-text-meta uk-margin-small-right uk-margin-small-bottom">Publisher: {{entity.result.publisher}} Journal: {{entity.result.journal}} + class="uk-text-meta uk-margin-small-right uk-margin-small-bottom">Journal: {{entity.result.journal}}
- Published: Published: {{entity.result.date}}
{{getProjectDurationMessage(entity)}}
diff --git a/claims/linking/selected/ClaimEntityTitle.component.ts b/claims/linking/selected/ClaimEntityTitle.component.ts index 44c56264..40c4c64f 100644 --- a/claims/linking/selected/ClaimEntityTitle.component.ts +++ b/claims/linking/selected/ClaimEntityTitle.component.ts @@ -6,14 +6,15 @@ import {StringUtils} from "../../../utils/string-utils.class"; selector: 'claim-title', template: ` -
- {{entity.title ? sliceString(entity.title) : '[No title available]'}} + ` @@ -58,7 +60,7 @@ export class ClaimEntityTitleComponent { } sliceString(mystr:string): string { if(this.slice){ - return StringUtils.sliceString(mystr,this.sliceSize); + // return StringUtils.sliceString(mystr,this.sliceSize); } return mystr; } diff --git a/claims/linking/selected/metadataPreview.component.html b/claims/linking/selected/metadataPreview.component.html index 14613363..96d55086 100644 --- a/claims/linking/selected/metadataPreview.component.html +++ b/claims/linking/selected/metadataPreview.component.html @@ -38,13 +38,22 @@ -
- -
- - +
+
+ insert_drive_file + +
+
+
+ +
+ + +
+
+
@@ -67,7 +76,13 @@
-
+ +
+ insert_drive_file + +
+
+ @@ -256,10 +271,6 @@
-
-
-
-
-
-
+
diff --git a/claims/linking/selected/metadataPreview.module.ts b/claims/linking/selected/metadataPreview.module.ts index 8d9174e9..1603eb2e 100644 --- a/claims/linking/selected/metadataPreview.module.ts +++ b/claims/linking/selected/metadataPreview.module.ts @@ -10,16 +10,17 @@ import { MatFormFieldModule } from '@angular/material/form-field'; import { MatInputModule } from '@angular/material/input'; import { MatSelectModule } from '@angular/material/select'; import {HelperModule} from "../../../utils/helper/helper.module"; +import {SelectedPublicationsModule} from "./selectedResults.module"; @NgModule({ - imports: [ - SharedModule, - AlertModalModule, - ClaimEntitiesMetadataModule, - InsertClaimsModule, - MatDatepickerModule, MatNativeDateModule, MatFormFieldModule, MatInputModule, MatSelectModule, - HelperModule - ], + imports: [ + SharedModule, + AlertModalModule, + ClaimEntitiesMetadataModule, + InsertClaimsModule, + MatDatepickerModule, MatNativeDateModule, MatFormFieldModule, MatInputModule, MatSelectModule, + HelperModule, SelectedPublicationsModule + ], declarations: [MetadataPreviewComponent], exports:[MetadataPreviewComponent] }) diff --git a/claims/linking/selected/selectedResults.component.html b/claims/linking/selected/selectedResults.component.html index 9eadfcab..fcf29218 100644 --- a/claims/linking/selected/selectedResults.component.html +++ b/claims/linking/selected/selectedResults.component.html @@ -1,13 +1,17 @@