alerts UI fix (#539)
* fix alerts button UI * remove comments
Serhii committed
Oct 20, 2022 at 01:28 UTC
3a9c8be9ca1768492247f1c3b268161bdb65e116
1 file changed
+13
-23
lib/src/widgets/base_alert_dialog.dart
+13
-23
@@ -41,21 +41,18 @@ class BaseAlertDialog extends StatelessWidget {
41
}
42
43
Widget actionButtons(BuildContext context) {
44
- return Row(
44
+ return Container(
45
+ height: 52,
46
+ child: Row(
47
mainAxisSize: MainAxisSize.max,
48
+ mainAxisAlignment: MainAxisAlignment.center,
49
children: <Widget>[
50
Flexible(
48
- child: Container(
49
- height: 52,
50
- padding: EdgeInsets.only(left: 6, right: 6),
51
- color: Theme.of(context).accentTextTheme!.bodyText1!.decorationColor!,
52
- child: ButtonTheme(
53
- minWidth: double.infinity,
51
+ child: Container(
52
+ width: double.infinity,
53
+ color: Theme.of(context).accentTextTheme!.bodyText1!.decorationColor!,
54
child: TextButton(
55
onPressed: actionLeft,
56
- // FIX-ME: Style
57
- //highlightColor: Colors.transparent,
58
- //splashColor: Colors.transparent,
56
child: Text(
57
leftActionButtonText,
58
textAlign: TextAlign.center,
@@ -68,24 +65,17 @@ class BaseAlertDialog extends StatelessWidget {
65
),
66
)),
67
),
71
- )),
68
+ ),
69
Container(
70
width: 1,
74
- height: 52,
71
color: Theme.of(context).dividerColor,
72
),
73
Flexible(
78
- child: Container(
79
- height: 52,
80
- padding: EdgeInsets.only(left: 6, right: 6),
81
- color: Theme.of(context).accentTextTheme!.bodyText2!.backgroundColor!,
82
- child: ButtonTheme(
83
- minWidth: double.infinity,
74
+ child: Container(
75
+ width: double.infinity,
76
+ color: Theme.of(context).accentTextTheme!.bodyText2!.backgroundColor!,
77
child: TextButton(
78
onPressed: actionRight,
86
- // FIX-ME: Style
87
- //highlightColor: Colors.transparent,
88
- //splashColor: Colors.transparent,
79
child: Text(
80
rightActionButtonText,
81
textAlign: TextAlign.center,
@@ -98,9 +88,9 @@ class BaseAlertDialog extends StatelessWidget {
88
),
89
)),
90
),
101
- )),
91
+ ),
92
],
103
- );
93
+ ));
94
}
95
96
@override