From bbae4b5789a9992d01223f49fd6628db59a59ae6 Mon Sep 17 00:00:00 2001 From: Kalonkarthik Date: Fri, 28 Feb 2025 18:04:45 +0530 Subject: [PATCH] Contact page created --- assets/icons/enquiry/at.svg | 10 ++ assets/icons/enquiry/building.svg | 3 + assets/icons/enquiry/fax.svg | 3 + assets/icons/enquiry/map.svg | 10 ++ assets/icons/enquiry/phone.svg | 3 + lib/config/my_router.dart | 6 + .../icons/enquiry_asset_icon_path.dart | 8 + .../drawer_routes/Drawer Items/contactUs.dart | 145 ++++++++++++++++++ .../drawer_routes/custom_drawer_routes.dart | 5 + pubspec.yaml | 1 + 10 files changed, 194 insertions(+) create mode 100644 assets/icons/enquiry/at.svg create mode 100644 assets/icons/enquiry/building.svg create mode 100644 assets/icons/enquiry/fax.svg create mode 100644 assets/icons/enquiry/map.svg create mode 100644 assets/icons/enquiry/phone.svg create mode 100644 lib/infrastructure/services/img_asset_paths/icons/enquiry_asset_icon_path.dart create mode 100644 lib/presentation/routes/drawer_routes/Drawer Items/contactUs.dart diff --git a/assets/icons/enquiry/at.svg b/assets/icons/enquiry/at.svg new file mode 100644 index 00000000..a3517c93 --- /dev/null +++ b/assets/icons/enquiry/at.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/assets/icons/enquiry/building.svg b/assets/icons/enquiry/building.svg new file mode 100644 index 00000000..5974d94d --- /dev/null +++ b/assets/icons/enquiry/building.svg @@ -0,0 +1,3 @@ + + + diff --git a/assets/icons/enquiry/fax.svg b/assets/icons/enquiry/fax.svg new file mode 100644 index 00000000..39a5ca7b --- /dev/null +++ b/assets/icons/enquiry/fax.svg @@ -0,0 +1,3 @@ + + + diff --git a/assets/icons/enquiry/map.svg b/assets/icons/enquiry/map.svg new file mode 100644 index 00000000..2f42121a --- /dev/null +++ b/assets/icons/enquiry/map.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/assets/icons/enquiry/phone.svg b/assets/icons/enquiry/phone.svg new file mode 100644 index 00000000..b154c7f8 --- /dev/null +++ b/assets/icons/enquiry/phone.svg @@ -0,0 +1,3 @@ + + + diff --git a/lib/config/my_router.dart b/lib/config/my_router.dart index 00f2c6a0..674dc32a 100644 --- a/lib/config/my_router.dart +++ b/lib/config/my_router.dart @@ -306,6 +306,7 @@ import 'package:uae_stat/presentation/Screens/charts/chart.dart'; import 'package:uae_stat/presentation/Screens/charts/screens/chart_screen.dart'; import 'package:uae_stat/presentation/Screens/demo_home2.dart'; import 'package:uae_stat/presentation/Screens/online_offline_verification/internet_check.dart'; +import 'package:uae_stat/presentation/routes/drawer_routes/Drawer%20Items/contactUs.dart'; import 'package:uae_stat/presentation/routes/drawer_routes/Drawer%20Items/notification/notification.dart'; import 'package:uae_stat/presentation/routes/drawer_routes/Drawer%20Items/user_guide/AboutTheApp/AboutFCSC.dart'; import 'package:uae_stat/presentation/routes/drawer_routes/Drawer%20Items/user_guide/AboutTheApp/getStarted.dart'; @@ -631,5 +632,10 @@ final GoRouter router = GoRouter( path: '/marriages', builder: (context, state) => Marriages(), ), + + GoRoute( + path: '/contact', + builder: (context, state) => Contact(), + ), ], ); diff --git a/lib/infrastructure/services/img_asset_paths/icons/enquiry_asset_icon_path.dart b/lib/infrastructure/services/img_asset_paths/icons/enquiry_asset_icon_path.dart new file mode 100644 index 00000000..e1219710 --- /dev/null +++ b/lib/infrastructure/services/img_asset_paths/icons/enquiry_asset_icon_path.dart @@ -0,0 +1,8 @@ +abstract class EnquiryAssetIconPath { + static const _basePath = 'assets/icons/enquiry'; + static const at = '$_basePath/at.svg'; + static const building = '$_basePath/building.svg'; + static const fax = '$_basePath/fax.svg'; + static const map = '$_basePath/map.svg'; + static const phone = '$_basePath/phone.svg'; +} \ No newline at end of file diff --git a/lib/presentation/routes/drawer_routes/Drawer Items/contactUs.dart b/lib/presentation/routes/drawer_routes/Drawer Items/contactUs.dart new file mode 100644 index 00000000..bc8cb507 --- /dev/null +++ b/lib/presentation/routes/drawer_routes/Drawer Items/contactUs.dart @@ -0,0 +1,145 @@ +import 'package:flutter/material.dart'; +import 'package:uae_stat/domain/use_cases/language.dart'; +import 'package:uae_stat/infrastructure/services/img_asset_paths/icons/enquiry_asset_icon_path.dart'; +import 'package:uae_stat/presentation/routes/drawer_routes/custom_drawer_routes.dart'; +import 'package:flutter_svg/flutter_svg.dart'; +class Contact extends StatefulWidget { + const Contact({super.key}); + + @override + State createState() => _ContactState(); +} + +class _ContactState extends State { + @override + Widget build(BuildContext context) { + final double screenWidth= MediaQuery.of(context).size.width; + final double screenHeight= MediaQuery.of(context).size.height; + + + return BaseScaffold( + body: Container( + color: Colors.grey[200], + width: screenWidth, + padding: EdgeInsets.all(16.0), + child: SingleChildScrollView( + child: Column( + children: [ + Container( + decoration: BoxDecoration( + color: Colors.white, + borderRadius: BorderRadius.circular(4.0), // Slight curve + ), + padding: EdgeInsets.all(7.0), + height: screenHeight*0.35, + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text(context.translate('DUBAI - EMIRATES TOWER -32ND FLOOR','دبي - أبراج الإمارات - الطابق 32'), + style: TextStyle( + color: Color(0xFF265E84), + fontSize: 20, + fontFamily: 'Roboto', + fontWeight: FontWeight.w500, + ), + ), + buildTextRow(EnquiryAssetIconPath.building,context.translate('Office : Dubai - Emirates Tower -32nd Floor','المقر الرئيسي : دبي - أبراج الإمارات - الطابق 32')), + buildTextRow(EnquiryAssetIconPath.phone,context.translate('Tel : 00971 46080000','الهاتف : 0097146080000'),), + buildTextRow(EnquiryAssetIconPath.fax, context.translate('Fax : 0097143273535','فاكس : 0097143273535')), + buildTextRow(EnquiryAssetIconPath.map, context.translate('P.O.Box : 127000 Dubai','ص.ب: : 127000 دبي')), + buildTextRow(EnquiryAssetIconPath.at, context.translate('Email Address : info@fcsc.gov.ae','البريد الإلكتروني : info@fcsc.gov.ae')), + buildTextRow(EnquiryAssetIconPath.map,context.translate( 'Latitude : 25.223926','خط العرض : 25.223926')), + buildTextRow(EnquiryAssetIconPath.map, context.translate('Longitude : 55.350526','خط الطول : 55.350526')), + ], + ), + ), + SizedBox(height: 10,), + Container( + padding: EdgeInsets.all(7.0), + decoration: BoxDecoration( + color: Colors.white, + borderRadius: BorderRadius.circular(4.0), // Slight curve + ), + height: screenHeight*0.34, + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text(context.translate('MEDIA SECTION','قسم الاعلام'), + style: TextStyle( + color: Color(0xFF265E84), + fontSize: 20, + fontFamily: 'Roboto', + fontWeight: FontWeight.w500, + ), + ), + buildTextRow(EnquiryAssetIconPath.building,context.translate('Office : Media Section','المقر الرئيسي : قسم الاعلام')), + buildTextRow(EnquiryAssetIconPath.phone,context.translate('Tel : 00971 46080000','الهاتف : 0097146080000'),), + buildTextRow(EnquiryAssetIconPath.fax, context.translate('Fax : 0097143273535','فاكس : 0097143273535')), + buildTextRow(EnquiryAssetIconPath.map, context.translate('P.O.Box : 127000 Dubai','ص.ب: : 127000 دبي')), + buildTextRow(EnquiryAssetIconPath.at, context.translate('Email Address : GCO@fcsc.gov.ae','البريد الإلكتروني : GCO@fcsc.gov.ae')), + buildTextRow(EnquiryAssetIconPath.map,context.translate( 'Latitude : 25.223926','خط العرض : 25.223926')), + buildTextRow(EnquiryAssetIconPath.map, context.translate('Longitude : 55.350526','خط الطول : 55.350526')), + ], + ), + ), + SizedBox(height: 10,), + Container( + decoration: BoxDecoration( + color: Colors.white, + borderRadius: BorderRadius.circular(4.0), // Slight curve + ), + padding: EdgeInsets.all(7.0), + height: screenHeight*0.34, + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text(context.translate('SGDS','أهداف التنمية المستدامة'), + style: TextStyle( + color: Color(0xFF265E84), + fontSize: 20, + fontFamily: 'Roboto', + fontWeight: FontWeight.w500, + ), + ), + buildTextRow(EnquiryAssetIconPath.building,context.translate('Office : SDGs','المقر الرئيسي : أهداف التنمية المستدامة')), + buildTextRow(EnquiryAssetIconPath.phone,context.translate('Tel : 00971 46080000','الهاتف : 0097146080000'),), + buildTextRow(EnquiryAssetIconPath.fax, context.translate('Fax : 0097143273535','فاكس : 0097143273535')), + buildTextRow(EnquiryAssetIconPath.map, context.translate('P.O.Box : 127000 Dubai','ص.ب: : 127000 دبي')), + buildTextRow(EnquiryAssetIconPath.at, context.translate('Email Address : sdgs@fcsc.gov.ae','البريد الإلكتروني : sdgs@fcsc.gov.ae')), + buildTextRow(EnquiryAssetIconPath.map,context.translate( 'Latitude : 25.223926','خط العرض : 25.223926')), + buildTextRow(EnquiryAssetIconPath.map, context.translate('Longitude : 55.350526','خط الطول : 55.350526')), + ], + ), + ), + ], + ), + ), + ), title: Text(context.translate('Contact Us','اتصل بنا')),); + } + + Widget buildTextRow(String iconName, String text) { + return Padding( + padding: const EdgeInsets.only(top:8.0), + child: Row( + mainAxisAlignment: MainAxisAlignment.start, + children: [ + SvgPicture.asset( + iconName, + semanticsLabel: 'Filter', + width: 24, + height: 24, + ), + SizedBox(width: 8), // Add spacing if needed + Text( + text, // Dynamic text + style: TextStyle( + fontSize: 16, + color: Color(0xFF878787), + ), + ), + ], + ), + ); + } + +} diff --git a/lib/presentation/routes/drawer_routes/custom_drawer_routes.dart b/lib/presentation/routes/drawer_routes/custom_drawer_routes.dart index 322e04bc..be6ba665 100644 --- a/lib/presentation/routes/drawer_routes/custom_drawer_routes.dart +++ b/lib/presentation/routes/drawer_routes/custom_drawer_routes.dart @@ -974,6 +974,11 @@ class _BaseScaffoldState extends ConsumerState { title: Text(AppLocalizations.of(context)!.guide_title), onTap: () => _navigateTo(context, '/user-guide'), ), + ListTile( + leading: Icon(Icons.phone), + title: const Text('Contact'), + onTap: () => context.push('/contact'), + ), if (userId != 'guest') ListTile( leading: Icon(Icons.logout), diff --git a/pubspec.yaml b/pubspec.yaml index 4248f8ff..c6b6c97f 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -139,6 +139,7 @@ flutter: - assets/icons/misc/group.png - assets/icons/misc/search.png - assets/icons/bookmark/ + - assets/icons/enquiry/ fonts: - family: Segoe