From 519b956808259ab05a0a1f4c9243c679c226712f Mon Sep 17 00:00:00 2001 From: GJ Date: Sun, 11 Oct 2026 00:01:24 +0800 Subject: [PATCH] =?UTF-8?q?feat(short-drama-agent-front):=20=E6=96=B0?= =?UTF-8?q?=E5=A2=9E=E8=A7=86=E8=A7=89=E9=A3=8E=E6=A0=BC=E9=AA=A8=E6=9E=B6?= =?UTF-8?q?=E5=B1=8F=E5=B9=B6=E4=BC=98=E5=8C=96=E5=8F=82=E8=80=83=E5=9B=BE?= =?UTF-8?q?=E6=B7=BB=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/features/projects/ProjectLayout.vue | 17 +- src/features/visual-style/VisualStylePage.vue | 50 ++- .../visual-style/VisualStyleSkeleton.vue | 122 ++++++ .../visual-style/components/StyleEditor.vue | 23 +- .../visual-style/components/StyleImages.vue | 390 +++++++++++------- tests/components/ui/ActionMenu.test.ts | 5 +- tests/components/ui/flatTheme.test.ts | 7 +- tests/components/ui/form.test.ts | 49 ++- tests/components/ui/layout.test.ts | 10 +- tests/features/projects/access.test.ts | 82 ++-- tests/features/workflows/pages.test.ts | 108 ++++- 11 files changed, 621 insertions(+), 242 deletions(-) create mode 100644 src/features/visual-style/VisualStyleSkeleton.vue diff --git a/src/features/projects/ProjectLayout.vue b/src/features/projects/ProjectLayout.vue index 8ad8d9d..78c25af 100644 --- a/src/features/projects/ProjectLayout.vue +++ b/src/features/projects/ProjectLayout.vue @@ -16,6 +16,7 @@ import { projectGenerationRevisionKey } from '../generation-config/context' import WorkflowExecutionPanel from '../workflows/WorkflowExecutionPanel.vue' import CreateDramaSkeleton from '../create-drama/CreateDramaSkeleton.vue' import BreakdownSkeleton from '../breakdown/BreakdownSkeleton.vue' +import VisualStyleSkeleton from '../visual-style/VisualStyleSkeleton.vue' /** 项目标题只保留名称;下游工作区在剧本完成前不挂载,直接链接也无法越过限制。 */ const route = useRoute() @@ -103,14 +104,8 @@ const currentAccess = computed(() => { return section ? stageAccess.sections.value[section] : null }) const isCreation = computed(() => currentSection.value === 'create-drama') -/** 剧本首次读取或切换项目时显示骨架;刷新已有项目时保留正文与阅读位置。 */ -const isCreationInitialLoading = computed( - () => isCreation.value && context.loading.value && context.project.value?.id !== id.value -) -/** 拆解页只在首次读取或切换项目时占位,刷新已有结果时保留内容与分类。 */ -const isBreakdownInitialLoading = computed( - () => currentSection.value === 'breakdown' && context.loading.value && context.project.value?.id !== id.value -) +/** 各工作区共用首次读取判定;切换项目显示占位,刷新已有项目保留内容。 */ +const isProjectInitialLoading = computed(() => context.loading.value && context.project.value?.id !== id.value) type OperationGuide = { title: string description: string @@ -311,9 +306,11 @@ onScopeDispose(() => { > - + - + + + diff --git a/src/features/visual-style/VisualStylePage.vue b/src/features/visual-style/VisualStylePage.vue index b93b2c5..8b00dcd 100644 --- a/src/features/visual-style/VisualStylePage.vue +++ b/src/features/visual-style/VisualStylePage.vue @@ -1,6 +1,5 @@