agentgui 1.0.957 → 1.0.958

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/AGENTS.md CHANGED
@@ -1,12 +1,26 @@
1
1
  # AgentGUI — Agent Notes
2
2
 
3
- ## GUI predictability + polish sweep (2026-06-05) — fifth maximum-effort run
3
+ ## GUI cohesion sweep (2026-06-10) — seventh maximum-effort run
4
+
5
+ The GUI reads as ONE polished chat-agent product (claude.ai/code / cowork / Claude-Desktop), not a kit of parts. New workflow deliverable `.claude/workflows/gui-cohesion.js` — 6 cohesion *lenses* (chat-agent-feel, fsbrowse-file-view, simultaneous-live-sessions, shell-navigation, visual-system, crosscut-perf-a11y-security) benchmark each surface against the real reference products, an adversarial verifier confirms each gap (kept-typography guard), a synthesizer orders them. Distinct from `gui-audit` (jank), `gui-overhaul` (new surfaces), `gui-predictability-polish` (primitive edges) — this one hunts the **product-cohesion/feel gap**. Ran 61 agents -> 40 confirmed gaps (`PUNCHLIST-COHESION.md`).
6
+
7
+ **Chat reads like a chat agent.** Every fenced code block has a per-block copy button: kit `chat.js` `injectCodeCopy()` wraps each rendered-markdown `<pre>` in `.chat-code-block` and injects a reveal-on-hover `.chat-code-copy` (idempotent via `data-copy-wired`, label flips copy->copied); the structured `CodeNode` head and `FilePreviewCode` header carry the same control. `ChatMessage` per-message actions render a text label beside the icon and use a real `copy` icon (not `page`). Mid-stream prose containing a code fence renders as a monospaced `<pre>` shell (`agent-chat.js` sets `preShell`, `chat.js` text renderer honors it) so it does not reflow prose->block on settle. `ChatComposer` shows a `context` line (agent · model · cwd) at the point of typing; `AgentChat` threads a stable per-agent `avatar` and `followups` chips after a settled turn.
8
+
9
+ **Files is an fsbrowse-grade browser.** Kit `files.js` `FileGrid` caps a large dir at `FILE_GRID_CAP=200` with a `shown`/`onShowMore` "show N more" row, uses `role=group` (NOT `listbox` — the rows host real action `<button>`s, which is invalid listbox/option semantics), `FileRow` shows a `permissions`/`locked` ASCII tag (`read-only`/`no access`) and disables open for EACCES, and a `RootsPicker` segmented control replaces the borrowed history `.pill`. `files-modals.js` ships `FilePreviewPane` (a non-modal split-view region for the shell pane) alongside the modal `FileViewer` (kept as the `<900px` fallback), both with an ASCII `prev`/`next` stepper (`onPrev`/`onNext` + ArrowLeft/Right). The app renders the preview INTO the WorkspaceShell pane when wide, modal only when narrow.
10
+
11
+ **All live sessions, managed at once.** Kit `sessions.js` `SessionCard` gains a `stale` status (`idle` word + non-pulsing `.status-dot-stale`, so a stuck agent differs from a busy one), a `selectable` checkbox (`role=checkbox`), and an `active` accent. `SessionDashboard` gains a sort `Select` (status/elapsed/activity/errors) + filter `SearchInput` + errors-only toggle, `stop-selected` bulk control, and a `streamState` line (the dashboard is listening even at 0 running). App `liveMain` derives `stale` (no activity >45s and no running tool), floats error-then-stale to the front, and keeps a per-sid `state.live.tally` incremented straight off the SSE stream so a brand-new chat shows motion before it lands in the history index.
4
12
 
5
- A polish sweep on top of the shipped Claude-Desktop redesign (workflow `wf_980345e1-201`, 65 agents -> 44 adversarially-confirmed gaps, punch-list `PUNCHLIST-POLISH.md`). New workflow deliverable `.claude/workflows/gui-predictability-polish.js` (per-surface polish -> adversarial verify with kept-typography guard -> dependency-ordered plan; distinct from `gui-audit` which hunts jank and `gui-overhaul` which designs new surfaces this one hunts the *primitive/half-wired* edge in the SHIPPED shell).
13
+ **One shell, one visual system.** Kit `shell.js` `WorkspaceShell` `stableFrame` keeps the pane grid TRACK present (width 0) when a tab has no pane, so the column geometry does not re-flow across tabs. There is ONE canonical `.status-dot-disc` (`status-dot-live` pulses via `color-mix`, `-error`/`-connecting`/`-stale` static, reduced-motion guarded) `index.html`'s `.status-dot`/`agentgui-pulse` override is deleted and the crumb dot uses the kit modifier classes. `.ds-session-row.rail-*` tones now match `.row.rail-*` (accent/purple-2/flame). The rail footer pins a `ThemeToggle`; page titles are sentence-case. Touch targets floor to 44px under `@media (pointer:coarse)`.
6
14
 
7
- **Kit changes (`c:\dev\anentrypoint-design`, rebuilt + vendored into `site/app/vendor/`).** (1) **files.js** — `FileGrid` gained `sort{key,dir,onSort}` + clickable column header (`FileSortHeader`, ASCII `asc/desc` not glyphs), `filter`, `loading` (renders new `FileSkeleton` shimmer), and keyboard nav (`role=listbox` + roving focus over `.ds-file-open`, Arrow/Home/End + Backspace->`onUp`); new exports `FileSkeleton`+`sortFiles` (dirs-first stable sort). (2) **sessions.js** `SessionCard` adds a words+disc status (`.ds-dash-status`, WCAG 1.4.1 — was colour-only), `lastActivity`+`currentTool` (`.ds-dash-activity`, so stuck vs busy differ), composes `counter`; `SessionDashboard` gained an `onStopAll` bulk header (`.ds-dash-header` count + stop-all). (3) **chat.js** `ChatMessage` `streaming` prop -> blinking `.chat-stream-caret`; `actions[]` -> hover `.chat-msg-actions` row. (4) **agent-chat.js** — `.agentchat-thread-wrap` + `.agentchat-jump` (scroll-listener reveals jump-to-latest when scrolled up; scroll-anchoring no longer fights a reading user); wires `onCopyMessage/onRetryMessage/onEditMessage` + `streaming`. (5) **context-pane.js** — `usage` prop -> a `last turn` panel (tokens/cost/turns/duration the dropped `result` event). (6) **shell.js (LOAD-BEARING mobile fix)** — the `<900px` sessions + pane drawers were DEAD (`.ws-sessions-open`/`.ws-pane-open` never toggled, no scrim): added `toggleWsDrawer`/`closeWsDrawers` + a `.ws-scrim` + crumb-hosted drawer toggles + Esc-close + auto-close-on-select; pane mobile reveal now keys off `.ws-pane-open` not `:not(.ws-pane-collapsed)`; rail/pane toggle aria-labels flip expand/collapse (were stale). chat.css: `.ds-session-group`/`-rows`/sticky label, session new+search bumped to 44px touch targets.
15
+ **Server.** `lib/http-handler.js` `/api/list` reports a per-entry `permissions` (`['read','write']` | `'EACCES'`) via `fs.accessSync`. New confined `/api/download` (raw bytes, `confineToRoots` realpath, 50MB cap, attachment disposition) — verified to 403 both out-of-roots and traversal. `backend.js` `listDir` carries `r.status` so the app maps 403/404 to plain copy; `downloadUrl()` is token-threaded.
16
+
17
+ **Scope cuts (documented in punch-list, not gaps).** File rename/delete (read-only browser, no mutation endpoints), upload/DropZone (legacy `routes-upload.js` is conversationId-keyed, not reusable), retry kept last-turn-only (mid-thread retry would destroy history).
18
+
19
+ **Witness.** localhost:3000/gm/ 0 console/page errors across chat/files/live/settings/history; per-block code copy + preview pane (opens with prev/next stepper) + dashboard stream line render; whole-DOM decorative-glyph count 0 (kept middot/ellipsis/dash); no h-scroll; a11y skip-link/`role=group`/`role=checkbox`/44px verified. Kit `lint-tokens`+`lint-glyphs` pass on build. **The app.js `C` destructure MUST list every kit component it calls (`Icon`/`RootsPicker`/`FilePreviewPane` were missing — the browser witness caught `Icon is not defined`).** Update flow unchanged: edit kit -> `node scripts/build.mjs` -> copy `dist/247420.{js,css}` into `site/app/vendor/anentrypoint-design/` -> witness -> push kit (rebase + rebuild dist when remote advances).
20
+
21
+ ## GUI predictability + polish sweep (2026-06-05) — fifth maximum-effort run
8
22
 
9
- **App wiring (`site/app/js/app.js`).** `sessionGroups()` -> kit `groups` (Running pinned + Today/Yesterday/This-week/Earlier); chat-tab inline search now shows server hits in the rail on BOTH tabs (was a dead control); `liveMain` fills per-session metrics/last-activity/current-tool from `sessionsBySid` + `stopAllActive`; `startLiveTick()` 1s elapsed advance; `filesMain` sort/filter/skeleton/roots-picker/always-toolbar/keyboard-up; initial `loadDir`/preview-fetch moved OUT of render (`navTo('files')` effect + scheduled microtasks) render is pure; `sendChat` captures `result.usage` -> `state.chat.usage`; `copyMessageText/retryLastTurn/editAndResend` message actions; `refreshActive` diffs `activeSig()` so the 3s poll only re-renders on real change.
23
+ Polish sweep on the shipped Claude-Desktop redesign (`wf_980345e1-201`, 65 agents -> 44 gaps, `PUNCHLIST-POLISH.md`); new workflow `.claude/workflows/gui-predictability-polish.js`. Landed `FileGrid` sort/filter/skeleton/keyboard, `SessionCard` words+disc status + last-activity/current-tool + `onStopAll`, `ChatMessage` streaming caret + `.chat-msg-actions`, `AgentChat` jump-to-latest, `ContextPane` last-turn usage, the load-bearing `<900px` drawer fix (`.ws-scrim` + `toggleWsDrawer`), and `confineToRoots()` realpath symlink-confinement on `/api/list,file,image`. The 7th run (above) supersedes/extends most of these. Full detail in rs-learn (recall "agentgui GUI predictability+polish sweep").
10
24
 
11
25
  **Security (`lib/http-handler.js`).** New `confineToRoots()` shared helper adds `fs.realpathSync` re-confinement to `/api/list`, `/api/file`, `/api/image` — a symlink living inside an allowed root but pointing OUTSIDE it passed the lexical prefix check but the resolved target now fails closed (symlink-escape / link-traversal, the workflow's one high-severity server gap).
12
26
 
package/CHANGELOG.md CHANGED
@@ -1,3 +1,10 @@
1
+ ## [Unreleased] - GUI cohesion sweep: one-product chat-agent feel (kit 9ef409a, app 15b626c)
2
+
3
+ - new workflow `.claude/workflows/gui-cohesion.js` (6 cohesion lenses -> adversarial verify -> ordered plan; 61 agents -> 40 confirmed gaps, `PUNCHLIST-COHESION.md`) — hunts the product-cohesion/feel gap vs claude.ai/code / cowork / Claude-Desktop, distinct from the audit/overhaul/predictability-polish workflows. Why: the shipped surfaces still read as a kit of parts.
4
+ - kit: per-block code copy buttons; fence-aware streaming (no prose->block reflow); composer context line + per-agent avatar + follow-up chips; SessionCard stale/idle status + select + active, SessionDashboard sort/filter/errors-only + stop-selected + stream-state; FileGrid large-dir cap + role=group + permissions tag + RootsPicker; FilePreviewPane split-view + prev/next stepper; ContextPane empty state; WorkspaceShell stable column geometry; one canonical status disc + unified rail tones + 44px touch targets. Why: close the cohesion gaps as correct kit defaults.
5
+ - app: inline file preview pane, live-session stale detection + per-sid SSE tally + bulk select, stable shell frame, sentence-case titles, rail ThemeToggle footer; deleted the index.html status-dot override (kit owns the disc). Server: `/api/list` per-entry permissions + confined `/api/download`. Why: wire the kit and eliminate the last app-layer override.
6
+ - witnessed localhost:3000/gm/ 0 console/page errors across all tabs, 0 decorative glyphs, no h-scroll, a11y verified.
7
+
1
8
  ## [Unreleased] - GUI moved into the anentrypoint-design kit, loaded from unpkg
2
9
 
3
10
  - the chat GUI now lives in the design kit: added a reusable `AgentChat` component to anentrypoint-design (agent-then-model picker + AICat auto-scroll/thinking + tool parts + cwd bar + caret-stable composer), pure props-in/vnode-out with all transport as host callbacks. Published via the kit's CI to npm -> unpkg.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "agentgui",
3
- "version": "1.0.957",
3
+ "version": "1.0.958",
4
4
  "description": "Multi-agent ACP client with real-time communication",
5
5
  "type": "module",
6
6
  "main": "electron/main.js",