IconicaAlertDialog.multiButton constructor

IconicaAlertDialog.multiButton(
  1. {required String title,
  2. required String body,
  3. required List<AlertDialogAction> buttons,
  4. bool? closeButton,
  5. ButtonCallback? primaryButton,
  6. ButtonCallback? secondaryButton,
  7. IconButtonCallback? iconButton}
)

Implementation

factory IconicaAlertDialog.multiButton({
  required String title,
  required String body,
  required List<AlertDialogAction> buttons,
  bool? closeButton,
  ButtonCallback? primaryButton,
  ButtonCallback? secondaryButton,
  IconButtonCallback? iconButton,
}) =>
    IconicaAlertDialog._(
      primaryButton: primaryButton,
      secondaryButton: secondaryButton,
      iconButton: iconButton,
      closeButton: closeButton,
      buttons: buttons,
      body: (context) => Column(
        children: [
          Padding(
            padding: const EdgeInsets.symmetric(
              horizontal: 20,
            ),
            child: Text(
              title,
              style: Theme.of(context).textTheme.titleLarge?.copyWith(
                    fontWeight: FontWeight.bold,
                    color: Theme.of(context).textTheme.bodyMedium?.color,
                  ),
              textAlign: TextAlign.center,
            ),
          ),
          Padding(
            padding: const EdgeInsets.only(top: 20, left: 20, right: 20),
            child: Text(
              body,
              style: Theme.of(context).textTheme.bodyMedium,
              textAlign: TextAlign.center,
            ),
          ),
        ],
      ),
    );