Skip to content

Commit

Permalink
fix(module: inputitem): type allows text (#818)
Browse files Browse the repository at this point in the history
  • Loading branch information
Anberm committed Dec 31, 2021
1 parent e461731 commit c0695e7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion components/input-item/input-item.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,10 +80,11 @@ export class InputItemComponent implements OnInit, AfterViewInit, ControlValueAc
this._type = 'password';
} else if (value === 'digit') {
this._type = 'number';
} else if (value !== 'text' && value !== 'number') {
} else {
this._type = value;
}
if (value === 'number') {
this._type = 'text';
this.pattern = '[0-9]*';
}
}
Expand Down

0 comments on commit c0695e7

Please sign in to comment.