Files
rasadyar_application/packages/livestock/lib/presentation/page/root/view.dart
2025-05-21 14:43:26 +03:30

47 lines
1.3 KiB
Dart

import 'package:flutter/material.dart';
import 'package:rasadyar_core/core.dart';
import 'logic.dart';
class RootPage extends GetView<RootLogic> {
const RootPage({super.key});
@override
Widget build(BuildContext context) {
return ObxValue((currentIndex) {
return Scaffold(
body: IndexedStack(
children: controller.pages,
index: currentIndex.value,
sizing: StackFit.expand,
),
bottomNavigationBar: BottomNavigation1(
items: [
BottomNavigation1Item(
icon: Assets.vec.filterSvg.path,
label: 'درخواست‌ها',
isSelected: currentIndex.value == 0,
onTap: () => controller.changePage(0),
),
BottomNavigation1Item(
icon: Assets.vec.mapSvg.path,
label: 'نقشه',
isSelected: currentIndex.value == 1,
onTap: () => controller.changePage(1),
),
BottomNavigation1Item(
icon: Assets.vec.profileUserSvg.path,
label: 'پروفایل',
isSelected: currentIndex.value == 2,
onTap: () => controller.changePage(2),
),
],
),
);
}, controller.currentIndex);
}
}