Skip to content
This repository has been archived by the owner on Mar 27, 2019. It is now read-only.

Pages length miscalculation #1247

Open
zofoklecja opened this issue Aug 9, 2018 · 0 comments
Open

Pages length miscalculation #1247

zofoklecja opened this issue Aug 9, 2018 · 0 comments

Comments

@zofoklecja
Copy link

zofoklecja commented Aug 9, 2018

On smaller resolutions, every 4 pixels, I'm getting one too many pages when using iscroll.pages.length. As a result there is one too many navigation dots in the carousel. The last dot doesn't seem to do much (see attached gif)
iscroll caorusel pages bug
The issue seems to be related to position calculation, rounding in particular. Inspecting the position of selected items on affected resolutions shows that it increases by 0.5px with each slide:

> $0.position()
{top: 0, left: 0}
> $1.position()
{top: 0, left: 0.5}
> $2.position()
{top: 0, left: 1}

On unaffected resolution it alternates between 0 and 0.5 or stays 0

I'm using Chrome 68

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant