Code Monkey home page Code Monkey logo

Comments (8)

jadjoubran avatar jadjoubran commented on May 11, 2024

That's what I'm currently doing to support All mobile devices and all desktop devices (including desktop devices with touch screens)

if ( 'ontouchend' in document.documentElement ){
   var FRIES_EVENT_TYPE = 'touchend';  //touch device
}else if ( 'ontouchleave' in document.documentElement ){
   var FRIES_EVENT_TYPE = 'touchleave';  //touch device
}else if ( 'ontouchstart' in document.documentElement ){
   var FRIES_EVENT_TYPE = 'touchstart';  //touch device
}else{
   var FRIES_EVENT_TYPE = 'click'; //desktop
}

and then instead of:

document.addEventListener( 'touchstart', function (e) {

I use

document.addEventListener( FRIES_EVENT_TYPE, function (e) {

from fries.

jaunesarmiento avatar jaunesarmiento commented on May 11, 2024

Wow @jadjoubran, this is great! Also I think you'll be needing to add the touchmove events as well. :)

from fries.

jadjoubran avatar jadjoubran commented on May 11, 2024

Well I honestly disabled the stack.js file
I only use the spinner.js and the tabs.js whenever needed

from fries.

jaunesarmiento avatar jaunesarmiento commented on May 11, 2024

Sorry to hear that. I'm really working hard to get these issues off the list.

from fries.

jadjoubran avatar jadjoubran commented on May 11, 2024

There are no issues with stack.js but I found it would be better not to include it
everything works fine without it
I really hope that soon I can contribute all my changes to fries!

from fries.

jaunesarmiento avatar jaunesarmiento commented on May 11, 2024

I'll be looking forward to it :)

from fries.

jaunesarmiento avatar jaunesarmiento commented on May 11, 2024

I pushed a branch that solves this issue. Please check out https://github.com/jaunesarmiento/fries/tree/fix-for-issue33 for this.

The only problem that I encountered with this is that the default behaviour of labels do not work, which is an issue for form elements. Anybody want to try fixing this issue on that branch? :)

from fries.

jaunesarmiento avatar jaunesarmiento commented on May 11, 2024

Workaround: Use fingerblast.js.

from fries.

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.