diff --git a/rslib/src/deckconfig/update.rs b/rslib/src/deckconfig/update.rs index 2ddfe59fa..47ead45d7 100644 --- a/rslib/src/deckconfig/update.rs +++ b/rslib/src/deckconfig/update.rs @@ -11,6 +11,7 @@ use anki_proto::deck_config::deck_configs_for_update::current_deck::Limits; use anki_proto::deck_config::deck_configs_for_update::ConfigWithExtra; use anki_proto::deck_config::deck_configs_for_update::CurrentDeck; use anki_proto::decks::deck::normal::DayLimit; +use fsrs::DEFAULT_WEIGHTS; use crate::config::StringKey; use crate::decks::NormalDeck; @@ -38,10 +39,12 @@ impl Collection { &mut self, deck: DeckId, ) -> Result { + let mut defaults = DeckConfig::default(); + defaults.inner.fsrs_weights = DEFAULT_WEIGHTS.into(); Ok(anki_proto::deck_config::DeckConfigsForUpdate { all_config: self.get_deck_config_with_extra_for_update()?, current_deck: Some(self.get_current_deck_for_update(deck)?), - defaults: Some(DeckConfig::default().into()), + defaults: Some(defaults.into()), schema_modified: self .storage .get_collection_timestamps()? diff --git a/ts/deck-options/FsrsOptions.svelte b/ts/deck-options/FsrsOptions.svelte index 59f9ccb1c..0afe34e39 100644 --- a/ts/deck-options/FsrsOptions.svelte +++ b/ts/deck-options/FsrsOptions.svelte @@ -214,7 +214,11 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
- + {tr.deckConfigWeights()}
diff --git a/ts/deck-options/WeightsInput.svelte b/ts/deck-options/WeightsInput.svelte index 2f4a387f7..f94c8b88b 100644 --- a/ts/deck-options/WeightsInput.svelte +++ b/ts/deck-options/WeightsInput.svelte @@ -4,9 +4,14 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html --> -