Open nofalx opened 4 years ago
Hi @nofalx .
It seems everything is ok. I changed id
s in slidesStore
:
slidesStore = [
{
id: 'slide-0',
},
{
id: 'slide-1',
},
{
id: 'slide-2',
},
{
id: 'slide-3',
},
{
id: 'slide-4',
},
{
id: 'slide-5',
},
{
id: 'slide-6',
},
{
id: 'slide-7',
},
]
id: 'slide-0'
is the id
for the first slide that is in the array on position 0. The option startPosition
always shows the index of the slide in the slidesStore
. That is when I finished dragging and the slide with id slide-3
is in the center, startPosition = 3
. Yea this slide is 4th slide, but it's on index 3 in the array.
And I see the same thing is with your example. Of course, if I understood your explanation correctly.
Hi, thank you for this library.
I was using the events callback and it seems to be reporting the wrong center. The example case is as following:
you have 3 items per page
and in template:
if we
console.log
the event fromcarouselChanged
you will notice that the center and start index are correct, after first scroll you will get the same output, then if you scroll again the index will start moving but lagging 1 position behindangular version ngx-owl:
"^3.0.0"
Thank you