mirror of
https://github.com/Dr-Blank/Vaani.git
synced 2025-12-06 11:09:28 +00:00
33 lines
901 B
Dart
33 lines
901 B
Dart
|
|
import 'package:flutter/material.dart';
|
||
|
|
import 'package:flutter_hooks/flutter_hooks.dart';
|
||
|
|
import 'package:hooks_riverpod/hooks_riverpod.dart';
|
||
|
|
|
||
|
|
class AppNavigation extends HookConsumerWidget {
|
||
|
|
const AppNavigation({super.key});
|
||
|
|
|
||
|
|
@override
|
||
|
|
Widget build(BuildContext context, WidgetRef ref) {
|
||
|
|
final currentIndex = useState(0);
|
||
|
|
return Scaffold(
|
||
|
|
bottomNavigationBar: BottomNavigationBar(
|
||
|
|
currentIndex: currentIndex.value,
|
||
|
|
onTap: (value) => currentIndex.value = value,
|
||
|
|
items: const [
|
||
|
|
BottomNavigationBarItem(
|
||
|
|
icon: Icon(Icons.home),
|
||
|
|
label: 'Home',
|
||
|
|
),
|
||
|
|
BottomNavigationBarItem(
|
||
|
|
icon: Icon(Icons.business),
|
||
|
|
label: 'Business',
|
||
|
|
),
|
||
|
|
BottomNavigationBarItem(
|
||
|
|
icon: Icon(Icons.school),
|
||
|
|
label: 'School',
|
||
|
|
),
|
||
|
|
],
|
||
|
|
),
|
||
|
|
);
|
||
|
|
}
|
||
|
|
}
|