mirror of
https://github.com/ankitects/anki.git
synced 2025-09-24 16:56:36 -04:00
Flip order of question/answer actions, and ascending/descending ease
https://forums.ankiweb.net/t/anki-24-10-beta/49989/53
This commit is contained in:
parent
de3b1754fa
commit
80ebdf1988
2 changed files with 76 additions and 62 deletions
|
@ -40,14 +40,14 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
|
|||
title: tr.deckConfigWaitForAudio(),
|
||||
help: tr.deckConfigWaitForAudioTooltip2(),
|
||||
},
|
||||
answerAction: {
|
||||
title: tr.deckConfigAnswerAction(),
|
||||
help: tr.deckConfigAnswerActionTooltip2(),
|
||||
},
|
||||
questionAction: {
|
||||
title: tr.deckConfigQuestionAction(),
|
||||
help: tr.deckConfigQuestionActionToolTip(),
|
||||
},
|
||||
answerAction: {
|
||||
title: tr.deckConfigAnswerAction(),
|
||||
help: tr.deckConfigAnswerActionTooltip2(),
|
||||
},
|
||||
};
|
||||
const helpSections = Object.values(settings) as HelpItem[];
|
||||
|
||||
|
@ -120,20 +120,6 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
|
|||
</SwitchRow>
|
||||
</Item>
|
||||
|
||||
<Item>
|
||||
<EnumSelectorRow
|
||||
bind:value={$config.answerAction}
|
||||
defaultValue={defaults.answerAction}
|
||||
choices={answerChoices()}
|
||||
>
|
||||
<SettingTitle
|
||||
on:click={() =>
|
||||
openHelpModal(Object.keys(settings).indexOf("answerAction"))}
|
||||
>
|
||||
{settings.answerAction.title}
|
||||
</SettingTitle>
|
||||
</EnumSelectorRow>
|
||||
</Item>
|
||||
<Item>
|
||||
<EnumSelectorRow
|
||||
bind:value={$config.questionAction}
|
||||
|
@ -148,5 +134,19 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
|
|||
</SettingTitle>
|
||||
</EnumSelectorRow>
|
||||
</Item>
|
||||
<Item>
|
||||
<EnumSelectorRow
|
||||
bind:value={$config.answerAction}
|
||||
defaultValue={defaults.answerAction}
|
||||
choices={answerChoices()}
|
||||
>
|
||||
<SettingTitle
|
||||
on:click={() =>
|
||||
openHelpModal(Object.keys(settings).indexOf("answerAction"))}
|
||||
>
|
||||
{settings.answerAction.title}
|
||||
</SettingTitle>
|
||||
</EnumSelectorRow>
|
||||
</Item>
|
||||
</DynamicallySlottable>
|
||||
</TitledContainer>
|
||||
|
|
|
@ -71,6 +71,7 @@ export function newSortOrderChoices(): Choice<DeckConfig_Config_NewCardSortOrder
|
|||
|
||||
export function reviewOrderChoices(fsrs: boolean): Choice<DeckConfig_Config_ReviewCardOrder>[] {
|
||||
return [
|
||||
...[
|
||||
{
|
||||
label: tr.deckConfigSortOrderDueDateThenRandom(),
|
||||
value: DeckConfig_Config_ReviewCardOrder.DAY,
|
||||
|
@ -91,14 +92,9 @@ export function reviewOrderChoices(fsrs: boolean): Choice<DeckConfig_Config_Revi
|
|||
label: tr.deckConfigSortOrderDescendingIntervals(),
|
||||
value: DeckConfig_Config_ReviewCardOrder.INTERVALS_DESCENDING,
|
||||
},
|
||||
{
|
||||
label: fsrs ? tr.deckConfigSortOrderDescendingDifficulty() : tr.deckConfigSortOrderAscendingEase(),
|
||||
value: DeckConfig_Config_ReviewCardOrder.EASE_ASCENDING,
|
||||
},
|
||||
{
|
||||
label: fsrs ? tr.deckConfigSortOrderAscendingDifficulty() : tr.deckConfigSortOrderDescendingEase(),
|
||||
value: DeckConfig_Config_ReviewCardOrder.EASE_DESCENDING,
|
||||
},
|
||||
],
|
||||
...difficultyOrders(fsrs),
|
||||
...[
|
||||
{
|
||||
label: tr.deckConfigSortOrderRelativeOverdueness(),
|
||||
value: DeckConfig_Config_ReviewCardOrder.RELATIVE_OVERDUENESS,
|
||||
|
@ -115,6 +111,7 @@ export function reviewOrderChoices(fsrs: boolean): Choice<DeckConfig_Config_Revi
|
|||
label: tr.decksLatestAddedFirst(),
|
||||
value: DeckConfig_Config_ReviewCardOrder.REVERSE_ADDED,
|
||||
},
|
||||
],
|
||||
];
|
||||
}
|
||||
|
||||
|
@ -197,3 +194,20 @@ export function questionActionChoices(): Choice<DeckConfig_Config_QuestionAction
|
|||
},
|
||||
];
|
||||
}
|
||||
|
||||
function difficultyOrders(fsrs: boolean): Choice<DeckConfig_Config_ReviewCardOrder>[] {
|
||||
const order = [
|
||||
{
|
||||
label: fsrs ? tr.deckConfigSortOrderDescendingDifficulty() : tr.deckConfigSortOrderAscendingEase(),
|
||||
value: DeckConfig_Config_ReviewCardOrder.EASE_ASCENDING,
|
||||
},
|
||||
{
|
||||
label: fsrs ? tr.deckConfigSortOrderAscendingDifficulty() : tr.deckConfigSortOrderDescendingEase(),
|
||||
value: DeckConfig_Config_ReviewCardOrder.EASE_DESCENDING,
|
||||
},
|
||||
];
|
||||
if (fsrs) {
|
||||
order.reverse();
|
||||
}
|
||||
return order;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue