2023-02-14 12:57:06 +01:00
|
|
|
import 'package:flutter/material.dart';
|
|
|
|
|
|
|
|
class TimerButton extends StatelessWidget {
|
2023-02-14 14:02:26 +01:00
|
|
|
final VoidCallback onClicked;
|
2023-02-14 12:57:06 +01:00
|
|
|
final Icon icon;
|
|
|
|
final Color color;
|
|
|
|
|
2023-02-14 14:02:26 +01:00
|
|
|
const TimerButton(
|
|
|
|
{Key? key,
|
|
|
|
required this.onClicked,
|
|
|
|
required this.icon,
|
|
|
|
required this.color})
|
|
|
|
: super(key: key);
|
2023-02-14 12:57:06 +01:00
|
|
|
|
2023-02-14 14:13:32 +01:00
|
|
|
@override
|
2023-02-14 14:02:26 +01:00
|
|
|
Widget build(BuildContext context) {
|
2023-02-14 12:57:06 +01:00
|
|
|
return Column(
|
|
|
|
children: [
|
|
|
|
InkWell(
|
2023-02-14 14:13:32 +01:00
|
|
|
onTap: onClicked,
|
2023-02-14 12:57:06 +01:00
|
|
|
child: CircleAvatar(
|
|
|
|
backgroundColor: color,
|
|
|
|
radius: 50,
|
|
|
|
child: icon,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
],
|
|
|
|
);
|
|
|
|
}
|
2023-02-14 14:02:26 +01:00
|
|
|
}
|