Support more format in preview thumbnails of media manager

Hello,

It’s hard to explain to the final customer that a modern media manager in 2022 soon 2023 can’t display SVG and video in preview thumbnail.

It would be great to update it to support natively most modern format. I think about many videos format, svg, lottie (that become popular) and probably some others format I forgot.

Thank you

Hey @PubliAlex

SVGs are not enabled by default for security reasons. You can enable them in the config/media.php file.

Not sure what you mean about the video preview, do you mean to show a small video player at the public URL? It could trigger a heavy file download for larger videos…

Hello @daftspunky

Didn’t know for media.php file, It perfectly works, thank you.

For the video, I mean that the only way to have a preview of the video is to click on it, and see it on the right sidebar. When you have a folder full of videos, it’s hard to pick one.

To handle that problem you could load the video player with preload=“metadata” attribute. It will load only the metadata which should be ok in term of performances and would allow to display the first frame of each videos, see an example here.

<video width="400" controls="controls" preload="metadata">
  <source src="https://www.w3schools.com/html/mov_bbb.mp4#t=0.1" type="video/mp4">
</video>

See here : html - How to set the thumbnail image on HTML5 video? - Stack Overflow

Best regards

1 Like

Good find. We will include this in the next hotfix.