// ignore_for_file: prefer_typing_uninitialized_variables, library_private_types_in_public_api

import 'package:flutter/material.dart';

class NotificationDynamicDialog extends StatefulWidget {
  final title;
  final body;
  const NotificationDynamicDialog({super.key, this.title, this.body});
  @override
  _NotificationDynamicDialogState createState() =>
      _NotificationDynamicDialogState();
}

class _NotificationDynamicDialogState extends State<NotificationDynamicDialog> {
  @override
  Widget build(BuildContext context) {
    // You can change the UI as per
    // your requirement or choice
    return AlertDialog(
      title: Text(widget.title),
      actions: <Widget>[
        OutlinedButton.icon(
            label: const Text('Close'),
            onPressed: () {
              Navigator.pop(context);
            },
            icon: const Icon(Icons.close))
      ],
      content: Text(widget.body),
    );
  }
}
