From df1ffdd5046a2ceb44fa41b80c133f137e2e4de7 Mon Sep 17 00:00:00 2001 From: iris Date: Fri, 5 Jun 2026 13:01:27 +0200 Subject: [PATCH] docs(agent): document model quick-picker in overflow menu --- docs/web-ui/agent.md | 34 ++++++++++++++++++++++------------ 1 file changed, 22 insertions(+), 12 deletions(-) diff --git a/docs/web-ui/agent.md b/docs/web-ui/agent.md index b9bbd8b7..c8271f67 100644 --- a/docs/web-ui/agent.md +++ b/docs/web-ui/agent.md @@ -63,18 +63,28 @@ through. Three flex columns: click opens the loose-ends flyout. - **Overflow button** (`⋯`): always visible. Opens a frosted popover (`#overflow-menu`, positioned outside the header to escape any - stacking context) with four rows: `↑ dashboard` (link), `↻ rebuild - container` (POST confirm, same action as the dashboard R3BU1LD - button), `↻ new claude session` (POST confirm → `POST - /api/new-session`; next turn drops `--continue`), `🔓 logout` - (POST confirm → `POST /api/logout`; SIGINTs any in-flight turn, - wipes OAuth credential files, flips the agent to `needs_login` - — session history preserved). All destructive actions require - one extra click to acknowledge — rare ops shouldn't live in the - primary state strip. The popover's display rules are scoped to - `:not([hidden])` so the `[hidden]` HTML attribute's UA `display: - none` isn't overridden by the author CSS's `display: flex` — - the popover stays hidden until JS removes the attribute. + stacking context) with four management rows followed by a model + quick-picker section: `↑ dashboard` (link), `↻ rebuild container` + (POST confirm, same action as the dashboard R3BU1LD button), + `↻ new claude session` (POST confirm → `POST /api/new-session`; + next turn drops `--continue`), `🔓 logout` (POST confirm → `POST + /api/logout`; SIGINTs any in-flight turn, wipes OAuth credential + files, flips the agent to `needs_login` — session history + preserved). All destructive actions require one extra click to + acknowledge — rare ops shouldn't live in the primary state strip. + Below a separator, a **model quick-picker** section labelled + `model` renders three one-click shortcuts: `haiku (fast)`, + `sonnet (balanced)`, `opus (powerful)`. Clicking a button POSTs + `/api/model` with the alias (same path as the `/model ` + slash command). The button for the currently-active model is + highlighted via the `active` class; `renderModelChip` keeps the + picker state in sync with live `model_changed` events so it stays + accurate when the model is changed from another session. Clicking + the already-active model closes the menu without an extra POST. + The popover's display rules are scoped to `:not([hidden])` so the + `[hidden]` HTML attribute's UA `display: none` isn't overridden by + the author CSS's `display: flex` — the popover stays hidden until + JS removes the attribute. `/api/state` is fetched once on cold load (+ while `status === 'needs_login_in_progress'`); all other updates arrive via