import type { SankeyLayoutLink, SankeyLayoutNode } from '../types/sankey-internal.js'; interface ConnectedShapes { nodes: ReadonlySet; links: ReadonlySet; } /** * A resolved layout selection ready for connected-shape computation. * * - `node`: the clicked layout node (source/target links are already * populated by d3-sankey). * - `link`: the clicked layout link with its endpoint nodes already resolved * to objects by the caller; callers must guard with `isResolvedNode` before * passing here so the function never needs to cast. */ type ResolvedShape = { type: 'node'; node: SankeyLayoutNode; } | { type: 'link'; link: SankeyLayoutLink; source: SankeyLayoutNode; target: SankeyLayoutNode; }; /** * Computes the 1-hop connected set for a resolved layout shape. * * - **Node**: the node, all of its direct source/target links, and the * other-end nodes of those links. Does not traverse further hops. * - **Link**: the link and its two endpoint nodes. * * Handles isolated nodes (no `sourceLinks`/`targetLinks`) without throwing. */ export declare function findConnectedShapes(shape: ResolvedShape): ConnectedShapes; export {}; //# sourceMappingURL=find-connected-shapes.d.ts.map