Code Monkey home page Code Monkey logo

Comments (5)

chrissainty avatar chrissainty commented on May 24, 2024 1

Based on what other typeahead controls do, it might be good to be able to select the first item by either tab OR the down arrow. That way users can type and then just keep pressing down rather than having to type > tab > down arrow. I think both should be an option though.

from typeahead.

vertonghenb avatar vertonghenb commented on May 24, 2024

I tried the arrow keys but failed, the tab can currently be done though. The arrow buttons get annoying when a scrollbar is in place since you also scroll using the arrow keys and there is no way to stop this from happening in Blazor at the moment.

You can see the changes in #28, but it wasn't bulletproof.

from typeahead.

egrabitt avatar egrabitt commented on May 24, 2024

Thank you Chris and Benjamin for your awesome typeahead control! I just found it and I was able to replace a jQuery based hack in my Server-side Blazor in no time. Much cleaner. However the Tab-behavior bothers me as it forces me to use the mouse.

You say "it might be good to be able to select the first item by either tab OR the down arrow." I second that!

Specifically, I'd like the control to behave like this: If you press Tab after typing something, the first suggestion is put into the typeahead input field and the form's next input is focused. So Tab behaves just like in a regular form with text input fields.
One "safety option" could be that a suggestion is only used if there is only one in the list.
Do you think this is possible?

Thanks again, Ernie

from typeahead.

vertonghenb avatar vertonghenb commented on May 24, 2024

@egrabitt check the gif at #31 I think it behaves as you'd like.

from typeahead.

egrabitt avatar egrabitt commented on May 24, 2024

thanks for your reply, but no, it doesn't. Pressing tab should move the focus to the form's next input element, putting the topmost typeahead suggestion into the now previous element.
The goal is that no clicking or Enter is required.

from typeahead.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.