Primeng: Dropdown with default value does not work properly with clear button

Created on 7 Mar 2018  路  9Comments  路  Source: primefaces/primeng

I'm submitting a ...

[x] bug report => Search github for a similar issue or PR before submitting
[ ] feature request => Please check if request is not on the roadmap already https://github.com/primefaces/primeng/wiki/Roadmap
[ ] support request => Please do not submit support request here, instead see http://forum.primefaces.org/viewforum.php?f=35

Plunkr Case (Bug Reports)
http://plnkr.co/edit/zIEhdMlGSNzCqmhZU41h?p=preview

Current behavior
bug-dropdown

Expected behavior
Open the dropdown.

Minimal reproduction of the problem with instructions

  1. Create a dropdown with selected/default value
  2. Click clear button
  3. Try to open the dropdown

What is the motivation / use case for changing the behavior?
Obviously this error makes the dropdown unusable.

Please tell us about your environment:
OS: MAC OS X High Sierra 10.13.3
IDE: WebStorm 2018.1 EAP
Package Manager: Yarn 1.5.1
Node: 9.7.1
Angular-cli: 1.7.2

  • Angular version: 5.2.7

  • PrimeNG version: 5.2.1

  • Browser: all

  • Language: all

  • Node (for AoT issues): node --version = 9.7.1

defect

Most helpful comment

Agreed. The dropdown is unusable

All 9 comments

The clear button does not emit an onChange event. Is that an intended behavior?

I don't know @perkma but for me is another bug

It is performing the same way even in the demo. This needs to fixed soon as it breaks the entire dropdown and makes in unusable.

Agreed. The dropdown is unusable

please make it optional.

Observing the same behavior, and I agree our team needs the clear icon optional.

Workaround to hide the clear button:

Add the following in global styes.scss:

p-dropdown {
  .ui-dropdown-clear-icon {
    display: none;
  }
}

Any idea when this is going to be fixed? We need both the clear button and the dropdowns in our application

5.2.2 is now published with this fix and others;

https://www.primefaces.org/primeng-5-2-2-released/

Was this page helpful?
0 / 5 - 0 ratings

Related issues

watalberto picture watalberto  路  3Comments

mitosandov picture mitosandov  路  3Comments

miresk picture miresk  路  3Comments

SchneMa picture SchneMa  路  3Comments

philly-vanilly picture philly-vanilly  路  3Comments