From a71b11caca88243a9e4399317bcc5234d432976c Mon Sep 17 00:00:00 2001
From: Adam <2363879+adamdotdevin@users.noreply.github.com>
Date: Fri, 6 Mar 2026 11:03:32 -0600
Subject: fix(app): stale keyed show errors
---
packages/ui/src/components/message-part.tsx | 202 ++++++++++----------
packages/ui/src/components/session-turn.tsx | 280 ++++++++++++++--------------
2 files changed, 230 insertions(+), 252 deletions(-)
(limited to 'packages/ui/src')
diff --git a/packages/ui/src/components/message-part.tsx b/packages/ui/src/components/message-part.tsx
index f59b17e9a..9286d2a92 100644
--- a/packages/ui/src/components/message-part.tsx
+++ b/packages/ui/src/components/message-part.tsx
@@ -527,19 +527,15 @@ export function AssistantParts(props: {
return (
- {(msg) => (
-
- {(p) => (
-
- )}
-
- )}
+
+
+
)
})()}
@@ -741,13 +737,11 @@ export function AssistantMessageDisplay(props: {
return (
- {(p) => (
-
- )}
+
)
})()}
@@ -1410,11 +1404,9 @@ ToolRegistry.register({
trigger={{ title: i18n.t("ui.tool.list"), subtitle: getDirectory(props.input.path || "/") }}
>
- {(output) => (
-
-
-
- )}
+
+
+
)
@@ -1436,11 +1428,9 @@ ToolRegistry.register({
}}
>
- {(output) => (
-
-
-
- )}
+
+
+
)
@@ -1465,11 +1455,9 @@ ToolRegistry.register({
}}
>
- {(output) => (
-
-
-
- )}
+
+
+
)
@@ -1613,16 +1601,14 @@ ToolRegistry.register({
- {(url) => (
- e.stopPropagation()}
- >
- {description()}
-
- )}
+ e.stopPropagation()}
+ >
+ {description()}
+
{description()}
@@ -1747,7 +1733,9 @@ ToolRegistry.register({
{(diff) => }
+
+
+
}
>
@@ -1974,74 +1962,72 @@ ToolRegistry.register({
}
>
- {(file) => (
-
-
-
-
-
-
-
-
- {getFilename(file().relativePath)}
-
-
-
-
- {getDirectory(file().relativePath)}
-
-
-
-
+
+
+
+
+
+
+
-
+ {getFilename(single()!.relativePath)}
+
+
+ {getDirectory(single()!.relativePath)}
+
+
+
+
+
+
+
+
+ }
+ >
+
+
+
+ {i18n.t("ui.patch.action.created")}
+
+
+
+
+ {i18n.t("ui.patch.action.deleted")}
+
+
+
+
+ {i18n.t("ui.patch.action.moved")}
+
+
+
+
+
+
}
>
-
-
-
- {i18n.t("ui.patch.action.created")}
-
-
-
-
- {i18n.t("ui.patch.action.deleted")}
-
-
-
-
- {i18n.t("ui.patch.action.moved")}
-
-
-
-
-
-
- }
- >
-
-
-
-
-
-
- )}
+
+
+
+
+
+
)
},
diff --git a/packages/ui/src/components/session-turn.tsx b/packages/ui/src/components/session-turn.tsx
index a8a41b8ef..3323a9fc6 100644
--- a/packages/ui/src/components/session-turn.tsx
+++ b/packages/ui/src/components/session-turn.tsx
@@ -388,157 +388,149 @@ export function SessionTurn(
>
- {(msg) => (
-
-
-
+
+
+
+
+
+
+
+
0}>
+
-
- {(part) => (
-
- )}
-
- 0}>
-
-
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
- 0 && !working()}>
-
-
-
-
-
-
- {i18n.t("ui.sessionReview.change.modified")}
-
-
- {edited()} {i18n.t(edited() === 1 ? "ui.common.file.one" : "ui.common.file.other")}
-
-
-
-
-
+
+
+
+
+
0 && !working()}>
+
+
+
+
+
+
{i18n.t("ui.sessionReview.change.modified")}
+
+ {edited()} {i18n.t(edited() === 1 ? "ui.common.file.one" : "ui.common.file.other")}
+
+
+
+
-
-
-
-
-
setExpanded(Array.isArray(value) ? value : value ? [value] : [])}
- >
-
- {(diff) => {
- const active = createMemo(() => expanded().includes(diff.file))
- const [visible, setVisible] = createSignal(false)
-
- createEffect(
- on(
- active,
- (value) => {
- if (!value) {
- setVisible(false)
- return
- }
-
- requestAnimationFrame(() => {
- if (!active()) return
- setVisible(true)
- })
- },
- { defer: true },
- ),
- )
-
- return (
-
-
-
-
-
-
-
- {`\u202A${getDirectory(diff.file)}\u202C`}
-
-
-
- {getFilename(diff.file)}
+
+
+
+
+
+
setExpanded(Array.isArray(value) ? value : value ? [value] : [])}
+ >
+
+ {(diff) => {
+ const active = createMemo(() => expanded().includes(diff.file))
+ const [visible, setVisible] = createSignal(false)
+
+ createEffect(
+ on(
+ active,
+ (value) => {
+ if (!value) {
+ setVisible(false)
+ return
+ }
+
+ requestAnimationFrame(() => {
+ if (!active()) return
+ setVisible(true)
+ })
+ },
+ { defer: true },
+ ),
+ )
+
+ return (
+
+
+
+
+
+
+
+ {`\u202A${getDirectory(diff.file)}\u202C`}
+
+ {getFilename(diff.file)}
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- )
- }}
-
-
-
-
-
-
-
-
-
-
- {errorText()}
-
-
-
- )}
+
+
+
+
+
+
+
+
+
+
+
+ )
+ }}
+
+
+
+
+
+
+
+
+
+
+ {errorText()}
+
+
+
{props.children}
--
cgit v1.2.3