Stop library Open/click from switching Video and Image tabs.
Previewing a still or clip only updates the output pane; Use as input stays on the current workspace instead of forcing Image for image stills. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
+11
-7
@@ -6297,7 +6297,7 @@ async function generateExtension() {
|
||||
}
|
||||
|
||||
function openClip(item: LibraryClip) {
|
||||
studioMode.value = 'video'
|
||||
// Preview only — never yank Video/Image workspace tabs.
|
||||
outputFocus.value = 'video'
|
||||
watchingLibrary.value = true
|
||||
ensureFamilyExpanded(item)
|
||||
@@ -6316,7 +6316,7 @@ function openClip(item: LibraryClip) {
|
||||
}
|
||||
|
||||
function openStill(still: LibraryStill) {
|
||||
studioMode.value = inferStillPipeline(still) === 'imagev2' ? 'editv2' : 'edit'
|
||||
// Preview only — never yank Video/Image workspace tabs.
|
||||
outputFocus.value = 'edit'
|
||||
browseFolderId.value = still.folderId
|
||||
editResultUrl.value = `/api/library/stills/${still.id}`
|
||||
@@ -6336,13 +6336,14 @@ function applyStillSettings(still: LibraryStill) {
|
||||
folderId.value = still.folderId
|
||||
browseFolderId.value = still.folderId
|
||||
rememberInputSeed(settings?.seed)
|
||||
applyPromptRestore(still.prompt || '', still)
|
||||
// Non-image stills are video start frames — keep Video mode and only restore prompt parts.
|
||||
if (!dest) {
|
||||
studioMode.value = 'video'
|
||||
outputFocus.value = 'video'
|
||||
// Stay on the current Video/Image tab. On Video, only restore prompt for
|
||||
// video-origin stills; image stills are start-frame pixels only.
|
||||
if (!imageStudio.value) {
|
||||
if (!dest) applyPromptRestore(still.prompt || '', still)
|
||||
return
|
||||
}
|
||||
applyPromptRestore(still.prompt || '', still)
|
||||
if (!dest) return
|
||||
if (dest === 'imagev2') {
|
||||
studioMode.value = 'editv2'
|
||||
outputFocus.value = 'edit'
|
||||
@@ -6403,6 +6404,9 @@ async function loadStillAsEditRef(stillId: string) {
|
||||
}
|
||||
|
||||
function stillUseAsInputMessage(still: LibraryStill) {
|
||||
if (!imageStudio.value) {
|
||||
return 'Loaded as start still. Stays on Video — switch to Image only if you want to edit it there.'
|
||||
}
|
||||
const dest = inferStillPipeline(still)
|
||||
const mode = still.settings?.mode
|
||||
if (dest === 'imagev2' && mode === 'generate') return 'Generate settings loaded. Tweak and generate.'
|
||||
|
||||
Reference in New Issue
Block a user