2 0
Sign in to rate

Default Easy Review Helper

<10kB. Updated 2019-07-08. Only supports Anki 2.1.x.
The author has shared 35 other item(s).

Description

An experimental very simple add-on prototype made by request. It's entirely based on Replay buttons on card. It only adds "defease" command. The add-on can be used to press the default button using JavaScript by calling pycmd("defease") instead of using Space or Enter. It's similar to pycmd("ans") to show the back side of the card or pycmd("ease3") to press 3rd button (usually it's Good, but can be Easy if it's a learning card). For example, <script>pycmd("ans")</script> on the Front Template and no {{FrontSide}} on the Back Template can be used to create something similar to one-sided flashcards, but only on the desktop version of Anki. The add-on can be used with typing cards to automatically skip the back side of the card and move to the next card if the typed answer was correct. But to do it, it's necessary to add at least the following code to the back side of the card: <script> var typeans = document.getElementById("typeans"); if (typeans) { var incorrect = typeans.querySelector(".typeBad, .typeMissed"); if (incorrect == null) { pycmd("defease"); } } </script> But the back side of the card will still be shown for a second and as a quick workaround something like this can be done instead: 1. Wrap the Back Template with <div class="back">. <div class="back"> {{FrontSide}} <hr id=answer> {{Back}} </div> 2. Add the following JavaScript code to the Back Template. <script> if (document.documentElement.classList.contains('mobile') == false) { var typeans = document.getElementById("typeans"); if (typeans) { var incorrect = typeans.querySelector(".typeBad, .typeMissed"); if (incorrect == null) { pycmd("defease"); } else { document.querySelector(".back").style.visibility = "visible"; } } } </script> 3. Add the following CSS code to the Styling: html:not(.mobile) .back { visibility: hidden; } Maybe sometime later it'd be better to make new add-on, don't use CSS and JavaScript and don't show the back side of the card if the typed answer was correct. Nickolay <kelciour@gmail.com>

Download

As add-ons are programs downloaded from the internet, they are potentially malicious. You should only download add-ons you trust.

To download this add-on, please copy and paste the following code into Anki 2.1:

815985411

If you were linked to this page from the internet, please open Anki on your computer, go to the Tools menu and then Add-ons>Browse & Install to paste in the code.

All Anki 2.1.x Add-Ons

Reviews

on 1583007653
Thank you for sharing this.
on 1562597920
Thanks! Works great!