@kgdata/forcegraph
Version:
forcegraph
8 lines (7 loc) • 569 B
TypeScript
import type { MutableRefObject } from 'react';
export declare type BasicTarget<T = HTMLElement> = (() => T | null) | T | null | MutableRefObject<T | null | undefined>;
export declare type TargetElement = HTMLElement | Element;
export declare type Target = BasicTarget<HTMLElement>;
export declare function getTargetElement(target?: BasicTarget<TargetElement>, defaultElement?: TargetElement): TargetElement | undefined | null;
export declare const computeHeight: (node: TargetElement) => number;
export declare const getAutoHeight: (n: TargetElement) => number;