1 | export declare type Id = number | string;
|
2 | export interface ColorObject {
|
3 | background: string;
|
4 | border: string;
|
5 | highlight: {
|
6 | background: string;
|
7 | border: string;
|
8 | };
|
9 | hover: {
|
10 | background: string;
|
11 | border: string;
|
12 | };
|
13 | }
|
14 | export interface GephiData {
|
15 | nodes: GephiNode[];
|
16 | edges: GephiEdge[];
|
17 | }
|
18 | export interface GephiParseOptions {
|
19 | fixed?: boolean;
|
20 | inheritColor?: boolean;
|
21 | parseColor?: boolean;
|
22 | }
|
23 | export interface GephiNode {
|
24 | id: Id;
|
25 | attributes?: {
|
26 | title?: string;
|
27 | };
|
28 | color?: string;
|
29 | label?: string;
|
30 | size?: number;
|
31 | title?: string;
|
32 | x?: number;
|
33 | y?: number;
|
34 | }
|
35 | export interface GephiEdge {
|
36 | id: Id;
|
37 | source: Id;
|
38 | target: Id;
|
39 | attributes?: {
|
40 | title?: string;
|
41 | };
|
42 | color?: string;
|
43 | label?: string;
|
44 | type?: string;
|
45 | }
|
46 | export interface VisData {
|
47 | nodes: VisNode[];
|
48 | edges: VisEdge[];
|
49 | }
|
50 | export interface VisNode {
|
51 | id: Id;
|
52 | fixed: boolean;
|
53 | color?: string | ColorObject;
|
54 | label?: string;
|
55 | size?: number;
|
56 | title?: string;
|
57 | x?: number;
|
58 | y?: number;
|
59 | attributes?: unknown;
|
60 | }
|
61 | export interface VisEdge {
|
62 | id: Id;
|
63 | from: Id;
|
64 | to: Id;
|
65 | arrows?: 'to';
|
66 | color?: string;
|
67 | label?: string;
|
68 | title?: string;
|
69 | attributes?: unknown;
|
70 | }
|
71 |
|
72 |
|
73 |
|
74 |
|
75 |
|
76 |
|
77 |
|
78 |
|
79 | export declare function parseGephi(gephiJSON: GephiData, optionsObj?: GephiParseOptions): VisData;
|
80 |
|
\ | No newline at end of file |