ArcaneGrid<E extends Object> constructor

const ArcaneGrid<E extends Object>({
  1. Key? key,
  2. required List<E> items,
  3. required ReorderableItemBuilder<Widget, E> itemBuilder,
  4. required SliverGridDelegate sliverGridDelegate,
  5. ReorderCallback? onReorder,
  6. List<AnimationEffect>? enterTransition,
  7. List<AnimationEffect>? exitTransition,
  8. Duration? insertDuration,
  9. Duration? removeDuration,
  10. void onReorderStart(
    1. int
    )?,
  11. void onReorderEnd(
    1. int
    )?,
  12. ReorderItemProxyDecorator? proxyDecorator,
  13. EdgeInsetsGeometry? padding,
  14. Axis scrollDirection = Axis.vertical,
  15. bool longPressDraggable = true,
  16. AnimatedWidgetBuilder<Widget, dynamic>? insertItemBuilder,
  17. AnimatedWidgetBuilder<Widget, dynamic>? removeItemBuilder,
  18. required bool isSameItem(
    1. E a,
    2. E b
    ),
  19. Duration dragStartDelay = const Duration(milliseconds: 500),
  20. List<E> nonDraggableItems = const [],
  21. List<E> lockedItems = const [],
  22. bool enableSwap = true,
})

Creates a ArcaneGrid that enables users to interactively reorder items through dragging, with animated insertion and removal of items.

Implementation

const ArcaneGrid(
    {Key? key,
    required this.items,
    required this.itemBuilder,
    required this.sliverGridDelegate,
    this.onReorder,
    this.enterTransition,
    this.exitTransition,
    this.insertDuration,
    this.removeDuration,
    this.onReorderStart,
    this.onReorderEnd,
    this.proxyDecorator,
    this.padding,
    this.scrollDirection = Axis.vertical,
    this.longPressDraggable = true,
    this.insertItemBuilder,
    this.removeItemBuilder,
    required this.isSameItem,
    this.dragStartDelay = const Duration(milliseconds: 500),
    this.nonDraggableItems = const [],
    this.lockedItems = const [],
    this.enableSwap = true})
    : super(key: key);