Keep search query input open if it has a value.
More tests and comments, still a little bug left.