diff --git a/src/renderer/src/components/editor/ReviewNotesSendMenuContent.test.tsx b/src/renderer/src/components/editor/ReviewNotesSendMenuContent.test.tsx index 1ae74985923..5f900b4cfd0 100644 --- a/src/renderer/src/components/editor/ReviewNotesSendMenuContent.test.tsx +++ b/src/renderer/src/components/editor/ReviewNotesSendMenuContent.test.tsx @@ -506,9 +506,11 @@ describe('ReviewNotesSendMenuContent', () => { const tree = render() const item = findByType(tree, 'DropdownMenuItem') + const stateDot = findByType(item, 'AgentStateDot') expect(item.props.disabled).toBe(true) expect(item.props.title).toBe('Agent needs permission') + expect(stateDot.props.title).toBeNull() ;(item.props.onSelect as () => void)() expect(harness.sendNotesToActiveAgentSession).not.toHaveBeenCalled() }) diff --git a/src/renderer/src/components/editor/ReviewNotesSendMenuContent.tsx b/src/renderer/src/components/editor/ReviewNotesSendMenuContent.tsx index adde4669ef4..0800be5b224 100644 --- a/src/renderer/src/components/editor/ReviewNotesSendMenuContent.tsx +++ b/src/renderer/src/components/editor/ReviewNotesSendMenuContent.tsx @@ -247,6 +247,7 @@ function AgentTargetMenuItem({ const tabTitle = target.tabTitle.trim() const state = asDotState(agent?.state ?? 'idle', agent?.entry.workingMode) const timeAgo = agent ? formatAgentRelativeTime(agent, now) : null + const disabledReason = target.status === 'disabled' ? target.disabledReason : undefined const secondaryParts = [ agentStateLabel(state), ...(timeAgo ? [timeAgo] : []), @@ -259,10 +260,16 @@ function AgentTargetMenuItem({ // Why: surface the ineligibility reason (permission/stale/no-terminal) as a // hover tooltip rather than inline text, matching DashboardAgentRow's // title-attribute treatment of the same disabledReason. - title={target.status === 'disabled' ? target.disabledReason : undefined} + title={disabledReason} className="min-w-[240px] gap-2 rounded-[7px] px-2 py-1.5 text-[12px] leading-5 font-medium" > - + {/* Why: the ancestor's actionable disabled reason must win on every hit area. */} +