FirestoreAnimatedStaggered<T> constructor

FirestoreAnimatedStaggered<T>({
  1. Key? key,
  2. required Query<T> query,
  3. required FirestoreAnimatedStaggeredItemBuilder<T> itemBuilder,
  4. required FirestoreStaggeredTileBuilder<T> staggeredTileBuilder,
  5. required int crossAxisCount,
  6. double mainAxisSpacing = 4.0,
  7. double crossAxisSpacing = 4.0,
  8. double childAspectRatio = 1.0,
  9. dynamic onLoaded(
    1. QuerySnapshot<T>
    )?,
  10. FilterCallback<T>? filter,
  11. Widget? defaultChild,
  12. Widget? errorChild,
  13. Widget? emptyChild,
  14. Axis scrollDirection = Axis.vertical,
  15. bool reverse = false,
  16. bool debug = false,
  17. bool linear = false,
  18. ScrollController? controller,
  19. bool? primary,
  20. ScrollPhysics? physics,
  21. bool shrinkWrap = false,
  22. EdgeInsets? padding,
  23. Duration duration = const Duration(milliseconds: 300),
})

Creates a scrolling container that animates items when they are inserted or removed.

Implementation

FirestoreAnimatedStaggered({
  Key? key,
  required this.query,
  required this.itemBuilder,
  required this.staggeredTileBuilder,
  required this.crossAxisCount,
  this.mainAxisSpacing = 4.0,
  this.crossAxisSpacing = 4.0,
  this.childAspectRatio = 1.0,
  this.onLoaded,
  this.filter,
  this.defaultChild,
  this.errorChild,
  this.emptyChild,
  this.scrollDirection = Axis.vertical,
  this.reverse = false,
  this.debug = false,
  this.linear = false,
  this.controller,
  this.primary,
  this.physics,
  this.shrinkWrap = false,
  this.padding,
  this.duration = const Duration(milliseconds: 300),
})  : assert(crossAxisCount > 0),
      assert(mainAxisSpacing >= 0),
      assert(crossAxisSpacing >= 0),
      assert(childAspectRatio > 0),
      super(key: key);