mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-07 01:54:15 +00:00
108588: Fix header ordering issues on community & collection pages
This commit is contained in:
@@ -1,13 +1,12 @@
|
|||||||
<div class="container">
|
|
||||||
<section class="comcol-page-browse-section">
|
<section class="comcol-page-browse-section">
|
||||||
<div class="browse-by-metadata w-100">
|
<div class="browse-by-metadata w-100">
|
||||||
<ds-browse-by *ngIf="startsWithOptions" class="col-xs-12 w-100"
|
<ds-browse-by *ngIf="startsWithOptions" class="col-xs-12 w-100"
|
||||||
title="{{'browse.title' | translate:
|
title="{{'browse.title' | translate:{
|
||||||
{
|
|
||||||
field: 'browse.metadata.' + browseId | translate,
|
field: 'browse.metadata.' + browseId | translate,
|
||||||
startsWith: (startsWith)? ('browse.startsWith' | translate: { startsWith: '"' + startsWith + '"' }) : '',
|
startsWith: (startsWith)? ('browse.startsWith' | translate: { startsWith: '"' + startsWith + '"' }) : '',
|
||||||
value: (value)? '"' + value + '"': ''
|
value: (value)? '"' + value + '"': ''
|
||||||
} }}"
|
} }}"
|
||||||
|
[displayTitle]="displayTitle"
|
||||||
[objects$]="(items$ !== undefined)? items$ : browseEntries$"
|
[objects$]="(items$ !== undefined)? items$ : browseEntries$"
|
||||||
[paginationConfig]="(currentPagination$ |async)"
|
[paginationConfig]="(currentPagination$ |async)"
|
||||||
[sortConfig]="(currentSort$ |async)"
|
[sortConfig]="(currentSort$ |async)"
|
||||||
@@ -16,7 +15,7 @@
|
|||||||
(prev)="goPrev()"
|
(prev)="goPrev()"
|
||||||
(next)="goNext()">
|
(next)="goNext()">
|
||||||
</ds-browse-by>
|
</ds-browse-by>
|
||||||
<ds-themed-loading *ngIf="!startsWithOptions" message="{{'loading.browse-by-page' | translate}}"></ds-themed-loading>
|
<ds-themed-loading *ngIf="!startsWithOptions"
|
||||||
|
message="{{'loading.browse-by-page' | translate}}"></ds-themed-loading>
|
||||||
</div>
|
</div>
|
||||||
</section>
|
</section>
|
||||||
</div>
|
|
||||||
|
@@ -52,6 +52,11 @@ export class BrowseByMetadataComponent implements OnInit, OnChanges, OnDestroy {
|
|||||||
*/
|
*/
|
||||||
@Input() scope: string;
|
@Input() scope: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Display the h1 title in the section
|
||||||
|
*/
|
||||||
|
@Input() displayTitle = true;
|
||||||
|
|
||||||
scope$: BehaviorSubject<string> = new BehaviorSubject(undefined);
|
scope$: BehaviorSubject<string> = new BehaviorSubject(undefined);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@@ -1,2 +1,4 @@
|
|||||||
|
<div class="container">
|
||||||
<ds-browse-by-switcher [browseByType]="browseByType$ | async">
|
<ds-browse-by-switcher [browseByType]="browseByType$ | async">
|
||||||
</ds-browse-by-switcher>
|
</ds-browse-by-switcher>
|
||||||
|
</div>
|
||||||
|
@@ -15,6 +15,8 @@ export class BrowseBySwitcherComponent extends AbstractComponentLoaderComponent<
|
|||||||
|
|
||||||
@Input() browseByType: BrowseByDataType;
|
@Input() browseByType: BrowseByDataType;
|
||||||
|
|
||||||
|
@Input() displayTitle: boolean;
|
||||||
|
|
||||||
@Input() scope: string;
|
@Input() scope: string;
|
||||||
|
|
||||||
protected inputNamesDependentForComponent: (keyof this & string)[] = [
|
protected inputNamesDependentForComponent: (keyof this & string)[] = [
|
||||||
@@ -25,6 +27,7 @@ export class BrowseBySwitcherComponent extends AbstractComponentLoaderComponent<
|
|||||||
protected inputNames: (keyof this & string)[] = [
|
protected inputNames: (keyof this & string)[] = [
|
||||||
'context',
|
'context',
|
||||||
'browseByType',
|
'browseByType',
|
||||||
|
'displayTitle',
|
||||||
'scope',
|
'scope',
|
||||||
];
|
];
|
||||||
|
|
||||||
|
@@ -1,4 +1,11 @@
|
|||||||
<div class="container">
|
<section>
|
||||||
|
<h1 *ngIf="displayTitle">
|
||||||
|
{{ ('browse.title') | translate:{
|
||||||
|
field: 'browse.metadata.' + vocabularyName | translate,
|
||||||
|
startsWith: '',
|
||||||
|
value: '',
|
||||||
|
} }}
|
||||||
|
</h1>
|
||||||
<div class="mb-3">
|
<div class="mb-3">
|
||||||
<ds-vocabulary-treeview [vocabularyOptions]=vocabularyOptions
|
<ds-vocabulary-treeview [vocabularyOptions]=vocabularyOptions
|
||||||
[multiSelect]="true"
|
[multiSelect]="true"
|
||||||
@@ -11,4 +18,4 @@
|
|||||||
[queryParams]="queryParams"
|
[queryParams]="queryParams"
|
||||||
[queryParamsHandling]="'merge'">
|
[queryParamsHandling]="'merge'">
|
||||||
{{ 'browse.taxonomy.button' | translate }}</a>
|
{{ 'browse.taxonomy.button' | translate }}</a>
|
||||||
</div>
|
</section>
|
||||||
|
@@ -36,6 +36,11 @@ export class BrowseByTaxonomyComponent implements OnInit, OnChanges, OnDestroy {
|
|||||||
*/
|
*/
|
||||||
@Input() scope: string;
|
@Input() scope: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Display the h1 title in the section
|
||||||
|
*/
|
||||||
|
@Input() displayTitle = true;
|
||||||
|
|
||||||
scope$: BehaviorSubject<string> = new BehaviorSubject(undefined);
|
scope$: BehaviorSubject<string> = new BehaviorSubject(undefined);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
<ng-container *ngVar="(subCollectionsRDObs | async) as subCollectionsRD">
|
<ng-container *ngVar="(subCollectionsRDObs | async) as subCollectionsRD">
|
||||||
<div *ngIf="subCollectionsRD?.hasSucceeded && subCollectionsRD?.payload.totalElements > 0" @fadeIn>
|
<div *ngIf="subCollectionsRD?.hasSucceeded && subCollectionsRD?.payload.totalElements > 0" @fadeIn>
|
||||||
<h2>{{'community.sub-collection-list.head' | translate}}</h2>
|
<h3>{{'community.sub-collection-list.head' | translate}}</h3>
|
||||||
<ds-viewable-collection
|
<ds-viewable-collection
|
||||||
[config]="config"
|
[config]="config"
|
||||||
[sortConfig]="sortConfig"
|
[sortConfig]="sortConfig"
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
<ng-container *ngVar="(subCommunitiesRDObs | async) as subCommunitiesRD">
|
<ng-container *ngVar="(subCommunitiesRDObs | async) as subCommunitiesRD">
|
||||||
<div *ngIf="subCommunitiesRD?.hasSucceeded && subCommunitiesRD?.payload.totalElements > 0" @fadeIn>
|
<div *ngIf="subCommunitiesRD?.hasSucceeded && subCommunitiesRD?.payload.totalElements > 0" @fadeIn>
|
||||||
<h2>{{'community.sub-community-list.head' | translate}}</h2>
|
<h3>{{'community.sub-community-list.head' | translate}}</h3>
|
||||||
<ds-viewable-collection
|
<ds-viewable-collection
|
||||||
[config]="config"
|
[config]="config"
|
||||||
[sortConfig]="sortConfig"
|
[sortConfig]="sortConfig"
|
||||||
|
@@ -1,5 +1,5 @@
|
|||||||
<ng-container *ngVar="(objects$ | async) as objects">
|
<ng-container *ngVar="(objects$ | async) as objects">
|
||||||
<h3>{{title | translate}}</h3>
|
<h1 *ngIf="displayTitle">{{title | translate}}</h1>
|
||||||
<ng-container *ngComponentOutlet="getStartsWithComponent(); injector: objectInjector;"></ng-container>
|
<ng-container *ngComponentOutlet="getStartsWithComponent(); injector: objectInjector;"></ng-container>
|
||||||
<div *ngIf="objects?.hasSucceeded && !objects?.isLoading && objects?.payload?.page.length > 0" @fadeIn>
|
<div *ngIf="objects?.hasSucceeded && !objects?.isLoading && objects?.payload?.page.length > 0" @fadeIn>
|
||||||
<div *ngIf="shouldDisplayResetButton$ |async" class="mb-2 reset">
|
<div *ngIf="shouldDisplayResetButton$ |async" class="mb-2 reset">
|
||||||
|
@@ -38,6 +38,11 @@ export class BrowseByComponent implements OnInit, OnDestroy {
|
|||||||
*/
|
*/
|
||||||
@Input() title: string;
|
@Input() title: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Whether the title should be displayed
|
||||||
|
*/
|
||||||
|
@Input() displayTitle = true;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The list of objects to display
|
* The list of objects to display
|
||||||
*/
|
*/
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
<h2 class="comcol-browse-label h5">{{'browse.comcol.head' | translate}}</h2>
|
<h2 class="comcol-browse-label">{{'browse.comcol.head' | translate}}</h2>
|
||||||
<nav *ngIf="(allOptions$ | async) as allOptions" class="comcol-browse mb-4" aria-label="Browse Community or Collection">
|
<nav *ngIf="(allOptions$ | async) as allOptions" class="comcol-browse mb-4" aria-label="Browse Community or Collection">
|
||||||
<div class="d-none d-sm-block">
|
<div class="d-none d-sm-block">
|
||||||
|
|
||||||
|
@@ -1,3 +1,4 @@
|
|||||||
<ds-browse-by-switcher [browseByType]="browseByType$ | async"
|
<ds-browse-by-switcher [browseByType]="browseByType$ | async"
|
||||||
|
[displayTitle]="false"
|
||||||
[scope]="scope$ | async">
|
[scope]="scope$ | async">
|
||||||
</ds-browse-by-switcher>
|
</ds-browse-by-switcher>
|
||||||
|
Reference in New Issue
Block a user