From 850d4fb796e4454e853150c0aba776099bdcc462 Mon Sep 17 00:00:00 2001 From: d-robotics Date: Tue, 27 Oct 2026 01:20:13 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=F0=9F=97=82=EF=B8=8F=20Add=20task=20card?= =?UTF-8?q?=20for=20workbench=20UI=20polish?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Opus 5.5 --- .scratch/workbench-ui-polish/work.md | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 .scratch/workbench-ui-polish/work.md diff --git a/.scratch/workbench-ui-polish/work.md b/.scratch/workbench-ui-polish/work.md new file mode 100644 index 00000000..cbbabcc0 --- /dev/null +++ b/.scratch/workbench-ui-polish/work.md @@ -0,0 +1,8 @@ +# Polish annotation, review, acceptance and rework workbench UI + +Goal: make the annotator / QC / final-acceptance workbenches (normal and focus layouts, rework and re-review states) tidier and smoother without changing any function; interaction changes need the user's approval first +Agent: Claude Code (desktop session, 2026-10-27) +Base: codex/frontend-polish-20261026 @ de96cfc2 (unmerged; it carries the production line review-runtime-trace, whose annotation workbench differs from origin/dev by ~1300 lines). Pending the user's confirmation. +Scope: src/index.css, src/styles/{capture-workspace,review-workspace,review-captions}.css, display-only class names in src/pages/AnnotationOperations.tsx and src/components/* used by the four workbenches +Out of scope: interaction changes (entry points, shortcuts, panel positions, confirmations, auto-claim/continuation behaviour), API, data, other pages +Risk: display only From 71cc91b9d7d89509d8037f5ae639d44b62775da9 Mon Sep 17 00:00:00 2001 From: d-robotics Date: Tue, 27 Oct 2026 01:50:27 +0800 Subject: [PATCH 2/3] =?UTF-8?q?=F0=9F=92=84=20Polish=20annotation,=20revie?= =?UTF-8?q?w=20and=20acceptance=20workbenches=20without=20changing=20inter?= =?UTF-8?q?actions?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Bare `border` utilities rendered near-black under Tailwind v4 inside the workbenches; colourless borders now use the panel tone (controls one step darker), scoped to .annotation-operations-page. - Normal review layout: the tall QC side panel no longer stretches the camera row and the playback bar; extra height goes to a trailing flexible row. - Focused review: collapse the 150px column reserved for an action list that review never renders. - Focused acceptance: the side-panel aside rule no longer squeezes the nested "current slice / current annotation" panel into overlapping 7px lines. - Pool cards (annotation and acceptance): capture names wrap after underscores instead of mid-word, status badge moves next to the time range, 9-10px text raised to 11px. - Light-theme fixes for dark-only leftovers: stage/status chips, refresh and sampling buttons, leave-guard and reslice dialogs. - Refresh icon keeps its own track instead of stretching across a 1fr column. - Consistent heights, hover feedback and pressed states for the pool toolbar, focused review heading and camera toolbar; soft focus ring on workbench roots; the unstyled "保存进度" button gets the sibling button style. Co-Authored-By: Claude Opus 5.5 --- src/components/AcceptanceTaskCard.tsx | 21 +-- src/components/CaptureAnnotationWorkbench.tsx | 7 +- src/components/CaptureName.tsx | 6 + src/index.css | 18 +++ src/pages/AnnotationOperations.tsx | 131 ++++++++++-------- src/styles/capture-workspace.css | 51 +++++++ src/styles/review-captions.css | 11 ++ src/styles/review-workspace.css | 45 ++++++ 8 files changed, 222 insertions(+), 68 deletions(-) create mode 100644 src/components/CaptureName.tsx diff --git a/src/components/AcceptanceTaskCard.tsx b/src/components/AcceptanceTaskCard.tsx index b7771d88..b39f5402 100644 --- a/src/components/AcceptanceTaskCard.tsx +++ b/src/components/AcceptanceTaskCard.tsx @@ -2,6 +2,7 @@ import { ReviewListTrace } from "./ReviewTrace"; import type { HumanItem } from "../types"; import { ReviewHistorySummary } from "./ReviewHistorySummary"; import { cn } from "../lib/utils"; +import { CaptureName } from "./CaptureName"; import { acceptanceTaskAction } from "../lib/acceptance-workspace.js"; export function AcceptanceTaskCard({ @@ -41,27 +42,27 @@ export function AcceptanceTaskCard({ data-testid="acceptance-task-card" data-item-id={item.id} className={cn( - "w-full overflow-hidden rounded-lg border", + "w-full overflow-hidden rounded-lg border transition-colors", selected ? "border-orange-400 bg-orange-50/50 dark:bg-orange-500/10" - : "border-[color:var(--app-border)] bg-[color:var(--app-panel)]", + : "border-[color:var(--app-border)] bg-[color:var(--app-panel)] hover:border-orange-400/50", )} > diff --git a/src/components/CaptureName.tsx b/src/components/CaptureName.tsx new file mode 100644 index 00000000..39ff9d19 --- /dev/null +++ b/src/components/CaptureName.tsx @@ -0,0 +1,6 @@ +// Capture names are long underscore-joined tokens. Offer a line break after each +// underscore instead of mid-word; adds no characters to copied text. +export function CaptureName({ name }: { name: string }) { + const parts = name.split("_"); + return <>{parts.flatMap((part, index) => (index < parts.length - 1 ? [`${part}_`, ] : [part]))}; +} diff --git a/src/index.css b/src/index.css index 38bdff44..de5efbd1 100644 --- a/src/index.css +++ b/src/index.css @@ -83,6 +83,24 @@ html:not(.dark) .annotation-operations-page { color: #0f172a; } +/* Tailwind v4 draws a bare `border` in currentColor, which is near-black on the + workbenches. Give colourless borders the panel tone (controls one step darker); + any border-* utility still wins because utilities sit in a later layer. */ +html { + --app-control-border: #cbd5e1; +} +html.dark { + --app-control-border: #3f4249; +} +@layer base { + .annotation-operations-page :where(*, ::before, ::after) { + border-color: var(--app-border); + } + .annotation-operations-page :where(button, select, input, textarea, a, summary) { + border-color: var(--app-control-border); + } +} + .capture-media-controls { position: relative; z-index: 10; diff --git a/src/pages/AnnotationOperations.tsx b/src/pages/AnnotationOperations.tsx index 73608c81..3386875f 100644 --- a/src/pages/AnnotationOperations.tsx +++ b/src/pages/AnnotationOperations.tsx @@ -72,6 +72,7 @@ import { checkSliceEditResolution, planSliceEditDragRelease } from "../lib/slice import { annotationTaskAction } from "../lib/annotation-task-action.js"; import { FinalAcceptanceWorkspace } from "../components/FinalAcceptanceWorkspace"; import { AcceptanceTaskCard } from "../components/AcceptanceTaskCard"; +import { CaptureName } from "../components/CaptureName"; import { loadMoviPlayer } from "../lib/movi-player"; import { Link, useBlocker, useLocation, useNavigate, useParams, useSearchParams } from "react-router-dom"; import { @@ -483,7 +484,9 @@ function PoseEvidencePreview({ {frameCount} 帧 · {String(artifact?.name || artifactId)} - 人工质检证据 + + 人工质检证据 + -
当前任务有未确认修改
-
+
当前任务有未确认修改
+
离开将清空本次未确认的切片调整和各片未保存的描述草稿。
@@ -6220,14 +6223,14 @@ export default function AnnotationOperations({ workPage = false }: { workPage?: type="button" onClick={cancelLeave} autoFocus - className="rounded-lg border border-[#34363b] px-4 py-2 text-sm text-gray-200" + className="rounded-lg border border-[color:var(--app-control-border)] px-4 py-2 text-sm text-slate-700 transition-colors hover:bg-slate-50 dark:text-gray-200 dark:hover:bg-white/5" > 继续编辑 @@ -6372,7 +6375,17 @@ export default function AnnotationOperations({ workPage = false }: { workPage?: )} {!workPage || !selectedTaskId ? ( -
+
{isManager ? ( {!blindAnnotator && ( -
) : null} -
+
{annotationStage === "split_annotation" || annotationStage === "cut_adjustment" ? "人工剪切调整" : annotationStage === "split_quality_review" || annotationStage === "cut_review" @@ -7468,21 +7481,21 @@ export default function AnnotationOperations({ workPage = false }: { workPage?: ); case "rework": return ( -
+
打回(需返工)
); case "rework_review": return ( -
+
返工复查(核对修正与原退回意见)
); case "slicing": return ( -
+
正在切片数据包…
@@ -7503,7 +7516,7 @@ export default function AnnotationOperations({ workPage = false }: { workPage?: ); case "pending_quality": return ( -
+
已送检(待质检)
); @@ -7525,7 +7538,7 @@ export default function AnnotationOperations({ workPage = false }: { workPage?: 处理中(领取人:{selectedHumanItem.assignedUserId})
) : ( -
+
待领取
); @@ -8018,17 +8031,17 @@ export default function AnnotationOperations({ workPage = false }: { workPage?: aria-modal="true" aria-label="重新切片警告" > -
-
+
+

重新切片会丢失全部标注

-

+

两种方式都会清空片内动作划分、描述和无效判断,返回切片编辑。此操作成功后不能通过撤销恢复。

{resliceError && ( -

+

{userErrorMessage(resliceError)}

)} @@ -8067,7 +8084,7 @@ export default function AnnotationOperations({ workPage = false }: { workPage?: diff --git a/src/styles/capture-workspace.css b/src/styles/capture-workspace.css index 2e2fe0df..1b74f762 100644 --- a/src/styles/capture-workspace.css +++ b/src/styles/capture-workspace.css @@ -1751,6 +1751,57 @@ font-size: 11px; white-space: nowrap; } +/* 工作台根节点拿到焦点(快捷键生效)时,用柔和的品牌色描边代替浏览器默认的 + 黑色粗焦点框;仍保留可见的焦点提示。 */ +.capture-workbench:focus-visible, +[data-testid="final-acceptance-workspace"]:focus-visible { + outline: 2px solid rgb(249 115 22 / 45%); + outline-offset: -2px; +} +/* 画面工具条:同一套描边、按下态与悬停反馈(只换外观,尺寸不变以守住 615px 底线)。 */ +.capture-caption-toggle, +.capture-slice-zoom, +.capture-camera-inspection-controls button { + background: var(--app-panel); + border-color: var(--app-control-border); + transition: + border-color 0.15s, + color 0.15s, + background-color 0.15s; +} +.capture-caption-toggle:hover:not(:disabled), +.capture-slice-zoom:hover:not(:disabled), +.capture-camera-inspection-controls button:hover:not(:disabled) { + border-color: rgb(249 115 22 / 60%); +} +.capture-slice-zoom[aria-pressed="true"] { + border-color: #f97316; + color: #c2410c; +} +html.dark .capture-slice-zoom[aria-pressed="true"], +html.dark .capture-camera-inspection-controls button[aria-pressed="true"] { + color: #fdba74; +} +/* 任务池顶栏(普通与专注):工作模式、容量、领取、任务切换和返回按钮统一为 28px 高的同一套控件。 */ +.annotation-operations-page .annotation-work-buffer :is(button, select), +.annotation-operations-page[data-workspace-compact] .annotation-work-page-navigation a { + min-height: 28px; + border-radius: 6px; + background-color: var(--app-panel); + transition: + border-color 0.15s, + color 0.15s, + background-color 0.15s; +} +.annotation-operations-page[data-workspace-compact] .annotation-work-page-navigation a { + padding: 3px 12px; + font-size: 13px; + line-height: 20px; +} +.annotation-operations-page .annotation-work-buffer :is(button, select):hover:not(:disabled), +.annotation-operations-page[data-workspace-compact] .annotation-work-page-navigation a:hover { + border-color: rgb(59 130 246 / 60%); +} .capture-caption-strip { flex-shrink: 0; min-height: 0; diff --git a/src/styles/review-captions.css b/src/styles/review-captions.css index c097ea89..0950dfce 100644 --- a/src/styles/review-captions.css +++ b/src/styles/review-captions.css @@ -62,6 +62,17 @@ grid-column: 2; grid-row: 1 / 4; } +/* 普通审查布局:侧栏常比左列高。多余高度交给末尾弹性行,相机行、画面和播放 + 控制条保持自身高度,不再被拉伸成大块空白。专注布局里本容器是 + display: contents,这里的行定义不生效。 */ +@media (min-width: 1001px) { + .capture-workbench .capture-review-video-panel { + grid-template-rows: repeat(4, auto) minmax(0, 1fr); + } + .capture-workbench .capture-review-video-panel > .review-qa-side-panel { + grid-row: 1 / -1; + } +} @media (max-width: 1000px) { .capture-review-video-panel { grid-template-columns: minmax(0, 1fr); diff --git a/src/styles/review-workspace.css b/src/styles/review-workspace.css index 14b5c7c6..3ee3f392 100644 --- a/src/styles/review-workspace.css +++ b/src/styles/review-workspace.css @@ -31,6 +31,28 @@ font-weight: 600; line-height: 1.5; } +.review-focus-heading > button { + border-radius: 8px; + padding: 4px 12px; + font-size: 13px; + line-height: 20px; + background: var(--app-panel); + transition: + border-color 0.15s, + color 0.15s, + background-color 0.15s; +} +.review-focus-heading > button:hover:not(:disabled) { + border-color: rgb(59 130 246 / 60%); + color: #2563eb; +} +html.dark .review-focus-heading > button:hover:not(:disabled) { + color: #93c5fd; +} +.review-focus-heading > button:disabled { + opacity: 0.5; + cursor: not-allowed; +} .annotation-operations-page[data-review-focused] > .annotation-workspace-heading, .annotation-operations-page[data-review-focused] .annotation-task-pool { display: none; @@ -390,6 +412,15 @@ [data-testid="final-acceptance-workspace"][data-review-focused] aside > .review-caption-details { flex: 0 1 135px; } +/* 上面的 aside 规则(flex 列 + 子项 min-height:0)也会命中内层的「当前画面标注」 + 面板,把标题和正文压成几像素高、互相重叠;内层面板恢复普通块排版并自行滚动。 */ +[data-testid="final-acceptance-workspace"][data-review-focused] aside.review-caption-details { + display: block; + overflow: auto; +} +[data-testid="final-acceptance-workspace"][data-review-focused] aside.review-caption-details > * { + margin-block: 0 6px; +} [data-testid="final-acceptance-workspace"][data-review-focused] aside > .review-problem-panel { flex: 1; min-height: 0; @@ -471,6 +502,20 @@ grid-template-columns: 150px minmax(0, 1fr) minmax(460px, 34vw); } } +/* 审查视图不渲染动作列表时,收起为它预留的 150px 左栏,画面不再空出一条白边; + 动作列表一旦出现,原三栏几何自动恢复。 */ +.annotation-operations-page[data-review-focused] + .capture-workbench-host + > .capture-workbench:not(:has(.capture-action-list)) { + grid-template-columns: 0 minmax(0, 1fr) 310px; +} +@media (min-width: 1001px) { + .annotation-operations-page[data-review-focused] + .capture-workbench-host + > .capture-workbench:has(.qc-review-dual-board):not(:has(.capture-action-list)) { + grid-template-columns: 0 minmax(0, 1fr) minmax(460px, 34vw); + } +} @media (max-width: 1000px) { .qc-review-dual-board { grid-template-columns: minmax(0, 1fr); From 19e9680aa7f792fd5e0d549f33faf7146abe5187 Mon Sep 17 00:00:00 2001 From: d-robotics Date: Tue, 27 Oct 2026 09:18:17 +0800 Subject: [PATCH 3/3] =?UTF-8?q?=F0=9F=A9=B9=20Keep=20read-only=20review=20?= =?UTF-8?q?footer=20and=20fold=20task=20diagnostics=20into=20each=20top=20?= =?UTF-8?q?row?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit A quality review that loses its edit lease no longer falls through to the annotator's slice-confirmation bar; it shows its own read-only footer with a takeover hint. The task-scoped connection-diagnostics link joins the subnav, work-page or focus-heading row instead of taking a line of its own. Co-Authored-By: Claude Opus 5.5 --- .scratch/workbench-ui-polish/work.md | 7 ++-- docs/review-workspace-guide.zh-CN.md | 2 +- src/components/CaptureAnnotationWorkbench.tsx | 18 +++++++- src/pages/AnnotationOperations.tsx | 41 +++++++++++++------ src/styles/capture-workspace.css | 12 ++++-- .../capture-annotation-workbench.test.mjs | 33 +++++++++++++++ 6 files changed, 92 insertions(+), 21 deletions(-) diff --git a/.scratch/workbench-ui-polish/work.md b/.scratch/workbench-ui-polish/work.md index cbbabcc0..cb54d075 100644 --- a/.scratch/workbench-ui-polish/work.md +++ b/.scratch/workbench-ui-polish/work.md @@ -2,7 +2,8 @@ Goal: make the annotator / QC / final-acceptance workbenches (normal and focus layouts, rework and re-review states) tidier and smoother without changing any function; interaction changes need the user's approval first Agent: Claude Code (desktop session, 2026-10-27) -Base: codex/frontend-polish-20261026 @ de96cfc2 (unmerged; it carries the production line review-runtime-trace, whose annotation workbench differs from origin/dev by ~1300 lines). Pending the user's confirmation. +Base: codex/frontend-polish-20261026 @ de96cfc2 (unmerged; it carries the production line review-runtime-trace, whose annotation workbench differs from origin/dev by ~1300 lines). Confirmed by the user on 2026-10-27. Scope: src/index.css, src/styles/{capture-workspace,review-workspace,review-captions}.css, display-only class names in src/pages/AnnotationOperations.tsx and src/components/* used by the four workbenches -Out of scope: interaction changes (entry points, shortcuts, panel positions, confirmations, auto-claim/continuation behaviour), API, data, other pages -Risk: display only +Approved interaction changes (2026-10-27 compare sheet): the task-scoped 当前任务连接诊断 link joins each layout's top row; a read-only quality review shows its own footer and takeover hint instead of the annotator slice bar. Declined: moving the QC opinion panel below the video; adding an action list to review focus. +Out of scope: other interaction changes (entry points, shortcuts, panel positions, confirmations, auto-claim/continuation behaviour), API, data, other pages +Risk: display plus one footer-routing fix; no API, data or shortcut changes diff --git a/docs/review-workspace-guide.zh-CN.md b/docs/review-workspace-guide.zh-CN.md index bef6ed9f..2d80f9cb 100644 --- a/docs/review-workspace-guide.zh-CN.md +++ b/docs/review-workspace-guide.zh-CN.md @@ -67,7 +67,7 @@ Shift + Delete(Mac:Shift + Backspace)删除列表中选中的本轮问题 刷新、直接打开地址、只读预览不会自动开启;普通与专注布局切换不算重新进入。显式暂停、提交异常、窗口过小或被接管后保持暂停,条件恢复后需要手动继续;自动进入的下一条沿用原连续会话。 -同一账号在两个页面打开同一任务时,只能一个页面编辑。另一个页面可查看,并可明确接管;接管后原页面停止写入,已保存草稿保留。这项能力适用于公司普通 HTTP 入口。 +同一账号在两个页面打开同一任务时,只能一个页面编辑。另一个页面可查看,并可明确接管;接管后原页面停止写入,已保存草稿保留。只读页面的底栏显示「质检审核模式(只读查看)」和「本页只读,点上方「在本页接管审查」后可审核」,不显示通过/退回按钮,也不显示标注员的切片确认条。这项能力适用于公司普通 HTTP 入口。 ## 供应商共享验收池(2026-09-29) diff --git a/src/components/CaptureAnnotationWorkbench.tsx b/src/components/CaptureAnnotationWorkbench.tsx index 81c14057..3ed9f348 100644 --- a/src/components/CaptureAnnotationWorkbench.tsx +++ b/src/components/CaptureAnnotationWorkbench.tsx @@ -201,6 +201,8 @@ type Props = ReviewViewingProps & { */ captionsViewable?: boolean; reviewWriteLocked?: boolean; + /** Footer hint shown while a review is read-only, e.g. why and how to regain the decision buttons. */ + reviewReadOnlyNotice?: string; reviewApprovalBlocked?: boolean; reviewMode?: "quality" | "acceptance"; reviewCaption?: ReviewCaption; @@ -385,6 +387,7 @@ export function CaptureAnnotationWorkbench({ isQualityReview = false, captionsViewable = false, reviewWriteLocked = false, + reviewReadOnlyNotice = "", reviewApprovalBlocked = false, reviewMode = "quality", reviewCaption: providedReviewCaption, @@ -6451,7 +6454,9 @@ export function CaptureAnnotationWorkbench({ )}
- ) : phase === "slice" ? ( + ) : phase === "slice" && !isQualityReview ? ( + // A read-only review falls through to the read-only footer below, never + // the annotator's slice-confirmation bar. <> {claimLocked @@ -6505,7 +6510,16 @@ export function CaptureAnnotationWorkbench({ {operationNotice}

)} - {segments.length} 个描述已确认 + + {isQualityReview + ? `${slices.length} 个切片 · ${segments.length} 个动作` + : `${segments.length} 个描述已确认`} + + {isQualityReview && reviewReadOnlyNotice ? ( + + {reviewReadOnlyNotice} + + ) : null} {isQualityReview ? "质检审核模式(只读查看)" : `${readOnlyStatusLabel}(只读查看)`} diff --git a/src/pages/AnnotationOperations.tsx b/src/pages/AnnotationOperations.tsx index 3386875f..5aa81f43 100644 --- a/src/pages/AnnotationOperations.tsx +++ b/src/pages/AnnotationOperations.tsx @@ -6064,6 +6064,17 @@ export default function AnnotationOperations({ workPage = false }: { workPage?: ); const showViewportPrompt = viewportPaused && pendingTaskId === null && leaveBlocker.state !== "blocked"; + // Rendered once, at the end of whichever top row the current layout shows. + const taskDiagnosticsLink = ( + + 当前任务连接诊断 + + ); const workspaceContent = (
- {reviewFocused && (

{workspaceMode === "acceptance" ? "最终验收" : "质检审查"}

@@ -6138,6 +6139,7 @@ export default function AnnotationOperations({ workPage = false }: { workPage?: > 返回任务池 + {taskDiagnosticsLink}
)} {draftGuardNotice && ( @@ -6358,7 +6360,8 @@ export default function AnnotationOperations({ workPage = false }: { workPage?: 工作模式由个人任务池旁的开关控制

-
+
+ {!reviewFocused && taskDiagnosticsLink} workSession.pauseContinuous("已返回任务池,连续工作暂停。")} to={workPoolPath} @@ -6371,7 +6374,16 @@ export default function AnnotationOperations({ workPage = false }: { workPage?: ) : ( <>

{workspaceTitle}

- +
+
+ +
+ {!reviewFocused && ( +
+ {taskDiagnosticsLink} +
+ )} +
)} {!workPage || !selectedTaskId ? ( @@ -7772,6 +7784,11 @@ export default function AnnotationOperations({ workPage = false }: { workPage?: )) } reviewWriteLocked={reviewWriteLocked || Boolean(reviewDecision.pending)} + reviewReadOnlyNotice={ + reviewSessionEnabled && !reviewSession.writable + ? "本页只读,点上方「在本页接管审查」后可审核" + : "" + } reviewProblemPanel={reviewProblemPanel} reviewTracePanel={reviewTracePanel} onReviewNavigate={reviewDraft.onNavigate} diff --git a/src/styles/capture-workspace.css b/src/styles/capture-workspace.css index 1b74f762..ed500df8 100644 --- a/src/styles/capture-workspace.css +++ b/src/styles/capture-workspace.css @@ -1784,7 +1784,9 @@ html.dark .capture-camera-inspection-controls button[aria-pressed="true"] { } /* 任务池顶栏(普通与专注):工作模式、容量、领取、任务切换和返回按钮统一为 28px 高的同一套控件。 */ .annotation-operations-page .annotation-work-buffer :is(button, select), -.annotation-operations-page[data-workspace-compact] .annotation-work-page-navigation a { +.annotation-operations-page[data-workspace-compact] + .annotation-work-page-navigation + a:not(.annotation-task-diagnostics) { min-height: 28px; border-radius: 6px; background-color: var(--app-panel); @@ -1793,13 +1795,17 @@ html.dark .capture-camera-inspection-controls button[aria-pressed="true"] { color 0.15s, background-color 0.15s; } -.annotation-operations-page[data-workspace-compact] .annotation-work-page-navigation a { +.annotation-operations-page[data-workspace-compact] + .annotation-work-page-navigation + a:not(.annotation-task-diagnostics) { padding: 3px 12px; font-size: 13px; line-height: 20px; } .annotation-operations-page .annotation-work-buffer :is(button, select):hover:not(:disabled), -.annotation-operations-page[data-workspace-compact] .annotation-work-page-navigation a:hover { +.annotation-operations-page[data-workspace-compact] + .annotation-work-page-navigation + a:not(.annotation-task-diagnostics):hover { border-color: rgb(59 130 246 / 60%); } .capture-caption-strip { diff --git a/tests/frontend/capture-annotation-workbench.test.mjs b/tests/frontend/capture-annotation-workbench.test.mjs index 9a1ae9ea..6a2e96d9 100644 --- a/tests/frontend/capture-annotation-workbench.test.mjs +++ b/tests/frontend/capture-annotation-workbench.test.mjs @@ -484,3 +484,36 @@ test("local mock preview is guarded by Vite development mode", () => { assert.match(preview, /href=\{href\}/); assert.match(preview, /onReturnToPool=\{\(\) => setView\("pool"\)\}/); }); + +test("a read-only quality review keeps its own footer instead of the annotator slice bar", () => { + const footer = workbench.slice(workbench.indexOf("")); + // Slice phase only routes to the annotator's confirmation bar outside quality review. + assert.match(footer, /\) : phase === "slice" && !isQualityReview \? \(/); + const readOnlyFooter = footer.slice(footer.indexOf(") : readOnly ? (")); + assert.match(readOnlyFooter, /isQualityReview && reviewReadOnlyNotice \?/); + assert.match(readOnlyFooter, /质检审核模式(只读查看)/); + // The hint appears exactly when the page offers the takeover button. + assert.match( + annotationOperations, + /reviewReadOnlyNotice=\{\s*reviewSessionEnabled && !reviewSession\.writable\s*\? "本页只读,点上方「在本页接管审查」后可审核"/, + ); + assert.match( + annotationOperations, + /reviewSessionEnabled && !reviewSession\.writable && \(\s* { + assert.equal(annotationOperations.match(/当前任务连接诊断/g)?.length, 1); + assert.doesNotMatch(annotationOperations, /