Chips: After clicking the clear button does not allow to input values #13011
Labels
Type: Bug
Issue contains a bug related to a specific component. Something about the component is not working
Milestone
Describe the bug
When we set the max and showClear attributes for the p-chips:
<p-chips [addOnBlur]="true" [showClear]="true" [max]="5"></p-chips>
After that type the max possible values (in that case 5) and press the clear button, the input is still disabled.
Environment
Windows 10
Reproducer
https://stackblitz.com/edit/primeng-chips-maxitems-bug?file=src%2Fapp%2Fapp.component.html
Angular version
14.2.0
PrimeNG version
14.2.2
Build / Runtime
Angular CLI App
Language
TypeScript
Node version (for AoT issues node --version)
18.16.0
Browser(s)
Chrome 113.0.5672.92
Steps to reproduce the behavior
Expected behavior
After the clicking clear button I should be able to write the value again.
A possible reason could be that
clear
method does not haveupdateMaxedOut method
:clear() { this.value = null; this.updateFilledState(); this.onModelChange(this.value); this.onClear.emit(); }
The text was updated successfully, but these errors were encountered: