Repository navigation
Render the item-page thumbnail only once - #5824
bram-atmire wants to merge 1 commit into
Conversation
The advanced attachment rendering (showDownloadLinkAsAttachment) showed a thumbnail (or 'no thumbnail' placeholder) per attachment card, duplicating the item thumbnail already rendered in the item-page sidebar. Remove the per-attachment thumbnail from BitstreamAttachmentComponent so the page renders a single thumbnail; the attachment cards keep their file metadata and download button. Fixes DSpace#5821
|
@bram-atmire : I'm not sure I agree with this PR as it removes the thumbnail entirely from the My understanding is that this came over from DSpace-CRIS because it's a part of the Configurable Layout of Entity/Item pages coming in DSpace 11, see DSpace/DSpace#11779 I believe the thumbnail appears in this component because it does NOT always appear in the other location, based on how the layout is configured. So, I think it'd be a better solution to make this configurable... or wait until DSpace/DSpace#11779 is fixed before we move this forward. |
|
@tdonohue Agreed, fine with either solution. What's the latest on DSpace/DSpace#11779 ? |
|
I'll already go ahead and close this PR. |
|
@bram-atmire : DSpace/DSpace#11779 is coming in 11.0. It has two open PRs which are under review right now: DSpace/DSpace#12789 and #5963 It's been through several rounds of review, so I expect it is close to ready for merger...but it really just depends on when it gets the +2 it needs. |
References
Fixes #5821
Description
Removes the duplicate thumbnail on the item page: the advanced attachment cards rendered their own thumbnail in addition to the item thumbnail already shown in the item-page sidebar.
Instructions for Reviewers
This affects the advanced attachment rendering used on the item page when
layout.showDownloadLinkAsAttachment: true(theds-bitstream-attachmentcards). Each card rendered a thumbnail (or the "no thumbnail" placeholder) for its bitstream, which duplicated the item-level thumbnail already rendered in the left sidebar (col-md-4), spending prime above-the-fold space on a second copy.List of changes in this PR:
BitstreamAttachmentComponent's template.thumbnail$subject, itsngOnInitsubscription, theThemedThumbnailComponentimport, and the dead.thumbnail-wrapperstyle.The single item thumbnail rendered in the sidebar is retained; the attachment cards keep their file metadata and download button.
How to test:
layout.showDownloadLinkAsAttachment: truein yourconfig.*.yml.Checklist
mainbranch of code.