Join pre/prompt/post for Comfy, stop zero-size generates snapping to a small square, and give the phone library a real closeable preview.
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -8,7 +8,7 @@ import { imageDimensions } from '~/server/utils/resolution'
|
||||
import { emitChainJob } from '~/server/utils/watch'
|
||||
import { saveStill, stillChainName } from '~/server/utils/library'
|
||||
import { comfyJobPrefix } from '~/utils/outputNames'
|
||||
import { composePromptParts } from '~/utils/promptParts'
|
||||
import { joinPromptParts } from '~/utils/promptParts'
|
||||
import { parseImageV2Engine, type ImageV2Engine, type ImageV2Mode, type ImageV2Task } from '~/utils/imageV2'
|
||||
import type { EditImageFile } from '~/server/utils/imageChain'
|
||||
|
||||
@@ -195,7 +195,7 @@ export async function runEditV2(job: Job, params: EditV2RunParams) {
|
||||
mode: params.mode,
|
||||
engine,
|
||||
task: params.task,
|
||||
prompt: composePromptParts(library.promptPre || '', prompt, library.promptPost || ''),
|
||||
prompt: joinPromptParts(library.promptPre, prompt, library.promptPost),
|
||||
negative: params.negative,
|
||||
imageAName: uploaded?.name,
|
||||
imageBName: uploadedRef?.name,
|
||||
@@ -211,13 +211,14 @@ export async function runEditV2(job: Job, params: EditV2RunParams) {
|
||||
megapixels: params.megapixels,
|
||||
width: params.width,
|
||||
height: params.height,
|
||||
aspect: params.aspect,
|
||||
turbo: params.turbo === true,
|
||||
filenamePrefix: chainTotal > 1 ? `${comfyJobPrefix(job.id)}_p${index + 1}` : comfyJobPrefix(job.id),
|
||||
kreaUnetName: krea?.unet,
|
||||
kreaClipName: krea?.clip,
|
||||
kreaVaeName: krea?.vae,
|
||||
kreaConceptLora: krea?.conceptLora,
|
||||
loraStack: params.loraStack
|
||||
loraStack: params.loraStack?.length ? params.loraStack : (library.loraStack || undefined)
|
||||
})
|
||||
const queued = await queuePrompt(built.graph, job.clientId)
|
||||
job.promptId = queued.prompt_id
|
||||
|
||||
Reference in New Issue
Block a user