From 5c1237dc74f45f4aa4bdb44b80645c44d822abc6 Mon Sep 17 00:00:00 2001 From: Daniel Supernault Date: Tue, 23 Oct 2018 20:15:15 -0600 Subject: [PATCH] Update compose view --- resources/views/status/compose.blade.php | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/resources/views/status/compose.blade.php b/resources/views/status/compose.blade.php index a6d17e4ec..8cf297d12 100644 --- a/resources/views/status/compose.blade.php +++ b/resources/views/status/compose.blade.php @@ -22,6 +22,9 @@
+
+
+

@@ -319,6 +322,7 @@ $(document).on('change', '.file-input', function(e) { if($('.welcome-text').hasClass('d-none') == false) { $('.welcome-text').addClass('d-none'); } + $('.composeLoader').removeClass('d-none'); let form = new FormData(); form.append('file', io); @@ -342,6 +346,7 @@ $(document).on('change', '.file-input', function(e) { }; pixelfed.uploader.meta.push(meta); pixelfed.uploader.media.push(e.data); + $('.composeLoader').addClass('d-none'); pixelfed.uploader.addPreview(e.data); pixelfed.uploader.paginate(e.data); if(pixelfed.uploader.ids.length >= pixelfed.uploader.limit) { @@ -358,6 +363,7 @@ $(document).on('change', '.file-input', function(e) { $(document).on('click', '#addMedia', function(e) { e.preventDefault(); let el = $(this); + el.attr('disabled', ''); if(pixelfed.uploader.ids.length >= pixelfed.uploader.limit) { el.remove(); return; @@ -365,6 +371,7 @@ $(document).on('click', '#addMedia', function(e) { let fi = $('.file-input'); fi.trigger('click'); el.blur(); + el.removeAttr('disabled'); }); $(document).on('change', '#filterSelectDropdown', function() { @@ -458,6 +465,9 @@ $(document).on('click', '.preview-thumbs img', function(e) { $(document).on('click', '#create', function(e) { e.preventDefault(); + let el = $(this); + el.attr('disabled', ''); + $('.composeLoader').removeClass('d-none'); let data = { media: pixelfed.uploader.meta, caption: $('.caption input').val(),