From 62613d4c7b57c7d32a6e5ad542aa676b05ed81e4 Mon Sep 17 00:00:00 2001 From: Navid Shad Date: Sun, 24 May 2026 18:56:56 +0300 Subject: [PATCH 1/5] feat(flashcard): new translation shape + L3+ fill-in cloze Read the new chunk-aware translation shape and add a fill-in-the-blank review card at Leitner level 3+, with recognition fallback. - Stop reading linguistic_data.examples[] / phonetic.ipa (gone after the save-schema overhaul); show phrase.translation plus per-chunk definitions on the card back, matching what the save modal displays. Same fix applied to the bundle PhraseCard list. - L3+ cloze: blank every confirmed chunk found in the source sentence; per-blank Check with green/red feedback, repeatable Recheck, and a Clear-wrong action to retry. Falls back to the recognition card when there is no chunk or the level is 1-2. - Wire chunks / Leitner level / source sentence through the review session; read boxLevel from the Mongoose _doc fallback and pick chunks that actually appear in the sentence. - Stable layout: fixed card height with internal scroll, and the cloze front is split into a flex-grow content area + a fixed-height action area so checking never shifts the sentence. - Expose the Chunk type to the frontend. Co-Authored-By: Claude Opus 4.7 (1M context) --- frontend/components/bundle/PhraseCard.vue | 11 +- .../practice/LeitnerReviewSession.vue | 39 ++- frontend/components/widget/FlashCard.vue | 273 ++++++++++++++---- frontend/pages/practice/flashcards-[id].vue | 23 +- frontend/types/database.type.ts | 6 +- 5 files changed, 284 insertions(+), 68 deletions(-) diff --git a/frontend/components/bundle/PhraseCard.vue b/frontend/components/bundle/PhraseCard.vue index dbfdf51..4e18f32 100644 --- a/frontend/components/bundle/PhraseCard.vue +++ b/frontend/components/bundle/PhraseCard.vue @@ -51,8 +51,8 @@
-