Skip to content

Jumping back during scroll when rows have different height #100

Closed
@arudnev

Description

@arudnev

If we take the chat demo and change it to generate / show rows of different height then when you try to scroll up slowly it will load and show older messages, but then will jump back to more recent ones, making it impossible to scroll up.

I've cloned ui-scroll repository, made couple of changes in styles (to have multi-line rows of different height) and changed generation of text for the chat items - http://rawgit.com/armortext/ui-scroll/master/demo/chat/chat.html

To reproduce scroll all the way up, then all the way down and up again, then around item 80 it will consistently start jumping back and forward while you are trying to scroll up, producing something like this in the console log:

index = -71; count = 10
index = -82; count = 10
index = -92; count = 10
index = -79; count = 10
index = -91; count = 10
index = -78; count = 10
index = -90; count = 10
index = -76; count = 10
index = -88; count = 10
index = -74; count = 10
index = -87; count = 10
index = -71; count = 10
index = -82; count = 10

It has similar behavior when you set minIndex / maxIndex on the datasource.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions