This commit is contained in:
2026-05-01 02:09:07 +08:00
parent 2a2bb42995
commit 250a55e92f
5 changed files with 43 additions and 15 deletions

View File

@@ -106,12 +106,17 @@ test('creation hub reflects updated draft title summary and counts after rerende
expect(screen.queryByText('地点 4')).toBeNull();
const rpgButton = screen.getByRole('button', { name: //u });
const puzzleButton = screen.getByRole('button', { name: /.*/u });
const match3dButton = screen.getByRole('button', { name: //u });
expect(
puzzleButton.compareDocumentPosition(rpgButton) &
Node.DOCUMENT_POSITION_FOLLOWING,
).toBeTruthy();
expect((rpgButton as HTMLButtonElement).disabled).toBe(true);
expect(within(rpgButton).getAllByText('敬请期待').length).toBeGreaterThan(0);
expect((match3dButton as HTMLButtonElement).disabled).toBe(true);
expect(
within(match3dButton).getAllByText('敬请期待').length,
).toBeGreaterThan(0);
expect(puzzleButton).toBeTruthy();
expect(screen.queryByRole('button', { name: //u })).toBeNull();

View File

@@ -1645,7 +1645,12 @@ export function PlatformEntryFlowShellImpl({
const handleCreationHubCreateType = useCallback(
(type: PlatformCreationTypeId) => {
if (type === 'rpg' || type === 'airp' || type === 'visual-novel') {
if (
type === 'rpg' ||
type === 'match3d' ||
type === 'airp' ||
type === 'visual-novel'
) {
return;
}
@@ -1660,13 +1665,6 @@ export function PlatformEntryFlowShellImpl({
return;
}
if (type === 'match3d') {
runProtectedAction(() => {
void openMatch3DAgentWorkspace();
});
return;
}
if (type === 'puzzle') {
runProtectedAction(() => {
void openPuzzleAgentWorkspace();
@@ -1675,7 +1673,6 @@ export function PlatformEntryFlowShellImpl({
},
[
openBigFishAgentWorkspace,
openMatch3DAgentWorkspace,
openPuzzleAgentWorkspace,
prepareCreationLaunch,
runProtectedAction,
@@ -4560,9 +4557,7 @@ export function PlatformEntryFlowShellImpl({
});
}}
onSelectMatch3D={() => {
runProtectedAction(() => {
void openMatch3DAgentWorkspace();
});
// 抓大鹅创作入口当前为敬请期待;保留回调防御,避免旧入口绕过锁定态。
}}
onSelectPuzzle={() => {
runProtectedAction(() => {

View File

@@ -68,9 +68,9 @@ export const PLATFORM_CREATION_TYPES: PlatformCreationTypeCard[] = [
{
id: 'match3d',
title: '抓大鹅',
subtitle: '经典消除玩法',
badge: '可创建',
locked: false,
subtitle: '敬请期待',
badge: '敬请期待',
locked: true,
},
{
id: 'airp',