Keep the Extend panel put and name sibling clips as branches.

A finished job no longer closes a draft or jumps the page, and a second extend from the same part saves as p8b instead of another p8.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Towsty
2026-09-02 15:16:30 -05:00
co-authored by Cursor
parent 4546aa5f61
commit 1be9bcb23f
9 changed files with 274 additions and 119 deletions
+3 -2
View File
@@ -12,7 +12,7 @@ import {
clipVideoPath,
extendTempDir,
getClip,
nextClipPartName,
nextFamilyPartName,
removeExtendTemp
} from '~/server/utils/library'
import { extractLastFrame, probeHasAudio } from '~/server/utils/ffmpeg'
@@ -63,6 +63,7 @@ export async function beginExtendFromClip(params: {
duration?: number
loraStack?: unknown
folderLocked?: boolean
name?: string
}) {
const source = getClip(params.ownerKey, params.clipId)
const sourcePath = clipVideoPath(params.ownerKey, source.id)
@@ -104,7 +105,7 @@ export async function beginExtendFromClip(params: {
const length = frameLength(durationSeconds, fps)
const width = source.width || 1344
const height = source.height || 768
const clipName = nextClipPartName(clipTitle(source))
const clipName = String(params.name || '').trim() || nextFamilyPartName(params.ownerKey, source)
const job = createJob()
job.kind = 'video'