GIF auch für Klick hinzugefügt
This commit is contained in:
parent
152772e3ad
commit
bf1182be54
@ -28,7 +28,7 @@ dropzone.addEventListener('click', function(e) {
|
|||||||
|
|
||||||
input.onchange = function(e) {
|
input.onchange = function(e) {
|
||||||
file = e.target.files[0];
|
file = e.target.files[0];
|
||||||
if( file.type == 'image/png' || file.type == 'image/jpeg' ) {
|
if(file.type == 'image/png' || file.type == 'image/jpeg' || file.type == 'image/gif') {
|
||||||
upload(e.target.files[0]);
|
upload(e.target.files[0]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -41,7 +41,7 @@ dropzone.addEventListener('drop', function(e) {
|
|||||||
this.classList.add('inactive');
|
this.classList.add('inactive');
|
||||||
|
|
||||||
file = e.dataTransfer.files[0];
|
file = e.dataTransfer.files[0];
|
||||||
if( file.type == 'image/png' || file.type == 'image/jpeg' || file.type == 'image/gif') {
|
if(file.type == 'image/png' || file.type == 'image/jpeg' || file.type == 'image/gif') {
|
||||||
upload(e.dataTransfer.files[0]);
|
upload(e.dataTransfer.files[0]);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user