From b60ecc38b3c4eba03850694f936e137846ad5903 Mon Sep 17 00:00:00 2001 From: Nathan Vegdahl Date: Thu, 4 Sep 2025 06:31:18 +0900 Subject: [PATCH] Use dictionary form of word for tracking learning. --- src/lib.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/lib.rs b/src/lib.rs index edb0ff6..4edf15e 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -346,7 +346,11 @@ fn add_html_furigana( (surface, kana, word, pitches) }; - let needs_help = learner.process(surface); + let needs_help = if !word.is_empty() && !is_kana_str(surface) { + learner.process(word) + } else { + learner.process(surface) + }; if !needs_help { new_text.push_str(surface);