feat: refactor financial wallet UI components and add offline map service support
This commit is contained in:
@@ -27,6 +27,7 @@ class AK {
|
||||
X.r(X.r(X.r(Env.accountSIDTwillo, cn), cC), cs);
|
||||
static final String serverAPI = X.r(X.r(X.r(Env.serverAPI, cn), cC), cs);
|
||||
static final String mapAPIKEY = Env.mapAPIKEY;
|
||||
static final String mapSaasKey = Env.mapSaasKey;
|
||||
static final String twilloRecoveryCode =
|
||||
X.r(X.r(X.r(Env.twilloRecoveryCode, cn), cC), cs);
|
||||
static final String authTokenTwillo =
|
||||
|
||||
@@ -1,33 +1,69 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:get/get.dart';
|
||||
|
||||
class AppColor {
|
||||
// --- Core Brand Colors ---
|
||||
|
||||
/// **Primary Color:** The brand's signature blue.
|
||||
static const Color primaryColor = Color(0xFF1DA1F2);
|
||||
static const Color writeColor = Color(0xff222359);
|
||||
|
||||
/// **Text/Write Color:** Dynamic based on theme.
|
||||
static Color get writeColor =>
|
||||
Get.isDarkMode ? Colors.white : const Color(0xFF1A1A1A);
|
||||
|
||||
/// **Secondary Color:** Main background color, dynamic based on theme.
|
||||
static Color get secondaryColor =>
|
||||
Get.isDarkMode ? const Color(0xFF121212) : Colors.white;
|
||||
|
||||
/// **Surface Color:** For cards and elevated elements.
|
||||
static Color get surfaceColor =>
|
||||
Get.isDarkMode ? const Color(0xFF1E1E1E) : Colors.white;
|
||||
|
||||
/// **Card Color:** Specifically for card backgrounds.
|
||||
static Color get cardColor =>
|
||||
Get.isDarkMode ? const Color(0xFF1E1E1E) : Colors.white;
|
||||
|
||||
/// **Border Color:** Subtle borders for both modes.
|
||||
static Color get borderColor =>
|
||||
Get.isDarkMode ? Colors.white10 : Colors.black12;
|
||||
|
||||
/// **Accent Color:** Greyish accent.
|
||||
static const Color accentColor = Color.fromARGB(255, 148, 140, 141);
|
||||
|
||||
// --- Neutral & Status Colors ---
|
||||
|
||||
/// **Grey Color:** Dynamic based on theme.
|
||||
static Color get grayColor =>
|
||||
Get.isDarkMode ? Colors.grey[400]! : const Color(0xFF8E8E93);
|
||||
|
||||
/// **Red Color (Error):** Clear red for alerts.
|
||||
static const Color redColor = Color(0xFFD32F2F);
|
||||
|
||||
/// **Green Color (Success):** Positive green.
|
||||
static const Color greenColor = Color(0xFF388E3C);
|
||||
|
||||
/// **Blue Color (Info):** Info text or success green variant.
|
||||
static const Color blueColor = Color(0xFF1DA1F2);
|
||||
|
||||
/// **Yellow Color (Warning):** Warm yellow.
|
||||
static const Color yellowColor = Color(0xFFFFA000);
|
||||
|
||||
// --- Tier & Social Colors ---
|
||||
|
||||
static const Color gold = Color(0xFFFFD700);
|
||||
static const Color bronze = Color(0xFFCD7F32);
|
||||
static const Color goldenBronze = Color(0xFFB87333); // Golden bronze color
|
||||
static const Color gold = Color(0xFFD4AF37);
|
||||
static const Color secondaryColor = Colors.white;
|
||||
static const Color accentColor = Colors.grey;
|
||||
static const Color greyColor = Colors.grey;
|
||||
static const Color twitterColor = Color(0xFF1DA1F2); // Twitter blue
|
||||
static const Color goldenBronze = Color(0xFFB87333);
|
||||
static const Color twitterColor = Color(0xFF1DA1F2);
|
||||
|
||||
static const Color redColor = Color(0xFFEA4335); // Google Red
|
||||
static const Color greenColor = Color(0xFF34A853); // Google Green
|
||||
static const Color blueColor = Color(0xFF1DA1F2); // Google Blue
|
||||
static const Color yellowColor = Color(0xFFFBBC05); // Google Yellow
|
||||
static Color deepPurpleAccent =
|
||||
const Color.fromARGB(255, 123, 76, 254).withOpacity(0.3);
|
||||
// --- Utility Colors ---
|
||||
|
||||
// For dynamic elements like gradients
|
||||
static List<Color> gradientStartEnd = [
|
||||
Color.fromARGB(255, 40, 158, 232), // Start with primary color
|
||||
Color.fromARGB(
|
||||
255, 44, 63, 75), // End with a slightly darker shade of Twitter blue
|
||||
];
|
||||
static Color get greyColor => grayColor;
|
||||
|
||||
static List<Color> secondaryGradientStartEnd = [
|
||||
const Color(0xFF1DA1F2), // Start with Twitter blue
|
||||
const Color(0xFF0C7ABF), // End with a slightly darker shade of Twitter blue
|
||||
];
|
||||
static Color get cyanBlue => const Color(0xFF1DA1F2);
|
||||
static Color get cyanAccent => const Color(0xFF1DA1F2).withOpacity(0.12);
|
||||
static Color get deepPurpleAccent => const Color(0xFFCE1126).withOpacity(0.1);
|
||||
|
||||
// --- Theme Helpers ---
|
||||
static Brightness get brightness => Get.isDarkMode ? Brightness.dark : Brightness.light;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// في ملف: constant/country_polygons.dart
|
||||
|
||||
import 'package:google_maps_flutter/google_maps_flutter.dart';
|
||||
import 'package:intaleq_maps/intaleq_maps.dart';
|
||||
|
||||
class CountryPolygons {
|
||||
// ==========================================================
|
||||
|
||||
53
lib/constant/finance_design_system.dart
Normal file
53
lib/constant/finance_design_system.dart
Normal file
@@ -0,0 +1,53 @@
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class FinanceDesignSystem {
|
||||
// --- Colors ---
|
||||
static const Color primaryDark = Color(0xFF0A0E21);
|
||||
static const Color accentBlue = Color(0xFF3D5AFE);
|
||||
static const Color successGreen = Color(0xFF00C853);
|
||||
static const Color dangerRed = Color(0xFFD50000);
|
||||
static const Color backgroundColor = Color(0xFFF6F8FA);
|
||||
static const Color cardColor = Color(0xFFFFFFFF);
|
||||
static const Color textSecondary = Color(0xFF757575);
|
||||
static const Color textMuted = Color(0xFFBDBDBD);
|
||||
|
||||
// --- Gradients ---
|
||||
static const LinearGradient balanceGradient = LinearGradient(
|
||||
colors: [Color(0xFF0A0E21), Color(0xFF1A237E)],
|
||||
begin: Alignment.topLeft,
|
||||
end: Alignment.bottomRight,
|
||||
);
|
||||
|
||||
static const LinearGradient dangerGradient = LinearGradient(
|
||||
colors: [Color(0xFFD50000), Color(0xFFFF5252)],
|
||||
begin: Alignment.topLeft,
|
||||
end: Alignment.bottomRight,
|
||||
);
|
||||
|
||||
// --- Radius ---
|
||||
static const double mainRadius = 16.0;
|
||||
static const double cardRadius = 20.0;
|
||||
static const double buttonRadius = 12.0;
|
||||
|
||||
// --- Spacing ---
|
||||
static const double horizontalPadding = 16.0;
|
||||
static const double verticalSectionPadding = 24.0;
|
||||
|
||||
// --- Text Styles ---
|
||||
static const TextStyle balanceStyle = TextStyle(
|
||||
fontSize: 32,
|
||||
fontWeight: FontWeight.bold,
|
||||
color: Colors.white,
|
||||
);
|
||||
|
||||
static const TextStyle headingStyle = TextStyle(
|
||||
fontSize: 18,
|
||||
fontWeight: FontWeight.bold,
|
||||
color: primaryDark,
|
||||
);
|
||||
|
||||
static const TextStyle subHeadingStyle = TextStyle(
|
||||
fontSize: 14,
|
||||
color: textSecondary,
|
||||
);
|
||||
}
|
||||
@@ -10,6 +10,11 @@ class AppLink {
|
||||
|
||||
static String locationServer =
|
||||
'https://location.intaleq.xyz/intaleq/ride/location';
|
||||
static String locationServerSide =
|
||||
'https://location.intaleq.xyz/intaleq/ride/location';
|
||||
static String mapSaasRoute = 'https://map-saas.intaleqapp.com/api/maps/route';
|
||||
static String mapSaasPlaces =
|
||||
'https://map-saas.intaleqapp.com/api/geocoding/places';
|
||||
static const String routeApiBaseUrl =
|
||||
"https://routesjo.intaleq.xyz/route/v1/driving";
|
||||
static final String endPoint = 'https://api.intaleq.xyz/intaleq_v1';
|
||||
|
||||
@@ -5,7 +5,7 @@ import 'package:google_fonts/google_fonts.dart';
|
||||
import 'colors.dart';
|
||||
|
||||
class AppStyle {
|
||||
static TextStyle headTitle = TextStyle(
|
||||
static TextStyle get headTitle => TextStyle(
|
||||
fontWeight: FontWeight.bold,
|
||||
fontSize: 36,
|
||||
color: AppColor.accentColor,
|
||||
@@ -13,57 +13,61 @@ class AppStyle {
|
||||
// ?GoogleFonts.markaziText().fontFamily
|
||||
? GoogleFonts.markaziText().fontFamily
|
||||
: GoogleFonts.inter().fontFamily);
|
||||
static TextStyle headTitle2 = TextStyle(
|
||||
static TextStyle get headTitle2 => TextStyle(
|
||||
fontWeight: FontWeight.bold,
|
||||
fontSize: 24,
|
||||
color: AppColor.writeColor,
|
||||
fontFamily: box.read(BoxName.lang) == 'ar'
|
||||
? GoogleFonts.markaziText().fontFamily
|
||||
: GoogleFonts.inter().fontFamily);
|
||||
static TextStyle title = TextStyle(
|
||||
static TextStyle get title => TextStyle(
|
||||
fontWeight: FontWeight.normal,
|
||||
fontSize: 16,
|
||||
color: AppColor.writeColor,
|
||||
fontFamily: box.read(BoxName.lang) == 'ar'
|
||||
? GoogleFonts.markaziText().fontFamily
|
||||
: GoogleFonts.inter().fontFamily);
|
||||
static TextStyle subtitle = TextStyle(
|
||||
static TextStyle get subtitle => TextStyle(
|
||||
fontWeight: FontWeight.bold,
|
||||
fontSize: 12,
|
||||
color: AppColor.writeColor,
|
||||
fontFamily: box.read(BoxName.lang) == 'ar'
|
||||
? GoogleFonts.markaziText().fontFamily
|
||||
: GoogleFonts.inter().fontFamily);
|
||||
static TextStyle number = const TextStyle(
|
||||
static TextStyle get number => TextStyle(
|
||||
fontWeight: FontWeight.bold,
|
||||
fontSize: 14,
|
||||
color: AppColor.writeColor,
|
||||
fontFamily: 'digit');
|
||||
|
||||
static BoxDecoration boxDecoration = const BoxDecoration(
|
||||
static BoxDecoration get boxDecoration => BoxDecoration(
|
||||
boxShadow: [
|
||||
BoxShadow(
|
||||
color: AppColor.accentColor, blurRadius: 5, offset: Offset(2, 4)),
|
||||
color: AppColor.accentColor.withValues(alpha: 0.3),
|
||||
blurRadius: 5,
|
||||
offset: const Offset(2, 4)),
|
||||
BoxShadow(
|
||||
color: AppColor.accentColor, blurRadius: 5, offset: Offset(-2, -2))
|
||||
color: AppColor.accentColor.withValues(alpha: 0.1),
|
||||
blurRadius: 5,
|
||||
offset: const Offset(-2, -2))
|
||||
],
|
||||
color: AppColor.secondaryColor,
|
||||
borderRadius: BorderRadius.all(
|
||||
borderRadius: const BorderRadius.all(
|
||||
Radius.elliptical(15, 30),
|
||||
));
|
||||
static BoxDecoration boxDecoration1 = const BoxDecoration(
|
||||
static BoxDecoration get boxDecoration1 => BoxDecoration(
|
||||
boxShadow: [
|
||||
BoxShadow(
|
||||
color: Color.fromARGB(255, 237, 230, 230),
|
||||
blurRadius: 5,
|
||||
offset: Offset(2, 4)),
|
||||
color: Colors.black.withValues(alpha: 0.05),
|
||||
blurRadius: 10,
|
||||
offset: const Offset(0, 4)),
|
||||
BoxShadow(
|
||||
color: Color.fromARGB(255, 242, 237, 237),
|
||||
color: AppColor.primaryColor.withValues(alpha: 0.02),
|
||||
blurRadius: 5,
|
||||
offset: Offset(-2, -2))
|
||||
offset: const Offset(-2, -2))
|
||||
],
|
||||
color: AppColor.secondaryColor,
|
||||
borderRadius: BorderRadius.all(
|
||||
borderRadius: const BorderRadius.all(
|
||||
Radius.elliptical(15, 30),
|
||||
),
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user