Skip to content

Commit 5bb7883

Browse files
committed
feat: Update bottom navbar
1 parent 283dcc9 commit 5bb7883

File tree

3 files changed

+7
-49
lines changed

3 files changed

+7
-49
lines changed

lib/presentation/pages/scaffold_with_nav_bar.dart

Lines changed: 6 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ import 'package:rtu_mirea_app/presentation/app_notifier.dart';
77
import 'package:rtu_mirea_app/presentation/theme.dart';
88
import 'package:rtu_mirea_app/presentation/typography.dart';
99
import 'package:unicons/unicons.dart';
10-
import 'package:dot_navigation_bar/dot_navigation_bar.dart';
1110
import 'package:salomon_bottom_bar/salomon_bottom_bar.dart';
1211
import '../constants.dart';
1312

@@ -43,45 +42,13 @@ class ScaffoldWithNavBar extends StatelessWidget {
4342
body: Consumer<AppNotifier>(
4443
builder: (_, value, child) => navigationShell,
4544
),
46-
extendBody: true,
47-
bottomNavigationBar: DotNavigationBar(
48-
boxShadow: [
49-
BoxShadow(
50-
color: Colors.black.withOpacity(0.1),
51-
blurRadius: 8,
52-
),
53-
],
54-
marginR: const EdgeInsets.symmetric(horizontal: 16),
55-
paddingR:
56-
const EdgeInsets.only(bottom: 5, top: 7, right: 8, left: 8),
57-
backgroundColor: AppTheme.colors.background03,
58-
splashBorderRadius: 30,
59-
currentIndex: navigationShell.currentIndex,
60-
onTap: (index) => _setActiveIndex(index),
61-
items: [
62-
DotNavigationBarItem(
63-
icon: const Icon(Icons.library_books_rounded),
64-
selectedColor: AppTheme.colors.colorful02,
65-
),
66-
DotNavigationBarItem(
67-
icon: const Icon(Icons.calendar_today_rounded),
68-
selectedColor: AppTheme.colors.colorful03,
69-
),
70-
DotNavigationBarItem(
71-
icon: const Icon(Icons.widgets_rounded),
72-
selectedColor: AppTheme.colors.colorful04,
73-
),
74-
isDesktop
75-
? DotNavigationBarItem(
76-
icon: const Icon(UniconsLine.info_circle),
77-
selectedColor: AppTheme.colors.colorful06,
78-
)
79-
: DotNavigationBarItem(
80-
icon: const Icon(Icons.person),
81-
selectedColor: AppTheme.colors.colorful06,
45+
bottomNavigationBar:
46+
navigationShell.route.toString().contains('home')
47+
? null
48+
: AppBottomNavigationBar(
49+
index: navigationShell.currentIndex,
50+
onClick: (index) => _setActiveIndex(index),
8251
),
83-
],
84-
),
8552
);
8653
}
8754
},

pubspec.lock

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -375,14 +375,6 @@ packages:
375375
url: "https://pub.dev"
376376
source: hosted
377377
version: "1.0.2"
378-
dot_navigation_bar:
379-
dependency: "direct main"
380-
description:
381-
name: dot_navigation_bar
382-
sha256: "753e1d91644e39beddd0a4ed7e366f37a95e38cafb601c3b7496120ae0532f63"
383-
url: "https://pub.dev"
384-
source: hosted
385-
version: "1.0.2"
386378
equatable:
387379
dependency: "direct main"
388380
description:

pubspec.yaml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ publish_to: 'none'
1212
# In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion.
1313
# Read more about iOS versioning at
1414
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
15-
version: 1.4.2+54
15+
version: 1.4.2+55
1616

1717
environment:
1818
sdk: ">=3.1.1"
@@ -46,7 +46,6 @@ dependencies:
4646
hydrated_bloc: ^9.1.2
4747

4848
bloc_concurrency: ^0.2.2
49-
dot_navigation_bar: ^1.0.2
5049

5150
# A wrapper around InheritedWidget to make them easier to use and more reusable.
5251
# See https://pub.dev/packages/provider

0 commit comments

Comments
 (0)