fix marker rendering & modernize riding widgets for dark mode - 2026-04-11

This commit is contained in:
Hamza-Ayed
2026-04-11 01:14:09 +03:00
parent 3f03f25142
commit 454276d1e0
88 changed files with 50376 additions and 23310 deletions

View File

@@ -36,7 +36,7 @@ class ContactUsPage extends StatelessWidget {
child: Image.asset('assets/images/logo.gif')),
IconButton(
onPressed: () async {
Get.put(TextToSpeechController()).speakText(
Get.find<TextToSpeechController>().speakText(
'Intaleq is the safest and most reliable ride-sharing app designed especially for passengers in Syria. We provide a comfortable, respectful, and affordable riding experience with features that prioritize your safety and convenience. Our trusted captains are verified, insured, and supported by regular car maintenance carried out by top engineers. We also offer on-road support services to make sure every trip is smooth and worry-free. With Intaleq, you enjoy quality, safety, and peace of mind—every time you ride.'
.tr);
},

View File

@@ -3,6 +3,7 @@ import 'package:flutter/material.dart';
import 'package:get/get.dart';
import '../../../constant/colors.dart';
import '../../../constant/style.dart';
import '../../../controller/home/profile/invit_controller.dart';
import '../../../print.dart';
@@ -12,16 +13,16 @@ class ShareAppPage extends StatelessWidget {
@override
Widget build(BuildContext context) {
return Scaffold(
backgroundColor: CupertinoColors.systemBackground,
backgroundColor: AppColor.secondaryColor,
appBar: AppBar(
backgroundColor: CupertinoColors.systemBackground,
backgroundColor: AppColor.secondaryColor,
elevation: 0,
title: Text(
'Invite'.tr,
style: const TextStyle(color: CupertinoColors.label),
style: AppStyle.headTitle2.copyWith(fontSize: 20),
),
leading: IconButton(
icon: const Icon(Icons.arrow_back_ios, color: AppColor.blueColor),
icon: Icon(Icons.arrow_back_ios, color: AppColor.cyanBlue),
onPressed: () => Get.back(),
),
),
@@ -51,7 +52,7 @@ class ShareAppPage extends StatelessWidget {
Container(
padding: const EdgeInsets.all(16),
decoration: BoxDecoration(
color: CupertinoColors.systemGrey6,
color: AppColor.grayColor.withOpacity(0.08),
borderRadius: BorderRadius.circular(12),
),
child: Column(
@@ -60,8 +61,8 @@ class ShareAppPage extends StatelessWidget {
"Share this code with your friends and earn rewards when they use it!"
.tr,
textAlign: TextAlign.center,
style: const TextStyle(
color: CupertinoColors.secondaryLabel,
style: TextStyle(
color: AppColor.grayColor,
fontSize: 13,
),
),
@@ -116,8 +117,9 @@ class ShareAppPage extends StatelessWidget {
Widget _buildPhoneInput() {
return Container(
decoration: BoxDecoration(
color: CupertinoColors.systemGrey6,
borderRadius: BorderRadius.circular(8),
color: AppColor.grayColor.withOpacity(0.1),
borderRadius: BorderRadius.circular(12),
border: Border.all(color: AppColor.grayColor.withOpacity(0.1)),
),
child: Row(
children: [
@@ -125,13 +127,16 @@ class ShareAppPage extends StatelessWidget {
child: CupertinoTextField.borderless(
controller: controller.invitePhoneController,
placeholder: 'Enter phone'.tr,
padding: const EdgeInsets.all(12),
placeholderStyle: TextStyle(
color: AppColor.grayColor.withOpacity(0.5), fontSize: 16),
style: TextStyle(color: AppColor.writeColor, fontSize: 16),
padding: const EdgeInsets.all(14),
keyboardType: TextInputType.phone,
),
),
CupertinoButton(
child: const Icon(CupertinoIcons.person_badge_plus,
color: AppColor.blueColor),
child: Icon(CupertinoIcons.person_badge_plus,
color: AppColor.cyanBlue),
onPressed: () async {
await controller.pickContacts();
Log.print('contacts: ${controller.contacts}');
@@ -169,16 +174,16 @@ class ShareAppPage extends StatelessWidget {
],
),
child: CupertinoButton(
color: AppColor.blueColor,
color: AppColor.primaryColor,
borderRadius: BorderRadius.circular(10),
padding: const EdgeInsets.symmetric(vertical: 14),
onPressed: controller.sendInviteToPassenger,
child: Text(
'Send Invite'.tr,
style: const TextStyle(
style: TextStyle(
fontSize: 16,
fontWeight: FontWeight.bold,
color: CupertinoColors.white,
color: AppColor.secondaryColor,
),
),
),
@@ -198,15 +203,15 @@ class ShareAppPage extends StatelessWidget {
],
),
child: CupertinoButton(
color: AppColor.blueColor,
color: AppColor.cyanBlue,
borderRadius: BorderRadius.circular(10),
padding: const EdgeInsets.symmetric(vertical: 14),
child: Text(
'Show Invitations'.tr,
style: const TextStyle(
style: TextStyle(
fontSize: 16,
fontWeight: FontWeight.bold,
color: CupertinoColors.white,
color: AppColor.secondaryColor,
),
),
onPressed: () async {
@@ -227,8 +232,8 @@ class ShareAppPage extends StatelessWidget {
? Center(
child: Text(
"No invitation found yet!".tr,
style: const TextStyle(
color: CupertinoColors.secondaryLabel,
style: TextStyle(
color: AppColor.grayColor,
fontSize: 17,
),
),
@@ -258,8 +263,9 @@ class ShareAppPage extends StatelessWidget {
margin: const EdgeInsets.symmetric(vertical: 8.0),
padding: const EdgeInsets.all(16),
decoration: BoxDecoration(
color: CupertinoColors.systemGrey6,
color: AppColor.grayColor.withOpacity(0.08),
borderRadius: BorderRadius.circular(12),
border: Border.all(color: AppColor.grayColor.withOpacity(0.05)),
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
@@ -267,10 +273,10 @@ class ShareAppPage extends StatelessWidget {
Text(
invitation['passengerName']
.toString(), // Handle null or missing data
style: const TextStyle(
style: TextStyle(
fontSize: 17,
fontWeight: FontWeight.w600,
color: CupertinoColors.label,
color: AppColor.writeColor,
),
),
const SizedBox(height: 8),
@@ -278,18 +284,18 @@ class ShareAppPage extends StatelessWidget {
borderRadius: BorderRadius.circular(4),
child: LinearProgressIndicator(
value: progressValue,
backgroundColor: CupertinoColors.systemGrey4,
backgroundColor: AppColor.grayColor.withOpacity(0.1),
valueColor:
const AlwaysStoppedAnimation<Color>(AppColor.blueColor),
AlwaysStoppedAnimation<Color>(AppColor.primaryColor),
minHeight: 6,
),
),
const SizedBox(height: 4),
Text(
'$countOfInvitDriver / 2 ${'Trip'.tr}', // Show trips completed
style: const TextStyle(
style: TextStyle(
fontSize: 13,
color: CupertinoColors.secondaryLabel,
color: AppColor.grayColor,
),
),
],
@@ -302,18 +308,19 @@ class ShareAppPage extends StatelessWidget {
return Container(
padding: const EdgeInsets.all(16),
decoration: BoxDecoration(
color: CupertinoColors.systemGrey6,
color: AppColor.grayColor.withOpacity(0.08),
borderRadius: BorderRadius.circular(12),
border: Border.all(color: AppColor.grayColor.withOpacity(0.05)),
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
"Your Rewards".tr,
style: const TextStyle(
style: TextStyle(
fontSize: 17,
fontWeight: FontWeight.w600,
color: CupertinoColors.label,
color: AppColor.writeColor,
),
),
const SizedBox(height: 16),
@@ -342,8 +349,8 @@ class ShareAppPage extends StatelessWidget {
children: [
Text(
label,
style: const TextStyle(
color: CupertinoColors.label,
style: TextStyle(
color: AppColor.writeColor,
fontSize: 15,
),
),
@@ -362,7 +369,9 @@ class ShareAppPage extends StatelessWidget {
void _showContactsDialog(BuildContext context) {
Get.defaultDialog(
backgroundColor: AppColor.secondaryColor,
title: 'Choose from contact'.tr,
titleStyle: TextStyle(color: AppColor.writeColor),
content: SizedBox(
height: 400,
width: 400,
@@ -409,10 +418,10 @@ class ShareAppPage extends StatelessWidget {
padding: const EdgeInsets.symmetric(
horizontal: 16, vertical: 12),
decoration: BoxDecoration(
color: CupertinoColors.systemBackground,
color: AppColor.secondaryColor,
border: Border(
bottom: BorderSide(
color: CupertinoColors.separator.withOpacity(0.5),
color: AppColor.grayColor.withOpacity(0.1),
),
),
),
@@ -425,16 +434,16 @@ class ShareAppPage extends StatelessWidget {
children: [
Text(
contact['name'],
style: const TextStyle(
color: CupertinoColors.label,
style: TextStyle(
color: AppColor.writeColor,
fontSize: 17,
fontWeight: FontWeight.w500,
),
),
Text(
(contact['phones'][0].toString()),
style: const TextStyle(
color: CupertinoColors.secondaryLabel,
style: TextStyle(
color: AppColor.grayColor,
fontSize: 15,
),
),
@@ -442,9 +451,9 @@ class ShareAppPage extends StatelessWidget {
),
),
// Chevron icon for selection
const Icon(
Icon(
CupertinoIcons.chevron_forward,
color: CupertinoColors.systemGrey2,
color: AppColor.grayColor.withOpacity(0.5),
),
],
),