From 2251a69f1a1227c05f5a68e6a3360315f6b3f50c Mon Sep 17 00:00:00 2001 From: ejclaw Date: Tue, 28 Apr 2026 13:49:43 +0900 Subject: [PATCH] Extract dashboard RoomCardV2 component --- apps/dashboard/src/App.tsx | 506 +------------- apps/dashboard/src/RoomCardV2.test.tsx | 111 ++++ apps/dashboard/src/RoomCardV2.tsx | 869 +++++++++++++++++++++++++ 3 files changed, 988 insertions(+), 498 deletions(-) create mode 100644 apps/dashboard/src/RoomCardV2.test.tsx create mode 100644 apps/dashboard/src/RoomCardV2.tsx diff --git a/apps/dashboard/src/App.tsx b/apps/dashboard/src/App.tsx index c5e687f..84ee950 100644 --- a/apps/dashboard/src/App.tsx +++ b/apps/dashboard/src/App.tsx @@ -1,5 +1,4 @@ -import { useEffect, useMemo, useRef, useState, type ReactNode } from 'react'; -import { Send } from 'lucide-react'; +import { useEffect, useMemo, useState, type ReactNode } from 'react'; import { type ClaudeAccountSummary, @@ -55,11 +54,8 @@ import { type DashboardFreshness, type DashboardView, } from './DashboardNav'; -import { - buildRoomThreadEntries, - isInternalProtocolPayload, - isWatcherRoomMessage, -} from './roomThread'; +import { isInternalProtocolPayload } from './roomThread'; +import { RoomCardV2, type RoomEntryWithService } from './RoomCardV2'; import { ParsedBody } from './ParsedBody'; import { redactSecretsForPreview } from './redaction'; import './styles.css'; @@ -1742,54 +1738,6 @@ function HealthPanel({ ); } -function RoomMessageForm({ - busy, - onChange, - onSubmit, - t, - value, -}: { - busy: boolean; - onChange: (value: string) => void; - onSubmit: () => void; - t: Messages; - value: string; -}) { - return ( -
{ - event.preventDefault(); - onSubmit(); - }} - > -