Open SVG files in browser

This commit is contained in:
Frédéric Guillot 2022-09-04 16:21:16 -07:00 committed by Frédéric Guillot
parent d7a4b59db3
commit f3966c99fc
1 changed files with 10 additions and 0 deletions

View File

@ -26,6 +26,7 @@ class FileHelper extends Base
case 'jpg': case 'jpg':
case 'png': case 'png':
case 'gif': case 'gif':
case 'svg':
return 'fa-file-image-o'; return 'fa-file-image-o';
case 'xls': case 'xls':
case 'xlsx': case 'xlsx':
@ -59,6 +60,7 @@ class FileHelper extends Base
case 'mov': case 'mov':
case 'mp4': case 'mp4':
case 'mkv': case 'mkv':
case 'webm':
return 'fa-file-video-o'; return 'fa-file-video-o';
case 'php': case 'php':
case 'html': case 'html':
@ -135,6 +137,14 @@ class FileHelper extends Base
return 'video/x-msvideo'; return 'video/x-msvideo';
case 'webm': case 'webm':
return 'video/webm'; return 'video/webm';
case 'mov':
return 'video/quicktime';
case 'm4v':
return 'video/x-m4v';
case 'mp4':
return 'video/mp4';
case 'svg':
return 'image/svg+xml';
} }
return null; return null;