add new featurs like new stat page
This commit is contained in:
@@ -13,7 +13,7 @@ class DailyGoalWidget extends StatelessWidget {
|
||||
return Container(
|
||||
padding: const EdgeInsets.all(20),
|
||||
decoration: BoxDecoration(
|
||||
color: Colors.white,
|
||||
color: FinanceDesignSystem.cardColor,
|
||||
borderRadius: BorderRadius.circular(FinanceDesignSystem.cardRadius),
|
||||
boxShadow: [
|
||||
BoxShadow(
|
||||
@@ -55,17 +55,17 @@ class DailyGoalWidget extends StatelessWidget {
|
||||
children: [
|
||||
Text(
|
||||
'Daily Goal'.tr,
|
||||
style: const TextStyle(
|
||||
style: TextStyle(
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.bold,
|
||||
color: FinanceDesignSystem.primaryDark,
|
||||
),
|
||||
),
|
||||
Text(
|
||||
'الهدف اليومي'.tr,
|
||||
'Daily Goal'.tr,
|
||||
style: TextStyle(
|
||||
fontSize: 11,
|
||||
color: Colors.grey.shade500,
|
||||
color: FinanceDesignSystem.textSecondary,
|
||||
),
|
||||
),
|
||||
],
|
||||
@@ -80,13 +80,11 @@ class DailyGoalWidget extends StatelessWidget {
|
||||
padding:
|
||||
const EdgeInsets.symmetric(horizontal: 12, vertical: 6),
|
||||
decoration: BoxDecoration(
|
||||
color: Colors.grey.shade100,
|
||||
color: FinanceDesignSystem.backgroundColor,
|
||||
borderRadius: BorderRadius.circular(8),
|
||||
),
|
||||
child: Text(
|
||||
controller.dailyGoal > 0
|
||||
? 'Edit'.tr
|
||||
: 'Set Goal'.tr,
|
||||
controller.dailyGoal > 0 ? 'Edit'.tr : 'Set Goal'.tr,
|
||||
style: TextStyle(
|
||||
fontSize: 12,
|
||||
fontWeight: FontWeight.w600,
|
||||
@@ -121,7 +119,7 @@ class DailyGoalWidget extends StatelessWidget {
|
||||
style: TextStyle(
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.w500,
|
||||
color: Colors.grey.shade400,
|
||||
color: FinanceDesignSystem.textMuted,
|
||||
),
|
||||
),
|
||||
],
|
||||
@@ -135,7 +133,7 @@ class DailyGoalWidget extends StatelessWidget {
|
||||
height: 12,
|
||||
width: double.infinity,
|
||||
decoration: BoxDecoration(
|
||||
color: Colors.grey.shade100,
|
||||
color: FinanceDesignSystem.backgroundColor,
|
||||
borderRadius: BorderRadius.circular(6),
|
||||
),
|
||||
),
|
||||
@@ -197,7 +195,7 @@ class DailyGoalWidget extends StatelessWidget {
|
||||
const SizedBox(width: 4),
|
||||
Text(
|
||||
'Goal Achieved!'.tr,
|
||||
style: const TextStyle(
|
||||
style: TextStyle(
|
||||
fontSize: 12,
|
||||
fontWeight: FontWeight.bold,
|
||||
color: FinanceDesignSystem.successGreen,
|
||||
@@ -210,7 +208,7 @@ class DailyGoalWidget extends StatelessWidget {
|
||||
'${'Remaining:'.tr} ${(controller.dailyGoal - controller.dailyEarnings).clamp(0, double.infinity).toStringAsFixed(0)} ${'SYP'.tr}',
|
||||
style: TextStyle(
|
||||
fontSize: 11,
|
||||
color: Colors.grey.shade500,
|
||||
color: FinanceDesignSystem.textSecondary,
|
||||
),
|
||||
),
|
||||
],
|
||||
@@ -228,6 +226,7 @@ class DailyGoalWidget extends StatelessWidget {
|
||||
);
|
||||
|
||||
Get.defaultDialog(
|
||||
backgroundColor: FinanceDesignSystem.cardColor,
|
||||
title: 'Set Daily Goal'.tr,
|
||||
titleStyle: FinanceDesignSystem.headingStyle,
|
||||
content: Column(
|
||||
@@ -252,13 +251,11 @@ class DailyGoalWidget extends StatelessWidget {
|
||||
suffixText: 'SYP'.tr,
|
||||
border: OutlineInputBorder(
|
||||
borderRadius: BorderRadius.circular(12),
|
||||
borderSide:
|
||||
BorderSide(color: Colors.grey.shade300),
|
||||
borderSide: BorderSide(color: FinanceDesignSystem.borderColor),
|
||||
),
|
||||
focusedBorder: OutlineInputBorder(
|
||||
borderRadius: BorderRadius.circular(12),
|
||||
borderSide:
|
||||
const BorderSide(color: FinanceDesignSystem.accentBlue),
|
||||
borderSide: BorderSide(color: FinanceDesignSystem.accentBlue),
|
||||
),
|
||||
),
|
||||
),
|
||||
@@ -270,7 +267,8 @@ class DailyGoalWidget extends StatelessWidget {
|
||||
return ActionChip(
|
||||
label: Text('$goal'),
|
||||
labelStyle: const TextStyle(fontSize: 12),
|
||||
backgroundColor: FinanceDesignSystem.accentBlue.withOpacity(0.1),
|
||||
backgroundColor:
|
||||
FinanceDesignSystem.accentBlue.withOpacity(0.1),
|
||||
side: BorderSide.none,
|
||||
onPressed: () {
|
||||
textController.text = goal.toString();
|
||||
@@ -291,16 +289,15 @@ class DailyGoalWidget extends StatelessWidget {
|
||||
style: ElevatedButton.styleFrom(
|
||||
backgroundColor: FinanceDesignSystem.accentBlue,
|
||||
foregroundColor: Colors.white,
|
||||
shape: RoundedRectangleBorder(
|
||||
borderRadius: BorderRadius.circular(12)),
|
||||
shape:
|
||||
RoundedRectangleBorder(borderRadius: BorderRadius.circular(12)),
|
||||
padding: const EdgeInsets.symmetric(horizontal: 32, vertical: 12),
|
||||
),
|
||||
child: Text('Save'.tr),
|
||||
),
|
||||
cancel: TextButton(
|
||||
onPressed: () => Get.back(),
|
||||
child: Text('Cancel'.tr,
|
||||
style: const TextStyle(color: Colors.grey)),
|
||||
child: Text('Cancel'.tr, style: const TextStyle(color: Colors.grey)),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user