jQuery UI sliders on touch devices

前端 未结 4 2000
慢半拍i
慢半拍i 2020-12-07 08:11

I\'m developing a website using jQuery UI, and there are several elements on my site that appear to be incompatible when viewed on touchscreen devices; they don\'t cause any

4条回答
  •  谎友^
    谎友^ (楼主)
    2020-12-07 08:58

    Just wanted to add some new info about this. Touch-punch will work fine for Ipads and Android devices. But the slider will not work on Windows mobile devices, as far is I could test(with the latest versions of jquery ui & Touch punch)

    The fix is quite simple, just add the following CSS-rules to the .ui-slider-handle:

    -ms-touch-action: none;
    touch-action: none;
    

    Hope this helps

提交回复
热议问题