GithubHelp home page GithubHelp logo

Comments (7)

Matt-Jensen avatar Matt-Jensen commented on July 17, 2024

Help me to understand your use case, because it seems to me that noSwiping and allowSwipeToPrev/allowSwipeToNext options are mutually exclusive as they naturally would conflict. Is there a situation you need to use both?

I guess what I'm getting at is that it would be easier for me to debug the issue once your example eliminates the possibility of incompatible settings.

from ember-cli-swiper.

mattmcginnis avatar mattmcginnis commented on July 17, 2024

Maybe I don't understand how it's intended to work. Which if any of these scenarios are valid?

{{#swiper-container
  noSwiping=true
  noSwipingClass='swiper-slide'
  allowSwipeToPrev=false
  allowSwipeToNext=false
}}
{{#swiper-container
  noSwiping=false
  noSwipingClass=null
  allowSwipeToPrev=true
  allowSwipeToNext=true
}}
{{#swiper-container
  noSwiping=false
  noSwipingClass=null
  allowSwipeToPrev=false
  allowSwipeToNext=true
}}

from ember-cli-swiper.

Matt-Jensen avatar Matt-Jensen commented on July 17, 2024

1 and 2 just look redundant to me. Far simpler to just do {{swiper-container noSwiping=true}} and {{swiper-container noSwiping=false}} respectively.

3 noSwiping=false conflicts with allowSwipeToNext=false rather the component should be defined as:

{{swiper-container
  allowSwipeToPrev=false
  allowSwipeToNext=true}}

Since you need more fine grained control than noSwiping provides.

from ember-cli-swiper.

mattmcginnis avatar mattmcginnis commented on July 17, 2024

So then this scenario is not possible, correct?

Dynamically switch between these two conditions:

noSwiping is true only for "class1"
allowSwipeToNext is true (for classes other than "class1")
allowSwipeToPrev is false for all classes

noSwiping is false
allowSwipeToNext is true
allowSwipeToPrev is false

from ember-cli-swiper.

Matt-Jensen avatar Matt-Jensen commented on July 17, 2024

While it's entirely possible to provide all those options together, all I'm saying is it doesn't make any sense to me why someone would do so when you could just do:

{{!-- Disabled --}}
{{swiper-container  allowSwipeToPrev=false  allowSwipeToNext=false}}
{{!-- Enabled --}}
{{swiper-container  allowSwipeToPrev=true  allowSwipeToNext=true}}

Whereas when you do:

{{swiper-container noSwiping=true  allowSwipeToPrev=true  allowSwipeToNext=true}}

You're basically saying: "The slider can swipe left and right... and swiping is disabled" those 2 instructions are obviously in conflict and which instruction wins is 100% up to how Swiper.js implements it and has nothing to do with this addon. This why I want us to stop using them together so we can get to the bug you've reported: that computed properties are not updating the container.

from ember-cli-swiper.

mattmcginnis avatar mattmcginnis commented on July 17, 2024

What I thought I could say is "Allow swiping for all classes except X". It seems this is not true.

from ember-cli-swiper.

Matt-Jensen avatar Matt-Jensen commented on July 17, 2024

Fair enough, I'm going to close this for now. If you find that computed properties are not updating the swiper-container please feel free to reopen the issue.

from ember-cli-swiper.

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.