#12356 closed bug (invalid)
bootstrap typeahead doesn't work with jquery 1.8 in google chrome
Reported by: | Owned by: | ||
---|---|---|---|
Priority: | undecided | Milestone: | None |
Component: | unfiled | Version: | 1.8.0 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
Specifically, navigating the suggestions list with the up/down keys doesn't work.
fiddle: http://jsfiddle.net/dH5z5/
this works fine with jquery 1.7 .
corresponding bootstrap issue: https://github.com/twitter/bootstrap/issues/4465
Change History (4)
comment:1 Changed 10 years ago by
Owner: | set to [email protected]… |
---|---|
Status: | new → pending |
comment:2 Changed 10 years ago by
Status: | pending → new |
---|
(sorry about the x-post from the bootstrap ticket - there might be people here not following both bugs)
It still doesn't seem to work: http://jsfiddle.net/8NRyr/ . I have added a console.log(e)
near the line , keypress: function (e) {
- keypresses due to 'up' and 'down' keys still don't show up.
comment:3 Changed 10 years ago by
Resolution: | → invalid |
---|---|
Status: | new → closed |
The events are occuring in the keyup handler, for some reason they totally duplicated that code rather than attaching both events to the same handler.
Sorry, I wish I had more time to help you debug this but at this point it's a plugin issue until proven otherwise. It seems like the original code was never tested with IE6/7/8, it's possible there are other issues that just weren't worked out. Can you work with someone to debug this and open a more specific ticket if you determine there is a jQuery core bug?
Looks like Bootstrap is using
event.keyCode
, which jQuery has never normalized. We used to copy it in 1.7 but that only caused more confusion because it wasn't present on oldIE and people would report that as a bug. To use the un-normalized value you can useevent.originalEvent.keyCode
although that won't work on oldIE for example.The only key-related event data we've normalized is
event.which
as documented here: http://api.jquery.com/category/events/event-object/Is this widget intended for use with oldIE? Bootstrap is in general so I'm not sure if this is an oversight or not.