refactor: migrate from clientSessionKey to clientId identity
This commit is contained in:
@@ -227,6 +227,10 @@ export function AgentInputArea({
|
||||
useEffect(() => {
|
||||
const previousUpdatedAt = latestAgentUpdatedAtRef.current
|
||||
if (agentUpdatedAtMs < previousUpdatedAt) {
|
||||
if (isProcessing && !isAgentRunning) {
|
||||
prevIsAgentRunningRef.current = false
|
||||
setIsProcessing(false)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
||||
@@ -48,7 +48,8 @@ export function ToolCallDetailsContent({
|
||||
(detail?.type === "shell" ||
|
||||
detail?.type === "edit" ||
|
||||
detail?.type === "write" ||
|
||||
detail?.type === "read");
|
||||
detail?.type === "read" ||
|
||||
detail?.type === "sub_agent");
|
||||
const codeBlockStyle = isFullBleed ? styles.fullBleedBlock : styles.diffContainer;
|
||||
|
||||
if (detail?.type === "shell") {
|
||||
@@ -126,6 +127,45 @@ export function ToolCallDetailsContent({
|
||||
</View>
|
||||
</View>
|
||||
);
|
||||
} else if (detail?.type === "sub_agent") {
|
||||
const activityLog = detail.log.replace(/^\n+/, "");
|
||||
const hasLog = activityLog.length > 0;
|
||||
const fallbackHeader =
|
||||
detail.subAgentType && detail.description
|
||||
? `${detail.subAgentType}: ${detail.description}`
|
||||
: detail.subAgentType ?? detail.description ?? "Sub-agent activity";
|
||||
sections.push(
|
||||
<View
|
||||
key="sub-agent"
|
||||
style={[styles.section, shouldFill && styles.fillHeight]}
|
||||
>
|
||||
<View style={[codeBlockStyle, shouldFill && styles.fillHeight]}>
|
||||
<ScrollView
|
||||
style={[
|
||||
styles.codeVerticalScroll,
|
||||
resolvedMaxHeight !== undefined && { maxHeight: resolvedMaxHeight },
|
||||
shouldFill && styles.fillHeight,
|
||||
]}
|
||||
contentContainerStyle={styles.codeVerticalContent}
|
||||
nestedScrollEnabled
|
||||
showsVerticalScrollIndicator
|
||||
>
|
||||
<ScrollView
|
||||
horizontal
|
||||
nestedScrollEnabled
|
||||
showsHorizontalScrollIndicator
|
||||
contentContainerStyle={styles.codeHorizontalContent}
|
||||
>
|
||||
<View style={styles.codeLine}>
|
||||
<Text selectable style={styles.scrollText}>
|
||||
{hasLog ? activityLog : fallbackHeader}
|
||||
</Text>
|
||||
</View>
|
||||
</ScrollView>
|
||||
</ScrollView>
|
||||
</View>
|
||||
</View>
|
||||
);
|
||||
} else if (detail?.type === "edit") {
|
||||
sections.push(
|
||||
<View
|
||||
|
||||
Reference in New Issue
Block a user