import * as cola from 'webcola';
import type { Rect, Vector } from './geometry';
import type { LayoutGraph, LayoutState } from './layout';
/**
 * @category Geometry
 */
export declare function evaluateColaLayout(graph: LayoutGraph, state: LayoutState, evaluateLayout: (nodes: Map<string, cola.Node>, links: cola.Link<number | cola.Node>[]) => void): LayoutState;
export interface ColaForceLayoutOptions {
    /** @default 200 */
    preferredLinkLength: number;
    /** @default true */
    avoidOverlaps?: boolean;
}
/**
 * @category Geometry
 */
export declare function colaForceLayout(graph: LayoutGraph, state: LayoutState, options?: ColaForceLayoutOptions): LayoutState;
export interface ColaFlowLayoutOptions {
    /** @default "y" */
    axis: 'x' | 'y';
    /** @default 200 */
    minSeparation?: number;
    /** @default 50 */
    preferredLinkLength?: number;
    /** @default true */
    avoidOverlaps?: boolean;
}
/**
 * @category Geometry
 */
export declare function colaFlowLayout(graph: LayoutGraph, state: LayoutState, options?: ColaFlowLayoutOptions): LayoutState;
/**
 * @category Geometry
 */
export declare function colaRemoveOverlaps(state: LayoutState): LayoutState;
export interface PaddedLayoutState {
    readonly state: LayoutState;
    readonly unwrap: (transformed: LayoutState) => LayoutState;
}
/**
 * @category Geometry
 */
export declare function layoutPadded(state: LayoutState, padding: Vector | undefined): PaddedLayoutState;
export interface PaddedBiasFreeLayoutState {
    readonly state: LayoutState;
    readonly unwrap: (transformed: LayoutState) => LayoutState;
}
/**
 * @category Geometry
 */
export declare function layoutPaddedBiasFree(state: LayoutState, padding: Vector | undefined): PaddedBiasFreeLayoutState;
/**
 * Options for {@link blockingDefaultLayout} function.
 *
 * @see {@link blockingDefaultLayout}
 */
export interface DefaultLayoutOptions {
    /**
     * Preferred length of the graph links in the result layout.
     *
     * @default 200
     */
    preferredLinkLength?: number;
    /**
     * Padding for each graph node to make them more spaced apart
     * when computing the layout.
     *
     * @default {x: 50, y: 50}
     */
    padding?: Vector;
}
/**
 * Default (fallback) diagram layout function.
 *
 * The algorithm used is force-directed layout from [cola.js](https://ialab.it.monash.edu/webcola/).
 *
 * This function is computationally expensive and should be used only as fallback
 * when other ways to compute diagram layout is not available.
 * The recommended way is to use web workers via `@reactodia/workspace/layout.worker`
 * and {@link useWorker Reactodia.useWorker()}`.
 *
 * @category Geometry
 */
export declare function blockingDefaultLayout(graph: LayoutGraph, state: LayoutState, options?: DefaultLayoutOptions): Promise<LayoutState>;
/**
 * Computes complete bounding box for the element bounds in the provided layout state.
 *
 * @category Geometry
 */
export declare function getContentFittingBoxForLayout(state: LayoutState): Rect;
//# sourceMappingURL=layoutShared.d.ts.map