I have been trying to change the popover preview image size. The default value is 400 as shown here :data-content="<img src="/api/access/datafile/3?imageThumb=400", but I could not find a place to change it in the CSS files. Is it possible to change this value to 800?
Thanks in advance for your help!
Have you tried /api/access/datafile/3?imageThumb=800?
I have checked the css files and did not find the place to make the change. Here is where the element lives:
div class="media-object thumbnail-block text-center">
<span data-toggle="popover" data-template="<div class="popover thumb-preview" role="tooltip"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>" data-placement="auto top" data-content="<img src="/api/access/datafile/3?imageThumb=400" alt="Preview: 277.jpg" />" data-trigger="hover" class="file-thumbnail-preview-img" data-html="true" data-original-title="" title=""><img id="datasetForm:tabView:filesTable:1:j_idt1317" src="/api/access/datafile/3?imageThumb=true&pfdrid_c=true" alt="277.jpg"></span>
</div>
Is it here?
src="/api/access/datafile/#{fileMetadata.dataFile.id}?imageThumb=400"
https://github.com/IQSS/dataverse/blob/v6.4/src/main/webapp/file-info-fragment.xhtml#L33C131-L33C208
Yes, that's it. But changing it to imageThumb=800 in the file-info-fragment.xhtml file only made the image background bigger, and did not change the image size.
oh
Sorry, JSF and frontend stuff generally is not a strength of mine.
Thank you for your time and help any way! You have saved me many times.
No worries. Do you think the new React frontend will need the same change? The code is at https://github.com/IQSS/dataverse-frontend and it's deployed to https://beta.dataverse.org/spa
It works the same way. Changing it to 800 in the inspector double the size.
Ok but are you happy with 400 in the new frontend? Should it be configurable?
One of our users requested to have bigger image for preview. It would be nice to make it configurable.
Ok. Please feel free to open an issue at https://github.com/IQSS/dataverse-frontend
Done. Thanks! Have a great weekend and a very happy Thanksgiving!
https://github.com/IQSS/dataverse-frontend/issues/555 looks great. Thanks! You too!
Henning Timm has marked this topic as resolved.
Last updated: Nov 01 2025 at 14:11 UTC