ExSwipe constructor
const
ExSwipe({
- required Widget child,
- Key? key,
- GestureDragUpdateCallback? onRightSwipe,
- GestureDragUpdateCallback? onLeftSwipe,
- IconData iconOnRightSwipe = Icons.reply,
- Widget? rightSwipeWidget,
- IconData iconOnLeftSwipe = Icons.reply,
- Widget? leftSwipeWidget,
- double iconSize = 26.0,
- Color? iconColor,
- Duration animationDuration = const Duration(milliseconds: 150),
- double offsetDx = 0.3,
- int swipeSensitivity = 5,
Implementation
const ExSwipe({
required this.child,
super.key,
this.onRightSwipe,
this.onLeftSwipe,
this.iconOnRightSwipe = Icons.reply,
this.rightSwipeWidget,
this.iconOnLeftSwipe = Icons.reply,
this.leftSwipeWidget,
this.iconSize = 26.0,
this.iconColor,
this.animationDuration = const Duration(milliseconds: 150),
this.offsetDx = 0.3,
this.swipeSensitivity = 5,
}) : assert(
swipeSensitivity >= 5 && swipeSensitivity <= 35,
'swipeSensitivity value must be between 5 to 35',
);