@kit-data-manager/react-search-component
Version:
All-in-one component for rendering an elastic search UI for searching anything. Built-in support for visualizing related items in a graph and resolving unique identifiers.
21 lines (20 loc) • 745 B
TypeScript
import { GraphNode } from "../../components/graph/GraphNode";
/**
* Utilities for working with the RelationsGraph
*/
export declare abstract class GraphNodeUtils {
/**
* Build a sequential graph (n:n:n:...) by passing just the identifiers of the nodes in layers.
* @param type Type of the nodes (use "result" to display your resultView)
* @param ids Each entry resembled one layer in the sequential graph
* @example
* buildSequentialGraphFromIds("result", "a", ["b", "c", "d"], "e")
* // result:
* // b
* // / \
* // a - c - e
* // \ /
* // d
*/
static buildSequentialGraphFromIds(type: string, ...ids: (string | string[])[]): GraphNode[];
}