Merge remote-tracking branch 'origin/master' into codex/tiaoyitiao

# Conflicts:
#	server-rs/crates/api-server/src/jump_hop.rs
#	server-rs/crates/api-server/src/modules/jump_hop.rs
This commit is contained in:
2026-06-06 21:04:46 +08:00
451 changed files with 25780 additions and 2687 deletions
@@ -5,6 +5,7 @@ import {
buildJumpHopGenerationAnchorEntries,
buildMatch3DGenerationAnchorEntries,
buildMiniGameDraftGenerationProgress,
buildPuzzleClearGenerationAnchorEntries,
buildPuzzleGenerationAnchorEntries,
buildWoodenFishGenerationAnchorEntries,
createMiniGameDraftGenerationState,
@@ -653,6 +654,56 @@ describe('miniGameDraftGenerationProgress', () => {
]);
});
test('puzzle clear draft generation exposes atlas and slice pipeline', () => {
const state = createMiniGameDraftGenerationState('puzzle-clear');
const progress = buildMiniGameDraftGenerationProgress(
state,
state.startedAtMs + 190_000,
);
expect(progress?.steps.map((step) => step.id)).toEqual([
'puzzle-clear-draft',
'puzzle-clear-background',
'puzzle-clear-atlas',
'puzzle-clear-slices',
'puzzle-clear-write-draft',
]);
expect(progress?.phaseId).toBe('puzzle-clear-atlas');
expect(progress?.phaseLabel).toBe('生成复合图集');
expect(progress?.estimatedRemainingMs).toBe(430_000);
});
test('puzzle clear generation anchors expose title, theme and background mode', () => {
const entries = buildPuzzleClearGenerationAnchorEntries(null, {
templateId: 'puzzle-clear',
workTitle: '星港拼消消',
workDescription: '星港主题连续消除。',
themePrompt: '霓虹星港',
boardBackgroundPrompt: '美少女',
generateBoardBackground: true,
boardBackgroundAsset: null,
});
expect(entries).toEqual([
{
id: 'puzzle-clear-title',
label: '作品',
value: '星港拼消消',
},
{
id: 'puzzle-clear-theme',
label: '主题',
value: '霓虹星港',
},
{
id: 'puzzle-clear-background',
label: '底图',
value: '美少女',
},
]);
});
test('puzzle generation anchors expose form payload as the display source', () => {
const entries = buildPuzzleGenerationAnchorEntries(
{