vgkappBar function
Implementation
Widget vgkappBar(String title, double size, String appId, String description,
String primaryColor) {
return SizedBox(
height: AppBar().preferredSize.height,
child: Container(
decoration: BoxDecoration(color: VgkProGamingTheme.white),
child: Row(
mainAxisAlignment: MainAxisAlignment.center,
children: <Widget>[
Expanded(
child: Center(
child: Padding(
padding: const EdgeInsets.only(top: 4, left: 60),
child: Text(
title,
style: size >= 375
? VgkProGamingTheme.h1(primaryColor)
: VgkProGamingTheme.h3(primaryColor),
),
),
),
),
SizedBox(
width: AppBar().preferredSize.height + 40,
height: AppBar().preferredSize.height,
child: Row(
crossAxisAlignment: CrossAxisAlignment.center,
mainAxisAlignment: MainAxisAlignment.end,
children: <Widget>[
Material(
color: Colors.white,
child: InkWell(
borderRadius: const BorderRadius.all(
Radius.circular(32.0),
),
onTap: () {
LaunchReview.launch(
androidAppId: appId,
);
},
child: Padding(
padding: const EdgeInsets.all(8.0),
child: Icon(
Icons.rate_review,
color: HexColor(primaryColor),
),
),
),
),
Material(
color: Colors.transparent,
child: InkWell(
borderRadius: const BorderRadius.all(
Radius.circular(32.0),
),
onTap: () {
Share.share(description);
},
child: Padding(
padding: const EdgeInsets.all(8.0),
child: Icon(
Icons.share,
color: HexColor(primaryColor),
),
),
),
),
],
),
),
],
),
),
);
}