Lane 2: setting up a new server, and what it leaves waiting (#728) #759
Loading…
Reference in a new issue
No description provided.
Delete branch "build/lane2-setup-ui"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Lane 2's last PR: PUB-8,
IS-251–IS-258, plus J1's setup steps. Frontend and e2e only — everywebapp/backend/file in the diff is #754 arriving through a merge (git diff origin/main..HEAD -- webapp/backend/is empty).Stacked on #758, so its four pages appear here until that merges.
The seven steps
The drawing's, in
PublicPage: the strip, each step, and Ready with the list of what was skipped and a way back to each. Every step is skippable and every skip is remembered — D70, it reminds and never blocks — and each is recorded throughPOST /api/setup/steps/{step}as the person leaves it, so the state survives a closed tab.Nothing writes settings by a second path. The steps drive endpoints that already existed: retention, the backup config and run, the bot settings,
regenerate-key,bot/ping, andwhisper/test+llm/test— Instance health's own tests, which is what PUB-8's header asked for.The two departures, verified in the committed code
SECRET_KEYappears twice inSetup.jsx: once in the file header explaining this, once as<code>SECRET_KEY</code>naming the environment variable. No value, no Copy button, no endpoint added. The step says where the key lives, says "A backup restored without it cannot read any of them", and reportssecrets-health— "All 2 encrypted settings can be read with the key this server is running with", or names the ones that cannot. The checkbox gates Next viaButton why(aria-disabled, in tab order, the reason on screen) and never gates Skip.One shared-component change, and it is additive
src/ui/Choices/index.jsxgains a named exportCheck: one.choicerow with a checkbox instead of a radio.Choicesitself has zero removed lines andChoices.csshas no diff at all;src/ui/index.jschanges by one line.The drawing's key step is
<label class="choice"><input type="checkbox">, and the kit had no single checkbox —Choicesis radios andToggleis arole="switch"for a setting. The alternatives were restating.choiceinSetup.css, which is how a kit stops being one, or a radio group of one, which cannot be unticked.What could not be built as drawn
pub--wide— following Help, Licences, Privacy and Accessibility one PR ago:widein a still means "fill the still"; in a window it is 1560px, and a form at that measure is unreadable.Segmented, not the drawing's.pickrow:.pickwas never ported, andSegmentedis lane 0's port of that idea withrole=radiogroupand arrow keys.IS-254does not repeat "Nobody can keep more." Same reason the privacy page does not: it is not true of the code yet (D24).And one departure from my own instruction, flagged
I asked for the first-run redirect to fire when the setup state is pristine. It also requires the administrator to have nothing on Home — because pristine is also true of every instance that predates the wizard, so pristine alone would bounce the administrator of a year-old server into "Setting up this server" on upgrade day, which is the nag D70 rules out. It is also why the seeded e2e stack is not a first boot. Good catch; say the word if you want it dropped.
A finding worth carrying into every later lane
Chromium folds CSS generated content into the accessible name and jsdom does not. The step strip's tick and turned arrow are
::before— the drawing's own CSS — so a completed step's accessible name was"✓ You — done"in a real browser and"You — done"under jsdom. The unit tests passed and the journey failed on the same assertion.That is a real defect, not a test artefact: any state carried only by
::beforeplus a hidden span is at the mercy of it. The state is anaria-labelnow, which both agree on and which keeps the visible word inside the name (WCAG 2.5.3), leaving the glyph as decoration.Checks
lint 0 errors (239 warnings, the unchanged legacy count; this PR's files are warning-free), 1392 tests in 123 files (was 1348), build clean. Journeys:
--grep J1exit 0, 6 passed, 3 skipped — the three are lane 3's placeholder across the three projects — with axe clean on/setupin all three. Every step looked at in the built app, desktop and ~492px, both themes.🤖 Generated with Claude Code
The journeys' axe gate failed on /dashboard in all three phone runs, on WCAG 2.2's 2.5.8 (target size): Target has insufficient size (62.8px by 20.1px, should be at least 24px by 24px). Safe clickable space has a diameter of 23.4px instead of at least 24px. `a:nth-child(3)` is the first footer link — `Footer` renders the version, then a separator and a link per door — and it was 0.6px short. Not a pre-existing fault: with two doors the footer never wrapped, so no link had a vertical neighbour and the spacing exemption carried it. This PR takes it to six (D15, amended by D63), they wrap on a phone, and vertically adjacent links then sat 1.6px apart. So the links carry a real target size, 24px, and the row gap goes to 4px. Both, deliberately: either alone lands within a rounding error of the threshold, and a gate that passes by 0.6px is one font-size change from failing again. 24px and not `--touch`'s 44px. That rule is for controls; a footer of six 44px links is a third of a phone screen, and 2.5.8 AA asks for 24 — 44 is 2.5.5, which is AAA. The text does not move: the box grows around the same line. Docker Desktop was down on this machine after a crash, so this is checked by CI's axe gate rather than locally — which is the only thing that can really check it in any case. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>