Giter Site home page Giter Site logo

Comments (3)

RyanMullins avatar RyanMullins commented on August 22, 2024

I'm actually working through a related in (see #16 and #19) where the default recognizers were not being initialized properly. It's part of a pretty big suite of bug and performance fixes coming in v2.1.3. I'll keep this open until I finalize those changes (target for that is Monday).

In the meantime, you're missing a couple of things in your recognizer options, namely a type and an explicit directions value. Without a type, Angular Hammer won't associate the options with a recognizer. The directions value is only necessary because of the issue I mentioned above. The deltaX value may not do anything, or at least I wouldn't expect it to given the Hammer docs for Pan. Try this and let me know if it works.

<div class="my-main-container" 
    hm-panright="onHammer"
    hm-recognizer-options='[{"type":"pan","directions":"DIRECTIONS_RIGHT"}]'>
</div>

One more thing to keep in mind. Pan, Press, Swipe, and Tap gestures are all pretty much universally supported, but other gestures may not be depending on the browser. If you run into issues check the Hammer Compatibility page to make sure your browser supports that gesture type.

from angular-hammer.

DmitryEfimenko avatar DmitryEfimenko commented on August 22, 2024

Thanks for the info and a suggestion. Though It still never gets hit.
I'm testing on latest Chrome locally.

from angular-hammer.

RyanMullins avatar RyanMullins commented on August 22, 2024

Interesting. I recommended this fix to another person and they reported the same thing. Maybe it's a bigger problem with the pan right gesture. I'll look into it.

from angular-hammer.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.