You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
PatientApp-KKUMC/lib/widgets/pharmacy/bottom_nav_pharmacy_bar.dart

111 lines
3.4 KiB
Dart

import 'package:diplomaticquarterapp/pages/landing/home_page.dart';
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
import 'package:eva_icons_flutter/eva_icons_flutter.dart';
import 'package:flutter/material.dart';
import 'bottom_nav_pharmacy_home_item.dart';
import 'bottom_nav_pharmacy_item.dart';
class BottomNavPharmacyBar extends StatefulWidget {
final ValueChanged<int> changeIndex;
final int index;
BottomNavPharmacyBar({Key key, this.changeIndex, this.index})
: super(key: key);
@override
_BottomNavPharmacyBarState createState() => _BottomNavPharmacyBarState();
}
class _BottomNavPharmacyBarState extends State<BottomNavPharmacyBar> {
int _index = 0;
_changeIndex(int index) {
widget.changeIndex(index);
}
@override
Widget build(BuildContext context) {
return BottomAppBar(
elevation: 4,
shape: CircularNotchedRectangle(),
color: Colors.white,
child: Padding(
padding: EdgeInsets.symmetric(horizontal: 18),
child: Row(
mainAxisSize: MainAxisSize.max,
mainAxisAlignment: MainAxisAlignment.spaceAround,
children: [
BottomNavHomeItem(
icon: EvaIcons.image,
activeIcon: EvaIcons.image,
changeIndex: _changeIndex,
index: widget.index,
currentIndex: 0,
title: TranslationBase.of(context).Alhabibapp,
),
// Container(
// height: 65.0,
// child: Center(
// child: VerticalDivider(
// color: Colors.grey,
// thickness: 0.5,
// width: 0.3,
// indent: 25.5,
// ),
// ),
// ),
BottomNavPharmacyItem(
icon: EvaIcons.list,
activeIcon: EvaIcons.list,
changeIndex: _changeIndex,
index: widget.index,
currentIndex: 1,
title: TranslationBase.of(context).categorise,
),
// Expanded(
// child: SizedBox(
// height: 50,
// child: Column(
// mainAxisSize: MainAxisSize.min,
// mainAxisAlignment: MainAxisAlignment.center,
// children: <Widget>[
// SizedBox(height: 22),
// ],
// ),
// ),
// ),
// Added Calendar Icon to access book appointment flow
BottomNavPharmacyItem(
icon: EvaIcons.home,
activeIcon: EvaIcons.home,
changeIndex: _changeIndex,
index: widget.index,
currentIndex: 0,
isHome: true,
title: TranslationBase.of(context).home),
BottomNavPharmacyItem(
icon: EvaIcons.person,
activeIcon: EvaIcons.person,
changeIndex: _changeIndex,
index: widget.index,
currentIndex: 3,
title: TranslationBase.of(context).myAccount,
),
BottomNavPharmacyItem(
icon: EvaIcons.shoppingCartOutline,
activeIcon: EvaIcons.shoppingCartOutline,
changeIndex: _changeIndex,
index: widget.index,
currentIndex: 4,
title: TranslationBase.of(context).cart)
],
),
),
);
}
}