Skip to content

animate triggered not by the actual order change in a scrollable div #16508

@gwwo

Description

@gwwo

Describe the bug

When the items of a keyed each block are rendered in a scrollable div, and the div is scrolled down to the bottom. there's a fair chance that animate gets triggered for the items that changed their visual positions, rather than the items that changed its order.

While I can see where this is coming from ,the Svelte documentation clearly states that animate is triggered by changes in item order. I’d appreciate some clarification on this behavior. Thanks a lot!

Image Image

Reproduction

https://svelte.dev/playground/c88a25e3f1db420eb7e3d863c5daaf65?version=5.37.0

Actions: Scroll to the bottom of the list and click on the #6 block

Logs

System Info

playground

Severity

annoyance

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