From 1c88b924d5b00328d31ab5fd397109f17ee2fc17 Mon Sep 17 00:00:00 2001 From: AIGameCreator App Date: Wed, 8 Jul 2026 20:26:19 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B8=85=E7=90=86=E9=A6=96=E9=A1=B5=E8=8F=9C?= =?UTF-8?q?=E5=8D=95=E4=B8=8E=E6=B3=A5=E7=82=B9=E5=BC=B9=E5=B1=82=E7=BB=86?= =?UTF-8?q?=E8=8A=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 移除泥点弹层账户读取状态文案 使用详情改为统一占位通知 修复帮助按钮展开态灰色背景 补充泥点弹层交互断言 --- apps/ai-game-creator-shell/src/App.tsx | 17 +++++++---------- apps/ai-game-creator-shell/src/styles.css | 9 +++++++++ .../tests/appSurface.test.ts | 9 +++++++++ 3 files changed, 25 insertions(+), 10 deletions(-) diff --git a/apps/ai-game-creator-shell/src/App.tsx b/apps/ai-game-creator-shell/src/App.tsx index 57695ad3f..8961828b7 100644 --- a/apps/ai-game-creator-shell/src/App.tsx +++ b/apps/ai-game-creator-shell/src/App.tsx @@ -2159,7 +2159,6 @@ export function WorkspaceLauncher({ useState(null); const [profileDashboard, setProfileDashboard] = useState(null); - const [profileStatus, setProfileStatus] = useState('正在读取账户'); const [walletPanelOpen, setWalletPanelOpen] = useState(false); const [walletLedger, setWalletLedger] = useState( [], @@ -2232,14 +2231,13 @@ export function WorkspaceLauncher({ return; } setProfileDashboard(dashboard); - setProfileStatus('已读取账户'); }) .catch((error) => { if (disposed) { return; } setProfileDashboard(null); - setProfileStatus(error instanceof Error ? error.message : '泥点读取失败'); + setWalletLedgerStatus(error instanceof Error ? error.message : '泥点读取失败'); }); void listClientShowcaseResources() .then((response) => { @@ -2709,6 +2707,7 @@ export function WorkspaceLauncher({ function showLauncherNotice(title: string) { setAccountMenuOpen(false); setHelpMenuOpen(false); + setWalletPanelOpen(false); setLauncherNotice({ title, message: `${title}正在接入中,当前版本会先保留入口。`, @@ -3048,11 +3047,7 @@ export function WorkspaceLauncher({ type="button" aria-label="帮助" title="帮助" - className={ - helpMenuOpen || ['guide', 'contact', 'news'].includes(launcherView) - ? 'launcher-nav-active' - : '' - } + className="launcher-config-button" aria-expanded={helpMenuOpen} onClick={() => { setAccountMenuOpen(false); @@ -3139,7 +3134,6 @@ export function WorkspaceLauncher({ {walletPanelOpen ? (
泥点 - {profileStatus}

{formatMudPoints(profileDashboard?.walletBalance)} 泥点

{walletLedger.length > 0 ? ( @@ -3153,7 +3147,10 @@ export function WorkspaceLauncher({ {walletLedgerStatus} )}
-
diff --git a/apps/ai-game-creator-shell/src/styles.css b/apps/ai-game-creator-shell/src/styles.css index 9fa441569..62d863d61 100644 --- a/apps/ai-game-creator-shell/src/styles.css +++ b/apps/ai-game-creator-shell/src/styles.css @@ -274,6 +274,15 @@ textarea { background: #f3f4f6; } +.launcher-help-nav .launcher-config-button, +.launcher-help-nav .launcher-config-button:hover, +.launcher-help-nav .launcher-config-button:focus, +.launcher-help-nav .launcher-config-button:focus-visible, +.launcher-help-nav .launcher-config-button:active, +.launcher-help-nav .launcher-config-button[aria-expanded='true'] { + background: transparent !important; +} + .launcher-main { position: relative; display: grid; diff --git a/apps/ai-game-creator-shell/tests/appSurface.test.ts b/apps/ai-game-creator-shell/tests/appSurface.test.ts index 190038d21..199488db1 100644 --- a/apps/ai-game-creator-shell/tests/appSurface.test.ts +++ b/apps/ai-game-creator-shell/tests/appSurface.test.ts @@ -801,6 +801,15 @@ describe('AI 游戏创作 App 界面边界', () => { name: '升级', }), ).not.toBeNull(); + fireEvent.click( + within(screen.getByLabelText('账户资产')).getByRole('button', { + name: '泥点余额', + }), + ); + expect(screen.queryByText('已读取账户')).toBeNull(); + fireEvent.click(screen.getByRole('button', { name: '使用详情' })); + expect(screen.getByRole('dialog', { name: '使用详情' })).not.toBeNull(); + fireEvent.click(screen.getByRole('button', { name: '知道了' })); expect( screen.queryByRole('button', { name: 'Agent 聊天' }), ).toBeNull();