aboutsummaryrefslogtreecommitdiff
path: root/ext/bg/js/options-form.js
diff options
context:
space:
mode:
authorAlex Yatskov <alex@foosoft.net>2017-01-18 20:46:17 -0800
committerAlex Yatskov <alex@foosoft.net>2017-01-18 20:46:17 -0800
commit03e1a03634ed5bccea3bddb3f6487effc7eb17db (patch)
tree2e813199fc87c181bcaa193052b82fcc3a4dc0fa /ext/bg/js/options-form.js
parent404f3f1b164fd924a8d34521f86bf3660acdc008 (diff)
add option for html cards
Diffstat (limited to 'ext/bg/js/options-form.js')
-rw-r--r--ext/bg/js/options-form.js2
1 files changed, 2 insertions, 0 deletions
diff --git a/ext/bg/js/options-form.js b/ext/bg/js/options-form.js
index 7139958a..d3275926 100644
--- a/ext/bg/js/options-form.js
+++ b/ext/bg/js/options-form.js
@@ -41,6 +41,7 @@ function getFormData() {
optionsNew.anki.enable = $('#anki-enable').prop('checked');
optionsNew.anki.tags = $('#card-tags').val().split(/[,; ]+/);
+ optionsNew.anki.htmlCards = $('#generate-html-cards').prop('checked');
optionsNew.anki.sentenceExt = parseInt($('#sentence-detection-extent').val(), 10);
if (optionsOld.anki.enable) {
optionsNew.anki.terms.deck = $('#anki-terms-deck').val();
@@ -101,6 +102,7 @@ $(document).ready(() => {
$('#anki-enable').prop('checked', options.anki.enable);
$('#card-tags').val(options.anki.tags.join(' '));
+ $('#generate-html-cards').prop('checked', options.anki.htmlCards);
$('#sentence-detection-extent').val(options.anki.sentenceExt);
$('input, select').not('.anki-model').change(onOptionsChanged);
$('.anki-model').change(onAnkiModelChanged);