Compare commits

2 Commits
Author SHA1 Message Date
Hamza-Ayed df1f487804 Update: 2026-07-06 04:23:43 2026-07-06 04:23:43 +03:00
Hamza-Ayed 32a6531613 Update: 2026-07-06 04:21:17 2026-07-06 04:21:17 +03:00
@@ -43,11 +43,14 @@ class NavigationView extends StatelessWidget {
builder: (_) => Stack( builder: (_) => Stack(
children: [ children: [
// ── 1. Map Layer ────────────────────────────────────────────── // ── 1. Map Layer ──────────────────────────────────────────────
IntaleqMap( Listener(
onPointerDown: (_) => c.onUserPanned(),
child: IntaleqMap(
apiKey: Env.mapSaasKey, apiKey: Env.mapSaasKey,
onMapCreated: c.onMapCreated, onMapCreated: c.onMapCreated,
onStyleLoaded: c.onStyleLoaded, onStyleLoaded: c.onStyleLoaded,
onLongPress: (latlng) => c.onMapLongPressed(Point(0, 0), latlng), onLongPress: (latlng) =>
c.onMapLongPressed(Point(0, 0), latlng),
onTap: (latlng) => c.onMapTapped(Point(0, 0), latlng), onTap: (latlng) => c.onMapTapped(Point(0, 0), latlng),
markers: c.markers, markers: c.markers,
polylines: c.polylines, polylines: c.polylines,
@@ -61,6 +64,7 @@ class NavigationView extends StatelessWidget {
zoom: 16.0), zoom: 16.0),
myLocationEnabled: false, myLocationEnabled: false,
), ),
),
// ── 2. Top UI (Explore Mode) ────────────────────────────────── // ── 2. Top UI (Explore Mode) ──────────────────────────────────
if (!c.isNavigating) _ExploreTopUI(controller: c), if (!c.isNavigating) _ExploreTopUI(controller: c),
@@ -89,10 +93,10 @@ class NavigationView extends StatelessWidget {
_LocationPickerOverlay(controller: c), _LocationPickerOverlay(controller: c),
// ── 10. Recenter Button ─────────────────────────────────────── // ── 10. Recenter Button ───────────────────────────────────────
if (!c.isCameraLocked && !c.isNavigating) if (!c.isCameraLocked)
Positioned( Positioned(
right: 16, right: 16,
bottom: 250, bottom: c.isNavigating ? 150 : 250,
child: _buildMapFAB( child: _buildMapFAB(
icon: Icons.my_location_rounded, icon: Icons.my_location_rounded,
onTap: () => c.relockCameraToUser(), onTap: () => c.relockCameraToUser(),
@@ -271,7 +275,8 @@ void _showMenuSheet(BuildContext context) {
mainAxisSize: MainAxisSize.min, mainAxisSize: MainAxisSize.min,
children: [ children: [
Container( Container(
width: 40, height: 4, width: 40,
height: 4,
decoration: BoxDecoration( decoration: BoxDecoration(
color: Colors.grey.withOpacity(0.3), color: Colors.grey.withOpacity(0.3),
borderRadius: BorderRadius.circular(2), borderRadius: BorderRadius.circular(2),
@@ -281,27 +286,42 @@ void _showMenuSheet(BuildContext context) {
_MenuTile( _MenuTile(
icon: Icons.settings_rounded, icon: Icons.settings_rounded,
label: isAr ? 'الإعدادات' : 'Settings', label: isAr ? 'الإعدادات' : 'Settings',
onTap: () { Get.back(); Get.to(() => const SettingPage()); }, onTap: () {
Get.back();
Get.to(() => const SettingPage());
},
), ),
_MenuTile( _MenuTile(
icon: Icons.account_balance_wallet_rounded, icon: Icons.account_balance_wallet_rounded,
label: isAr ? 'المحفظة' : 'Wallet', label: isAr ? 'المحفظة' : 'Wallet',
onTap: () { Get.back(); Get.toNamed('/wallet'); }, onTap: () {
Get.back();
Get.toNamed('/wallet');
},
), ),
_MenuTile( _MenuTile(
icon: Icons.history_rounded, icon: Icons.history_rounded,
label: isAr ? 'سجل الرحلات' : 'Trip History', label: isAr ? 'سجل الرحلات' : 'Trip History',
onTap: () { Get.back(); Get.to(() => const OrderHistory()); }, onTap: () {
Get.back();
Get.to(() => const OrderHistory());
},
), ),
_MenuTile( _MenuTile(
icon: Icons.headset_mic_rounded, icon: Icons.headset_mic_rounded,
label: isAr ? 'اتصل بنا' : 'Contact Us', label: isAr ? 'اتصل بنا' : 'Contact Us',
onTap: () { Get.back(); Get.toNamed('/contactSupport'); }, onTap: () {
Get.back();
Get.toNamed('/contactSupport');
},
), ),
_MenuTile( _MenuTile(
icon: Icons.info_outline_rounded, icon: Icons.info_outline_rounded,
label: isAr ? 'حول التطبيق' : 'About', label: isAr ? 'حول التطبيق' : 'About',
onTap: () { Get.back(); Get.to(() => const AboutPage()); }, onTap: () {
Get.back();
Get.to(() => const AboutPage());
},
), ),
const SizedBox(height: 12), const SizedBox(height: 12),
], ],
@@ -314,13 +334,15 @@ class _MenuTile extends StatelessWidget {
final IconData icon; final IconData icon;
final String label; final String label;
final VoidCallback onTap; final VoidCallback onTap;
const _MenuTile({required this.icon, required this.label, required this.onTap}); const _MenuTile(
{required this.icon, required this.label, required this.onTap});
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
return ListTile( return ListTile(
leading: Icon(icon, color: _kPrimary, size: 24), leading: Icon(icon, color: _kPrimary, size: 24),
title: Text(label, style: TextStyle(fontWeight: FontWeight.w600, color: _kOnSurface)), title: Text(label,
style: TextStyle(fontWeight: FontWeight.w600, color: _kOnSurface)),
trailing: const Icon(Icons.chevron_right_rounded, color: Colors.grey), trailing: const Icon(Icons.chevron_right_rounded, color: Colors.grey),
onTap: onTap, onTap: onTap,
); );