FS#32904 - {archweb} typeahead: set focus back after click
Attached to Project:
Arch Linux
Opened by Marcel Korpel (Marcel-) - Thursday, 29 November 2012, 17:47 GMT
Last edited by Dan McGee (toofishes) - Saturday, 29 March 2014, 23:05 GMT
Opened by Marcel Korpel (Marcel-) - Thursday, 29 November 2012, 17:47 GMT
Last edited by Dan McGee (toofishes) - Saturday, 29 March 2014, 23:05 GMT
|
Details
When you click an item in the typeahead box,
#pkgsearch-field loses focus. Please set focus back after
clicking so we can always just press enter to start the
search after selecting an item (using keyboard and
mouse).
Possible, quick-and-dirty, untested, not-so-nice solution: diff --git a/sitestatic/bootstrap-typeahead.js b/sitestatic/bootstrap-typeahead.js index 3d355ae..5bc24da 100644 --- a/sitestatic/bootstrap-typeahead.js +++ b/sitestatic/bootstrap-typeahead.js @@ -252,6 +252,7 @@ e.stopPropagation() e.preventDefault() this.select() + this.$element.focus() } , mouseenter: function (e) { |
This task depends upon
Closed by Dan McGee (toofishes)
Saturday, 29 March 2014, 23:05 GMT
Reason for closing: Fixed
Additional comments about closing: Fixed a different way.
Saturday, 29 March 2014, 23:05 GMT
Reason for closing: Fixed
Additional comments about closing: Fixed a different way.
https://github.com/twitter/bootstrap/issues/5933
https://github.com/twitter/bootstrap/pull/6099