SliverVisibiltyDetector reports a SliverPersistentHeader as not visible when pinned
Opened this issue · 1 comments
Problem description
package: visibility_detector,
version: 0.4.0+2
SliverVisibiltyDetector reports a SliverPersistentHeader as not visible when its pinned at the topo of the CustomScrollView
Steps to reproduce
CustomScrollView(
slivers: [
SliverVisibilityDetector(
key: uniqueKey,
onVisibilityChanged: (visInfo) {
// visInfo.visibleFraction is 0 when header is pinned
},
sliver: SliverPersistentHeader(
delegate:
mySliverPersistentHeaderDelegate( ),
pinned: true,
),
),
//after persistentHeader
SliverList(),
],
),
A setup like this seems to make the problem reappaer on a different project
Expected behavior
I expect it to still be considered as visible since its stuck at the top of the ScrollView
Actual behavior
It doesnt detect the Sliver visible
Environment
Windows 10, Flutter 3.13.3
I wonder if this is what is making VisibilityDetector fail to recognise that widgets are underneath a pinned header?