-
Notifications
You must be signed in to change notification settings - Fork 29.8k
Closed
Labels
P2Important issues not at the top of the work listImportant issues not at the top of the work listc: regressionIt was better in the past than it is nowIt was better in the past than it is nowf: material designflutter/packages/flutter/material repository.flutter/packages/flutter/material repository.f: scrollingViewports, list views, slivers, etc.Viewports, list views, slivers, etc.found in release: 3.38Found to occur in 3.38Found to occur in 3.38found in release: 3.39Found to occur in 3.39Found to occur in 3.39frameworkflutter/packages/flutter repository. See also f: labels.flutter/packages/flutter repository. See also f: labels.has reproducible stepsThe issue has been confirmed reproducible and is ready to work onThe issue has been confirmed reproducible and is ready to work onr: fixedIssue is closed as already fixed in a newer versionIssue is closed as already fixed in a newer versionteam-frameworkOwned by Framework teamOwned by Framework teamtriaged-frameworkTriaged by Framework teamTriaged by Framework team
Description
Steps to reproduce
Summary
In Flutter 3.38.x, a SliverMainAxisGroup containing nested SliverMainAxisGroups with SliverPersistentHeader(pinned: true) stops pushing the previous header out of view. The new header “dives under” the
previous one instead of replacing it. The same layout works correctly on 3.35.x and earlier.
Environment
- Flutter: 3.38.3 (stable) — bug reproduces
- Flutter: 3.35.7 (stable) — works as expected
- Dart: 3.10.1 (3.38), 3.8.x (3.35)
- Platform tested: iOS Simulator (iPhone 16 Pro)
Minimal reproduction
DartPad repro: [paste the DartPad link here]
Key structure:
CustomScrollView- outer
SliverMainAxisGroupSliverPersistentHeader(pinned: true)for Year A- inner
SliverMainAxisGroupSliverPersistentHeader(pinned: true)for Month a1SliverListSliverPersistentHeader(pinned: true)for Month a2SliverList
- Next year section follows.
Steps to reproduce
- Run the DartPad sample on Flutter 3.38.3 (stable).
- Scroll so Month A1 content scrolls away and Month A2 header should replace it.
- Observe that the incoming header overlaps/slots under the previous header instead of pushing it off.
- Repeat on Flutter 3.35.7 — headers push off correctly.
Videos
- 3.38.3 (bug):
3.38.mov
- 3.35.7 (correct):
3.35.mov
Additional notes
- Tried replacing
SliverPersistentHeaderwithPinnedHeaderSliver; the overlap still occurs on 3.38.x. - ScrollOffsetCorrection changes and PinnedHeaderSliver fixes in 3.38 were suspected, since the regression is only between 3.35.x → 3.38.x.
Expected results
Expected behavior
When a new pinned header enters, it should push the previous pinned header off-screen (standard sticky behavior).
Actual results
Actual behavior
On 3.38.x, the new header overlaps/overdraws the previous header; it does not push it away.
Code sample
https://dartpad.dev/bc460238c9a5abd2802f9d3a1daaf4fe
Screenshots or Video
Screenshots / Video demonstration
[Upload media here]
Logs
Logs
[Paste your logs here]Flutter Doctor output
Doctor output
[Paste your output here]Metadata
Metadata
Assignees
Labels
P2Important issues not at the top of the work listImportant issues not at the top of the work listc: regressionIt was better in the past than it is nowIt was better in the past than it is nowf: material designflutter/packages/flutter/material repository.flutter/packages/flutter/material repository.f: scrollingViewports, list views, slivers, etc.Viewports, list views, slivers, etc.found in release: 3.38Found to occur in 3.38Found to occur in 3.38found in release: 3.39Found to occur in 3.39Found to occur in 3.39frameworkflutter/packages/flutter repository. See also f: labels.flutter/packages/flutter repository. See also f: labels.has reproducible stepsThe issue has been confirmed reproducible and is ready to work onThe issue has been confirmed reproducible and is ready to work onr: fixedIssue is closed as already fixed in a newer versionIssue is closed as already fixed in a newer versionteam-frameworkOwned by Framework teamOwned by Framework teamtriaged-frameworkTriaged by Framework teamTriaged by Framework team