mirrored_repositories/firebase-chatapp/lib
import 'package:flutter/material.dart';

class CustomButton extends StatelessWidget {
  CustomButton({required this.text, required this.color, required this.onPressed});
  final String text;
  final Color color;
  final Function onPressed;

  @override
  Widget build(BuildContext context) {
    return  Padding(
              padding: EdgeInsets.symmetric(vertical: 16.0),
              child: Material(
                elevation: 5.0,
                color: color,
         
                borderRadius: BorderRadius.circular(30.0),
                child: MaterialButton(
                  textColor: Colors.white,
                  onPressed: () => onPressed(),
                  minWidth: 200.0,
                  height: 42.0,
                  child: Text(
                    text,
                  ),
                ),
              ),
            );
  }
}