EdsonBueno / infinite_scroll_pagination

Flutter package to help you lazily load and display pages of items as the user scrolls down your screen.
https://pub.dev/packages/infinite_scroll_pagination
MIT License
623 stars 210 forks source link

feat: create PagedSliverMasonryGrid #224

Closed clragon closed 1 year ago

clragon commented 1 year ago

I added PagedSliverMasonryGrid and rewrote PagedMasonryGrid to use it internally. To facilitate this change, I moved _AppendedSliverGrid into its own file. SliverMasonryGrid is very similar to SliverGrid but not the same, so reusing this felt right. I imagine if we implement other wrappers around the new custom staggered grid view types, this will also come in handy. All tests pass as usual and I did not add new ones as PagedMasonrySliverGrid is tested through PagedMasonryGridView and I have seen that PagedSliverGrid does not have tests at the moment either. I have reverted PagedMasonryGridView to a BoxScrollView so that it is consistent with other paged sliver wrappers and can be used with pull_to_refresh.

(code based on provisional code for a masonry grid I added in my own repo)