import * as React from 'react'; import {ConditionFunc} from './Node'; import {IconName} from '@unidata/icon'; type NodeKey = string; export interface ITreeNode { key: NodeKey; // member key expanded: boolean; // the flag is folded/deployed parent?: ITreeNode; // the parent node children: Array> | null; // descendants row: T; // data to display path?: string; // path to the element todo Brauer Ilya as keys array from root type?: string; // todo Brauer Ilya what it is? icon?: IconName; root?: boolean; // is the node the parent node iconCls?: string; disabled?: boolean; // flag for displaying the node as " disabled" selected?: boolean; // flag for displaying the node as " selected" isEdited?: boolean | ConditionFunc; // flag to show that cell is edited now //todo Brauer Ilya: for what? readOnly?: boolean; isLastInLevel?: boolean; // is node last in level } export interface ITreeColumn { name: string; displayName: string; renderer?: (node: ITreeNode) => React.ReactNode; } export interface IFlatListItem { nodeId: string; path?: string; name: string; parentId: string | null; model: T; }