From 8e5ce8494bff8559b8e5d65c7ce03b28eebd0f02 Mon Sep 17 00:00:00 2001 From: Alan Silva Date: Mon, 19 Oct 2026 08:22:16 +0100 Subject: [PATCH] =?UTF-8?q?web:=20background-tasks=20bar=20=E2=80=94=20run?= =?UTF-8?q?ning=20shells,=20capped=20list,=20bounded=20output=20(C11)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add the background-tasks bar to an open conversation: heading "Background tasks" plus "{n} running", shown only while at least one shell is running. Rows are capped at 3 (BACKGROUND_TASK_VISIBLE_ROWS) and the list scrolls beyond; each row is a play glyph, "Running", a one-line shellCommandSummary and "Details" while selected. Tapping a row toggles its detail pane ("Command"/"Task identity"/"Status: running" plus the bounded output: spinner, error + "Retry", "Output unavailable for this task.", "No output yet.", or the monospace output and "Output is bounded to 64 KiB." with "Refresh"). Fold shell frames without ever marking the turn running, merge a blank command from the previous frame, list only running shells (an exited shell is never a task) and drop/relearn shells on reconnect via chat_shells. Refresh always rereads the bounded 64 KiB page from cursor 0. Update PARITY.md C11 with its captures and the replayed-vs-real note. Checks: node --check on every touched file; cd web && node --test test/ (456 pass). --- web/PARITY.md | 2 +- web/src/app.js | 257 +++++++++++++++++++++++- web/src/chat.js | 185 ++++++++++++++++- web/src/protocol.js | 13 ++ web/src/repository.js | 59 ++++++ web/styles.css | 83 ++++++++ web/test/chat.test.mjs | 183 +++++++++++++++++ web/test/repository.test.mjs | 103 +++++++++- web/test/ui-smoke.mjs | 372 +++++++++++++++++++++++++++++++++++ 9 files changed, 1239 insertions(+), 18 deletions(-) diff --git a/web/PARITY.md b/web/PARITY.md index 6b5b05ad..3adf8a19 100644 --- a/web/PARITY.md +++ b/web/PARITY.md @@ -98,7 +98,7 @@ the pipeline list already carries — rather than a pluralised verb. | C8 | Composer: send, stop, attachments, draft | `chat_prompt`, `chat_interrupt` | done — the composer at the foot of an open conversation: a growing 1–6-row `