Skip to content

Commit 39c208b

Browse files
authored
feat: export er layout (#52)
1 parent 9b200f8 commit 39c208b

File tree

4 files changed

+7
-2
lines changed

4 files changed

+7
-2
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@antv/layout",
3-
"version": "0.1.19-beta.5",
3+
"version": "0.1.19",
44
"description": "graph layout algorithm",
55
"main": "lib/index.js",
66
"module": "es/index.js",

src/layout/index.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ import { FruchtermanGPULayout } from "./gpu/fruchterman";
1212
import { GForceGPULayout } from "./gpu/gForce";
1313
import { ComboForceLayout } from "./comboForce";
1414
import { ForceAtlas2Layout } from "./forceAtlas2";
15+
import { ERLayout } from './er';
1516

1617
import { Layout, Layouts } from "./layout";
1718

@@ -33,6 +34,7 @@ export {
3334
GForceGPULayout,
3435
ComboForceLayout,
3536
ForceAtlas2Layout,
37+
ERLayout
3638
};
3739

3840
// types file

src/layout/layout.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ import { FruchtermanGPULayout } from "./gpu/fruchterman";
1515
import { GForceGPULayout } from "./gpu/gForce";
1616
import { ComboForceLayout } from "./comboForce";
1717
import { ForceAtlas2Layout } from "./forceAtlas2";
18+
import { ERLayout } from "./er";
1819
export class Layout {
1920
public readonly layoutInstance: Base;
2021

@@ -66,4 +67,5 @@ export const Layouts: { [key: string]: any } = {
6667
random: RandomLayout,
6768
'gForce-gpu': GForceGPULayout,
6869
'fruchterman-gpu': FruchtermanGPULayout,
70+
er: ERLayout,
6971
};

src/layout/types.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -367,5 +367,6 @@ export namespace ILayout {
367367
| GForceLayoutOptions
368368
| GForceGPULayoutOptions
369369
| ComboForceLayoutOptions
370-
| ForceAtlas2LayoutOptions;
370+
| ForceAtlas2LayoutOptions
371+
| ERLayoutOptions;
371372
}

0 commit comments

Comments
 (0)