Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chosen dropdown scroll doesn't work for touch device #2597

Closed
asvetlenko opened this issue May 4, 2016 · 4 comments
Closed

Chosen dropdown scroll doesn't work for touch device #2597

asvetlenko opened this issue May 4, 2016 · 4 comments

Comments

@asvetlenko
Copy link

I have Sony Z4 Tablet with Android 6.0 (Google Chrome 50). And I try to use chosen drop-down, but unfortunately it is impossible because I cannot use scroll for chosen drop-down: You can try to reproduce this bug here: https://harvesthq.github.io/chosen/.
You should remover condition:
if (/Mobile/i.test(window.navigator.userAgent)) {
return false;
}

from function "AbstractChosen.browser_is_supported"

@koenpunt
Copy link
Collaborator

koenpunt commented May 6, 2016

I don't believe Chosen should be enabled on such a device.

What would removing that condition change?

@mkmms
Copy link

mkmms commented May 23, 2016

There is a simple fix, in my case i have commented the following in register_observers

this.container.bind('touchstart.chosen', function(evt) {
_this.container_mousedown(evt);
// return evt.preventDefault();
});

in my case its working fine.

if anything wrong in that please suggest me

@pfiller
Copy link
Contributor

pfiller commented Jun 2, 2016

I agree with @koenpunt that Chosen should be disabled on mobile out of the box. Personally, I don't feel like its UI is really an improvement over the built-in selects on Android and iOS. Select boxes on the desktop are so much worse...

@pfiller pfiller closed this as completed Jun 2, 2016
@tornikeshavishvili
Copy link

There is a simple fix, in my case i have commented the following in register_observers

this.container.bind('touchstart.chosen', function(evt) { _this.container_mousedown(evt); // return evt.preventDefault(); });

in my case its working fine.

if anything wrong in that please suggest me

This Suggestion Helped

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants