fix(forms): fixed the selector of NgRequiredValidator
This commit is contained in:
parent
6622826587
commit
35197acc1a
|
@ -2,7 +2,7 @@ import {Directive} from '../../../angular2';
|
|||
import {Validators} from '../validators';
|
||||
import {NgControl} from '../directives';
|
||||
|
||||
@Directive({selector: '[required]'})
|
||||
@Directive({selector: '[required][ng-control],[required][ng-form-control],[required][ng-model]'})
|
||||
export class NgRequiredValidator {
|
||||
constructor(c: NgControl) {
|
||||
c.validator = Validators.compose([c.validator, Validators.required]);
|
||||
|
|
Loading…
Reference in New Issue