File tree Expand file tree Collapse file tree 2 files changed +9
-1
lines changed
Resources/views/Admin/MediaManager/Modal/Content/Files Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -43,6 +43,9 @@ interface FileHelperInterface
4343 'image/gif ' ,
4444 'image/jpeg ' ,
4545 'image/png ' ,
46+ 'image/svg+xml ' ,
47+ 'image/webp ' ,
48+ 'image/avif ' ,
4649 ];
4750
4851 public const VIDEO_TYPE_MIMES = [
@@ -61,6 +64,7 @@ interface FileHelperInterface
6164 'image/vnd.microsoft.icon ' ,
6265 'image/x-icon ' ,
6366 'image/ico ' ,
67+ 'image/svg+xml ' ,
6468 'image/gif ' ,
6569 'image/jpeg ' ,
6670 'image/png ' ,
Original file line number Diff line number Diff line change 11{% set filePath = folder is not empty ? folder ~ ' /' ~ file .path : file .path %}
2- {% if file .isImage %}
2+ {% if file .isImage and file . mimeType != ' image/svg+xml ' %}
33 <a href =" /media/{{ filePath }}" target =" _blank" rel =" noopener noreferrer" >
44 <img src =" {{ filePath | imagine_filter(' monsieurbiz_sylius_media_manager_uploaded_image' ) }}" alt =" {{ filePath | escape (' html_attr' ) }}" style =" max-width: 300px;max-height: 30px;" />
55 </a >
6+ {% elseif file .isImage and file .mimeType == ' image/svg+xml' %}
7+ <a href =" /media/{{ filePath }}" target =" _blank" rel =" noopener noreferrer" >
8+ <img src =" /media/{{ filePath }}" alt =" {{ filePath | escape (' html_attr' ) }}" style =" max-width: 300px;max-height: 30px;" />
9+ </a >
610{% elseif file .isFile %}
711 <a href =" /media/{{ filePath }}" target =" _blank" rel =" noopener noreferrer" class =" ui button mini icon" >
812 <i class =" eye icon" ></i >
You can’t perform that action at this time.
0 commit comments