Fancy Flutter Alert Dialog
To show custom alert Dialog, a flutter Package completely supports you in performing this. In addition, you can totally choose between two themes, ‘Fancy’ and ‘Flat’ for your own.
At present, the package is available in fancy_dialog.
Usage
Import the Package
add this dependencies to your appdependencies: fancy_dialog: ^1.0.1
Use the Package
add this import statementimport 'package:fancy_dialog/fancy_dialog.dart';
to show a Basic Dialog
showDialog(
context: context,
builder: (BuildContext context) => FancyDialog(
title: "Fancy Gif Dialog",
descreption: "This is descreption for fancy gif,you can load any image or gif to be displayed :), and you can choose between two themes Fancy and Flat",
)
)
},
the title
and descreption
are required
and the rest of the parameters are :
okFun
: the function to be called when the user press Ok button (positive button)cancelFun
: the function to be called when the user press cancel button (negative button)cancelColor
: the color of the negative button, by default it’sColors.grey
oklColor
: the color of the positive button, by default it’sColors.pink
ok
: the text of the positive button, by default it’s ‘OK !’cancel
: the text of the negative button, by default it’s ‘cancel’animationType
: The type of the animation, there are 4 types,which are :FancyAnimation.LEFT_RIGHT
the default oneFancyAnimation.RIGHT_LEFT
FancyAnimation.TOP_BOTTOM
FancyAnimation.BOTTOM_TOP
gifpath
: the path for the image or the GIF to be displayed,or you can choose between 6 Gifs the package provides :FancyGif.MOVE_FORWARD
the default oneFancyGif.CHECK_MAIL
FancyGif.FUNNY_MAN
FancyGif.PLAY_MEDIA
FancyGif.SUBMIT
FancyGif.SHARE
theme
: Fancy or FlatFancyTheme.FANCY
FancyTheme.FLAT
The dialog will be dismissed by default when the user clicks Ok or cancel, DON’T ADDNavigator.of(context).pop()
to okFun
or cancelFun




GitHub
https://github.com/DokkarRachidReda/Fancy-Flutter-Alert-Dialog