ai-design-system 0.1.43 → 0.1.44

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -60,10 +60,6 @@ export const ToolCallDisplay = React.memo<ToolCallDisplayProps>(
60
60
  }
61
61
  }, [toolCall])
62
62
 
63
- const toggleExpanded = React.useCallback(() => {
64
- setIsExpanded((prev) => !prev)
65
- }, [])
66
-
67
63
  const hasContent = React.useMemo(() => {
68
64
  return result !== null || Object.keys(args).length > 0
69
65
  }, [result, args])
@@ -83,7 +79,7 @@ export const ToolCallDisplay = React.memo<ToolCallDisplayProps>(
83
79
  }, [status])
84
80
 
85
81
  return (
86
- <Tool defaultOpen={isExpanded}>
82
+ <Tool open={isExpanded} onOpenChange={setIsExpanded}>
87
83
  <ToolHeader
88
84
  title={name}
89
85
  type={`tool-${name}` as const}
package/dist/index.cjs CHANGED
@@ -2439,9 +2439,6 @@ var ToolCallDisplay = React3__namespace.memo(
2439
2439
  status: toolStatus
2440
2440
  };
2441
2441
  }, [toolCall]);
2442
- React3__namespace.useCallback(() => {
2443
- setIsExpanded((prev) => !prev);
2444
- }, []);
2445
2442
  React3__namespace.useMemo(() => {
2446
2443
  return result !== null || Object.keys(args).length > 0;
2447
2444
  }, [result, args]);
@@ -2457,7 +2454,7 @@ var ToolCallDisplay = React3__namespace.memo(
2457
2454
  return "output-available";
2458
2455
  }
2459
2456
  }, [status]);
2460
- return /* @__PURE__ */ jsxRuntime.jsxs(Tool, { defaultOpen: isExpanded, children: [
2457
+ return /* @__PURE__ */ jsxRuntime.jsxs(Tool, { open: isExpanded, onOpenChange: setIsExpanded, children: [
2461
2458
  /* @__PURE__ */ jsxRuntime.jsx(
2462
2459
  ToolHeader,
2463
2460
  {