feat(ui): show pending/queued status in toast and background_output

This commit is contained in:
justsisyphus
2026-01-19 10:22:34 +09:00
parent 9710e10aca
commit 92942a562f
3 changed files with 31 additions and 11 deletions
+13 -7
View File
@@ -130,6 +130,18 @@ export class BackgroundManager {
log("[background-agent] Task queued:", { taskId: task.id, key, queueLength: queue.length })
const toastManager = getTaskToastManager()
if (toastManager) {
toastManager.addTask({
id: task.id,
description: input.description,
agent: input.agent,
isBackground: true,
status: "queued",
skills: input.skills,
})
}
// Trigger processing (fire-and-forget)
this.processKey(key)
@@ -227,13 +239,7 @@ export class BackgroundManager {
const toastManager = getTaskToastManager()
if (toastManager) {
toastManager.addTask({
id: task.id,
description: input.description,
agent: input.agent,
isBackground: true,
skills: input.skills,
})
toastManager.updateTask(task.id, "running")
}
log("[background-agent] Calling prompt (fire-and-forget) for launch with:", {
+2 -1
View File
@@ -137,7 +137,8 @@ export class TaskToastManager {
for (const task of queued) {
const bgIcon = task.isBackground ? "⏳" : "⏸️"
const skillsInfo = task.skills?.length ? ` [${task.skills.join(", ")}]` : ""
lines.push(`${bgIcon} ${task.description} (${task.agent})${skillsInfo}`)
const isNew = task.id === newTask.id ? " ← NEW" : ""
lines.push(`${bgIcon} ${task.description} (${task.agent})${skillsInfo} - Queued${isNew}`)
}
}