diff --git a/apps/web/app/(dashboard)/agents/page.tsx b/apps/web/app/(dashboard)/agents/page.tsx index 70625205..7fb11efd 100644 --- a/apps/web/app/(dashboard)/agents/page.tsx +++ b/apps/web/app/(dashboard)/agents/page.tsx @@ -11,6 +11,7 @@ import { Wrench, FileText, BookOpenText, + MessageSquare, Timer, Trash2, Save, @@ -30,6 +31,7 @@ import type { AgentStatus, AgentTool, AgentTrigger, + AgentTriggerType, AgentTask, RuntimeDevice, CreateAgentRequest, @@ -820,7 +822,7 @@ function TriggersTab({ setTriggers((prev) => prev.filter((t) => t.id !== triggerId)); }; - const addTrigger = (type: "on_assign" | "scheduled") => { + const addTrigger = (type: AgentTriggerType) => { const newTrigger: AgentTrigger = { id: generateId(), type, @@ -869,18 +871,26 @@ function TriggersTab({
{trigger.type === "on_assign" ? ( + ) : trigger.type === "on_comment" ? ( + ) : ( )}
- {trigger.type === "on_assign" ? "On Issue Assign" : "Scheduled"} + {trigger.type === "on_assign" + ? "On Issue Assign" + : trigger.type === "on_comment" + ? "On Comment" + : "Scheduled"}
{trigger.type === "on_assign" ? "Runs when an issue is assigned to this agent" - : `Cron: ${(trigger.config as { cron?: string }).cron ?? "Not set"}`} + : trigger.type === "on_comment" + ? "Runs when a member comments on the agent's issue" + : `Cron: ${(trigger.config as { cron?: string }).cron ?? "Not set"}`}
@@ -959,6 +969,15 @@ function TriggersTab({ Add On Assign +