mirror of
https://framagit.org/tom79/fediplan.git
synced 2025-04-05 21:51:50 +02:00
Fix an issue when adding new media
This commit is contained in:
parent
65acc0295a
commit
eed599f615
1 changed files with 3 additions and 3 deletions
|
@ -414,7 +414,7 @@
|
||||||
var content;
|
var content;
|
||||||
content = ' <div class="row" id="media_container_'+data.id+'">\n' +
|
content = ' <div class="row" id="media_container_'+data.id+'">\n' +
|
||||||
' <div class="col-md-4">\n' +
|
' <div class="col-md-4">\n' +
|
||||||
' <img src="'+data.preview_url+'" style="width:100%;max-width:400px;" id="media_preview_'+data.id+'"/>\n' +
|
' <img src="'+data.preview_url+'" style="width:100%;max-width:200px;" id="media_preview_'+data.id+'"/>\n' +
|
||||||
' </div>\n' +
|
' </div>\n' +
|
||||||
' <div class="col-md-6">\n' +
|
' <div class="col-md-6">\n' +
|
||||||
' <textarea name="media_description_'+data.id+'" class="form-control"></textarea>\n' +
|
' <textarea name="media_description_'+data.id+'" class="form-control"></textarea>\n' +
|
||||||
|
@ -428,11 +428,11 @@
|
||||||
' </div>\n' +
|
' </div>\n' +
|
||||||
' </div>'
|
' </div>'
|
||||||
|
|
||||||
$('#media_container').html($('#media_container').html() + content);
|
$('#media_container').append($(content));
|
||||||
|
|
||||||
},
|
},
|
||||||
url: 'https://{{ instance }}/api/v1/media',
|
url: 'https://{{ instance }}/api/v1/media',
|
||||||
acceptFileTypes: /(\.|\/)(gif|jpe?g|png|mp4|mp3)$/i
|
acceptFileTypes: /(\.|\/)(gif|jpe?g|apng|png|mp4|mp3|avi|mov|webm|wmv|flv|wav|ogg)$/i
|
||||||
});
|
});
|
||||||
|
|
||||||
// Enable iframe cross-domain access via redirect option:
|
// Enable iframe cross-domain access via redirect option:
|
||||||
|
|
Loading…
Add table
Reference in a new issue