import type { Edge, Node } from '@xyflow/react';
export type LayoutDirection = 'TB' | 'LR' | 'BT' | 'RL';
export interface LayoutOptions {
    /** Graph direction: top-bottom, left-right, etc. Default "TB" */
    direction?: LayoutDirection;
    /** Default node size when per-node size is unavailable */
    nodeSize?: {
        width: number;
        height: number;
    };
    /** Vertical separation between ranks (default 80) */
    ranksep?: number;
    /** Horizontal separation between nodes in the same rank (default 30) */
    nodesep?: number;
}
/**
 * Canonical layout defaults for the control-center canvas.
 *
 * `nodesep` is the gap between nodes in the SAME rank (vertical
 * gap in the LR layout we use). Bumped from 30 → 48 so the taller
 * application cards (~300px) get obvious breathing room when
 * stacked — 30px looked cramped enough that cards felt touching.
 */
export declare const CANVAS_LAYOUT_DEFAULTS: LayoutOptions;
/** Returns canvas layout defaults with direction adjusted for text direction. */
export declare function getCanvasLayoutDefaults(dir?: 'ltr' | 'rtl'): LayoutOptions;
/**
 * Compute an automatic hierarchical layout for React Flow nodes and edges
 * using Dagre. Returns new node/edge arrays — never mutates the originals.
 *
 * Disconnected nodes (no edges) are interleaved with connected root trees
 * in their original input order, preserving the caller's sort (e.g. createdAt).
 */
export declare function layoutWithDagre<N extends Node>(nodes: N[], edges: Edge[], opts?: LayoutOptions): {
    nodes: N[];
    edges: Edge[];
};
//# sourceMappingURL=layout-with-dagre.d.ts.map