summaryrefslogtreecommitdiff
path: root/ext/settings.html
diff options
context:
space:
mode:
authorsoriac <soriac@users.noreply.github.com>2021-04-30 18:57:53 -0300
committerGitHub <noreply@github.com>2021-04-30 17:57:53 -0400
commitba3f7b3e96df7f034b56132d8c2c90289e16c288 (patch)
treee8f87b440d79d3c43904d43f04fe9c396602c76a /ext/settings.html
parent69a739f00a335496e9222b4758d9c8bf2190df92 (diff)
Show any custom tags on words that have anki cards created (#1628)
* Proof-of-concept for showing card tags (#1626) * Resolved most PR comments: - Added a snackbar notification when clicking tag button - Replaced magnifying glass icon with new tag icon - Button now contains a span w/icon, to use text color - Removed unnecessary attributes from button - Backend now returns full noteInfos object - Frontend now handles filtering tags * Add options to show/hide tag button & filter tags * Do not show tags button if, after filtering, we have zero tags. * Change tags option to enums, optimize tags intersection check & fix code style. * Update options-util.js to include new tag options. * Fix wording on new tag setting. * Add CSS to remove hidden buttons from the display layout. * getAnkiNoteInfo extra parameter for additional info. * Add new tag option to tests. * Remove unnecessary changes related to anki tags option. * Code style fixes.
Diffstat (limited to 'ext/settings.html')
-rw-r--r--ext/settings.html28
1 files changed, 28 insertions, 0 deletions
diff --git a/ext/settings.html b/ext/settings.html
index 7f9cc8ec..872dac4d 100644
--- a/ext/settings.html
+++ b/ext/settings.html
@@ -1565,6 +1565,34 @@
<label class="toggle"><input type="checkbox" data-setting="anki.suspendNewCards"><span class="toggle-body"><span class="toggle-track"></span><span class="toggle-knob"></span></span></label>
</div>
</div></div>
+ <div class="settings-item advanced-only">
+ <div class="settings-item-inner">
+ <div class="settings-item-left">
+ <div class="settings-item-label">
+ Show card tags
+ <a class="more-toggle more-only" data-parent-distance="4">(?)</a>
+ </div>
+ </div>
+ <div class="settings-item-right">
+ <select data-setting="anki.displayTags">
+ <option value="never">Never</option>
+ <option value="always">Always</option>
+ <option value="non-standard">Non-Standard</option>
+ </select>
+ </div>
+ </div>
+ <div class="settings-item-children more" hidden>
+ <p>
+ When coming across a word that is already in an Anki deck, a button will appear that shows
+ the tags the card has. If set to <em>Non-Standard</em>, all tags that are included in the
+ <em>Card tags</em> option will be filtered out from the list. If no tags remain after filtering,
+ then the button will not be shown.
+ </p>
+ <p>
+ <a class="more-toggle" data-parent-distance="3">Less&hellip;</a>
+ </p>
+ </div>
+ </div>
<div class="settings-item settings-item-button" data-modal-action="show,anki-cards"><div class="settings-item-inner">
<div class="settings-item-left">
<div class="settings-item-label">Configure Anki card format&hellip;</div>