summaryrefslogtreecommitdiff
path: root/ext
diff options
context:
space:
mode:
Diffstat (limited to 'ext')
-rw-r--r--ext/bg/js/options-form.js8
-rw-r--r--ext/bg/options.html4
2 files changed, 11 insertions, 1 deletions
diff --git a/ext/bg/js/options-form.js b/ext/bg/js/options-form.js
index 68a18d8f..d1e6fa18 100644
--- a/ext/bg/js/options-form.js
+++ b/ext/bg/js/options-form.js
@@ -313,6 +313,12 @@ function populateDictionaries(opts) {
}
function onPurgeDb() {
+ const dictControls = $('#dict-importer, #dict-groups');
+ dictControls.hide();
+
+ const dictProgress = $('.dict-purge-progress');
+ dictProgress.show();
+
const dictError = $('#dict-error');
dictError.hide();
@@ -323,6 +329,8 @@ function onPurgeDb() {
dictError.show().find('span').text(error);
}).then(() => {
dictSpinner.hide();
+ dictProgress.hide();
+ dictControls.show();
return loadOptions().then(opts => populateDictionaries(opts));
});
}
diff --git a/ext/bg/options.html b/ext/bg/options.html
index c3450c39..5b6301c6 100644
--- a/ext/bg/options.html
+++ b/ext/bg/options.html
@@ -7,7 +7,7 @@
<link rel="stylesheet" type="text/css" href="../lib/bootstrap-3.3.6-dist/css/bootstrap-theme.min.css">
<style>
#anki-spinner, #anki-general, #anki-error,
- #dict-spinner, #dict-error, #dict-warning, .dict-import-progress, .dict-delete-progress,
+ #dict-spinner, #dict-error, #dict-warning, .dict-purge-progress, .dict-import-progress, .dict-delete-progress,
#options-advanced {
display: none;
}
@@ -77,6 +77,8 @@
wait for import and delete operations to complete before closing this page.
</p>
+ <div class="dict-purge-progress">Dictionary data is being purged, please be patient...</div>
+
<div id="dict-groups"></div>
<div class="alert alert-warning" id="dict-warning">