Giter Site home page Giter Site logo

Comments (3)

SiriusStarr avatar SiriusStarr commented on September 21, 2024

Good catch! So there's not actually anything wrong with presenting Hard for a learning-stage card, it's just that it doesn't do anything different at that stage than answering Again. The behavior of bother "learning" and "lapsed" cards is identical, inasmuch as both Again and Hard reset the card to the first stage, whereas Good advances it and Easy instantly graduates it to review. Anki itself I believe only presents 3 buttons for those stages to avoid the false illusion of choice.

So in the short term, nothing wrong with leaving Hard as an option. However, I think it would be good moving forwards to reveal what stage a card is in, as one could imagine wanting to display this information to a user, and it would also allow changing the presentation of the answer buttons. One option would be to make getDueCardIndices return queue status as well, making its signature something like

type Queue
    = New
    | Learning
    | Reviewing
    | Lapsed

getDueCardIndices : Posix -> Deck a b -> List ( Int, Queue, Bool )

The downside to this is its a breaking change, necessitating a major version bump. Other downside is that it's simply more information that someone might not want to have.

Other option would be to keep getDueCardIndices the same and add a new function, like

type Queue
    = New
    | Learning
    | Reviewing
    | Lapsed

getDueCardIndices : Posix -> Deck a b -> List ( Int, Bool )

getDueCardIndicesAndQueue : Posix -> Deck a b -> List ( Int, Queue, Bool )

Which would allow one to choose which they wanted and would be a minor version.

from elm-spaced-repetition.

eniac314 avatar eniac314 commented on September 21, 2024

I think having the possibility to adapt displayed information and controls to the state of the card would be nice indeed.A new getDueCardIndicesAndQueue function would be welcome!
Great work anyway!

from elm-spaced-repetition.

SiriusStarr avatar SiriusStarr commented on September 21, 2024

Added in 7f71df9. See getDueCardIndicesWithDetails to get the detailed queue status and the like for all cards or getCardDetails for details on a single card.

Sorry turnaround was slow on that! Had a lot of demands on my time this past month.

from elm-spaced-repetition.

Related Issues (4)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.