1 | import { NodeMenuItem } from './menu/node-menu.component';
|
2 | export declare class FoldingType {
|
3 | private _cssClass;
|
4 | static Expanded: FoldingType;
|
5 | static Collapsed: FoldingType;
|
6 | static Empty: FoldingType;
|
7 | static Leaf: FoldingType;
|
8 | constructor(_cssClass: string);
|
9 | get cssClass(): string;
|
10 | }
|
11 | export type ChildrenLoadingFunction = (callback: (children: TreeModel[]) => void) => void;
|
12 | export interface TreeModel {
|
13 | value: string | RenamableNode;
|
14 | id?: string | number;
|
15 | children?: TreeModel[];
|
16 | loadChildren?: ChildrenLoadingFunction;
|
17 | settings?: TreeModelSettings;
|
18 | emitLoadNextLevel?: boolean;
|
19 | _status?: TreeStatus;
|
20 | _foldingType?: FoldingType;
|
21 | [additionalData: string]: any;
|
22 | }
|
23 | export interface CssClasses {
|
24 | expanded?: string;
|
25 | collapsed?: string;
|
26 | empty?: string;
|
27 | leaf?: string;
|
28 | }
|
29 | export interface Templates {
|
30 | node?: string;
|
31 | leaf?: string;
|
32 | leftMenu?: string;
|
33 | }
|
34 | export declare class TreeModelSettings {
|
35 | cssClasses?: CssClasses;
|
36 | templates?: Templates;
|
37 | |
38 |
|
39 |
|
40 |
|
41 |
|
42 |
|
43 | leftMenu?: boolean;
|
44 | |
45 |
|
46 |
|
47 |
|
48 |
|
49 |
|
50 | rightMenu?: boolean;
|
51 | |
52 |
|
53 |
|
54 |
|
55 |
|
56 | menuItems?: NodeMenuItem[];
|
57 | |
58 |
|
59 |
|
60 |
|
61 |
|
62 |
|
63 | static?: boolean;
|
64 | isCollapsedOnInit?: boolean;
|
65 | checked?: boolean;
|
66 | selectionAllowed?: boolean;
|
67 | keepNodesInDOM?: boolean;
|
68 | static readonly NOT_CASCADING_SETTINGS: string[];
|
69 | static merge(child: TreeModel, parent: TreeModel): TreeModelSettings;
|
70 | }
|
71 | export declare class Ng2TreeSettings {
|
72 | |
73 |
|
74 |
|
75 |
|
76 |
|
77 | rootIsVisible?: boolean;
|
78 | showCheckboxes?: boolean;
|
79 | enableCheckboxes?: boolean;
|
80 | }
|
81 | export declare enum TreeStatus {
|
82 | New = 0,
|
83 | Modified = 1,
|
84 | IsBeingRenamed = 2
|
85 | }
|
86 | export interface RenamableNode {
|
87 | |
88 |
|
89 |
|
90 |
|
91 | setName(name: string): void;
|
92 | |
93 |
|
94 |
|
95 |
|
96 | toString(): string;
|
97 | }
|