diff --git a/desktop/src/components/activity/SessionActivityPanel.test.tsx b/desktop/src/components/activity/SessionActivityPanel.test.tsx
index e93d1f40..f24518b9 100644
--- a/desktop/src/components/activity/SessionActivityPanel.test.tsx
+++ b/desktop/src/components/activity/SessionActivityPanel.test.tsx
@@ -52,6 +52,7 @@ vi.mock('../../i18n', () => ({
'session.activity.status.inProgress': 'In progress',
'session.activity.status.completed': 'Completed',
'session.activity.status.running': 'Running',
+ 'session.activity.status.stopping': 'Stopping',
'session.activity.status.failed': 'Failed',
'session.activity.status.stopped': 'Stopped',
'session.activity.status.idle': 'Idle',
@@ -406,6 +407,41 @@ describe('SessionActivityPanel', () => {
expect(screen.queryByRole('button', { name: 'Stop background task Background reviewer' })).not.toBeInTheDocument()
})
+ it('stops SubAgent motion while a global stop request is settling', () => {
+ render(
+ ,
+ )
+
+ expect(screen.getByText('Stopping')).toBeInTheDocument()
+ expect(screen.getByTestId('agent-mascot')).toHaveAttribute('data-agent-mascot-motion', 'still')
+ expect(screen.queryByTestId('agent-mascot-motion-ring')).not.toBeInTheDocument()
+ })
+
it('keeps SubAgent rows to name and status instead of result previews', () => {
render(
+ return
}
const Icon = getRowIcon(row)
@@ -316,6 +324,11 @@ function ActivityRowView({
}) {
const t = useTranslation()
const isTask = row.section === 'tasks'
+ const isStoppingSubagent = row.section === 'subagents' && row.status === 'running' && stoppingBackgroundTask
+ const displayStatus: ActivityRow['status'] = isStoppingSubagent ? 'pending' : row.status
+ const statusLabel = isStoppingSubagent
+ ? t('session.activity.status.stopping')
+ : getActivityStatusLabel(row.status, t)
const label = row.taskHistory
? t('session.activity.tasks.earlier')
: row.label
@@ -335,7 +348,7 @@ function ActivityRowView({
{isTask ? (
) : (
-
+
)}
{isTask ? null : (
)}
@@ -389,7 +402,6 @@ function ActivityRowView({
}
if (row.section === 'subagents' && row.openable && row.toolUseId) {
- const statusLabel = getActivityStatusLabel(row.status, t)
const openButton = (