PagedSliverAlignedGrid<PageKeyType, ItemType> class

A SliverAlignedGrid with pagination capabilities.

You can also see this as a PagedSliverGrid that ensures that the items in its rows all have the same size.

This is a wrapper around the SliverAlignedGrid from the flutter_staggered_grid_view package. For more info on how to build staggered grids, check out the referred package's documentation and examples.

Inheritance

Constructors

PagedSliverAlignedGrid({required PagedChildBuilderDelegate<PagingItem> builderDelegate, required SliverSimpleGridDelegateBuilder gridDelegateBuilder, double mainAxisSpacing = 0, double crossAxisSpacing = 0, bool addAutomaticKeepAlives = true, bool addRepaintBoundaries = true, bool addSemanticIndexes = true, bool showNewPageProgressIndicatorAsGridChild = true, bool showNewPageErrorIndicatorAsGridChild = true, bool showNoMoreItemsIndicatorAsGridChild = true, bool shrinkWrapFirstPageIndicators = false, required PagingDataController<dynamic, PagingItem> pagingDataController, PagedChildStatusBuilderDelegate<PagingItem>? statusBuilderDelegate, Key? key, bool? persistent, bool? forceUseInitData})
const
PagedSliverAlignedGrid.count({required PagedChildBuilderDelegate<PagingItem> builderDelegate, required int crossAxisCount, double mainAxisSpacing = 0, double crossAxisSpacing = 0, bool addAutomaticKeepAlives = true, bool addRepaintBoundaries = true, bool addSemanticIndexes = true, bool showNewPageProgressIndicatorAsGridChild = true, bool showNewPageErrorIndicatorAsGridChild = true, bool showNoMoreItemsIndicatorAsGridChild = true, bool shrinkWrapFirstPageIndicators = false, PagedChildStatusBuilderDelegate<PagingItem>? statusBuilderDelegate, Key? key, required PagingDataController<dynamic, PagingItem> pagingDataController, bool? persistent, bool? forceUseInitData})
PagedSliverAlignedGrid.extent({Key? key, required PagedChildBuilderDelegate<PagingItem> builderDelegate, required double maxCrossAxisExtent, double mainAxisSpacing = 0, double crossAxisSpacing = 0, bool addAutomaticKeepAlives = true, bool addRepaintBoundaries = true, bool addSemanticIndexes = true, bool showNewPageProgressIndicatorAsGridChild = true, bool showNewPageErrorIndicatorAsGridChild = true, bool showNoMoreItemsIndicatorAsGridChild = true, bool shrinkWrapFirstPageIndicators = false, PagedChildStatusBuilderDelegate<PagingItem>? statusBuilderDelegate, required PagingDataController<dynamic, PagingItem> pagingDataController, bool? persistent, bool? forceUseInitData})

Properties

addAutomaticKeepAlives bool
Matches SliverChildBuilderDelegate.addAutomaticKeepAlives.
final
addRepaintBoundaries bool
Matches SliverChildBuilderDelegate.addRepaintBoundaries.
final
addSemanticIndexes bool
Matches SliverChildBuilderDelegate.addSemanticIndexes.
final
builderDelegate PagedChildBuilderDelegate<PagingItem>
Matches PagedLayoutBuilder.builderDelegate.
final
crossAxisSpacing double
Matches SliverAlignedGrid.crossAxisSpacing.
final
forceUseInitData bool?
final
gridDelegateBuilder SliverSimpleGridDelegateBuilder
Provides the adjusted child count (based on the pagination status) so that a SliverSimpleGridDelegate can be returned.
final
hashCode int
The hash code for this object.
no setterinherited
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
mainAxisSpacing double
Matches SliverAlignedGrid.mainAxisSpacing.
final
pagingDataController PagingDataController<dynamic, PagingItem>
final
persistent bool?
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
showNewPageErrorIndicatorAsGridChild bool
Matches PagedSliverGrid.showNewPageErrorIndicatorAsGridChild.
final
showNewPageProgressIndicatorAsGridChild bool
Matches PagedSliverGrid.showNewPageProgressIndicatorAsGridChild.
final
showNoMoreItemsIndicatorAsGridChild bool
Matches PagedSliverGrid.showNoMoreItemsIndicatorAsGridChild.
final
shrinkWrapFirstPageIndicators bool
Matches PagedLayoutBuilder.shrinkWrapFirstPageIndicators.
final
statusBuilderDelegate PagedChildStatusBuilderDelegate<PagingItem>?
final

Methods

build(BuildContext context) Widget
Describes the part of the user interface represented by this widget.
override
createElement() StatelessElement
Creates a StatelessElement to manage this widget's location in the tree.
inherited
debugDescribeChildren() List<DiagnosticsNode>
Returns a list of DiagnosticsNode objects describing this node's children.
inherited
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) String
A string representation of this object.
inherited
toStringDeep({String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) String
Returns a string representation of this node and its descendants.
inherited
toStringShallow({String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) String
Returns a one-line detailed description of the object.
inherited
toStringShort() String
A short, textual description of this widget.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited