dismiss method
Animate to dismiss the notification.
Implementation
@override
Future<void> dismiss() async {
final endValue = dragDistance.sign * _screenWidth;
currentAnimation = Tween(begin: dragDistance, end: endValue)
.chain(_defaultCurve)
.animate(this);
dragDistance = 0.0;
await forward(from: 0.0);
currentAnimation = null;
}