From 2142027f858b96a786d90845ba16339506b87b7e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E5=BE=B7=E5=AE=87?= Date: Fri, 18 Sep 2026 17:15:50 +0800 Subject: [PATCH] =?UTF-8?q?=E7=AE=80=E5=8C=96=E4=BF=9D=E5=AD=98=E7=BB=93?= =?UTF-8?q?=E6=9E=9C=E5=BC=B9=E7=AA=97=E5=86=85=E5=AE=B9=E5=88=86=E6=94=AF?= =?UTF-8?q?=20=E7=94=A8=E6=98=BE=E5=BC=8F=E6=97=A9=E8=BF=94=E5=9B=9E?= =?UTF-8?q?=E6=9B=BF=E6=8D=A2=E5=B5=8C=E5=A5=97=E4=B8=89=E5=85=83=E6=B8=B2?= =?UTF-8?q?=E6=9F=93?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/UiEditorSaveResultModal.tsx | 24 +++++++++++++------ 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/apps/ai-game-creator-shell/src/view/ui-editor/components/UiEditorSaveResultModal.tsx b/apps/ai-game-creator-shell/src/view/ui-editor/components/UiEditorSaveResultModal.tsx index 463b9b76a..f6cfe4e8c 100644 --- a/apps/ai-game-creator-shell/src/view/ui-editor/components/UiEditorSaveResultModal.tsx +++ b/apps/ai-game-creator-shell/src/view/ui-editor/components/UiEditorSaveResultModal.tsx @@ -30,17 +30,27 @@ export function UiEditorSaveResultModal({ ariaLabel={ariaLabelForNotice(notice)} panelClassName="w-[min(460px,calc(100vw-2rem))] rounded-2xl p-5" > - {notice?.kind === 'generated' ? ( - - ) : notice?.kind === 'saved' ? ( - - ) : notice?.kind === 'failure' ? ( - - ) : null} + {renderNoticeContent(notice, onClose)} ); } +function renderNoticeContent( + notice: UiEditorSaveResultNotice | null, + onClose: () => void, +) { + if (!notice) return null; + if (notice.kind === 'generated') { + return ( + + ); + } + if (notice.kind === 'saved') { + return ; + } + return ; +} + function GeneratedNotice({ relativePath, onClose,