From 43a0ea876aea76568f3b013adbeee6ffc83bcb51 Mon Sep 17 00:00:00 2001 From: David Taylor Date: Mon, 21 Oct 2024 15:09:14 +0100 Subject: [PATCH] DEV: Update watched-word-uploader uppy usage (#29280) --- .../components/watched-word-uploader.hbs | 1 + .../addon/components/watched-word-uploader.js | 44 +++++++++---------- .../addon/templates/watched-words-action.hbs | 1 - .../components/watched-word-uploader-test.js | 9 ++-- 4 files changed, 26 insertions(+), 29 deletions(-) diff --git a/app/assets/javascripts/admin/addon/components/watched-word-uploader.hbs b/app/assets/javascripts/admin/addon/components/watched-word-uploader.hbs index 21a01f3fa59..fbb840ef237 100644 --- a/app/assets/javascripts/admin/addon/components/watched-word-uploader.hbs +++ b/app/assets/javascripts/admin/addon/components/watched-word-uploader.hbs @@ -2,6 +2,7 @@ {{d-icon "upload"}} {{i18n "admin.watched_words.form.upload"}} ({ action_key: this.actionKey }), + uploadDone: () => { + this.dialog.alert(I18n.t("admin.watched_words.form.upload_successful")); this.done(); - } - } + }, + }); + + @alias("uppyUpload.uploading") addDisabled; } diff --git a/app/assets/javascripts/admin/addon/templates/watched-words-action.hbs b/app/assets/javascripts/admin/addon/templates/watched-words-action.hbs index 587bf0b5968..438d3c241af 100644 --- a/app/assets/javascripts/admin/addon/templates/watched-words-action.hbs +++ b/app/assets/javascripts/admin/addon/templates/watched-words-action.hbs @@ -11,7 +11,6 @@ />