Skip to content

Scrollable.ensureVisible(context) broken due to incorrect childScrollOffset() #59

@spkersten

Description

@spkersten

When using Scrollable.ensureVisible(context) on a child of SliverStickyHeader with overlapsContent: true, the Scrollable scrolls to the wrong position.

The problem appears to be in childScrollOffset (https://github.com/letsar/flutter_sticky_header/blob/master/lib/src/rendering/sliver_sticky_header.dart#L346) which returns _headerExtent even with overlapping headers. I think that should be headerLogicalExtent (= overlapsContent ? 0.0 : _headerExtent).

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions