From f723a2fea4da24d50381914f941a2d7d57a67fe3 Mon Sep 17 00:00:00 2001 From: Daniel Date: Fri, 11 Sep 2026 03:25:37 +0200 Subject: [PATCH] fix: opening a session no longer launches it MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Every link from the history went to /quizzes/:id, which auto-started. Clicking "Board Review IX" out of curiosity began a 243-question exam, clock running. That is why the links looked broken: they worked exactly as built, and what they did was wrong. Landing on a session now shows it — mode, length, and what the clock does — and starts when asked. The session rows and the analysis rail open the session's own analysis rather than the raw answer list, which is what a rail of past sessions is for. Sessions carry no category, so the row no longer prints one; that field was still showing the retired "PREP" label. Twenty tests asserted the old behaviour by mounting the player and waiting for the stem. They now start the session the way a person does, which is the point: the assertion was encoding a bug. Settings is on the list. Before restyling it, the question is what belongs there at all — several things have drifted in because there was nowhere else to put them. 249 frontend tests green. Co-Authored-By: Claude Opus 5 Claude-Session: https://claude.ai/code/session_01TqXevQJhxFrM7jJg82cgZN --- docs/TODO.md | 14 ++++++++++--- frontend/src/pages/AnalysisPage.jsx | 6 ++++-- frontend/src/pages/QuizPage.jsx | 30 +++++++++++++++++++++++++++- frontend/src/pages/QuizPage.test.jsx | 11 ++++++++-- frontend/src/pages/QuizPlayer.css | 8 ++++++++ frontend/src/pages/SessionsPage.jsx | 11 +++++++--- 6 files changed, 69 insertions(+), 11 deletions(-) diff --git a/docs/TODO.md b/docs/TODO.md index c50bcdb..06c9f23 100644 --- a/docs/TODO.md +++ b/docs/TODO.md @@ -18,9 +18,11 @@ Captured so nothing is lost while the article writing runs. table with time and peer statistics. Time per question is now recorded (`attempt_answers.seconds_spent`); answers from before that read "—" rather than claiming zero. -- [ ] **Return to a session with Resume, not an immediate start** — opening a - part-finished session currently restarts it. It should offer Resume and - Repeat, as the reference does. +- [x] **Return to a session rather than being launched into it** — `/quizzes/:id` + auto-started, so every link from the history fired a 243-question exam on + click. It now shows the session — mode, length, what the clock does — and + starts when asked. Session rows and the analysis rail open the session's + analysis rather than the raw answer list. - [ ] **An unsuspended exam keeps running** — closing an exam-mode session should let the clock continue and show the score when it expires, rather than quietly pausing. @@ -34,6 +36,12 @@ Captured so nothing is lost while the article writing runs. - [ ] **Adaptive session** — questions ordered by what would help most, with an explanation of how it decides. +### Settings +- [ ] **Revamp the settings page** — called out as the worst screen in the app. + Work out what belongs there at all before restyling it: account, theme, + exam objective, voice, integrations, data. Several of those have drifted + in because there was nowhere else to put them. + ### Editor and figures - [x] **Rich editing on the question page** — no new platform needed: Milkdown is already installed and used for articles, courses and the quick modal. diff --git a/frontend/src/pages/AnalysisPage.jsx b/frontend/src/pages/AnalysisPage.jsx index 5bad3bb..4e2ab36 100644 --- a/frontend/src/pages/AnalysisPage.jsx +++ b/frontend/src/pages/AnalysisPage.jsx @@ -107,8 +107,10 @@ export default function AnalysisPage() { :