Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 13 additions & 1 deletion lib/grouped_list.dart
Original file line number Diff line number Diff line change
Expand Up @@ -386,7 +386,19 @@ class _GroupedListViewState<T, E> extends State<GroupedListView<T, E>> {
initialData: _topElementIndex,
builder: (context, snapshot) {
if (snapshot.hasData) {
return _showFixedGroupHeader(snapshot.data!);
return ListenableBuilder(
listenable: _controller,
builder: (context, child) {
final offset = _controller.offset;

return Padding(
padding:
EdgeInsets.only(top: offset < 0 ? offset.abs() : 0),
child: child,
);
},
child: _showFixedGroupHeader(snapshot.data!),
);
}
return const SizedBox.shrink();
}),
Expand Down