This commit is contained in:
2026-04-16 15:45:00 +08:00
parent 6363267bca
commit 91b63675eb
43 changed files with 5652 additions and 853 deletions

View File

@@ -87,11 +87,7 @@ function buildAgentDraftFoundationSteps(
detail: step.detail,
completed: isCompleted ? 1 : 0,
total: 1,
status: isCompleted
? 'completed'
: isActive
? 'active'
: 'pending',
status: isCompleted ? 'completed' : isActive ? 'active' : 'pending',
} satisfies CustomWorldGenerationStep;
});
}
@@ -113,10 +109,7 @@ function resolveEstimatedRemainingMs(
const elapsedMs = Math.max(0, nowMs - startedAtMs);
const progressFraction = progress / 100;
return Math.max(
0,
Math.round(elapsedMs / progressFraction - elapsedMs),
);
return Math.max(0, Math.round(elapsedMs / progressFraction - elapsedMs));
}
export function isDraftFoundationOperation(
@@ -184,19 +177,19 @@ export function buildAgentDraftFoundationSettingText(
);
if (creatorIntent) {
const displayText =
buildCustomWorldCreatorIntentDisplayText(creatorIntent).trim();
const generationText =
buildCustomWorldCreatorIntentGenerationText(creatorIntent).trim();
if (displayText) {
return displayText;
}
const displayText =
buildCustomWorldCreatorIntentDisplayText(creatorIntent).trim();
if (generationText) {
return generationText;
}
if (displayText) {
return displayText;
}
if (creatorIntent.rawSettingText.trim()) {
return creatorIntent.rawSettingText.trim();
}