top-snackbar-flutter
top-snackbar-flutter copied to clipboard
onTap doesn't work when using onSwipe
I want to let the user to select to tap on the snackBar to go to the main screen, or just dismiss it by swipe, but it doesn't work, the onTap function is working only if i'm not using DismissType.onSwipe
showTopSnackBar( Overlay.of(context), Container(child: Text('Text')), curve: Curves.fastLinearToSlowEaseIn, dismissDirection: [DismissDirection.up, DismissDirection.horizontal], dismissType: DismissType.onSwipe, <----------------- when comment it, the goToMainScreen() is working onTap: () => goToMainScreen(context), );