feat: add variadic render graph logic nodes
Amp-Thread-ID: https://ampcode.com/threads/T-019f9d91-77c1-7206-a60f-ed6554ce92ab Co-authored-by: Heaust Azure <heaust.azure@gmail.com>
This commit is contained in:
+3
-1
@@ -138,7 +138,9 @@ export function hitTest(layout: LayoutSnapshot, view: Vec2, preferredDirection?:
|
||||
.filter(
|
||||
(socket) =>
|
||||
(!topNode || socket.nodeId === topNode.id) &&
|
||||
Math.hypot(world.x - socket.anchor.x, world.y - socket.anchor.y) <= tolerance,
|
||||
(socket.shape === "multi-input" && socket.bounds
|
||||
? inRect(world, socket.bounds, tolerance)
|
||||
: Math.hypot(world.x - socket.anchor.x, world.y - socket.anchor.y) <= tolerance),
|
||||
)
|
||||
.sort((a, b) => {
|
||||
const an = layout.nodes.get(a.nodeId),
|
||||
|
||||
Reference in New Issue
Block a user