From 97dc784c8b1df1e25b2c3a12c5d18c232712ed39 Mon Sep 17 00:00:00 2001 From: GouJ Date: Fri, 16 Oct 2026 13:07:05 +0800 Subject: [PATCH] =?UTF-8?q?refactor:=20=E5=88=86=E9=95=9C=E8=B4=A8?= =?UTF-8?q?=E9=87=8F=E8=AF=8A=E6=96=AD=E7=A7=BB=E8=87=B3=E5=88=86=E9=95=9C?= =?UTF-8?q?=20Tab=20=E5=B9=B6=E4=B8=8E=E6=8B=86=E8=A7=A3=E8=AE=BE=E7=BD=AE?= =?UTF-8?q?=E8=A7=A3=E8=80=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/features/breakdown/BreakdownPage.vue | 210 ++++++++++++----------- 1 file changed, 110 insertions(+), 100 deletions(-) diff --git a/src/features/breakdown/BreakdownPage.vue b/src/features/breakdown/BreakdownPage.vue index 916ab7a..d1eb6f4 100644 --- a/src/features/breakdown/BreakdownPage.vue +++ b/src/features/breakdown/BreakdownPage.vue @@ -32,6 +32,8 @@ const preview = ref(null) const previewBusy = ref(false) const tab = ref('character') const toolsOpen = ref(false) +/** 分镜诊断与拆解设置解耦,默认不占用列表空间。 */ +const qualityPanelOpen = ref(false) /** 仅打开设置面板时按需查询,不增加页面常驻提示或后台轮询。 */ const handDiagnostics = ref(null) const handDiagnosticsBusy = ref(false) @@ -43,9 +45,9 @@ async function loadHandRepairPreview(id: string) { handRepairBusy.value = true try { const data = await breakdownApi.handRepairPreview(id) - if (version === handDiagnosticsVersion && toolsOpen.value && projectId.value === id) handRepairPreview.value = data + if (version === handDiagnosticsVersion && qualityPanelOpen.value && projectId.value === id) handRepairPreview.value = data } catch (cause) { - if (version === handDiagnosticsVersion && toolsOpen.value && projectId.value === id) actionMessage?.error(errorMessage(cause)) + if (version === handDiagnosticsVersion && qualityPanelOpen.value && projectId.value === id) actionMessage?.error(errorMessage(cause)) } finally { if (version === handDiagnosticsVersion) handRepairBusy.value = false } @@ -58,9 +60,9 @@ async function loadHandDiagnostics(id: string) { handDiagnostics.value = null try { const data = await breakdownApi.handOccupancyDiagnostics(id) - if (version === handDiagnosticsVersion && toolsOpen.value && projectId.value === id) handDiagnostics.value = data + if (version === handDiagnosticsVersion && qualityPanelOpen.value && projectId.value === id) handDiagnostics.value = data } catch (cause) { - if (version === handDiagnosticsVersion && toolsOpen.value && projectId.value === id) actionMessage?.error(errorMessage(cause)) + if (version === handDiagnosticsVersion && qualityPanelOpen.value && projectId.value === id) actionMessage?.error(errorMessage(cause)) } finally { if (version === handDiagnosticsVersion) handDiagnosticsBusy.value = false } @@ -82,7 +84,7 @@ const summary = computed(() => snapshot.value?.taskSummary) const validation = computed(() => result.value?.storyboardShotValidation ?? snapshot.value?.storyboardShotValidation) const projectId = computed(() => project.value?.id ?? '') const operation = computed(() => getOperation(projectId.value)) -watch([toolsOpen, projectId], () => { +watch([qualityPanelOpen, projectId], () => { ++handDiagnosticsVersion handDiagnostics.value = null handDiagnosticsBusy.value = false @@ -114,15 +116,15 @@ async function loadLegacyResults() { legacyResultsBusy.value = true try { const data = await breakdownApi.legacyActionDiagnosisResults(id, episode) - if (requestVersion === legacyResultsRequest && version === handDiagnosticsVersion && projectId.value === id && toolsOpen.value) legacyResults.value = data + if (requestVersion === legacyResultsRequest && version === handDiagnosticsVersion && projectId.value === id && qualityPanelOpen.value) legacyResults.value = data } catch (cause) { - if (requestVersion === legacyResultsRequest && version === handDiagnosticsVersion && projectId.value === id && toolsOpen.value) actionMessage?.error(errorMessage(cause)) + if (requestVersion === legacyResultsRequest && version === handDiagnosticsVersion && projectId.value === id && qualityPanelOpen.value) actionMessage?.error(errorMessage(cause)) } finally { if (requestVersion === legacyResultsRequest) legacyResultsBusy.value = false } } watch(() => legacyDiagnosisExecution.query.data.value?.status, (status, previous) => { - if (status && status !== previous && (status === 'completed' || status === 'failed') && toolsOpen.value) { + if (status && status !== previous && (status === 'completed' || status === 'failed') && qualityPanelOpen.value) { void loadLegacyResults() } }) @@ -143,9 +145,9 @@ async function loadLegacyPreview() { const data = await breakdownApi.legacyActionDiagnosisPreview(id, legacyEpisodeNo.value, legacyDiagnosisScope.value === 'beat' || legacyDiagnosisScope.value === 'shot' ? legacyBeatNo.value : undefined, legacyDiagnosisScope.value === 'shot' ? legacyShotNo.value : undefined) - if (version === handDiagnosticsVersion && projectId.value === id && toolsOpen.value) legacyPreview.value = data + if (version === handDiagnosticsVersion && projectId.value === id && qualityPanelOpen.value) legacyPreview.value = data } catch (cause) { - if (version === handDiagnosticsVersion && projectId.value === id && toolsOpen.value) actionMessage?.error(errorMessage(cause)) + if (version === handDiagnosticsVersion && projectId.value === id && qualityPanelOpen.value) actionMessage?.error(errorMessage(cause)) } finally { if (version === handDiagnosticsVersion) legacyPreviewBusy.value = false } @@ -156,7 +158,8 @@ async function openLegacyShotDiagnosis(scope: { episodeNo: number; beatNo: numbe legacyBeatNo.value = scope.beatNo legacyShotNo.value = scope.shotNo legacyDiagnosisScope.value = scope.shotNo === undefined ? 'beat' : 'shot' - toolsOpen.value = true + tab.value = 'storyboard' + qualityPanelOpen.value = true await loadLegacyPreview() } async function startLegacyDiagnosis() { @@ -508,95 +511,6 @@ const rules = { @refresh="backgroundExecution.query.refresh" @dismiss="backgroundExecution.dismiss" /> - -
-
-

手部动作质量

- {{ handDiagnostics ? '刷新' : '查看诊断' }} -
-
- 镜头 {{ handDiagnostics.shotCount }} - 有效证据 {{ handDiagnostics.evidenceShotCount }} / {{ handDiagnostics.shotCount }} - 冲突 {{ handDiagnostics.warningCount }} - 证据不足 - 部分镜头缺少证据 -
-
-
- 第 {{ issue.episodeNo }} 集 / Beat {{ issue.beatNo }} / Shot {{ issue.shotNo }} / 阶段 {{ issue.phaseNo }}:{{ issue.suggestion }} -
-
-
-
-
-

历史镜头 AI 动作诊断

- 预览范围 -
-
- 单集 - 全项目 - Beat {{ legacyBeatNo }}{{ legacyDiagnosisScope === 'shot' ? ` / Shot ${legacyShotNo}` : '' }} - - 并发 - -
-
- 第 {{ legacyPreview.episodeNo }} 集:{{ legacyPreview.candidateCount }} 个镜头,{{ legacyPreview.needsEvidenceCount }} 个待补证据 -
-
- -
-
- 诊断结果 - 查看结果 -
-
-
- 总计 {{ legacyResults.counts.total }} - 冲突 {{ legacyResults.counts.conflict }} - 未发现冲突 {{ legacyResults.counts.clear }} - 证据不足 {{ legacyResults.counts.insufficient }} - 证据无效 {{ legacyResults.counts.invalid }} - 已过期 {{ legacyResults.counts.stale }} - 未诊断 {{ legacyResults.counts.pending }} -
-
- 第 {{ item.episodeNo }} 集 / Beat {{ item.beatNo }} / Shot {{ item.shotNo }} · {{ item.title }} - {{ ({ - conflict_found: '手部冲突', - insufficient_evidence: '证据不足', - invalid_evidence: '证据无效', - stale: '诊断过期', - not_diagnosed: '尚未诊断', - no_conflict_found: '未发现冲突' - } as const)[item.status] }} -
-
- -
-
-
-

局部修复候选

- - {{ handRepairPreview ? '刷新候选' : '查看候选' }} - -
-
-
-

第 {{ item.episodeNo }} 集 / Beat {{ item.beatNo }} / Shot {{ item.shotNo }} / 阶段 {{ item.phaseNo }}

-

{{ item.suggestion }}

-

{{ item.blockingReasons.join(';') }}

-
-
-

@@ -770,6 +684,102 @@ const rules = { />

+
+ {{ qualityPanelOpen ? '收起质量诊断' : '分镜质量诊断' }} +
+
+
分镜质量诊断
+ +
+
+

结构化动作校验

+ {{ handDiagnostics ? '刷新' : '查看诊断' }} +
+
+ 镜头 {{ handDiagnostics.shotCount }} + 有效证据 {{ handDiagnostics.evidenceShotCount }} / {{ handDiagnostics.shotCount }} + 冲突 {{ handDiagnostics.warningCount }} + 证据不足 + 部分镜头缺少证据 +
+
+
+ 第 {{ issue.episodeNo }} 集 / Beat {{ issue.beatNo }} / Shot {{ issue.shotNo }} / 阶段 {{ issue.phaseNo }}:{{ issue.suggestion }} +
+
+
+
+
+

历史镜头 AI 诊断

+ 预览范围 +
+
+ 单集 + 全项目 + Beat {{ legacyBeatNo }}{{ legacyDiagnosisScope === 'shot' ? ` / Shot ${legacyShotNo}` : '' }} + + 并发 + +
+
+ 第 {{ legacyPreview.episodeNo }} 集:{{ legacyPreview.candidateCount }} 个镜头,{{ legacyPreview.needsEvidenceCount }} 个待补证据 +
+
+ +
+
+ 诊断结果 + 查看结果 +
+
+
+ 总计 {{ legacyResults.counts.total }} + 冲突 {{ legacyResults.counts.conflict }} + 未发现冲突 {{ legacyResults.counts.clear }} + 证据不足 {{ legacyResults.counts.insufficient }} + 证据无效 {{ legacyResults.counts.invalid }} + 已过期 {{ legacyResults.counts.stale }} + 未诊断 {{ legacyResults.counts.pending }} +
+
+ 第 {{ item.episodeNo }} 集 / Beat {{ item.beatNo }} / Shot {{ item.shotNo }} · {{ item.title }} + {{ ({ + conflict_found: '手部冲突', + insufficient_evidence: '证据不足', + invalid_evidence: '证据无效', + stale: '诊断过期', + not_diagnosed: '尚未诊断', + no_conflict_found: '未发现冲突' + } as const)[item.status] }} +
+
+ +
+
+
+

局部修复候选

+ + {{ handRepairPreview ? '刷新候选' : '查看候选' }} + +
+
+
+

第 {{ item.episodeNo }} 集 / Beat {{ item.beatNo }} / Shot {{ item.shotNo }} / 阶段 {{ item.phaseNo }}

+

{{ item.suggestion }}

+

{{ item.blockingReasons.join(';') }}

+
+
+
+ +