Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Keep autosuggest text search in focus even when user deletes search text #345

Closed
glorp47 opened this issue Mar 22, 2017 · 3 comments
Closed

Comments

@glorp47
Copy link

glorp47 commented Mar 22, 2017

I've noticed that for some reason, whenever I'm using the text search function for Autocomplete, the component ceases to be in focus and the text cursor disappears if I delete the last character from the search bar. However, this doesn't seem to happen in the Codepen examples, so I've been trying to debug this to no avail. It doesn't seem like I can set a ref to the input field and then use the .focus() method on it either, so I'm a bit at a loss. Thanks.

@moroshko
Copy link
Owner

Which browser/OS did you observe this behavior?

@glorp47
Copy link
Author

glorp47 commented Mar 22, 2017

In both Firefox and Safari using OSX

@glorp47
Copy link
Author

glorp47 commented Mar 22, 2017

My bad, I found the bug. I was stupidly setting the key for the component to a random number which was inducing component re-rendering. Fun times.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants