ivirabyan / jquery-mentions

Adds mentioning support to your text fields.
http://ivirabyan.github.io/jquery-mentions/
MIT License
114 stars 49 forks source link

Pressing Enter on Mention list; how do I capture it w/o the input using that keypress? #51

Closed realdem closed 8 years ago

realdem commented 8 years ago

Hello, this isn't a true issue per say- but it would be fantastic if I can resolve this. Your mentions function has been exactly what I have been needing. When you are requesting mentions- It comes out in a neat list under the input box. You may scroll through these (with arrow keys) and select one with the Enter key. Is there a way in which jQuery can detect that the browser's focus is in that very list, instead of the input box, only for that selection time? Perhaps there is a variable in your script which records whether that list is being shown currently-or-not. For when the user will select the mention, they should still be able to type more text before submitting their entire thought. I'd like to do this without showing another button- and the Enter key should be that method.

Thank you for focus on this. It'd be a real help.

ivirabyan commented 8 years ago

Currently if you select mention from the list by pressing the Enter key, the keypress event is not fired. So it must not be a problem. I might help you if you post an example code here.

ivirabyan commented 8 years ago

Closing this issue as no feedback was given