SVG preview in backoffice dosn't work

Just upgraded to Umbraco 17.1 and now all my SVG files in the backoffice arent showing their preview anymore? Is this a common bug? Upgraded from version 13.5.2 where I could preview all the media files, but somehow after the upgrade SVG files seems to have an issue.

maybe try deleting the temp cache perhaps, SVG preview should work fine in 17.1

Tried that just before you wrote, byt i still se the issue.

I tried spinning up a new 17.1 umbraco instance locally and uploaded a SVG. Here the problem does not seem to be happening. This is starting to get wird.

Found the problem, but still need a solution. I found that the url value in the table umbracoPropertyData always end with a “/” character. Removing this from the varcharValue the SVG images works again. But whenever i upload a new error, I have to edit the varcharValue in the table again.

Seems like if i open a PNG image in the backoffice, is does fetch the image (event with the / at the end of the umbracoFile.src). But if i open a SVG that also has the / at the end, i don’t see any network calls towards it.

Could this be a validation in the UI? Maybe it prevents fetching of SVG if they end with a trailing slash ?

Found the issue. We had a package old corworker who had made a simple package, that somehow added “/” to the end of all files, when craeted.

1 Like