2023-07-28 02:35:36 +00:00
|
|
|
import 'package:flutter/material.dart';
|
2023-09-01 03:22:48 +00:00
|
|
|
import 'package:unit2/theme-data.dart/colors.dart';
|
2023-07-28 02:35:36 +00:00
|
|
|
|
|
|
|
class CustomButton extends StatelessWidget {
|
|
|
|
final VoidCallback onPressed;
|
|
|
|
final Icon icon;
|
|
|
|
|
|
|
|
CustomButton({required this.onPressed, required this.icon});
|
|
|
|
|
|
|
|
@override
|
|
|
|
Widget build(BuildContext context) {
|
|
|
|
return ElevatedButton(
|
|
|
|
onPressed: onPressed,
|
|
|
|
style: ElevatedButton.styleFrom(
|
|
|
|
shape: const CircleBorder(),
|
|
|
|
padding: const EdgeInsets.all(30),
|
2023-09-01 03:22:48 +00:00
|
|
|
backgroundColor: primary,
|
2023-07-28 02:35:36 +00:00
|
|
|
foregroundColor: Colors.white,
|
|
|
|
),
|
|
|
|
child: icon,
|
|
|
|
);
|
|
|
|
}
|
|
|
|
}
|