Skip to content

The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.

fix(assistant-ui): flatten requires-action selector callback

Steven Enamakelb6ffe65b1eb2
diff --git a/app/src/components/assistant-ui/activity-group.tsx b/app/src/components/assistant-ui/activity-group.tsx
index 68035af89e..70f01a9a5d 100644
--- a/app/src/components/assistant-ui/activity-group.tsx
+++ b/app/src/components/assistant-ui/activity-group.tsx
@@ -59,8 +59,8 @@ export const ActivityGroup: FC<PropsWithChildren<{ group: ActivityGroupPart }>>
);
// `GroupedParts` takes its status from the final part. A completed call after
// a parked approval would otherwise collapse the approval card out of sight.
- const requiresAction = useAuiState(
- s => indices.some(i => s.message.parts[i]?.status?.type === 'requires-action')
+ const requiresAction = useAuiState(s =>
+ indices.some(i => s.message.parts[i]?.status?.type === 'requires-action')
);
const [userOpen, setUserOpen] = useState<boolean | null>(null);
diff --git a/app/src/components/assistant-ui/thread.activityGroup.test.tsx b/app/src/components/assistant-ui/thread.activityGroup.test.tsx
index a598ada7a8..5c3fc031cc 100644
--- a/app/src/components/assistant-ui/thread.activityGroup.test.tsx
+++ b/app/src/components/assistant-ui/thread.activityGroup.test.tsx
@@ -106,9 +106,7 @@ describe('activity group', () => {
role: 'assistant',
status: { type: 'complete', reason: 'stop' },
content: [
- tool('t1', 'shell', {
- status: { type: 'requires-action', reason: 'interrupt' },
- }),
+ tool('t1', 'shell', { status: { type: 'requires-action', reason: 'interrupt' } }),
tool('t2', 'search_two'),
],
},