forceSelection not clearing invalid single numbers/strings #7841
Labels
Type: Bug
Issue contains a bug related to a specific component. Something about the component is not working
Milestone
I'm submitting a ... (check one with "x")
Plunkr Case (Bug Reports)
Please demonstrate your case at stackblitz by using the issue template below. Issues without a test case have much less possibility to be reviewd in detail and assisted.
https://stackblitz.com/edit/github-9pxw5z?file=src/app/app.component.ts
Current behavior
If I type a number/single string that would not bring any valid value on an Autocomplete(forceSelection=true), it does not clear the invalid value.
If I type a number with a letter, it does clear (this should also happen with the single string/number) and after that it does also clear the single number (as shown on the example bellow), but on the first time I type the number, it does not clear.
Expected behavior
It should clear the invalid value just like it does after typing a number plus another character.
Minimal reproduction of the problem with instructions
type a number on a p-autocomplete (forceSelection=true), for exemple "1" then press tab, it should clear the value because it is an invalid value.
https://stackblitz.com/edit/github-9pxw5z?file=src/app/app.component.ts
Language: [all | TypeScript X.X | ES6/7 | ES5]
Node (for AoT issues):
node --version
= 10.15.1The text was updated successfully, but these errors were encountered: