Skip to content

Commit 33e94d2

Browse files
author
Andrea Barbasso
committed
Merged dspace-cris-2023_02_x into task/dspace-cris-2023_02_x/DSC-1852
2 parents 1e8ecea + f402dcd commit 33e94d2

47 files changed

Lines changed: 186 additions & 30 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

config/config.example.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -275,6 +275,8 @@ browseBy:
275275
fiveYearLimit: 30
276276
# The absolute lowest year to display in the dropdown (only used when no lowest date can be found for all items)
277277
defaultLowerLimit: 1900
278+
# Whether to add item badges to BOTH browse and search result lists.
279+
showLabels: true
278280
# If true, thumbnail images for items will be added to BOTH search and browse result lists.
279281
showThumbnails: true
280282
# The number of entries in a paginated browse results list.

src/app/entity-groups/research-entities/submission/item-list-elements/external-source-entry/external-source-entry-list-submission-element.component.html

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,8 @@
4343
<ds-themed-item-list-preview [item]="match"
4444
[object]="itemPreviewObject"
4545
[metadataList]="metadataList"
46+
[showLabel]="showLabel"
47+
[showMetrics]="showMetrics"
4648
[showThumbnails]="showThumbnails">
4749
</ds-themed-item-list-preview>
4850
<div class="offset-2">

src/app/shared/browse-most-elements/browse-most-elements.component.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
[index]="i"
77
[listID]="paginatedSearchOptions.configuration"
88
[object]="object"
9+
[showLabel]="showLabel"
910
[showMetrics]="showMetrics"
1011
[showThumbnails]="showThumbnails"
1112
[viewMode]="paginatedSearchOptions.view"></ds-listable-object-component-loader>

src/app/shared/browse-most-elements/browse-most-elements.component.ts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,16 +23,20 @@ export class BrowseMostElementsComponent implements OnInit {
2323
@Input() paginatedSearchOptions: PaginatedSearchOptions;
2424

2525
@Input() context: Context;
26+
/**
27+
* Whether to show the badge label or not
28+
*/
29+
@Input() showLabel: boolean;
2630

2731
/**
2832
* Whether to show the metrics badges
2933
*/
30-
@Input() showMetrics;
34+
@Input() showMetrics: boolean;
3135

3236
/**
3337
* Whether to show the thumbnail preview
3438
*/
35-
@Input() showThumbnails;
39+
@Input() showThumbnails: boolean;
3640

3741
searchResults: RemoteData<PaginatedList<SearchResult<DSpaceObject>>>;
3842

src/app/shared/browse-most-elements/themed-browse-most-elements.component.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,13 @@ export class ThemedBrowseMostElementsComponent extends ThemedComponent<BrowseMos
1818

1919
@Input() paginatedSearchOptions: PaginatedSearchOptions;
2020

21-
@Input() showMetrics;
21+
@Input() showLabel: boolean;
2222

23-
@Input() showThumbnails;
23+
@Input() showMetrics: boolean;
2424

25-
protected inAndOutputNames: (keyof BrowseMostElementsComponent & keyof this)[] = ['context', 'paginatedSearchOptions', 'showMetrics', 'showThumbnails'];
25+
@Input() showThumbnails: boolean;
26+
27+
protected inAndOutputNames: (keyof BrowseMostElementsComponent & keyof this)[] = ['context', 'paginatedSearchOptions', 'showLabel', 'showMetrics', 'showThumbnails'];
2628

2729
protected getComponentName(): string {
2830
return 'BrowseMostElementsComponent';

src/app/shared/explore/section-component/top-section/top-section.component.html

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,11 @@
33
<div *ngIf="topSection.titleKey" class="card-header">{{ 'explore.index.' + topSection.titleKey | translate }}</div>
44
<div *ngIf="!topSection.titleKey" class="card-header">{{ 'explore.index.' + topSection.sortField | translate }}</div>
55
<div class="card-body p-0">
6-
<ds-themed-browse-most-elements [context]="context" [paginatedSearchOptions]="paginatedSearchOptions" [showThumbnails]="showThumbnails"></ds-themed-browse-most-elements>
6+
<ds-themed-browse-most-elements [context]="context"
7+
[paginatedSearchOptions]="paginatedSearchOptions"
8+
[showLabel]="showLabel"
9+
[showMetrics]="showMetrics"
10+
[showThumbnails]="showThumbnails"></ds-themed-browse-most-elements>
711
</div>
812
</div>
913
</div>

src/app/shared/explore/section-component/top-section/top-section.component.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,10 @@ export class TopSectionComponent implements OnInit {
2626

2727
paginatedSearchOptions: PaginatedSearchOptions;
2828

29+
showLabel: boolean;
30+
31+
showMetrics = true;
32+
2933
showThumbnails: boolean;
3034

3135
ngOnInit() {

src/app/shared/object-collection/object-collection.component.html

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
[linkType]="linkType"
88
[context]="context"
99
[hidePaginationDetail]="hidePaginationDetail"
10+
[showLabel]="showLabel"
1011
[showMetrics]="showMetrics"
1112
[showPaginator]="showPaginator"
1213
[showThumbnails]="showThumbnails"
@@ -37,6 +38,7 @@
3738
[linkType]="linkType"
3839
[context]="context"
3940
[hidePaginationDetail]="hidePaginationDetail"
41+
[showLabel]="showLabel"
4042
[showMetrics]="showMetrics"
4143
[showPaginator]="showPaginator"
4244
[showThumbnails]="showThumbnails"
@@ -55,6 +57,7 @@
5557
[linkType]="linkType"
5658
[context]="context"
5759
[hidePaginationDetail]="hidePaginationDetail"
60+
[showLabel]="showLabel"
5861
[showMetrics]="showMetrics"
5962
[showPaginator]="showPaginator"
6063
[showThumbnails]="showThumbnails"

src/app/shared/object-collection/object-collection.component.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,11 @@ export class ObjectCollectionComponent implements OnInit {
110110
*/
111111
@Input() hidePaginationDetail = false;
112112

113+
/**
114+
* Whether to show the badge label or not
115+
*/
116+
@Input() showLabel: boolean;
117+
113118
/**
114119
* Whether to show the metrics badges
115120
*/
@@ -123,7 +128,7 @@ export class ObjectCollectionComponent implements OnInit {
123128
/**
124129
* Whether to show the thumbnail preview
125130
*/
126-
@Input() showThumbnails;
131+
@Input() showThumbnails: boolean;
127132

128133
/**
129134
* Whether or not to show an alert for hidden related items

src/app/shared/object-collection/shared/listable-object/listable-object-component-loader.component.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ export class ListableObjectComponentLoaderComponent implements OnInit, OnChanges
6868
/**
6969
* Whether to show the badge label or not
7070
*/
71-
@Input() showLabel = true;
71+
@Input() showLabel: boolean;
7272

7373
/**
7474
* Whether to show the metrics badges
@@ -78,7 +78,7 @@ export class ListableObjectComponentLoaderComponent implements OnInit, OnChanges
7878
/**
7979
* Whether to show the thumbnail preview
8080
*/
81-
@Input() showThumbnails;
81+
@Input() showThumbnails: boolean;
8282

8383
/**
8484
* The value to display for this element

0 commit comments

Comments
 (0)