Commit 988318a5 authored by Andrew Hrdy's avatar Andrew Hrdy
Browse files

Focus input on search (mobile)

Closes #37
parent ae70a19f
......@@ -61,7 +61,12 @@ class SearchBar extends React.Component {
This timeout is necessary because inputElement is not displayed when execution reaches this point.
By using setTimeout with no delay, inputElement.focus() is added to the end of the execution stack, therefore
being executed after the input is visible.,
setTimeout(() => this.inputElement.focus());
handleMobileCollapse = () => {
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment