From fffc93d355c338ec12a2e90fca5b2aee004a6b0c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E5=BE=B7=E5=AE=87?= Date: Tue, 18 Aug 2026 13:20:19 +0800 Subject: [PATCH] =?UTF-8?q?=E5=85=81=E8=AE=B8=E4=BB=BB=E6=84=8F=E7=95=8C?= =?UTF-8?q?=E9=9D=A2=E5=9B=BE=E5=88=9B=E5=BB=BA=20UI=20=E6=A0=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 移除仅 Page 角色自动创建 UITree 的限制 保持每张界面图与最多一棵 UI 树同步 --- .../src/features/ui-editor/useUiEditorState.ts | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/apps/ai-game-creator-shell/src/features/ui-editor/useUiEditorState.ts b/apps/ai-game-creator-shell/src/features/ui-editor/useUiEditorState.ts index 1af37815c..95f585a63 100644 --- a/apps/ai-game-creator-shell/src/features/ui-editor/useUiEditorState.ts +++ b/apps/ai-game-creator-shell/src/features/ui-editor/useUiEditorState.ts @@ -140,10 +140,7 @@ function synchronizeDesignImageTrees(state: State): void { imageIds.has(tree.src_ui_design), ); for (const [id] of Object.entries(state.ui_design_images)) { - if ( - state.ui_design_images[id]!.metadata.role === 'Page' && - !state.ui_trees.some((tree) => tree.src_ui_design === id) - ) { + if (!state.ui_trees.some((tree) => tree.src_ui_design === id)) { state.ui_trees.push({ src_ui_design: id, root: createPageRoot(state) }); } }