diff --git a/templates/fediplan/schedule.html.twig b/templates/fediplan/schedule.html.twig index 88395e6..47dcd95 100644 --- a/templates/fediplan/schedule.html.twig +++ b/templates/fediplan/schedule.html.twig @@ -393,7 +393,7 @@ ' \n' + ' \n' + '
\n' + - ' \n' + @@ -447,7 +447,14 @@ .replace(/(^|[^\/\w])@(([a-z0-9_]+)@[a-z0-9\.\-]+[a-z0-9]+)/ig, '$1@$3'); $("#count").text(inputText.length); }); - var timezone = Intl.DateTimeFormat().resolvedOptions().timeZone; - $('#compose_timeZone').val(timezone); + + $(document).ready(function() { + var timezone = Intl.DateTimeFormat().resolvedOptions().timeZone; + $('#compose_timeZone').val(timezone); + $(document).on('click', '.delete_media', function () { + var id = $(this).attr('data-id'); + $('#media_container_' + id).remove(); + }) + }); {% endblock %}