Skip to content

feat(desktop): redesign the clarify prompt + fix its awaiting-input states - #52993

Merged
OutThisLife merged 2 commits into
mainfrom
bb/desktop-clarify-redesign
Jun 26, 2026
Merged

feat(desktop): redesign the clarify prompt + fix its awaiting-input states#52993
OutThisLife merged 2 commits into
mainfrom
bb/desktop-clarify-redesign

Conversation

@OutThisLife

Copy link
Copy Markdown
Collaborator

Summary

The desktop clarify prompt (the inline "answer this question" panel) was visually
out of step with the rest of the chat and had a few awkward lifecycle states.
This reworks both: a clean rebuild on the shared design tokens, plus modeling a
pending prompt as paused-on-you rather than an in-flight turn.

What changed

Redesign (clarify-tool.tsx)

  • Rebuilt on the shared --ui-* / --conversation-* tokens — compact panel, no
    bespoke card/animated ring, reads as part of the transcript.
  • Letter-key badges (A/B/C…) that double as a/b/c… keyboard
    shortcuts; selection lives on the badge alone (solid primary; outlined while
    "Other" is focused-but-empty).
  • "Other" is an inline content-sizing field (CSS field-sizing, same
    primitive as the commit bar / search field) — no view swap, no layout shift on
    focus.
  • Picking an option selects instead of auto-sending; a Continue button (or
    Enter) confirms. Focusing "Other" deselects any choice, so the two inputs can
    never both look selected.
  • The panel settles into the standard tool block once the turn stops running, so
    a stopped turn never strands a live, unanswerable prompt.

Awaiting-input behavior

  • New $activeSessionAwaitingInput (mirrors the pet's awaitingInput concept,
    scoped to the active session) composed from the existing clarify/approval/
    sudo/secret atoms.
  • The "thinking" stall timer is suppressed while a prompt waits — the agent
    isn't working, it's waiting on you.
  • Esc no longer interrupts the run while a prompt is pending, so you can leave
    a question parked (per-session) and come back to it. Stop and turn end clear
    the session's prompts + needsInput, so a resolved/aborted turn can't leave a
    dead panel or a stuck "needs input" dot.

Notes / out of scope

  • Clarify remains single-select — the clarify tool's protocol returns one
    string (max 4 choices + Other) across all surfaces (CLI/TUI/gateway/desktop).
    Real multiselect is a separate cross-surface change; the new UI is already
    shaped to drop in checkboxes when that lands.

Test plan

  • tsc typecheck clean
  • eslint clean on all touched files
  • vitest — clarify/prompts/approval/prompt-actions/state-cache/thread-loading (86) + new $activeSessionAwaitingInput contract tests
  • Manual: pick via mouse + a/b/c; type in Other (grows, no shift); Continue/Enter; Skip; hit Stop mid-clarify (panel settles, dot clears); switch chats and return (prompt still parked)

Screenshots

To attach: the rebuilt panel (choices + letter badges), the content-sizing "Other" field, and a selected/Continue state.

The inline clarify panel used its own card tokens, an animated ring, and
oversized spacing — out of step with every other tool row. Rebuild it on the
shared --ui-*/--conversation-* tokens: a compact panel, letter-key badges
(A/B/C…) that double as a/b/c… shortcuts, an inline content-sizing "Other" field
(CSS field-sizing — no view swap, no layout shift on focus), and a Continue
button so picking an option selects rather than auto-sends. Selection lives on
the letter badge alone (solid primary; outlined while Other is focused-but-empty).
Also settle the panel into the standard tool block once the turn stops running,
so a stopped turn no longer strands a live, unanswerable prompt.
A clarify/approval/sudo/secret prompt blocks the turn on the user, but the UI
treated it as an in-flight turn: the "thinking" timer kept ticking and Esc
interrupted the run — discarding a question you might want to come back to. Add
$activeSessionAwaitingInput (the pet's awaitingInput concept, scoped to the
active session) and use it to suppress the stall indicator and disarm Esc while a
prompt waits. Clear the session's prompts (and needsInput) on Stop and on turn
end so a resolved/aborted turn can't leave a dead panel or a stuck "needs input"
dot.
@OutThisLife
OutThisLife enabled auto-merge June 26, 2026 08:56
@OutThisLife
OutThisLife merged commit ca82d0a into main Jun 26, 2026
21 checks passed
@OutThisLife
OutThisLife deleted the bb/desktop-clarify-redesign branch June 26, 2026 08:57
@alt-glitch alt-glitch added type/feature New feature or request comp/desktop Electron desktop app (apps/desktop/*) P3 Low — cosmetic, nice to have labels Jun 26, 2026
waefrebeorn pushed a commit to waefrebeorn/slermes that referenced this pull request Jul 2, 2026
…arify-redesign

feat(desktop): redesign the clarify prompt + fix its awaiting-input states
habarmc1223-sudo pushed a commit to habarmc1223-sudo/hermes-agent-fluxmem that referenced this pull request Jul 8, 2026
…arify-redesign

feat(desktop): redesign the clarify prompt + fix its awaiting-input states
santhreal pushed a commit to santhreal/hermes-agent that referenced this pull request Jul 13, 2026
…arify-redesign

feat(desktop): redesign the clarify prompt + fix its awaiting-input states
Gravezzz pushed a commit to Gravezzz/hermes-agent that referenced this pull request Jul 21, 2026
…arify-redesign

feat(desktop): redesign the clarify prompt + fix its awaiting-input states
leewenjie pushed a commit to leewenjie/hermes-agent that referenced this pull request Aug 7, 2026
…arify-redesign

feat(desktop): redesign the clarify prompt + fix its awaiting-input states
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/desktop Electron desktop app (apps/desktop/*) P3 Low — cosmetic, nice to have type/feature New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants