Skip to content
This repository was archived by the owner on Apr 1, 2026. It is now read-only.

Commit 3068e7d

Browse files
committed
fix(desktop): animating too much
1 parent f83d621 commit 3068e7d

1 file changed

Lines changed: 4 additions & 5 deletions

File tree

packages/desktop/src/pages/session.tsx

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -459,8 +459,6 @@ export default function Page() {
459459
) as AssistantMessageType[]
460460
})
461461
const error = createMemo(() => assistantMessages().find((m) => m?.error)?.error)
462-
const initialCompleted = !!message.summary?.body || !!error()
463-
const [completed, setCompleted] = createSignal(initialCompleted)
464462
const [detailsExpanded, setDetailsExpanded] = createSignal(false)
465463
const parts = createMemo(() => sync.data.part[message.id])
466464
const hasToolPart = createMemo(() =>
@@ -471,16 +469,17 @@ export default function Page() {
471469
const working = createMemo(
472470
() => message.id === session.messages.last()?.id && session.working(),
473471
)
472+
const initialCompleted = !(message.id === session.messages.last()?.id && session.working())
473+
const [completed, setCompleted] = createSignal(initialCompleted)
474474

475475
// allowing time for the animations to finish
476476
createEffect(() => {
477477
const title = message.summary?.title
478478
setTimeout(() => setTitled(!!title), 10_000)
479479
})
480480
createEffect(() => {
481-
const summary = message.summary?.body
482-
const complete = !!summary || !!error()
483-
setTimeout(() => setCompleted(complete), 1200)
481+
const completed = !working()
482+
setTimeout(() => setCompleted(completed), 1200)
484483
})
485484

486485
return (

0 commit comments

Comments
 (0)