Refactor publish section in AIAgentConfigWorkbench for improved layout and readability by simplifying the structure and enhancing the display of workflow versions

This commit is contained in:
mlogclub
2026-06-23 21:06:11 +08:00
parent 622cfeef59
commit ca4e4c7a88
@@ -878,28 +878,6 @@ export function AIAgentConfigWorkbench({
{activeSection === "publish" ? (
<ConfigSection>
<div className="flex flex-wrap items-center gap-x-6 gap-y-2 rounded-md border px-3 py-2 text-sm">
<div className="flex items-center gap-2">
<span className="text-muted-foreground">Agent </span>
<Badge variant="secondary">{agent?.statusName || "-"}</Badge>
</div>
<div className="flex items-center gap-2">
<span className="text-muted-foreground"></span>
<Badge variant={agent?.workflowVersionId ? "default" : "outline"}>
{agent?.workflowVersionId ? `#${agent.workflowVersionId}` : "未发布"}
</Badge>
</div>
<div className="min-w-0 flex-1 text-xs text-muted-foreground">
稿
</div>
</div>
<div className="space-y-3">
<div>
<h3 className="text-sm font-medium"></h3>
{/* <p className="mt-1 text-xs text-muted-foreground">
仅展示已发布的不可变流程版本,当前页面暂不支持切换或回滚版本。
</p> */}
</div>
<div className="overflow-hidden rounded-md border">
{workflowVersions.length > 0 ? (
<Table>
@@ -943,7 +921,6 @@ export function AIAgentConfigWorkbench({
<div className="p-4 text-sm text-muted-foreground"></div>
)}
</div>
</div>
</ConfigSection>
) : null}