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

kibana 3: pressing enter in search field selects first suggestion #358

Closed
lexelby opened this issue Aug 13, 2013 · 15 comments
Closed

kibana 3: pressing enter in search field selects first suggestion #358

lexelby opened this issue Aug 13, 2013 · 15 comments

Comments

@lexelby
Copy link

lexelby commented Aug 13, 2013

Actions:

  1. enter a search for "foo bar" (without the quotes)
  2. delete the bar so your search is just "foo"
  3. press enter

Observed results:

The search box reverts back to "foo bar".

Expected results:

I expect pressing enter to be the equivalent of pressing the magnifying glass icon; it should search for "foo".

This issue gives the impression that Kibana is ignoring/reverting any changes I make to the query input box. Suggestions should only be selected if I press down to select one before pressing enter, or perhaps if I press tab.

@rashidkpc
Copy link
Contributor

This is the expected behavior, if you don't want to select the first item, hit the escape key then press enter

@lexelby
Copy link
Author

lexelby commented Aug 13, 2013

I really hope I can convince you to reopen this and consider changing this behavior. The current behavior is completely antithetical to what the average user expects. If I make a change and press enter, then I expect that change to be applied, but the top suggestion seems to always be the value that was previously in the field, so pressing enter always reverts what I typed. Users of web pages are generally accustomed to submitting forms by pressing enter, but that doesn't work here.

I'm a highly technical user and it actually took me a few weeks to figure out what the heck was going on here. I just figured that Kibana had some kind of bug and I'd need to reload to change my query.

@amitelad7
Copy link

+1 this is also what I was expecting and keep finding myself and the people on my team pressing enter and then retype the query when it does something we did not expect

@miguelcoelhosantos
Copy link

I've been bitten by this too.

@cdeszaq
Copy link

cdeszaq commented Aug 14, 2013

👍 The simple solution to this is to use the current value of the text box as the 1st option in the suggestions list, which is what Chrome's Omnibox does. This doesn't require adjusting how Enter works, and only adds a single key-stroke to select the next offered suggestion.

@olej-a
Copy link

olej-a commented Aug 14, 2013

+1 Need correction

@rashidkpc
Copy link
Contributor

I'm open to pull requests, but this is a functionality of the angular-strap typeahead directive. You may wish to petition angular-strap to bring in one of the forks of bootstrap-typeahead

@lexelby
Copy link
Author

lexelby commented Aug 14, 2013

Unfortunately, I really lack the javascript know-how to figure out how to fix this. Anyone have time to take a look?

@vicwomg
Copy link

vicwomg commented Aug 30, 2013

+1 for this. Also driving me a bit nuts. If I mistype a query, for example, then try to retype it, pressing enter will keep selecting the mistyped one. Most other autocomplete text fields I've encountered use enter to override the autocomplete results.

@Ziaunys
Copy link

Ziaunys commented Aug 30, 2013

+1 This is especially painful since I use Vimperator. In my configuration, hitting escape will leave insert mode.

@rashidkpc
Copy link
Contributor

This is fixed. I caved and made the changes to the bootstrap type ahead code

@dmourati
Copy link

Can you link to the change?

@rashidkpc
Copy link
Contributor

19dc44d

spalger pushed a commit to spalger/kibana that referenced this issue Mar 3, 2016
harper-carroll pushed a commit to harper-carroll/kibana that referenced this issue Jul 11, 2016
add new protofiles for request reply census
@Bouke
Copy link

Bouke commented Oct 20, 2017

In recent versions of Kibana the behaviour changed back to selecting the first suggestion. I'm on 5.5.1 and using Safari. Should I open a new ticket for this, or do you want to use this ticket as to track this regression?

Update: after further testing it appears that my cursor (mouse) was moving over the auto-suggestions and highlighting one of the options. If enter is pressed, Kibana will then use the highlighted auto-suggestion. The issue here is that when the mouse leaves the list of suggestions, the last highlighted suggestion will keep it's selection. So you need to press [esc] in order to deselect any suggestion.

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

11 participants