Merge branch 'development_sikander' into 'master'

Development sikander

See merge request mirza.shafique/mohem_flutter_app!45
faiz_marathon_signalR_critical
Sikander Saleem 2 years ago
commit 5efce66cfb

@ -323,68 +323,74 @@ class _DashboardScreenState extends State<DashboardScreen> {
drawer: SafeArea(
child: AppDrawer(),
),
bottomNavigationBar: BottomNavigationBar(
items: <BottomNavigationBarItem>[
BottomNavigationBarItem(
icon: Padding(
padding: const EdgeInsets.all(4.0),
child: SvgPicture.asset(
bottomNavigationBar: SizedBox(
height: 70,
child: BottomNavigationBar(
items: <BottomNavigationBarItem>[
BottomNavigationBarItem(
icon: SvgPicture.asset(
"assets/icons/home.svg",
width: 20,
height: 20,
),
color: currentIndex == 0 ? MyColors.grey3AColor : MyColors.grey98Color,
).paddingAll(4),
label: LocaleKeys.home.tr(),
),
label: LocaleKeys.home.tr(),
),
BottomNavigationBarItem(
icon: Padding(
padding: const EdgeInsets.all(4.0),
child: SvgPicture.asset(
BottomNavigationBarItem(
icon: SvgPicture.asset(
"assets/icons/create_req.svg",
width: 20,
height: 20,
),
color: currentIndex == 1 ? MyColors.grey3AColor : MyColors.grey98Color,
).paddingAll(4),
label: LocaleKeys.createRequest.tr(),
),
label: LocaleKeys.createRequest.tr(),
),
BottomNavigationBarItem(
icon: Padding(
padding: const EdgeInsets.all(4.0),
child: SvgPicture.asset(
"assets/icons/work_list.svg",
width: 20,
height: 20,
BottomNavigationBarItem(
icon: Stack(
alignment: Alignment.centerLeft,
children: [
SvgPicture.asset(
"assets/icons/work_list.svg",
color: currentIndex == 2 ? MyColors.grey3AColor : MyColors.grey98Color,
).paddingAll(4),
Consumer<DashboardProviderModel>(
builder: (cxt, data, child) {
if (data.workListCounter == 0) {
return const SizedBox();
}
return Positioned(
right: 0,
top: 0,
child: Container(
padding: const EdgeInsets.only(left: 4, right: 4),
alignment: Alignment.center,
decoration: BoxDecoration(color: MyColors.redColor, borderRadius: BorderRadius.circular(17)),
child: data.workListCounter.toString().toText10(color: Colors.white),
),
);
},
),
],
),
label: LocaleKeys.workList.tr(),
),
label: LocaleKeys.workList.tr(),
),
BottomNavigationBarItem(
icon: Padding(
padding: const EdgeInsets.all(4.0),
child: SvgPicture.asset(
BottomNavigationBarItem(
icon: SvgPicture.asset(
"assets/icons/item_for_sale.svg",
width: 20,
height: 20,
),
color: currentIndex == 3 ? MyColors.grey3AColor : MyColors.grey98Color,
).paddingAll(4),
label: LocaleKeys.itemsForSale.tr(),
),
label: LocaleKeys.itemsForSale.tr(),
),
],
currentIndex: currentIndex,
selectedLabelStyle: TextStyle(
fontSize: 8,
color: Color(0xff989898),
fontWeight: FontWeight.w600,
),
unselectedLabelStyle: TextStyle(
fontSize: 8,
color: Color(0xff989898),
fontWeight: FontWeight.w600,
],
currentIndex: currentIndex,
selectedLabelStyle: const TextStyle(fontSize: 10, color: MyColors.grey3AColor, fontWeight: FontWeight.w600),
unselectedLabelStyle: const TextStyle(fontSize: 10, color: MyColors.grey98Color, fontWeight: FontWeight.w600),
type: BottomNavigationBarType.fixed,
selectedItemColor: MyColors.grey3AColor,
backgroundColor: MyColors.backgroundColor,
selectedIconTheme: const IconThemeData(color: MyColors.grey3AColor, size: 28),
unselectedIconTheme: const IconThemeData(color: MyColors.grey98Color, size: 28),
onTap: (int index) {
currentIndex = index;
setState(() {});
},
),
type: BottomNavigationBarType.fixed,
selectedItemColor: Colors.black,
backgroundColor: Color(0xffF8F8F8),
onTap: (index) {},
),
);
}

Loading…
Cancel
Save