Quiz list: drill down by Books → book and Lectures → year
The All tab is now a click-through of category cards — Books, Lectures & Conversations, Other quizzes — each opening its books or years, then the quizzes themselves. Only categories with quizzes get a card. The position and tab live in the URL (?in=books&book=bg, ?tab=todo), so refresh, Back and shared links keep your place. Book quizzes list in chapter order. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
3af4e1bcd3
commit
0a23ab59f7
+6
-1
@@ -72,7 +72,12 @@ export function groupQuizzes(cards: QuizCard[]): QuizSections {
|
||||
.map(([code, quizzes]) => ({
|
||||
key: code,
|
||||
label: BOOK_NAMES[code] ?? code.toUpperCase(),
|
||||
quizzes,
|
||||
// Chapter order (/books/bg/2 before /books/bg/10), not newest first.
|
||||
quizzes: [...quizzes].sort((a, b) =>
|
||||
(a.target_path ?? "").localeCompare(b.target_path ?? "", undefined, {
|
||||
numeric: true,
|
||||
}),
|
||||
),
|
||||
})),
|
||||
lectures: [...years.entries()]
|
||||
// Oldest first; undated (null) last.
|
||||
|
||||
Reference in New Issue
Block a user