AppDialog class Null safety

Constructors

AppDialog({required BuildContext context, DialogType dialogType = DialogType.INFO, Widget? customHeader, String? title, String? desc, Widget? body, Widget? btnOk, Widget? btnCancel, String? btnOkText, IconData? btnOkIcon, Function? btnOkOnPress, Color? btnOkColor, String? btnCancelText, IconData? btnCancelIcon, Function? btnCancelOnPress, Color? btnCancelColor, Function? onDismissCallback, bool isDense = false, bool dismissOnTouchOutside = true, bool headerAnimationLoop = true, AlignmentGeometry alignment = Alignment.center, AnimType animType = AnimType.SCALE, Duration? animDuration, EdgeInsetsGeometry? padding, bool useRootNavigator = false, Duration? autoHide, bool keyboardAware = true, bool dismissOnBackKeyPress = true, double? width, BorderRadiusGeometry? buttonsBorderRadius, bool showCloseIcon = false, Widget? closeIcon, Color? dialogBackgroundColor, BorderRadius? backgroundBorderRadius, BorderSide? borderSide, TextStyle? buttonsTextStyle, bool noVerticalMargin = false})

Properties

alignment AlignmentGeometry
Alignment of the Dialog
final
animDuration Duration?
Custom duration for dialog animation
final
animType AnimType
Anim Type can be { SCALE, LEFT_SLIDE, RIGHT_SLIDE, BOTTOM_SLIDE, TOP_SLIDE, SMOOTH_SCALE }
final
autoHide Duration?
For Auto Hide Dialog after some Duration.
final
backgroundBorderRadius BorderRadius?
Changes the BorderRadius of the dialog background
final
body Widget?
Create your own Widget for body, if this property is set title and description will be ignored.
final
borderSide BorderSide?
Set BorderSide of DialogShape
final
btnCancel Widget?
Custom Btn Cancel
final
btnCancelColor Color?
final
btnCancelIcon IconData?
final
btnCancelOnPress Function?
final
btnCancelText String?
Btn Cancel props
final
btnOk Widget?
Custom Btn OK
final
btnOkColor Color?
final
btnOkIcon IconData?
final
btnOkOnPress Function?
final
btnOkText String?
Btn OK props
final
buttonsBorderRadius BorderRadiusGeometry?
Border Radius for built in buttons.
final
buttonsTextStyle TextStyle?
TextStyle for built in buttons.
final
closeIcon Widget?
Custom closeIcon.
final
context BuildContext
@required
final
customHeader Widget?
Widget with priority over DialogType, for a custom header widget
final
desc String?
Set the description text of the dialog.
final
dialogBackgroundColor Color?
Custom background color for dialog + header
final
dialogType DialogType
Dialog Type can be INFO, WARNING, ERROR, SUCCESS, NO_HEADER
final
dismissOnBackKeyPress bool
Control if Dialog is dismiss by back key.
final
dismissOnTouchOutside bool
Barrier Dismissible
final
hashCode int
The hash code for this object.
read-onlyinherited
headerAnimationLoop bool
Whenever the animation Header loops or not.
final
isDense bool
This Prop is useful to Take advantage of screen dimensions
final
isDismissedBySystem bool
read / write
keyboardAware bool
Control if add or not the Padding EdgeInsets.only(bottom: MediaQuery.of(context).viewInsets.bottom).
final
noVerticalMargin bool
Set zero margin of dialog if true
final
onDismissCallback Function?
Callback to execute after dialog get dismissed
final
padding EdgeInsetsGeometry?
Padding off inner content of Dialog
final
runtimeType Type
A representation of the runtime type of the object.
read-onlyinherited
showCloseIcon bool
Control if close icon is appear.
final
title String?
Dialog Title
final
useRootNavigator bool
To use the RootNavigator
final
width double?
Max with of entire Dialog.
final

Methods

dismiss() → dynamic
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed.
inherited
show() Future
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited