@@ -46,7 +46,7 @@ export class ConnectBase implements OnDestroy, AfterContentInit {
46
46
}
47
47
@Input ( ) connect ?: ( ) => ( string | number ) | ( string | number ) [ ] ;
48
48
protected store ?: FormStore ;
49
- protected form : any ;
49
+ protected formGroup : any ;
50
50
private stateSubscription ?: Unsubscribe ;
51
51
52
52
private formSubscription ?: Subscription ;
@@ -70,7 +70,7 @@ export class ConnectBase implements OnDestroy, AfterContentInit {
70
70
}
71
71
72
72
Promise . resolve ( ) . then ( ( ) => {
73
- this . formSubscription = ( this . form . valueChanges as any )
73
+ this . formSubscription = ( this . formGroup . valueChanges as any )
74
74
. pipe ( debounceTime ( 0 ) )
75
75
. subscribe ( ( values : any ) => this . publish ( values ) ) ;
76
76
} ) ;
@@ -106,13 +106,15 @@ export class ConnectBase implements OnDestroy, AfterContentInit {
106
106
107
107
return pairs . filter ( p => {
108
108
const parent = ( p . control as any ) . _parent ;
109
- return parent === this . form . control || parent === this . form ;
109
+ return parent === this . formGroup . control || parent === this . formGroup ;
110
110
} ) ;
111
111
}
112
112
113
113
private resetState ( ) {
114
114
const formElement =
115
- this . form . control === undefined ? this . form : this . form . control ;
115
+ this . formGroup . control === undefined
116
+ ? this . formGroup
117
+ : this . formGroup . control ;
116
118
117
119
const children = this . descendants ( [ ] , formElement ) ;
118
120
@@ -129,7 +131,7 @@ export class ConnectBase implements OnDestroy, AfterContentInit {
129
131
130
132
private publish ( value : any ) {
131
133
if ( this . store ) {
132
- this . store . valueChanged ( this . path , this . form , value ) ;
134
+ this . store . valueChanged ( this . path , this . formGroup , value ) ;
133
135
}
134
136
}
135
137
0 commit comments