Coral 0.2.17 candidate API
    Preparing search index...

    Function incrementalLayout

    • Perform incremental layout with pinned positions for existing nodes.

      Strategy: Run ELK on all nodes but restore pinned positions afterwards. This ensures edge routing works correctly while preserving user positions.

      If all nodes need layout (no pins), this performs a full ELK layout. If no nodes need layout (all pinned), this returns the pinned positions unchanged.

      Parameters

      • nodes: LayoutNodeInfo[]

        All nodes to layout (with dimensions)

      • edges: LayoutEdgeInfo[]

        All edges in the graph

      • pinnedPositions: Map<string, Position>

        Positions to preserve (node IDs to positions)

      • needsLayout: string[]

        Node IDs that need ELK positioning

      • Optionaloptions: {
            algorithm?: string;
            direction?: "UP" | "DOWN" | "LEFT" | "RIGHT";
            spacing?: number;
        }

        Optional layout options (direction, algorithm, etc.)

      • Optionalsignal: AbortSignal

      Returns Promise<Map<string, Position>>

      Map of node IDs to computed positions