import type { DefaultTheme } from '@darajs/styled-components';
import type { GraphTiers, NodeCategory, SimulationGraph } from '../types';
export declare const DEFAULT_NODE_SIZE = 64;
export declare const TARGET_NODE_MULTIPLIER = 1.25;
/**
 * Check if adding an edge to the graph will create a cycle.
 *
 * @param graph current graph state instance
 * @param edge edge to add
 */
export declare function willCreateCycle(graphOriginal: SimulationGraph, edge: [string, string]): boolean;
/**
 * Format a given name, i.e. a snake_case label to 'Sentence case'
 *
 * @param name name to format
 */
export declare function formatName(name: string): string;
export declare function coerceToArray<T>(value: T | T[]): T[];
/**
 * A function that generates a tooltip to be displayed for nodes and edges
 *
 * @param id - the id of the Node or Edge to display on top
 * @param data - the key values pairs of data to be displayed
 * @param label - a label to show instead of the id and preserve the id for the key
 * @param tooltipSize - font size to use for the tooltip
 */
export declare function getTooltipContent(id: string, data: {
    [k: string]: any;
} | string, theme: DefaultTheme, label?: string, tooltipSize?: number): JSX.Element;
/**
 * Get node category
 *
 * @param graph current graph state instance
 * @param id node id
 * @param isLatent whether the node is latent
 */
export declare function getNodeCategory(graph: SimulationGraph, id: string, isLatent?: boolean): NodeCategory;
/**
 * Defines if a Graph is a DAG (directed acyclic graph). Two criteria must be met for this, the first it must not have cyclews and the second is that all edges must be directed.
 *
 * @param graph current graph state instance
 */
export declare function isDag(graph: SimulationGraph): boolean;
/**
 * Based on a node attribute checks if the path is in the attribute or in extras, if not found returns undefined
 * @param attributes node object or a sub attribute of the node object
 * @param path path to the attribute
 *  */
export declare function getPathInNodeAttribute(attributes: Record<string, any>, path: string): any;
/**
 * Gets nodes grouped by a given attribute
 * @param nodes nodes to be grouped
 * @param group the attribute to group by
 * @param graph the graph
 * @returns a record of group name to an array of nodes
 *  */
export declare function getGroupToNodesMap(nodes: string[], group: string, graph: SimulationGraph): Record<string, string[]>;
/**
 * Gets the group for each node based on a given attribute
 * @param nodes nodes to be checked
 * @param group the attribute to check
 * @param graph the graph
 * @returns a map of node to group
 */
export declare function getNodeToGroupMap(nodes: string[], group: string, graph: SimulationGraph): Record<string, string>;
/**
 * Gets nodes grouped by a given attribute
 * @param nodes nodes to be grouped
 * @param group the attribute to group by
 * @param graph the graph
 *  */
export declare function getNodeOrder(nodes: string[], orderPath: string, graph: SimulationGraph): Record<string, string>;
/**
 * Gets an array of array of nodes where if rank is defined in the coorect hierarchical order
 * @param tiers the GraphTiers information passed to the layout
 * @param graph the graph
 *  */
export declare function getTiersArray(tiers: GraphTiers, graph: SimulationGraph): string[][];
//# sourceMappingURL=utils.d.ts.map