typeahead.js icon indicating copy to clipboard operation
typeahead.js copied to clipboard

Clicking vertical scrollbar for suggestions in IE closes menu

Open henkli opened this issue 12 years ago • 10 comments

If the suggestions menu has a vertical scrollbar, e.g. has a max-width set, clicking the scrollbar closes the typeahead menu in Internet Explorer. The scroll bar works fine in Firefox and Chrome.

Affects at least IE8, IE11 (probably IE9 and IE10 as well). IE8: Clicking scroll up/down icons works fine, but dragging the "scroll element" does not. IE11: Clicking anywhere on the scrollbar closes the menu. Tested using typeahead.js 0.10.1

Example fiddle: http://jsfiddle.net/r2a2G/

henkli avatar Feb 18 '14 19:02 henkli

Thanks for reporting this. I'll look into getting this fixed for v0.10.2.

jharding avatar Feb 18 '14 23:02 jharding

Any temp fix for this?

lgoudriaan avatar Mar 04 '14 12:03 lgoudriaan

#752 contains what I think is a fix. If you can, please test it out and let me know if it resolves your issue.

jharding avatar Mar 08 '14 05:03 jharding

Yes this works for me, Thanks!

lgoudriaan avatar Mar 10 '14 09:03 lgoudriaan

still happening

DealerCorp avatar Sep 19 '16 20:09 DealerCorp

I'm not too sure why this is closed as I still experience this issue? Is there a fix for this? It even happens on the main examples page for the Scrollable Dropdown Menu.

chrisbuckmaster avatar Oct 17 '17 13:10 chrisbuckmaster

Hi guys, just to let you know it looks like a bug in the latest IE11.0.47, which has reintroduced this bug.

worthy7 avatar Oct 18 '17 04:10 worthy7

In case anyone needs a solution, I basically made a version of _hacks() that relies on a focus flag set using mouseenter, mouseleave events on the menu. Seems to do the trick.

joezp avatar Oct 20 '17 10:10 joezp

That's what I did too: https://github.com/corejavascript/typeahead.js/issues/166

worthy7 avatar Oct 20 '17 10:10 worthy7

mouseenter/leave didn't occur to me until I saw this on a similar problem. https://stackoverflow.com/questions/2284541/form-input-loses-focus-on-scroll-bar-click-in-ie

joezp avatar Oct 20 '17 13:10 joezp