Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ BUG ] : AppinioSwiper cardBuilder's index parameter didnt return correct index for each of cards #265

Open
geryruslandi opened this issue Apr 6, 2024 · 0 comments
Assignees
Labels
Appinio swiper This label is used to indicate that this issue belongs to Appinio swiper plugin

Comments

@geryruslandi
Copy link

AppinioSwiper

Describe the bug
When cardBuilder function was called, it didn't pass the correct index on cardBuilder's second prop (which is for storing index).
for example, we have 5 items on the swiper widget, when cardBuilder is executed, the passed index is wrong.
card builder WILL be executed 5 times, I expect the index value for every interaction on card builder Iteration to be :

  • 0
  • 1
  • 2
  • 3
  • 4

instead, the passed index value will be:

  • 0
  • 1
  • 1
  • 1
  • 1

To Reproduce
Steps to reproduce the behavior:

  1. Create AppinioSwiper widget, for this example, try to render 5 items
  2. print the index value from cardBuilder prop

Expected behavior
For every of cardBuilder iteration, it should return correct index.
if current iteration is first iteration, index should be 0, if second index should be 1, and so on.

Screenshots
image

Desktop (please complete the following information):

  • OS: Kubuntu 23.10
  • Browser Firefox
  • Version 124.0.1

Smartphone (please complete the following information):

  • Device: Galaxy A54
  • OS: Samsung OneUI, Android 14
  • Browser Firefox
  • Version

Additional context
I need to render the bottom stacked card with correct color, with that, i need to have the correct index,
below is the goal of mine
image

Because of this issue, i cant get the correct card index, and because of this, the result of my stacked bottom card color become incorrect
image

@geryruslandi geryruslandi changed the title [ BUG ] : cardBuilder's index parameter didnt return correct index for each of cards [ BUG ] : AppinioSwiper cardBuilder's index parameter didnt return correct index for each of cards Apr 6, 2024
@khanmujeeb687 khanmujeeb687 added the Appinio swiper This label is used to indicate that this issue belongs to Appinio swiper plugin label Jul 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Appinio swiper This label is used to indicate that this issue belongs to Appinio swiper plugin
Projects
None yet
Development

No branches or pull requests

2 participants