File tree 4 files changed +5
-5
lines changed
4 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -23,6 +23,7 @@ import {
23
23
ArrowPathFn ,
24
24
} from './flow-interface' ;
25
25
import { FlowConfig , FlowPlugin } from './plugins/plugin' ;
26
+ import { Connections } from './plugins/connections' ;
26
27
27
28
const BASE_SCALE_AMOUNT = 0.05 ;
28
29
@@ -137,6 +138,7 @@ export class FlowComponent
137
138
@ViewChild ( 'guideLines' ) guideLines : ElementRef < SVGGElement > ;
138
139
initialX = 0 ;
139
140
initialY = 0 ;
141
+ defaultPlugins = [ new Connections ( ) ] ;
140
142
141
143
constructor (
142
144
public el : ElementRef < HTMLElement > ,
@@ -171,6 +173,9 @@ export class FlowComponent
171
173
}
172
174
173
175
private runPlugin ( callback : ( e : FlowPlugin ) => void ) {
176
+ for ( const plug of this . defaultPlugins ) {
177
+ callback ( plug ) ;
178
+ }
174
179
for ( const key in this . config . Plugins ) {
175
180
if ( Object . prototype . hasOwnProperty . call ( this . config . Plugins , key ) ) {
176
181
const element = this . config . Plugins [ key ] ;
Original file line number Diff line number Diff line change @@ -10,5 +10,4 @@ export * from './lib/svg';
10
10
export { FitToWindow } from './lib/plugins/fit-to-window' ;
11
11
export { ScrollIntoView } from './lib/plugins/scroll-into-view' ;
12
12
export { Arrangements } from './lib/plugins/arrangements' ;
13
- export { Connections } from './lib/plugins/connections' ;
14
13
export { FlowConfig , FlowPlugin } from './lib/plugins/plugin' ;
Original file line number Diff line number Diff line change @@ -13,7 +13,6 @@ import {
13
13
FitToWindow ,
14
14
ScrollIntoView ,
15
15
Arrangements ,
16
- Connections ,
17
16
} from '@ngu/flow' ;
18
17
import { EditorComponent } from '../editor.component' ;
19
18
import { ToolbarComponent } from './toolbar.component' ;
@@ -91,7 +90,6 @@ export class DemoOneComponent implements AfterViewInit {
91
90
scroll : new ScrollIntoView ( '1' ) ,
92
91
fitWindow : new FitToWindow ( true ) ,
93
92
arrange : new Arrangements ( ) ,
94
- connections : new Connections ( ) ,
95
93
} ;
96
94
config : FlowConfig = {
97
95
Arrows : true ,
Original file line number Diff line number Diff line change @@ -13,7 +13,6 @@ import {
13
13
ScrollIntoView ,
14
14
FitToWindow ,
15
15
Arrangements ,
16
- Connections ,
17
16
} from '@ngu/flow' ;
18
17
import { EditorComponent } from '../editor.component' ;
19
18
import { ToolbarComponent } from './toolbar.component' ;
@@ -101,7 +100,6 @@ export class DemoTwoComponent implements AfterViewInit {
101
100
scroll : new ScrollIntoView ( '1' ) ,
102
101
fitWindow : new FitToWindow ( false ) ,
103
102
arrange : new Arrangements ( ) ,
104
- connections : new Connections ( ) ,
105
103
} ;
106
104
config : FlowConfig = {
107
105
Arrows : true ,
You can’t perform that action at this time.
0 commit comments