Make the agents overview an interactive task dashboard (#39112)

## What changed

- Let users start tasks, open root sessions, rename tasks, and stop active work directly from the agents overview.
- Show details for the selected task on wide terminals and limit the overview to root sessions while still reflecting background activity.
- Preserve draft input and pending server requests when switching sessions so running roots and their subagents can continue in the background.
- Apply the selected project's working directory when dispatching from project grouping, including remote workspaces.

## Testing

- Expand overview rendering and interaction coverage for root filtering, dispatch, search, selection, renaming, and responsive input.
- Cover switching away from roots with running subagents and retaining background server requests.

GitOrigin-RevId: b7b0d33b7ecc077498efb756a0ad2fd425158b17
This commit is contained in:
Eric Traut authored and copyberry committed 2026-08-17 23:47:55 +00:00
1 parent 632420e67a
commit 319b2f72b1
11 files changed
+1129 -138

No files matched your search

+28
View File
@@ -445,6 +445,7 @@ impl App {
app_server
.start_thread_with_session_start_source(
&config, /*session_start_source*/ None,
/*remote_cwd_override*/ None,
)
.await
}
@@ -2320,6 +2321,33 @@ impl App {
AppEvent::AgentsOverviewThreadsLoaded { request_id, result } => {
self.apply_agents_overview_thread_refresh(app_server, request_id, result);
}
AppEvent::SelectAgentsOverviewThread { thread_id } => {
match self
.select_agents_overview_thread(tui, app_server, thread_id)
.await?
{
AppRunControl::Continue => {}
AppRunControl::Exit(reason) => return Ok(AppRunControl::Exit(reason)),
}
}
AppEvent::DispatchAgentsOverviewTask { prompt, cwd } => {
self.dispatch_agents_overview_task(app_server, prompt, cwd)
.await;
}
AppEvent::RenameAgentsOverviewThread { thread_id, name } => {
if let Err(error) = app_server.thread_set_name(thread_id, name.clone()).await {
if let Ok(mut state) = self.agents_overview.view_state.lock() {
state.input = name;
state.renaming = true;
}
self.chat_widget
.add_error_message(format!("Failed to rename task: {error}"));
}
}
AppEvent::StopAgentsOverviewThread { thread_id } => {
self.stop_agents_overview_thread(app_server, thread_id)
.await;
}
AppEvent::OpenAgentPicker => {
self.open_agent_picker(app_server).await;
}