feat: add preview for webp images, videos and pdf files

This commit is contained in:
Louis Dalibard 2024-06-11 14:30:50 +02:00
parent 9d6b38057a
commit 7a619b7526

View File

@ -18,7 +18,7 @@ import (
ffmpeg "github.com/u2takey/ffmpeg-go"
)
var SupportedFileTypes = []string{".png", ".PNG", ".jpg", ".JPG", ".jpeg", ".JPEG", ".webp", ".WEBP", ".pdf", ".PDF", ".mp4", ".MP4", ".webm", ".WEBM", ".mkv", ".MKV"}
var SupportedFileTypes = []string{".png", ".PNG", ".jpg", ".JPG", ".jpeg", ".JPEG", ".webp", ".webP", ".WEBP", ".pdf", ".PDF", ".mp4", ".MP4", ".webm", ".WEBM", ".mkv", ".MKV"}
var FileTypesMap = map[string]imaging.Format{
".png": imaging.PNG,
".PNG": imaging.PNG,
@ -40,6 +40,7 @@ var FileTypesMap = map[string]imaging.Format{
var FFMPEGFormats = []string{
".webp",
".webP",
".WEBP",
".mp4",
".MP4",