diff --git a/src/pages/settings/AgentsPage.tsx b/src/pages/settings/AgentsPage.tsx index 1044796..bd7ab76 100644 --- a/src/pages/settings/AgentsPage.tsx +++ b/src/pages/settings/AgentsPage.tsx @@ -12,7 +12,7 @@ export default function AgentsPage() { const load = async () => { try { const members = await getMembers(); - setAgents(members.filter((m) => m.type === "agent")); + setAgents(members.filter((m) => m.type === "agent" || m.type === "bridge")); } finally { setLoading(false); } @@ -22,6 +22,11 @@ export default function AgentsPage() { load(); }, []); + const typeIcon = (type: string) => { + if (type === "bridge") return { bg: "bg-purple-500/20", text: "text-purple-400", icon: "🔗" }; + return { bg: "bg-blue-500/20", text: "text-blue-400", icon: "🤖" }; + }; + return (
@@ -40,45 +45,56 @@ export default function AgentsPage() {
Нет агентов
) : (
- {agents.map((agent) => ( -
setSelected(agent)} - className="bg-[var(--card)] border border-[var(--border)] rounded-xl p-4 cursor-pointer hover:border-[var(--accent)]/50 transition-colors" - > -
-

{agent.name}

- - {agent.status === "online" ? "online" : "offline"} - -
-
@{agent.slug}
- - {agent.agent_config?.capabilities && agent.agent_config.capabilities.length > 0 && ( -
- {agent.agent_config.capabilities.map((cap) => ( - - {cap} - - ))} + {agents.map((agent) => { + const ti = typeIcon(agent.type); + return ( +
setSelected(agent)} + className="bg-[var(--card)] border border-[var(--border)] rounded-xl p-4 cursor-pointer hover:border-[var(--accent)]/50 transition-colors" + > +
+
+ {ti.icon} +

{agent.name}

+
+ + {agent.status === "online" ? "online" : "offline"} + +
+
+ @{agent.slug} • {agent.type}
- )} -
-
💬 chat: {agent.agent_config?.chat_listen || "—"}
-
📋 tasks: {agent.agent_config?.task_listen || "—"}
+ {agent.agent_config?.labels && agent.agent_config.labels.length > 0 && ( +
+ {agent.agent_config.labels.map((label) => ( + + {label} + + ))} +
+ )} + +
+
💬 чат: {agent.agent_config?.chat_listen || "—"}
+
📋 задачи: {agent.agent_config?.task_listen || "—"}
+ {agent.agent_config?.mentionable === false && ( +
🚫 не упоминаемый
+ )} +
-
- ))} + ); + })}
)} @@ -98,4 +114,4 @@ export default function AgentsPage() { )}
); -} \ No newline at end of file +}