From 63d573636cc488bc4731152863ddce681a8399d3 Mon Sep 17 00:00:00 2001 From: Shy Alter Date: Wed, 29 Jul 2026 15:33:57 +0200 Subject: [PATCH] Remove unfinished comments tab Generated-By: PostHog Code Task-Id: df260293-b59c-4a18-9654-d1748366ce52 --- .../canvas/components/ActivityPanel.tsx | 29 ++----------------- 1 file changed, 2 insertions(+), 27 deletions(-) diff --git a/packages/ui/src/features/canvas/components/ActivityPanel.tsx b/packages/ui/src/features/canvas/components/ActivityPanel.tsx index a0a36a23dd..c59a26979b 100644 --- a/packages/ui/src/features/canvas/components/ActivityPanel.tsx +++ b/packages/ui/src/features/canvas/components/ActivityPanel.tsx @@ -13,7 +13,6 @@ import { AgentStatusLine, ThreadLoadingState, ThreadReplyComposer, - ThreadTimeline, } from "@posthog/ui/features/canvas/components/ThreadPanel"; import { useThreadConversation } from "@posthog/ui/features/canvas/hooks/useThreadConversation"; import { buildConversationItems } from "@posthog/ui/features/sessions/components/buildConversationItems"; @@ -22,19 +21,13 @@ import { track } from "@posthog/ui/shell/analytics"; import { useQuery } from "@tanstack/react-query"; import { useCallback, useEffect, useMemo, useRef, useState } from "react"; -type ActivityTab = "timeline" | "artifacts" | "comments"; +type ActivityTab = "timeline" | "artifacts"; const ACTIVITY_TABS: readonly { key: ActivityTab; label: string }[] = [ { key: "timeline", label: "Timeline" }, { key: "artifacts", label: "Artifacts" }, - { key: "comments", label: "Comments" }, ] as const; -const TABS_WITH_COMPOSER: ReadonlySet = new Set([ - "timeline", - "comments", -]); - /** The 32px row this panel leads with: the tabs are the header, so the strip * lines up with the tab bar of the pane on its left (TabbedPanel) and the * review toolbar, which are the same fixed height and border. */ @@ -160,10 +153,6 @@ function ActivityConversation({ [taskId], ); - const commentRows = useMemo( - () => timeline.filter((row) => row.kind === "human"), - [timeline], - ); const conversationItems = useMemo( () => tab === "timeline" @@ -178,7 +167,7 @@ function ActivityConversation({ scrollRef.current?.scrollTo({ top: scrollRef.current.scrollHeight }); }, [timeline, events.length, agentStatus?.phase, tab]); - const showComposer = TABS_WITH_COMPOSER.has(tab); + const showComposer = tab === "timeline"; const body = () => { if (tab === "artifacts") { @@ -190,20 +179,6 @@ function ActivityConversation({ /> ); } - if (tab === "comments") { - return ( - - ); - } if (!isReady) return ; return (