tsiclient
Version:
<a href="https://tsiclientsample.azurewebsites.net"><img src="https://insights.timeseries.azure.com/favicons/android-chrome-192x192.png" align="left" hspace="10" vspace="6" height="100px"></a>
35 lines (34 loc) • 1.22 kB
TypeScript
import { Component } from "./Component-8ea21f2e";
declare class HierarchyNode {
name: string;
markedName: string;
children: Array<HierarchyNode>;
parent: HierarchyNode;
isExpanded: boolean;
isSelected: boolean;
isLeaf: boolean;
childrenInFilter: boolean;
selfInFilter: boolean;
color: (n: HierarchyNode) => string;
click: (n: any) => void;
isLeafParent: boolean; // used in the event of context menut to denote that we should use a context menu for children
level: number;
constructor(name: string, level: number);
filter(filterText: any): void;
traverse(condition: (n: HierarchyNode) => boolean): any[];
colorify(el: any): void;
}
declare class Hierarchy extends Component {
private filterText;
private root;
private withContextMenu;
private contextMenu;
private clickedNode;
private hierarchyList;
constructor(renderTarget: Element);
render(data: any, options: any): void;
expandCollapseList: (node: HierarchyNode, el: any, isFromClick?: boolean) => void;
buildTree(data: any): HierarchyNode;
private closeContextMenu;
}
export { Hierarchy as default, HierarchyNode };