2021-04-12 06:18:30 +02:00
|
|
|
<!--
|
|
|
|
Copyright: Ankitects Pty Ltd and contributors
|
|
|
|
License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
|
|
|
|
-->
|
|
|
|
<script lang="ts">
|
2021-04-22 19:55:26 +02:00
|
|
|
import * as tr from "lib/i18n";
|
2021-05-13 07:23:16 +02:00
|
|
|
import CheckBox from "./CheckBox.svelte";
|
2021-04-12 06:18:30 +02:00
|
|
|
import EnumSelector from "./EnumSelector.svelte";
|
2021-04-25 10:40:02 +02:00
|
|
|
import type { DeckOptionsState } from "./lib";
|
2021-04-12 06:18:30 +02:00
|
|
|
|
2021-04-25 10:40:02 +02:00
|
|
|
export let state: DeckOptionsState;
|
2021-04-16 15:29:21 +02:00
|
|
|
let config = state.currentConfig;
|
|
|
|
let defaults = state.defaults;
|
2021-04-12 06:18:30 +02:00
|
|
|
|
2021-05-13 07:23:16 +02:00
|
|
|
const reviewOrderChoices = [
|
|
|
|
tr.deckConfigSortOrderDueDateThenRandom(),
|
|
|
|
tr.deckConfigSortOrderAscendingIntervals(),
|
|
|
|
tr.deckConfigSortOrderDescendingIntervals(),
|
|
|
|
];
|
2021-04-12 06:18:30 +02:00
|
|
|
</script>
|
|
|
|
|
|
|
|
<div>
|
2021-05-13 07:23:16 +02:00
|
|
|
<h2>{tr.schedulingReviews()}</h2>
|
2021-04-12 06:18:30 +02:00
|
|
|
|
2021-05-16 13:50:51 +02:00
|
|
|
{#if state.v3Scheduler}
|
|
|
|
<EnumSelector
|
|
|
|
label={tr.deckConfigSortOrder()}
|
|
|
|
tooltip={tr.deckConfigReviewSortOrderTooltip()}
|
|
|
|
choices={reviewOrderChoices}
|
|
|
|
defaultValue={defaults.reviewOrder}
|
|
|
|
bind:value={$config.reviewOrder} />
|
|
|
|
{/if}
|
2021-04-12 06:18:30 +02:00
|
|
|
|
2021-05-13 07:23:16 +02:00
|
|
|
<CheckBox
|
|
|
|
label={tr.deckConfigBuryReviewSiblings()}
|
|
|
|
tooltip={tr.deckConfigBuryTooltip()}
|
|
|
|
defaultValue={defaults.buryReviews}
|
|
|
|
bind:value={$config.buryReviews} />
|
2021-04-12 06:18:30 +02:00
|
|
|
</div>
|