From 17c2ad5f0f2408c2ffda29efb056986ede6a523c Mon Sep 17 00:00:00 2001 From: Chris Dumas Date: Thu, 15 Oct 2026 08:42:44 +0000 Subject: [PATCH] Preserve prompt edits during timeline drag --- web/sequence_prompt_builder.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/web/sequence_prompt_builder.js b/web/sequence_prompt_builder.js index 92e6a07..ddc80c9 100644 --- a/web/sequence_prompt_builder.js +++ b/web/sequence_prompt_builder.js @@ -127,7 +127,12 @@ function configure(node) { slot.end = point; next.start = point; updateTimeline(); }; handle.onpointerdown = (event) => { - event.preventDefault(); handle.setPointerCapture?.(event.pointerId); + event.preventDefault(); + // Textarea edits are intentionally committed on change, but a + // drag can happen while it still has focus. Capture them before + // the timeline redraws the prompt from state. + if (prompt) syncPrompt(clip, prompt.value); + handle.setPointerCapture?.(event.pointerId); handle.onpointermove = move; handle.onpointerup = () => { handle.onpointermove = null; setState(); render(); }; };