0

Preface: Introducing YUI3 delegated on-tap events has seemed to broken all on-page default click events... buttons, input-field editing, radio button selection, etc. Everything worked fine before... all I did was include the event-tap module in a couple of relevant YUI calls wherever I need to delegate the on-tap event.

Details: My web app has to be used on both PC and touchscreen devices. My early versions just supported on-"click" event listener delegation, which worked fine (even on most touch devices). Now, I'm migrating to using more proper on-"tap" event listeners whenever YUI.Env.UA.touchEnabled is true. But, since I've made the update, none of my normal "click" events are working right on my iPad Air (Safari iOS 7.1.1) ~ while working just fine on an iPod Touch (Safari iOS 6.1.3). And by "normal click event" I mean simple/standard buttons, fields, and elements with default click behavior baked into them (as mentioned in my preface above).

Web-app Description: Sorry, my app is pretty large and complext to easily include code here; but, basically, I have a dynamic list of items (ul/li) that I've used YUI3's event delegation to define on-click subscriptions to. So, whenever the user clicks/taps an item, a YUI-Panel is supposed to show. That panel has a few buttons and text fields on it. That worked beautifully until I introduced the event-tap stuff.

SO...
Does anyone know whether this is a known bug or something? I couldn't turn up anything online in my searches. Click works just fine on PC and older mobile-safari (even with the tap stuff included)... just not on the newest mobile Safari.

Brian Tompsett - 汤莱恩
  • 5,753
  • 72
  • 57
  • 129
csr19us
  • 105
  • 9

1 Answers1

0

After chatting with the YUI team on IRC, it was suggested that I migrate to using hammer.js instead of the YUI events module. The engineer who heads integration of Hammer into YUI indicated that Hammer is a lot better at managing cross-platform gesture/touch events. I'm still trying to integrate the early version to get something working (it will be included in YUI, eventually - maybe late summer 2014), and since there's no native YUI solution, I'm marking this as answered.

Hammer git:
https://github.com/EightMedia/hammer.js

YUI's early work at integration:
https://github.com/tilomitra/yui-hammer

csr19us
  • 105
  • 9