SVG thumbnails in display templates are not scaled down to fit the display in details view
Describe the Bug
When setting the display template to contain the thumbnail of an image and the image is a large SVG file, the thumbnail fails to scale it down to fit the line height and the image shows up on top of the fields and you cannot click behind the image. The user is forced to use keyboard navigation to edit the fields
Screenshot:
To Reproduce
- Create a collection with an image and some other fields such as title
- Set the display template of that collection to be the image thumbnail followed by the title
- Create an item in that collection with a large SVG for the image
- Open the details view for that object
- The thumbnail image from the title line shows up large and overlaps fields that I need to edit
Directus Version
v11.14.0
Hosting Strategy
Self-Hosted (Docker Image)
Database
PostgreSQL 16
I do not know how to best provide the sample image I use for testing this. Hopefully I can attach it here
Hi @AlexGaillard , can I take up this issue?
@Tsaishashanth Yeah sure 😄 Please do
@Tsaishashanth Sorry, didn't realize this was fixed elsewhere 🫠
@AlexGaillard No worries,it took me some time to get it running locally too. I’ll try to contribute to other issues.