feat(ui): default expand tool call results and execution log
Tool call status cards and execution log panel now expand by default so users can see CoT process and results without clicking. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.6
parent
3ef9624385
commit
4267d0a62a
@@ -39,7 +39,7 @@ interface ExecutionLogPanelProps {
|
||||
}
|
||||
|
||||
export function ExecutionLogPanel({ executionLog }: ExecutionLogPanelProps) {
|
||||
const [expanded, setExpanded] = useState(false);
|
||||
const [expanded, setExpanded] = useState(true);
|
||||
|
||||
if (!executionLog.length) return null;
|
||||
|
||||
|
||||
@@ -105,7 +105,7 @@ function ToolCallRow({
|
||||
globalExpanded,
|
||||
}: ToolCallRowProps) {
|
||||
// Local state used only when globalExpanded is undefined (single tool or no global toggle)
|
||||
const [localExpanded, setLocalExpanded] = useState(isFailed);
|
||||
const [localExpanded, setLocalExpanded] = useState(true);
|
||||
const expanded = globalExpanded !== undefined ? globalExpanded : localExpanded;
|
||||
const setExpanded = useCallback((val: boolean | ((v: boolean) => boolean)) => {
|
||||
if (globalExpanded === undefined) {
|
||||
@@ -252,7 +252,7 @@ export default function ToolCallStatus({
|
||||
if (!toolCalls.length) return null;
|
||||
|
||||
// Global expand/collapse state — only active when there are >= 2 tool calls
|
||||
const [globalExpanded, setGlobalExpanded] = useState<boolean | undefined>(undefined);
|
||||
const [globalExpanded, setGlobalExpanded] = useState<boolean | undefined>(true);
|
||||
|
||||
const UI_NAME_MAP: Record<string, string> = {
|
||||
kb_search: "knowledge-result",
|
||||
|
||||
Reference in New Issue
Block a user