Remove the 8-extension queue cap.
You can chain as many extension segments as you want from generate or a restored draft.
This commit is contained in:
+2
-4
@@ -95,7 +95,7 @@
|
|||||||
<button
|
<button
|
||||||
type="button"
|
type="button"
|
||||||
class="w-full rounded-2xl border border-dashed border-white/15 px-4 py-2.5 text-sm text-zinc-300 transition hover:border-amber-300/40 hover:text-amber-100 disabled:cursor-not-allowed disabled:opacity-50"
|
class="w-full rounded-2xl border border-dashed border-white/15 px-4 py-2.5 text-sm text-zinc-300 transition hover:border-amber-300/40 hover:text-amber-100 disabled:cursor-not-allowed disabled:opacity-50"
|
||||||
:disabled="busy || extensionQueue.length >= MAX_EXTENSIONS"
|
:disabled="busy"
|
||||||
@click="queueExtension"
|
@click="queueExtension"
|
||||||
>
|
>
|
||||||
+ Queue Extension
|
+ Queue Extension
|
||||||
@@ -663,7 +663,6 @@ const file = ref<File | null>(null)
|
|||||||
const preview = ref('')
|
const preview = ref('')
|
||||||
const dragging = ref(false)
|
const dragging = ref(false)
|
||||||
const prompt = ref('')
|
const prompt = ref('')
|
||||||
const MAX_EXTENSIONS = 8
|
|
||||||
const extensionQueue = ref<QueuedExtension[]>([])
|
const extensionQueue = ref<QueuedExtension[]>([])
|
||||||
const clipName = ref('')
|
const clipName = ref('')
|
||||||
const outputDownloadName = ref('aigen')
|
const outputDownloadName = ref('aigen')
|
||||||
@@ -1170,7 +1169,7 @@ async function loadDraft(draft: RetryDraft) {
|
|||||||
withSound.value = draft.sound !== false
|
withSound.value = draft.sound !== false
|
||||||
if (draft.hideInput && showPrivacyToggles.value) hideInputPreview.value = true
|
if (draft.hideInput && showPrivacyToggles.value) hideInputPreview.value = true
|
||||||
duration.value = clampDuration(Number(draft.duration))
|
duration.value = clampDuration(Number(draft.duration))
|
||||||
extensionQueue.value = (draft.extensions || []).slice(0, MAX_EXTENSIONS).map(item => ({
|
extensionQueue.value = (draft.extensions || []).map(item => ({
|
||||||
id: crypto.randomUUID(),
|
id: crypto.randomUUID(),
|
||||||
prompt: String(item.prompt || ''),
|
prompt: String(item.prompt || ''),
|
||||||
duration: clampDuration(Number(item.duration))
|
duration: clampDuration(Number(item.duration))
|
||||||
@@ -1435,7 +1434,6 @@ function revealAndPlay() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function queueExtension() {
|
function queueExtension() {
|
||||||
if (extensionQueue.value.length >= MAX_EXTENSIONS) return
|
|
||||||
extensionQueue.value.push({
|
extensionQueue.value.push({
|
||||||
id: crypto.randomUUID(),
|
id: crypto.randomUUID(),
|
||||||
prompt: prompt.value.trim(),
|
prompt: prompt.value.trim(),
|
||||||
|
|||||||
@@ -24,7 +24,6 @@ function parseExtensions(raw: string | undefined) {
|
|||||||
const parsed = JSON.parse(raw)
|
const parsed = JSON.parse(raw)
|
||||||
if (!Array.isArray(parsed)) return []
|
if (!Array.isArray(parsed)) return []
|
||||||
return parsed
|
return parsed
|
||||||
.slice(0, 8)
|
|
||||||
.map((item: { prompt?: unknown; duration?: unknown }) => ({
|
.map((item: { prompt?: unknown; duration?: unknown }) => ({
|
||||||
prompt: String(item?.prompt || '').trim(),
|
prompt: String(item?.prompt || '').trim(),
|
||||||
duration: parseExtendDuration(item?.duration)
|
duration: parseExtendDuration(item?.duration)
|
||||||
|
|||||||
Reference in New Issue
Block a user