support more image formats, server avif is supported for larger images
This commit is contained in:
parent
0748265fe6
commit
406237b837
9 changed files with 31 additions and 11 deletions
|
|
@ -421,7 +421,7 @@ pandora.createLinks = function($element) {
|
|||
};
|
||||
|
||||
pandora.uploadDroppedFiles = function(files) {
|
||||
var documentExtensions = ['pdf', /* 'epub', 'txt', */ 'png', 'gif', 'jpg', 'jpeg'];
|
||||
var documentExtensions = ['pdf', /* 'epub', 'txt', */ 'png', 'gif', 'jpg', 'jpeg', 'webp', 'heic', 'heif', 'avif'];
|
||||
files = Ox.map(files, function(file) { return file });
|
||||
|
||||
if (files.every(function(file) {
|
||||
|
|
@ -2132,7 +2132,9 @@ pandora.getSpan = function(state, val, callback) {
|
|||
} else {
|
||||
state.span = val;
|
||||
}
|
||||
} else if (Ox.contains(['gif', 'jpg', 'png'], extension)) {
|
||||
} else if (Ox.contains([
|
||||
'gif', 'gif', 'jpg', 'png', 'webp', 'heic', 'heif', 'avif'
|
||||
], extension)) {
|
||||
values = val.split(',');
|
||||
if (values.length == 4) {
|
||||
state.span = values.map(function(number, index) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue