Skip to content
This repository has been archived by the owner on Jul 19, 2019. It is now read-only.

[fixed] Select highlighted item on input click #84

Merged
merged 1 commit into from
Jun 5, 2016

Conversation

CMTegner
Copy link
Collaborator

While trying to debug #80 I discovered that clicking the input field to
"confirm" a suggestion didn't work as expected.

The problem:

  1. Navigate to https://reactcommunity.org/react-autocomplete/static-data/
  2. Type 'a' in input field
  3. Observe that the input has been filled with 'Alabama'
  4. Click anywhere inside the input field
  5. Observe that the highlighted selection is gone, and the menu has been closed
  6. Click/tab outside the input
  7. Observe that the input value has been reverted to 'a'

This change ensures that clicking in the input field has the same effect as
clicking the highlighted item in the suggestion menu.

While trying to debug reactjs#80 I discovered that clicking the input field to
"confirm" a suggestion didn't work as expected.

The problem:

1. Navigate to https://reactcommunity.org/react-autocomplete/static-data/
2. Type 'a' in input field
3. Observe that the input has been filled with 'Alabama'
4. Click anywhere inside the input field
5. Observe that the highlighted selection is gone, and the menu has been closed
6. Click/tab outside the input
7. Observe that the input value has been reverted to 'a'

This change ensures that clicking in the input field has the same effect as
clicking the highlighted item in the suggestion menu.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants