Gate graph display on fsrs status

This commit is contained in:
Damien Elmes 2023-09-23 15:59:02 +10:00
parent 8b849dd629
commit 2126ff9a16
5 changed files with 5 additions and 3 deletions

View file

@ -154,6 +154,7 @@ message GraphsResponse {
ReviewCountsAndTimes reviews = 9;
uint32 rollover_hour = 10;
Retrievability retrievability = 12;
bool fsrs = 13;
}
message GraphPreferences {

View file

@ -75,6 +75,7 @@ impl Collection {
card_counts: Some(ctx.card_counts()),
rollover_hour: self.rollover_for_current_scheduler()? as u32,
retrievability: Some(ctx.retrievability()),
fsrs: self.get_config_bool(BoolKey::Fsrs),
};
Ok(resp)
}

View file

@ -35,7 +35,7 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
const subtitle = tr.statisticsCardDifficultySubtitle();
</script>
{#if histogramData}
{#if sourceData?.fsrs}
<Graph {title} {subtitle}>
<HistogramGraph data={histogramData} />

View file

@ -35,7 +35,7 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
const subtitle = tr.statisticsCardEaseSubtitle();
</script>
{#if histogramData}
{#if !(sourceData?.fsrs ?? false)}
<Graph {title} {subtitle}>
<HistogramGraph data={histogramData} />

View file

@ -35,7 +35,7 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
const subtitle = tr.statisticsRetrievabilitySubtitle();
</script>
{#if histogramData}
{#if sourceData?.fsrs}
<Graph {title} {subtitle}>
<HistogramGraph data={histogramData} />