cozy / cozy-contacts-v2

Contact books manager for Cozy
http://cozy.io
GNU Affero General Public License v3.0
20 stars 20 forks source link

Closing label dropdown do not reset the "add label" button #297

Open Phyks opened 8 years ago

Phyks commented 8 years ago

Hi,

Steps to reproduce:

  1. Open the label dropdown in contact edit form.
  2. Click the "Add new label" button.
  3. Close the label dropdown without effectively add a new label.
  4. Reopen the label dropdown. The "Add new label" button is not there, but the input is still there instead, with the same content as it used to have.

I am not sure this is done on purpose. I can understand that if some text has been entered in the input field, the label dropdown is kept as is at reopening, to avoid accidentally closing the dropdown and losing the content of the input.

However, if the input is empty, it looks weird when reopening the dropdown as (depending on user browser styling I think), there is only a large white space at the end of the bottom of the dropdown, without any indication it is here (typically, a placeholder).

Thanks

EDIT: Also, not sure if it deserves its own issue but the blue color of the "add label" button is the same one as the blue color for the "save" button, and can lead to confusion. When label dropdown is opened, I often accidentally click "add a label" instead of "save".