appBar static method
Cretaes a customised Appbar
Implementation
static AppBar appBar(
final BuildContext context,
final String title,
final TextStyle appBarTitleTextStyle,
final Icon appBarIcon,
final Color appBarColor,
[final Function? handleBackPress]) {
return AppBar(
backgroundColor: appBarColor,
titleTextStyle: appBarTitleTextStyle,
leading: IconButton(
icon: appBarIcon,
onPressed: () => handleBackPress == null
? _goBackToPaymentScreen(context)
: handleBackPress(),
),
title: Text(title, style: appBarTitleTextStyle),
);
}