From b09cdfaf5b6193a946caef1c4bf8a6c743be328a Mon Sep 17 00:00:00 2001 From: maria-rcks <254055478+maria-rcks@users.noreply.github.com> Date: Mon, 2 Nov 2026 22:36:39 +0000 Subject: [PATCH] revert(web): undo hover timestamp change from #28610 This reverts commit f3ccba809ba9e3a6a550c65deedfef44d6f95e1d. --- .../chat/MessagesTimeline.logic.test.ts | 54 ------------------- .../components/chat/MessagesTimeline.logic.ts | 13 ++--- .../components/chat/TimelineAssistantRows.tsx | 7 --- .../chat/timelineMinimapItems.test.ts | 1 - 4 files changed, 3 insertions(+), 72 deletions(-) diff --git a/apps/web/src/components/chat/MessagesTimeline.logic.test.ts b/apps/web/src/components/chat/MessagesTimeline.logic.test.ts index e32a7eb485fc6..4c7eba620b5d1 100644 --- a/apps/web/src/components/chat/MessagesTimeline.logic.test.ts +++ b/apps/web/src/components/chat/MessagesTimeline.logic.test.ts @@ -1528,60 +1528,6 @@ describe("deriveMessagesTimelineRows", () => { expect(rows.at(-1)).toMatchObject({ kind: "thinking" }); }); - it("keeps the latest finished reply's timestamp while a command is still running", () => { - const reply = (streaming: boolean) => ({ - id: "assistant-reply-entry", - kind: "message" as const, - createdAt: "2026-01-01T00:00:10Z", - message: { - id: "assistant-reply" as never, - role: "assistant" as const, - text: "Training finished, checking memory next.", - runId: "turn-1" as never, - createdAt: "2026-01-01T00:00:10Z", - updatedAt: "2026-01-01T00:00:12Z", - streaming, - }, - }); - const rowsWith = (streaming: boolean) => - deriveMessagesTimelineRows({ - timelineEntries: [ - reply(streaming), - { - id: "command-entry", - kind: "work", - createdAt: "2026-01-01T00:00:15Z", - entry: { - id: "command", - createdAt: "2026-01-01T00:00:15Z", - runId: "turn-1" as never, - label: "Running command", - command: "nvidia-smi", - tone: "tool" as const, - toolLifecycleStatus: "inProgress" as const, - }, - }, - ], - latestRun: { - runId: "turn-1" as never, - status: "running", - startedAt: "2026-01-01T00:00:00Z", - completedAt: null, - }, - isWorking: true, - activeTurnStartedAt: "2026-01-01T00:00:00Z", - turnDiffSummaries: [], - supportsConversationRollback: false, - }).find((row) => row.id === "assistant-reply-entry"); - - expect(rowsWith(false)).toMatchObject({ - showAssistantMeta: false, - showAssistantTimestamp: true, - showAssistantCopyButton: false, - }); - expect(rowsWith(true)).toMatchObject({ showAssistantTimestamp: false }); - }); - it("does not show Thinking once the open run's provider turn has ended", () => { const input = { timelineEntries: [ diff --git a/apps/web/src/components/chat/MessagesTimeline.logic.ts b/apps/web/src/components/chat/MessagesTimeline.logic.ts index 8a4a7552901a2..2fe811db4d18f 100644 --- a/apps/web/src/components/chat/MessagesTimeline.logic.ts +++ b/apps/web/src/components/chat/MessagesTimeline.logic.ts @@ -591,8 +591,6 @@ type MessagesTimelineRowContent = message: ChatMessage; projectedItem?: OrchestrationV2ProjectedTurnItem; showAssistantMeta: boolean; - /** The latest finished reply of a still-running response shows only its timestamp. */ - showAssistantTimestamp: boolean; showAssistantCopyButton: boolean; assistantCopyStreaming: boolean; assistantTurnDiffSummary?: TurnDiffSummary | undefined; @@ -2029,10 +2027,10 @@ export function deriveMessagesTimelineRows(input: { timelineEntry.message.role === "assistant" && runIdIsActiveResponse(timelineEntry.message.runId); - const isTerminalAssistantMessage = + const showAssistantMeta = timelineEntry.message.role === "assistant" && - terminalAssistantMessageIds.has(timelineEntry.message.id); - const showAssistantMeta = isTerminalAssistantMessage && !assistantResponseStillInProgress; + terminalAssistantMessageIds.has(timelineEntry.message.id) && + !assistantResponseStillInProgress; nextRows.push({ kind: "message", @@ -2043,10 +2041,6 @@ export function deriveMessagesTimelineRows(input: { ? {} : { projectedItem: timelineEntry.projectedItem }), showAssistantMeta, - showAssistantTimestamp: - isTerminalAssistantMessage && - assistantResponseStillInProgress && - !timelineEntry.message.streaming, showAssistantCopyButton: showAssistantMeta, assistantCopyStreaming: timelineEntry.message.streaming || assistantResponseStillInProgress, assistantTurnDiffSummary: @@ -2510,7 +2504,6 @@ function isRowUnchanged(a: MessagesTimelineRow, b: MessagesTimelineRow): boolean a.message === bm.message && a.projectedItem === bm.projectedItem && a.showAssistantMeta === bm.showAssistantMeta && - a.showAssistantTimestamp === bm.showAssistantTimestamp && a.showAssistantCopyButton === bm.showAssistantCopyButton && a.assistantCopyStreaming === bm.assistantCopyStreaming && a.assistantTurnDiffSummary === bm.assistantTurnDiffSummary && diff --git a/apps/web/src/components/chat/TimelineAssistantRows.tsx b/apps/web/src/components/chat/TimelineAssistantRows.tsx index b425e1009d1b1..458d84b9e982b 100644 --- a/apps/web/src/components/chat/TimelineAssistantRows.tsx +++ b/apps/web/src/components/chat/TimelineAssistantRows.tsx @@ -76,13 +76,6 @@ export function AssistantTimelineRow({ row }: { row: Extract - ) : row.showAssistantTimestamp ? ( - ) : null} diff --git a/apps/web/src/components/chat/timelineMinimapItems.test.ts b/apps/web/src/components/chat/timelineMinimapItems.test.ts index a72813d8f755b..776cd39096a8a 100644 --- a/apps/web/src/components/chat/timelineMinimapItems.test.ts +++ b/apps/web/src/components/chat/timelineMinimapItems.test.ts @@ -15,7 +15,6 @@ describe("deriveTimelineMinimapItems", () => { id: "image-only", createdAt: at, showAssistantMeta: false, - showAssistantTimestamp: false, showAssistantCopyButton: false, assistantCopyStreaming: false, message: {