From 356cdbd18d740b3c7f5c12e291f7c21af604c1a4 Mon Sep 17 00:00:00 2001 From: Menghuan1918 Date: Wed, 25 Nov 2026 00:59:30 +0800 Subject: [PATCH] =?UTF-8?q?refactor(ui):=20=E4=BB=BB=E5=8A=A1=E7=AA=97?= =?UTF-8?q?=E5=8F=A3=E4=B8=8E=E4=BB=BB=E5=8A=A1=E5=9B=BE=E6=8E=A5=E5=85=A5?= =?UTF-8?q?=E7=BB=9F=E4=B8=80=E7=BB=84=E4=BB=B6=E5=B1=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - TaskWindow:所有者/阻塞信息改用 FactList,视图与编辑态的两个字段改用 Field(label 关联 input/textarea),空描述改用 Notice(hint),冲突/错误 提示改用 Notice(error);窗口底部动作改用 ActionButton,图标移入按钮内容。 MultilineField 增加可选 id,供 Field 的 label 关联。 - TasksGraph:空画布加载行改用共享 LoadingIndicator,删除自绘的旋转图标 行与对应 CSS。 - tasks-graph.module.css:表单「描述字段吃满窗口」的规则跟随 Field 的 div 结构改写;删除随替换失效的 .teamNote/.taskLabel/.jobPopMeta 作用域规则。 - 行为、文案、aria 名称与 data-* 均未改变;图形卡片与右下控件簇是图形 专用形状,本轮不动(见报告)。 --- src/client/TaskWindow.tsx | 97 +++++++++++++++--------------- src/client/TasksGraph.tsx | 6 +- src/client/tasks-canvas.module.css | 6 -- src/client/tasks-graph.module.css | 35 ++++------- 4 files changed, 66 insertions(+), 78 deletions(-) diff --git a/src/client/TaskWindow.tsx b/src/client/TaskWindow.tsx index 5a7a8545..15f62ec5 100644 --- a/src/client/TaskWindow.tsx +++ b/src/client/TaskWindow.tsx @@ -21,7 +21,7 @@ import { useEffect, useId, useRef, useState, type ReactNode } from 'react' import clsx from 'clsx' import { - Button, IconCheckOutlineRegular, IconEditOutlineRegular, + IconCheckOutlineRegular, IconEditOutlineRegular, IconRefreshOutlineRegular, IconTrashOutlineRegular, Input, MarkdownDelegateProvider, MarkdownText, Pill, StateDot, Tag, } from '@deepseek-ai/dsh-client-ui-primitives' import type { Context, SidebarTeamTaskView } from '../context-types.ts' @@ -30,6 +30,7 @@ import { markdownTextProps } from './markdown-labels.tsx' import { useMarkdownSurface } from './use-markdown-surface.ts' import { FloatingWindow } from './FloatingWindow.tsx' import { taskBlocked, taskDotState, taskStatusLabel, taskTone } from './tasks-shared.tsx' +import { ActionButton, FactList, Field, Notice } from './ui/index.ts' import type { TeamMemberRow } from './team-projection.ts' import { t } from './locales.ts' import css from './tasks-graph.module.css' @@ -50,10 +51,13 @@ export function MultilineField(props: { label: string placeholder?: string rows?: number + /** Id the enclosing {@link Field}'s label points at. */ + id?: string onChange?(next: string): void }): ReactNode { return (