From 6541677cba2d5ed51e29fe124c7416d4bb9fd75e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?S=C4=ABlav=C4=81pi=20Cheesley?=
Date: Wed, 23 Sep 2026 20:03:38 +0100
Subject: [PATCH] Make the page usable: board beside the text, and Return takes
the offer
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Three things found by using the hosted app rather than by testing it.
Pressing Return on a finished drill threw away whatever the result card was
offering. The keyboard path went straight to "start this drill again" instead
of through the same handler the button uses, so a card reading "Repair drill ยท
T" restarted the lesson when you pressed a key. That is the same failure as a
button that lies, reached by a different route, and it silently discarded the
repair every time.
The board sat 770 pixels above the text being typed, so a learner could see
where the next key was or what they were meant to type, but never both. The
readout naming the key and the diagram showing it are meant to reinforce each
other and could not. They now sit side by side above 62rem and stack below it,
in the order they appear in the markup, so what the eye follows and what Tab
follows still agree.
The sprint, the ladder, the statistics and the saving controls were somewhere
down a five-thousand-pixel page with nothing to say they existed. There is a
section navigation now, revealed once a layout is loaded and skippable by the
link that already existed; the ladder is a grid of cards instead of thirteen
full-width rows; choosing a layout and reading what was found in it share one
band instead of two; and the instructions stand down once they have been
followed. The page is 3786 pixels where it was 5366, and the content uses the
window instead of 42 per cent of it.
New tests guard all of it, including at 380 pixels where the columns stack.
The keyboard-only journey is updated for the navigation: it now takes the skip
link, which is what the skip link is for.
Co-Authored-By: Claude Opus 5
---
index.html | 176 ++++++++++++++++++++------------------
src/ui/drill-view.ts | 6 +-
src/ui/load-form.ts | 7 ++
src/ui/theme.css | 144 ++++++++++++++++++++++++++++++-
tests/e2e/drill.spec.ts | 25 ++++++
tests/e2e/layout.spec.ts | 110 ++++++++++++++++++++++++
tests/e2e/pending.spec.ts | 11 ++-
7 files changed, 389 insertions(+), 90 deletions(-)
create mode 100644 tests/e2e/layout.spec.ts
diff --git a/index.html b/index.html
index f25cf3e..514013e 100644
--- a/index.html
+++ b/index.html
@@ -19,49 +19,56 @@
Touchwright
-
-
-
Load your layout
-
- Export your layout from the MoErgo Layout Editor and choose the file here. Nothing is
- uploaded anywhere; the file is read in your browser.
-
-
-
-
-
-
-
+
-
-
What that layout looks like
-
-
-
-
-
-
Where those keys are
-
-
-
- Each cap is outlined in the colour of the finger that owns it.
-
-
-
- Every key on the board, in words
-
-
-
+
+
+
+
Load your layout
+
+ Export your layout from the MoErgo Layout Editor and choose the file here. Nothing is
+ uploaded anywhere; the file is read in your browser.
+
+
+
+
+
+
+
+
+
+
What that layout looks like
+
+
+
+
+
+
+
Where those keys are
+
+
+
+ Each cap is outlined in the colour of the finger that owns it.
+
+
+
+ Every key on the board, in words
+
+
+
-
-
-
Practise
-
- Choose Start drill and type what you see.
- Press Escape at any time to give the keyboard back. The page then works
- as usual, and Resume drill picks up exactly where you left off. Tab always moves
- focus, even while the drill has the keyboard.
-
-
-
-
-
-
-
-
-
-
-
-
- Escape releases the keyboard from anywhere in the drill.
-
-
-
-
-
-
-
-
How that went
-
-
-
-
-
- Or press any key to start the next drill.
+
+
+
+
+
+ Escape releases the keyboard from anywhere in the drill.