From 555a0d99109f59b5fe9c1c9882ece9d918b4329a Mon Sep 17 00:00:00 2001 From: Victor Giers Date: Wed, 1 Apr 2026 04:20:15 +0200 Subject: [PATCH] Update App.tsx to re-sync trigger volume flags after deleting an interaction link --- src/app/App.tsx | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/app/App.tsx b/src/app/App.tsx index 3e386d8b..1f772277 100644 --- a/src/app/App.tsx +++ b/src/app/App.tsx @@ -1639,8 +1639,17 @@ export function App({ store, initialStatusMessage }: AppProps) { const handleDeleteInteractionLink = (linkId: string) => { try { + const link = editorState.document.interactionLinks[linkId]; store.executeCommand(createDeleteInteractionLinkCommand(linkId)); setStatusMessage("Deleted interaction link."); + // Re-sync trigger volume flags after deletion + if (link !== undefined) { + const remainingLinks = getInteractionLinksForSource( + editorState.document.interactionLinks, + link.sourceEntityId + ).filter((l) => l.id !== linkId); + syncTriggerVolumeFlags(link.sourceEntityId, remainingLinks); + } } catch (error) { setStatusMessage(getErrorMessage(error)); }