import { useCallback } from "react"; import { agentsApi, type OrgNode } from "../api/agents"; import { useCompany } from "../context/CompanyContext"; import { useApi } from "../hooks/useApi"; import { StatusBadge } from "../components/StatusBadge"; import { Card, CardContent } from "@/components/ui/card"; function OrgTree({ nodes, depth = 0 }: { nodes: OrgNode[]; depth?: number }) { return (
{node.name}
{node.role}
Select a company first.
; } return (Loading...
} {error &&{error.message}
} {data && data.length === 0 &&No agents in org.
} {data && data.length > 0 &&