Preserve newly added prompt shots
tests / test (push) Canceled after 0s
tests / windows-storage (push) Canceled after 0s

This commit is contained in:
2026-10-16 12:53:38 +00:00
parent 3f2cadc993
commit 5abeb7dd24
+3 -3
View File
@@ -229,9 +229,9 @@ function configure(node) {
if (redraw) render();
};
const rebuildPromptAfterStructureChange = (clip) => {
// Adding/removing a shot is the one operation allowed to add/remove
// marker lines. Preserve all existing shot text before formatting.
syncPrompt(clip, clip.prompt || promptFor(clip));
// The caller syncs the current text before changing the slot list.
// Do not parse clip.prompt again here: after adding a shot it still
// has the old marker count, and reparsing would discard the new slot.
clip.prompt = formatPromptFromSlots(clip);
};
const render = () => {