#6008·xyflow

Unexpected connection line formation on dragging over a dialog/modal

Author: 9137318058PCreated Sep 10, 2026Updated Sep 10, 2026

What platform were you using when you found the bug?

  • React Flow version: 12.11.6
  • Browser and version: Chrome v153.0.8010.37 (Official Build) (64-bit)
  • OS and version: Windows 11 64 bit

Live code example

https://stackblitz.com/~/github.com/sibananda485/reactflow-connection-line-issue

Describe the Bug

When someone tries to drag on a dialog it unexpectedly closes the dialog and creates a connection line from that handle inside where the dialog trigger was rendered.

Steps to reproduce the bug or issue

  1. Render a shadcn dialog inside ButtonHandle (Or Handle) component.
  2. Click on the dialog trigger button.
  3. Let the dialog open.
  4. Drag on the dialog or overlay.
  5. See the dialog closes unexpectedly and creates a new connection line.

Expected behavior

As a user, I expected to have a usual interaction with dialog to fill the form and proceed. Instead, it is allowing me to create a connection from the dialog itself

Screenshots or Videos

https://github.com/user-attachments/assets/1f277eba-35c4-4a36-989e-e49ac07a3b61

Additional context

No response