fix(resources/api): allow svg xml format (#4705)

This commit is contained in:
Devonte W 2023-02-23 19:19:58 +00:00 committed by GitHub
parent 2a7833ca17
commit aea5c474db
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -47,7 +47,7 @@ export const rawDataToFileObject = (data: FractalResponseData): FileObject => ({
isEditable: function () {
if (this.isArchiveType() || !this.isFile) return false;
const matches = ['application/jar', 'application/octet-stream', 'inode/directory', /^image\//];
const matches = ['application/jar', 'application/octet-stream', 'inode/directory', /^image\/(?!svg\+xml)/];
return matches.every((m) => !this.mimetype.match(m));
},