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 @@ + + - @@ -131,7 +149,7 @@ function removeImage(image: VisualStyleImage) { - + 视觉风格已准备好,可以继续确认人物、场景和道具的主体身份。 继续主体身份 → 有未保存修改,AI 重生成暂不可用。刷新不会覆盖编辑内容;离开页面不会自动保存。
+ AI + 生成时,若项目和世界观没有明确其它人物背景,人物风格默认采用中国人物选角基线;人工填写的人物背景和角色事实优先。修改风格只影响之后的生成,旧资产不会自动更新。 +
正在读取视觉风格…
- 优先从项目资产库选择,也可登记已有 HTTP(S) 或 /storage/ - 图片地址。启用的参考图会参与后续身份与形态生图,已有图片不会自动更新。 + 添加已有图片作为风格参考。参与生成的参考图用于后续主体身份与形态生图,已有图片不会自动更新。
尚无风格参考图。先保存视觉风格,再登记图片。
+ {{ hasStyle ? '尚无风格参考图,可从资产库或通过图片链接添加。' : '先保存视觉风格,再添加参考图。' }} +
{{ assetError }}
正在读取项目素材…
+ 资产库暂无图片。 + 前往资产库上传 +
同一应用范围内,数值越小越靠前。
+ 关闭后仍会保存参考图,后续生成不会使用它;已有图片不会自动更新。 +
{{ addError }}