Merge branch 'explore-redesign' of code-repo.d4science.org:MaDgIK/openaire-library into explore-redesign
This commit is contained in:
commit
bfd1bc3f0b
|
@ -27,7 +27,7 @@ import {HelperFunctions} from "../../../utils/HelperFunctions.class";
|
|||
<ul class="uk-list uk-margin">
|
||||
<li *ngFor="let result of results.slice((page-1)*pageSize, page*pageSize)">
|
||||
<result-preview [modal]="modal" [properties]="properties" [hasLink]="false" [result]="getResultPreview(result)"
|
||||
[showOrcid]="false" [isCard]="false" [prevPath]="prevPath"></result-preview>
|
||||
[showOrcid]="false" [isCard]="false" [prevPath]="prevPath" [showInline]="true"></result-preview>
|
||||
</li>
|
||||
</ul>
|
||||
<no-load-paging *ngIf="results.length > pageSize" [type]="type"
|
||||
|
|
|
@ -548,7 +548,7 @@ export class ResultLandingComponent {
|
|||
this.enermapsId = ParsingFunctions.getEnermapsConceptId(this.resultLandingInfo.contexts);
|
||||
}
|
||||
|
||||
|
||||
this.relatedClassFilters = [{"label": "All relations", "value": ""}];
|
||||
if(this.resultLandingInfo.relatedClassFilters.size > 1) {
|
||||
for (let relClass of this.resultLandingInfo.relatedClassFilters) {
|
||||
this.relatedClassFilters.push({"label": HelperFunctions.getVocabularyLabel(relClass, this.relationsVocabulary), "value": relClass});
|
||||
|
|
|
@ -102,7 +102,7 @@ import {properties} from "../../../../environments/environment";
|
|||
</div>
|
||||
</modal-alert>
|
||||
|
||||
<fs-modal *ngIf="isMobile" #authorsModal>
|
||||
<fs-modal *ngIf="isMobile" #authorsModal classTitle="uk-tile-default uk-border-bottom">
|
||||
<div class="uk-text-small uk-text-emphasis uk-grid uk-grid-column-collapse uk-grid-row-small" uk-grid>
|
||||
<ng-container *ngFor="let author of authors; let i=index">
|
||||
<ng-container *ngTemplateOutlet="author_template; context: { author: author, i:i}"></ng-container>
|
||||
|
@ -121,6 +121,7 @@ export class ShowAuthorsComponent {
|
|||
@Input() showAll: boolean = true;
|
||||
@Input() modal: AlertModal;
|
||||
@Input() viewAll: boolean = false;
|
||||
@Input() showInline: boolean = false; // do not open modal for "view more" when this is true
|
||||
public lessBtn: boolean = false;
|
||||
@ViewChild('authorsModal') authorsModal;
|
||||
|
||||
|
@ -143,7 +144,7 @@ export class ShowAuthorsComponent {
|
|||
}
|
||||
|
||||
public viewAllClick() {
|
||||
if(this.authors.length <= this.authorsLimit*2) {
|
||||
if(this.authors.length <= this.authorsLimit*2 || this.showInline) {
|
||||
this.viewAll = true;
|
||||
this.lessBtn = true;
|
||||
} else {
|
||||
|
|
|
@ -124,7 +124,7 @@
|
|||
<!-- Authors -->
|
||||
<div *ngIf="result.authors" class="uk-margin-xsmall-bottom">
|
||||
<showAuthors [authors]="result.authors" [authorsLimit]=4 [modal]="modal"
|
||||
[showAll]=true></showAuthors>
|
||||
[showAll]=true [showInline]="showInline"></showAuthors>
|
||||
</div>
|
||||
<!-- Identifiers -->
|
||||
<div *ngIf="result.identifiers && result.identifiers.size > 0" class="uk-margin-xsmall-bottom">
|
||||
|
|
|
@ -37,6 +37,7 @@ export class ResultPreviewComponent implements OnInit, OnChanges {
|
|||
@Input() showEnermaps: boolean = false;
|
||||
@Input() provenanceActionVocabulary = null;
|
||||
@Input() relationsVocabulary = null;
|
||||
@Input() showInline: boolean = false; // do not open modal for "view more" when this is true
|
||||
|
||||
/* Metadata */
|
||||
public type: string;
|
||||
|
|
Loading…
Reference in New Issue