AlertStyle class

Alert style class for reusable customization of dialogs.

Constructors

AlertStyle({AnimationType animationType = AnimationType.fromBottom, Duration animationDuration = const Duration(milliseconds: 200), ShapeBorder? alertBorder, bool isButtonVisible = true, bool isCloseButton = true, bool isOverlayTapDismiss = true, Color? backgroundColor, Color overlayColor = Colors.black87, TextStyle titleStyle = const TextStyle(color: Colors.black, fontWeight: FontWeight.w500, fontStyle: FontStyle.normal), TextAlign titleTextAlign = TextAlign.center, TextStyle descStyle = const TextStyle(color: Colors.black, fontWeight: FontWeight.w400, fontStyle: FontStyle.normal), TextAlign descTextAlign = TextAlign.center, EdgeInsets buttonAreaPadding = const EdgeInsets.all(20.0), BoxConstraints? constraints, ButtonsDirection buttonsDirection = ButtonsDirection.row, double? alertElevation, EdgeInsets alertPadding = defaultAlertPadding, AlignmentGeometry alertAlignment = Alignment.center, bool isTitleSelectable = false, bool isDescSelectable = false, EdgeInsets? titlePadding, EdgeInsets descPadding = const EdgeInsets.all(0.0)})
Alert style constructor function All properties are optional.
const

Properties

alertAlignment AlignmentGeometry
The alertAlignment parameter sets alert dialog alignment.
final
alertBorder ShapeBorder?
The alertBorder parameter sets border.
final
alertElevation double?
The alertElevation parameter sets elevation of alert dialog container.
final
alertPadding EdgeInsets
The alertPadding parameter sets alert area padding.
final
animationDuration Duration
The animationDuration parameter is used to set the animation transition time. Default: "200 ms"
final
animationType AnimationType
The animationType parameter is used for transitions. Default: "fromBottom"
final
backgroundColor Color?
The backgroundColor parameter sets the background color.
final
buttonAreaPadding EdgeInsets
The buttonAreaPadding parameter sets button area padding.
final
buttonsDirection ButtonsDirection
The buttonsDirection parameter sets button container as Row or Col.
final
constraints BoxConstraints?
The constraints parameter sets Alert size.
final
descPadding EdgeInsets
The descPadding parameter sets desc area padding.
final
descStyle TextStyle
The descStyle parameter sets alert desc text style.
final
descTextAlign TextAlign
The descTextAlign parameter sets alignment of the desc.
final
hashCode int
The hash code for this object.
no setterinherited
isButtonVisible bool
The isButtonVisible paramater is used to decide hide or display buttons
final
isCloseButton bool
The isCloseButton parameter sets visibility of the close button. Default: "true"
final
isDescSelectable bool
The isDescSelectable parameter sets desc text is selectable or not.
final
isOverlayTapDismiss bool
The isOverlayTapDismiss parameter sets closing the alert by clicking outside. Default: "true"
final
isTitleSelectable bool
The isTitleSelectable parameter sets title text is selectable or not.
final
overlayColor Color
The overlayColor parameter sets the background color of the outside. Default: "Color(0xDD000000)"
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
titlePadding EdgeInsets?
The titlePadding parameter sets title area padding.
final
titleStyle TextStyle
The titleStyle parameter sets alert title text style.
final
titleTextAlign TextAlign
The titleTextAlign parameter sets alignment of the title.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

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