diff --git a/cloud/console-react/src/App.tsx b/cloud/console-react/src/App.tsx index 51ca873..3a81d2c 100644 --- a/cloud/console-react/src/App.tsx +++ b/cloud/console-react/src/App.tsx @@ -19,17 +19,13 @@ import SkillsToolsPanel from "./sections/SkillsToolsPanel"; import AutomationsSection from "./sections/AutomationsSection"; import TriageSection from "./sections/TriageSection"; -// Layout only: ONE scrollable console page, Muse web/desktop tokens -// (white, hairlines, grey/blue bubbles) but console ordering — no -// icon-rail column, no left list column, no right panel column, no -// view switching. Everything is on the page: a slim sticky top bar -// (name + real connection status + health + quota + refresh stamp + -// anchor nav), a data-cards row, then every module as a section in -// order. The old right panel's content moved here: its profile/status -// line is the top bar, its 今天 list is redundant with the full task -// list section, and its detail/context panels sit under their own -// sections below (detail under 对话, members under 项目, and so on). -// The old icon rail's module switching is the anchor nav. +// Layout only: ONE scrollable console page in GitHub Primer style — +// a dark header bar (name + real connection status + health + quota +// + refresh stamp + anchor nav as header links), a data-cards row, +// then every module as a bordered section in order. No icon-rail +// column, no left list column, no right panel column, no view +// switching. Detail/context panels sit under their own sections +// below (detail under 对话, members under 项目, and so on). const NAV: Array<[string, string]> = [ ["#sec-dispatch", "派发"], ["#sec-tasks", "任务"], ["#sec-conv", "对话"], ["#sec-projects", "项目"], ["#sec-env", "环境"], ["#sec-workers", "Workers"], diff --git a/cloud/console-react/src/components/chat/Chat.tsx b/cloud/console-react/src/components/chat/Chat.tsx index 832cbd9..1560e22 100644 --- a/cloud/console-react/src/components/chat/Chat.tsx +++ b/cloud/console-react/src/components/chat/Chat.tsx @@ -18,16 +18,19 @@ export function useAutoFollow(dep: unknown) { return { ref, following, onScroll }; } +// GitHub-style comment box, not a chat bubble: full-width white box +// with a subtle header row (role label only — no timestamp or sender +// is invented; the backend provides neither) and the body below. +// Status entries are plain muted timeline text on the timeline line. export function ChatBubble({ msg }: { msg: ChatMessage }) { if (msg.role === "status") { return
{msg.text}
; } + const author = msg.label || (msg.role === "user" ? "用户" : msg.role === "assistant" ? "助手" : "工具"); return ( -
-
- {msg.label ?
{msg.label}
: null} -
{msg.text}
-
+
+
{author}
+
{msg.text}
); } @@ -54,25 +57,24 @@ export function ChatInput({ onSend, disabled, placeholder }: { onSend(v); setText(""); }; - // Pill input bar, Muse screenshot style: the textarea is the pill - // itself, and send is a light-blue circular arrow. No mic or - // attachment button here: the continue chat has no voice or - // attachment API (attachments live in Dispatch), so a mic/+ icon - // would be a dead button; the left list header's + is the new-task - // entry instead. + // GitHub comment box: textarea on top, a subtle footer row with the + // green primary send button. No mic or attachment button here: the + // continue chat has no voice or attachment API (attachments live in + // Dispatch), so a mic/+ icon would be a dead button. return ( -
+