* refactor(webui): organize shared components with an internal gallery * refactor(webui): decouple views and expand component gallery * fix(docker): include channel sources in WebUI build * refactor(webui): cover all channel interfaces in gallery * docs(webui): remove manual paragraph wrapping
18 lines
796 B
TypeScript
18 lines
796 B
TypeScript
import { SubagentThreadView } from "@/components/thread/SubagentThreadView";
|
|
import { useSubagentThread } from "@/components/thread/useSubagentThread";
|
|
import type { SubagentTaskSnapshot } from "@/lib/types";
|
|
|
|
interface SubagentThreadProps {
|
|
token: string;
|
|
sessionKey: string;
|
|
task: SubagentTaskSnapshot;
|
|
historyEnabled: boolean;
|
|
isStreaming: boolean;
|
|
}
|
|
|
|
export function SubagentThread({ token, sessionKey, task, historyEnabled, isStreaming }: SubagentThreadProps) {
|
|
const { messages, loading, failed, activeTurnId, retry } = useSubagentThread({ token, sessionKey, task, historyEnabled });
|
|
return <SubagentThreadView messages={messages} loading={loading} failed={failed} isStreaming={isStreaming}
|
|
activeTurnId={activeTurnId} runStartedAt={task.created_at} onRetry={retry} />;
|
|
}
|