diff --git a/assets/images/svgs/bottom_nav/qr reader-active.svg b/assets/images/svgs/bottom_nav/reader-active.svg similarity index 100% rename from assets/images/svgs/bottom_nav/qr reader-active.svg rename to assets/images/svgs/bottom_nav/reader-active.svg diff --git a/assets/images/svgs/bottom_nav/Dr reply-active.svg b/assets/images/svgs/bottom_nav/reply-active.svg similarity index 100% rename from assets/images/svgs/bottom_nav/Dr reply-active.svg rename to assets/images/svgs/bottom_nav/reply-active.svg diff --git a/lib/widgets/shared/bottom_nav_bar.dart b/lib/widgets/shared/bottom_nav_bar.dart index 16988d82..bcce6818 100644 --- a/lib/widgets/shared/bottom_nav_bar.dart +++ b/lib/widgets/shared/bottom_nav_bar.dart @@ -50,6 +50,7 @@ class _BottomNavBarState extends State { BottomNavigationItem( icon: DoctorApp.home_1, activeIcon: DoctorApp.home_active_1, + svgPath: "assets/images/svgs/bottom_nav/home-active.svg", changeIndex: _changeIndex, index: widget.index, currentIndex: 0, @@ -59,6 +60,7 @@ class _BottomNavBarState extends State { BottomNavigationItem( icon: DoctorApp.schedule_1, activeIcon: DoctorApp.schedule_active_1, + svgPath: "assets/images/svgs/bottom_nav/schedule-active.svg", changeIndex: _changeIndex, index: widget.index, currentIndex: 1, @@ -69,6 +71,7 @@ class _BottomNavBarState extends State { BottomNavigationItem( icon: DoctorApp.qr_reader, activeIcon: DoctorApp.qr_reader_active_1, + svgPath: "assets/images/svgs/bottom_nav/reader-active.svg", changeIndex: _changeIndex, index: widget.index, currentIndex: 2, @@ -79,6 +82,7 @@ class _BottomNavBarState extends State { BottomNavigationItem( icon: DoctorApp.dr_reply_1, activeIcon: DoctorApp.dr_reply_active_1, + svgPath: "assets/images/svgs/bottom_nav/reply-active.svg", changeIndex: _changeIndex, index: widget.index, currentIndex: 3, diff --git a/lib/widgets/shared/bottom_navigation_item.dart b/lib/widgets/shared/bottom_navigation_item.dart index 151855a0..7956eb1d 100644 --- a/lib/widgets/shared/bottom_navigation_item.dart +++ b/lib/widgets/shared/bottom_navigation_item.dart @@ -5,6 +5,7 @@ import 'package:doctor_app_flutter/core/viewModel/dashboard_view_model.dart'; import 'package:doctor_app_flutter/core/viewModel/doctor_replay_view_model.dart'; import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; +import 'package:flutter_svg/flutter_svg.dart'; import 'package:provider/provider.dart'; import '../../locator.dart'; @@ -17,6 +18,8 @@ class BottomNavigationItem extends StatelessWidget { final int currentIndex; final String name; final DashboardViewModel dashboardViewModel; + final String svgPath; + BottomNavigationItem( {this.icon, @@ -25,7 +28,7 @@ class BottomNavigationItem extends StatelessWidget { this.index, this.currentIndex, this.name, - this.dashboardViewModel}); + this.dashboardViewModel, this.svgPath}); @override Widget build(BuildContext context) { @@ -58,8 +61,9 @@ class BottomNavigationItem extends StatelessWidget { height: 15, ), Container( - child: Icon(currentIndex == index ? activeIcon : icon, - color: AppGlobal.appTextColor, size: 22.0), + child: SvgPicture.asset(svgPath,width: SizeConfig.widthMultiplier* (10), height:SizeConfig.getHeightMultiplier(height:SizeConfig.heightMultiplier * + (SizeConfig.isHeightVeryShort ? 10:SizeConfig.isHeightShort ?8.5 : 7) ) * 40, + ), ), SizedBox( height: 8,