{sendError ?
: null}
{channel === "direct" && !directRecipientId ?
: null}
{replyTo ? (
Replying to {agents.find((a) => a.id === replyTo.fromAgentId)?.name ?? "agent"}{replyTo.subject ? `: ${replyTo.subject}` : ""}
) : null}
You (Board)
{!replyTo ?
setSubject(e.target.value)} placeholder="Subject (optional)" aria-label="Message subject" className="min-w-0 flex-1 rounded-lg border border-border bg-card px-2.5 py-1 text-[11px] text-foreground placeholder:text-muted-foreground" /> : null}
{attachments.length > 0 && (
{attachments.map((att) => (
{att.title}
))}
)}
void handleSend()} label="Send message" />
{mentionState.active && (
)}
Press {navigator.platform.includes("Mac") ? "Cmd" : "Ctrl"}+Enter to send
)
}
export function TaskDiscussionComposer({ companyId, taskId, onSent }: { companyId: string; taskId: string; onSent: () => void }) {
const [body, setBody] = useState(""); const [sending, setSending] = useState(false); const [sendError, setSendError] = useState