From ada9bc955357590a8f0bbdfa65306906ee91a7ad Mon Sep 17 00:00:00 2001 From: AIGameCreator App Date: Wed, 8 Jul 2026 10:26:48 +0800 Subject: [PATCH] =?UTF-8?q?=E9=9A=90=E8=97=8F=E7=A9=BA=E9=80=9A=E7=9F=A5?= =?UTF-8?q?=E6=9D=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 启动器通知列表为空时不渲染顶部通知条 移除登录页顶部通知占位背景 补充默认无通知条的启动器测试 --- apps/ai-game-creator-shell/src/App.tsx | 32 +++++++++---------- apps/ai-game-creator-shell/src/styles.css | 4 +-- .../tests/appSurface.test.ts | 1 + 3 files changed, 18 insertions(+), 19 deletions(-) diff --git a/apps/ai-game-creator-shell/src/App.tsx b/apps/ai-game-creator-shell/src/App.tsx index 49e0ff72a..1a1e0b4db 100644 --- a/apps/ai-game-creator-shell/src/App.tsx +++ b/apps/ai-game-creator-shell/src/App.tsx @@ -75,6 +75,11 @@ const AGENT_RUN_HISTORY_VISIBLE_STEP = 20; const CONVERSATION_INITIAL_VISIBLE_COUNT = 20; const CONVERSATION_VISIBLE_STEP = 20; const ACCESS_TOKEN_STORAGE_KEY = 'genarrative.auth.access-token.v1'; +const launcherNotifications: Array<{ + label: string; + detail: string; + actionLabel: string; +}> = []; type LauncherView = 'home' | 'projects' | 'guide' | 'contact' | 'news'; interface InitLocalProjectResult { @@ -2074,22 +2079,17 @@ export function WorkspaceLauncher({
-
- 0 - 1 - : - 1 - 9 - : - 5 - 3 - : - 4 - 6 - 限时优惠,立享5折 - Seedance 2.0 低至 $0.02/秒, Image-2 低至 $0.004/张 - -
+ {launcherNotifications.length > 0 ? ( +
+ {launcherNotifications.map((notification) => ( + + {notification.label} + {notification.detail} + + + ))} +
+ ) : null}
☁ 同时出图放大 +91% diff --git a/apps/ai-game-creator-shell/src/styles.css b/apps/ai-game-creator-shell/src/styles.css index 8cd170084..d4f8ab2f8 100644 --- a/apps/ai-game-creator-shell/src/styles.css +++ b/apps/ai-game-creator-shell/src/styles.css @@ -23,9 +23,7 @@ textarea { display: grid; min-height: 100vh; padding: 24px; - background: - linear-gradient(180deg, #dfff4b 0 32px, transparent 32px), - #f8fafc; + background: #f8fafc; color: #111827; place-items: center; } diff --git a/apps/ai-game-creator-shell/tests/appSurface.test.ts b/apps/ai-game-creator-shell/tests/appSurface.test.ts index 86efb4ff7..558e6029f 100644 --- a/apps/ai-game-creator-shell/tests/appSurface.test.ts +++ b/apps/ai-game-creator-shell/tests/appSurface.test.ts @@ -544,6 +544,7 @@ describe('AI 游戏创作 App 界面边界', () => { renderLauncherProjectsAt('/?launcher'); expect(screen.getByLabelText('项目启动器')).not.toBeNull(); + expect(screen.queryByLabelText('通知')).toBeNull(); expect(screen.queryByLabelText('聊天')).toBeNull(); fireEvent.change(screen.getByLabelText('项目目录'), { target: { value: '/tmp/authorized-game' },