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

Pages length miscalculation #1247

@zofoklecja

Description

@zofoklecja

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions