Skip to content

c-form-feedback component not displayed with cFormPassword input #237

@bernik1980

Description

@bernik1980

I have the following input group, to let the user specify a password:

<c-input-group>
  <input cFormControl cFormPassword id="password" formControlName="password" [valid]="isFormControlValid('password')" />
  <c-form-feedback [valid]="false">Please specify a valid password.</c-form-feedback>
</c-input-group>

isFormControlValid() just checks if the control is valid and if it was touched.

The related formGroup looks like this:

itemForm = new FormGroup({
  password: new FormControl('', [Validators.required, Validators.minLength(8)])
})

If the input of the user is invalid (no input or less then 8 chars), the border of the input becomes red (which is of course correct), but the c-form-feedback is not displayed.

If i remove the cFormPassword directive, the c-form-feedback is displayed.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions