aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/server/routes/study.ts
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2025-12-31 13:25:42 +0900
committernsfisis <nsfisis@gmail.com>2025-12-31 13:25:42 +0900
commitce9011bf351d9666bb2e81c92ae06a0eb1716d12 (patch)
treebeea42ad8c4b755d1c36705c6c052d5b0588eaac /src/server/routes/study.ts
parent5e42032146de07d4ab53598e9311efd145f9dfc3 (diff)
downloadkioku-ce9011bf351d9666bb2e81c92ae06a0eb1716d12.tar.gz
kioku-ce9011bf351d9666bb2e81c92ae06a0eb1716d12.tar.zst
kioku-ce9011bf351d9666bb2e81c92ae06a0eb1716d12.zip
feat(study): render note-based cards using template system
Update StudyPage to support both legacy cards (direct front/back) and note-based cards (template rendering with field values). Add new CardForStudy type that includes note type templates and field values as a name-value map for efficient client-side rendering. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Diffstat (limited to 'src/server/routes/study.ts')
-rw-r--r--src/server/routes/study.ts6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/server/routes/study.ts b/src/server/routes/study.ts
index ccb0692..9c16699 100644
--- a/src/server/routes/study.ts
+++ b/src/server/routes/study.ts
@@ -51,11 +51,7 @@ export function createStudyRouter(deps: StudyDependencies) {
}
const now = new Date();
- const dueCards = await cardRepo.findDueCardsWithNoteData(
- deckId,
- now,
- 100,
- );
+ const dueCards = await cardRepo.findDueCardsForStudy(deckId, now, 100);
return c.json({ cards: dueCards }, 200);
})