ftlabs / fastclick

Polyfill to remove click delays on browsers with touch UIs
MIT License
18.65k stars 3.22k forks source link

Windows Phone 8.1: select and input elements not usable #304

Closed michaelboellet closed 9 years ago

michaelboellet commented 10 years ago

Fastclick works great with Windows Phone 8.0 but since the 8.1 upgrade I have a strange behavior on select and input elements. On selects I can't choose an option, the options are not even showing up. I can click on input elements but the keyboard is not showing, only until I click multiple times on the field.

I've tested it with my Lumia 920 on two projects which use Fastclick, both have the same behavior. Is this a known bug? Couldn't find any info about this yet. Thanks!

michaelboellet commented 10 years ago

Since the User Agent on Windows Phone 8.1 includes "Android", "deviceIsAndroid" is returning true on WP 8.1. I expanded it with "&& navigator.userAgent.indexOf('Windows Phone') == 0" and now its working perfectly on Android and Windows Phone 8.1. Maybe that helps :)

dimchez commented 9 years ago

Having same issues on WinPhone 8.1. Works fine if I add needsclick class on input and select elements.

alexdiliberto commented 9 years ago

Also confirming this is an issue with v1.0.3 and WinPhone 8.1

Spent a couple hours debugging today only to find it was FastClick... :confused:

matthew-andrews commented 9 years ago

I'm sorry you had to spend so many hours debugging FastClick. As long as you set up the correct CSS classes, FastClick shouldn't even do anything on IE10+ but it looks like our check for this didn't match the advice we were giving in our README.md.

Would you mind trying this version? https://github.com/ftlabs/fastclick/blob/match-ie10%2B-advice/lib/fastclick.js

davidhouweling commented 9 years ago

Hi @matthew-andrews, I've tried the suggested version in Windows Phone 8.1 Update 1 Emulator and on a Nokia Lumia 920 (with developer preview) and it appears to work.

matthew-andrews commented 9 years ago

Unfortunately I don't have a device to test this on, but going to go by @davidhouweling's verification in this case and say that this is fixed in v1.0.5.