export interface LayeredLayoutNode{id:string; /** Finite, non-negative box width. */ width:number; /** Finite, non-negative box height. */ height:number;}export interface LayeredLayoutEdge{source:string;target:string;}export interface LayeredLayoutOptions{ /** * Finite, non-negative box-center coordinates kept verbatim and excluded from computed * assignment. Their combined inline extent is reserved before computed boxes, and each fixed * layer's block extent advances later layers. Conflicts between two caller-fixed boxes are kept * verbatim and remain the caller's responsibility. */ fixedPositions?:ReadonlyMap>; /** Finite, non-negative in-layer gap between adjacent box edges (not centers). Default 24. */ gapX?:number; /** Finite, non-negative gap between layers (block axis). Default 100. */ gapY?:number; /** Maximum synthetic ordering waypoints. Invalid values use the 10,000 default; negative * values clamp to zero and fractional values truncate. */ maxVirtualWaypoints?:number;} /** The bounded output of `layeredLayout()`. */ export interface LayeredLayoutResult{ /** Raw box-center coordinates for every real input node. */ readonly positions:ReadonlyMap>; /** Whether one or more long-edge waypoint chains were omitted because the budget was exhausted. */ readonly truncated:boolean; /** Number of synthetic ordering waypoints actually allocated. */ readonly virtualWaypointCount:number;} /** * A deterministic Sugiyama-lite layered ("DAG-ish") layout, dependency-free: (1) iterative * depth-first cycle handling (back edges reversed internally for layering only; the caller's own * edge array is never mutated); (2) longest-path layering; (3) four barycenter sweeps for crossing * reduction, * routing any edge spanning more than one layer through synthetic virtual waypoints that * participate in ordering only and are never returned. Virtual routing is capped globally; once * the cap is exhausted, a long edge participates through its real endpoints rather than allocating * every intermediate waypoint. The returned resource metadata makes that degradation explicit. * (4) Computed coordinates are assigned top -> bottom (block axis, RTL-neutral), left -> right * within a layer by stable input order on ties. Fixed anchors are excluded from that computed * ordering and may appear anywhere in the caller's coordinate space. * `fixedPositions` entries keep their given coordinates verbatim. Computed boxes begin after the * combined fixed inline extent, and a fixed layer's block extent advances every later layer, so a * fixed box cannot collide with a computed one. Two conflicting caller-fixed boxes are not moved. * The caller is responsible for centering the returned drawing within its own canvas -- this * function returns raw box centers with layer 0 starting at y=0. * * Node dimensions, gaps, and fixed coordinates must be finite, non-negative values no greater * than `Number.MAX_SAFE_INTEGER`; invalid geometry throws before graph traversal begins. The * waypoint budget is normalized as described by `LayeredLayoutOptions.maxVirtualWaypoints`. * * A single, shared, dependency-free implementation -- suitable for any future layered-diagram * consumer beyond ``'s own `layout="layered"` mode, not just this component. * * @throws {RangeError} When node geometry, gaps, fixed coordinates, or their required extents are * outside the supported numeric range. */ export declare function layeredLayout(input:{nodes:readonly LayeredLayoutNode[];edges:readonly LayeredLayoutEdge[];options?:LayeredLayoutOptions;}):LayeredLayoutResult;