diff --git a/src/renderer/components/organization/AgentEditor.tsx b/src/renderer/components/organization/AgentEditor.tsx index 16550aa8..c1bc6e93 100644 --- a/src/renderer/components/organization/AgentEditor.tsx +++ b/src/renderer/components/organization/AgentEditor.tsx @@ -3,7 +3,9 @@ import { Pencil, Trash } from "@phosphor-icons/react"; import type { AgentRecord, ConnectorRecord, WorkspaceRecord } from "@shared/types"; import { getConnectorExecutionReadinessIssue, isConnectorExecutionReady } from "@shared/connector-policy"; import { unwrap } from "../../lib/desktop"; +import { useAppStore } from "../../state/store"; import { ActionButton, Input, Select, TextArea } from "../ui"; +import { SkillAgentToggles } from "../skills/SkillAgentToggles"; import { ConfirmDelete, HeartbeatSection } from "./helpers"; export function AgentEditor({ @@ -74,6 +76,17 @@ export function AgentEditor({ } }, [connectorId, agent.connectorId]); + const skills = useAppStore((s) => s.skills); + const setSkills = useAppStore((s) => s.setSkills); + + useEffect(() => { + if (skills.length === 0 && companyId) { + window.agentCompany.listSkills(companyId).then((result) => { + if (result.ok) setSkills(result.data); + }); + } + }, [companyId, skills.length, setSkills]); + const managerCandidates = agents.filter((a) => a.id !== agent.id); return ( @@ -162,6 +175,12 @@ export function AgentEditor({ + {/* Skills section (D-04 dual access) */} +
+

Skills

+ +
+