#.valid class not applied onto handle

1 messages · Page 1 of 1 (latest)

austere moss
#

The valid class is only applied during the connection(when the mouse is down and the connection is successful). Once I release my mouse and the edge is created, the class goes away. Do you want the valid class applied during the connection or after its successful?

Also if you want the former and its not happening, can you check if removing the Custom Handle and replacing it with the default Handle component fixes the issue?

austere moss
# copper wadi After its successful

After you leave the mouse and the connection ends/edge has been made, if you want to detect if a handle has connection, you can do that via the useNodeConnections hook. If this hooks return an array with any items inside it, then this handle has connections.

Svelte Flow

This hook returns an array of connected edges. Components that use this hook will re-render whenever any edge changes.

copper wadi
austere moss