Interleaved Decks: New item to choose for 'new card gather order' option.

This commit is contained in:
David Grundberg 2026-01-09 20:42:56 +01:00
parent 8f2144534b
commit 57e47a5f09
4 changed files with 19 additions and 0 deletions

View file

@ -142,6 +142,13 @@ deck-config-new-gather-priority-tooltip-2 =
can stop before all subdecks have been checked. This order is fastest in large collections, and
allows you to prioritize subdecks that are closer to the top.
`Interleaved Decks`: Gathers cards by taking one card at a time
from each deck in order. This allows new cards to be distributed
evenly across decks. Cards from each subdeck are gathered in
ascending position. If the number of decks are not equal to the
daily limit of the selected deck, the last round of cards will be
drawn from a random sample of decks.
`Ascending position`: Gathers cards by ascending position (due #), which is typically
the oldest-added first.
@ -197,6 +204,8 @@ deck-config-display-order-will-use-current-deck =
deck-config-new-gather-priority-deck = Deck
# Gather new cards ordered by deck, then ordered by random notes, ensuring all cards of the same note are grouped together.
deck-config-new-gather-priority-deck-then-random-notes = Deck, then random notes
# Gather new cards by interleaving decks, taking one card at a time from each deck in order.
deck-config-new-gather-priority-interleaved-decks = Interleaved Decks
# Gather new cards ordered by position number, ascending (lowest to highest).
deck-config-new-gather-priority-position-lowest-first = Ascending position
# Gather new cards ordered by position number, descending (highest to lowest).

View file

@ -69,6 +69,8 @@ message DeckConfig {
// Notes are randomly picked from each deck in alphabetical order.
// Siblings are consecutive, provided they have the same position.
NEW_CARD_GATHER_PRIORITY_DECK_THEN_RANDOM_NOTES = 5;
// One card from each deck at a time, ascending position in each deck.
NEW_CARD_GATHER_PRIORITY_INTERLEAVED_DECKS = 6;
// Ascending position.
// Siblings are consecutive, provided they have the same position.
NEW_CARD_GATHER_PRIORITY_LOWEST_POSITION = 1;

View file

@ -69,6 +69,10 @@ impl QueueBuilder {
NewCardGatherPriority::DeckThenRandomNotes => {
self.gather_new_cards_by_deck(col, NewCardSorting::RandomNotes(salt))
}
NewCardGatherPriority::InterleavedDecks => {
// TODO: Actually implement the new gathering option
self.gather_new_cards_by_deck(col, NewCardSorting::RandomNotes(salt))
}
NewCardGatherPriority::LowestPosition => {
self.gather_new_cards_sorted(col, NewCardSorting::LowestPosition)
}

View file

@ -25,6 +25,10 @@ export function newGatherPriorityChoices(): Choice<DeckConfig_Config_NewCardGath
label: tr.deckConfigNewGatherPriorityDeckThenRandomNotes(),
value: DeckConfig_Config_NewCardGatherPriority.DECK_THEN_RANDOM_NOTES,
},
{
label: tr.deckConfigNewGatherPriorityInterleavedDecks(),
value: DeckConfig_Config_NewCardGatherPriority.INTERLEAVED_DECKS,
},
{
label: tr.deckConfigNewGatherPriorityPositionLowestFirst(),
value: DeckConfig_Config_NewCardGatherPriority.LOWEST_POSITION,