bqworks / accordion-slider-js

Modular accordion slider written in Vanilla JavaScript.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Open panel after swipe

hog-seruj opened this issue · comments

Is it possible to open the next panel event we have navigation?

There is a pageScrollComplete event that is triggered after the swipe or other page navigation methods.

Yes but for example: We display 3 items per page. The second item is active and on swipe, I need the open the third item.

Do you want to change the swiping functionality so that it opens the next panel instead of scrolling to the next page?

I tried that. But it doesn't work.

I'm not sure if I understand the functionality you're trying to achieve? Is it what I mentioned above?

On swipe, I need open the next panel, not the next page. I should display 3 items on the screen. When I swipe I need open panels one by one. By default on swipe, we got to the next page.

This is not possible. You would have to modify the touch-swipe add-on, so that:

  1. the panels are not dragged when you swipe
  2. when you release the swipe, the panel navigation is used instead of the page navigation

It's not too hard to achieve. Maybe you can create a new add-on by duplicating the current touch-swipe and add the above modifications.