This commit is contained in:
2026-03-28 00:59:59 -03:00
parent f6ef95ebea
commit 8a90436f33
7 changed files with 260 additions and 195 deletions

View File

@@ -66,11 +66,13 @@ export function useCheckpointLoader(
currentFrameRef.value = frame.seq
}
const { checkpointStageFor } = useStageRegistry()
const { stages, checkpointStageFor } = useStageRegistry()
// Auto-load checkpoint when entering editor mode
// Auto-load checkpoint when entering editor mode.
// Also watches stages — the registry fetch is async, so on first load
// stages may be empty. When they arrive, re-evaluate.
watch(
() => [pipeline.layoutMode, pipeline.editorStage, jobId.value] as const,
() => [pipeline.layoutMode, pipeline.editorStage, jobId.value, stages.value.length] as const,
([mode, stage, job]) => {
if (mode === 'bbox_editor' && stage && job) {
const cpStage = checkpointStageFor(stage)