flexibleDialog method

  1. @override
Widget flexibleDialog(
  1. AppModel app,
  2. BuildContext context, {
  3. Key? key,
  4. String? title,
  5. required Widget child,
  6. List<Widget>? buttons,
  7. bool? includeHeading,
  8. double? widthFraction,
})
override

Implementation

@override
Widget flexibleDialog(
  AppModel app,
  BuildContext context, {
  Key? key,
  String? title,
  required Widget child,
  List<Widget>? buttons,
  bool? includeHeading,
  double? widthFraction, // percentage of screen width
}) {
  return dialogHelper.build(
    app,
    context,
    width: widthFraction == null
        ? null
        : fullScreenWidth(context) * widthFraction,
    includeHeading: includeHeading,
    key: key,
    title: title,
    dialogButtonPosition: DialogButtonPosition.topRight,
    contents: child,
    buttons: buttons,
    dialogBackgroundColor:
        _style.monaStyleAttributesModel.dialogBackgroundColor,
    dialogSeperatorColor:
        _style.monaStyleAttributesModel.dialogSeperatorColor,
  );
}