Enhance Pad Tracking with new Flow and Supply logic

This commit is contained in:
2026-01-09 13:35:07 -06:00
parent 24ffac2415
commit dc6bcad83f
17 changed files with 765 additions and 171 deletions

View File

@@ -329,6 +329,8 @@ class _HusbandDashboardState extends ConsumerState<_HusbandDashboard> {
Widget build(BuildContext context) {
final user = ref.watch(userProfileProvider);
final cycleInfo = ref.watch(currentCycleInfoProvider);
final theme = Theme.of(context);
final isDark = theme.brightness == Brightness.dark;
final wifeName = user?.partnerName ?? "Wife";
final phase = cycleInfo.phase;
@@ -349,7 +351,7 @@ class _HusbandDashboardState extends ConsumerState<_HusbandDashboard> {
'Hey there,',
style: GoogleFonts.outfit(
fontSize: 16,
color: AppColors.warmGray,
color: isDark ? Colors.white70 : AppColors.warmGray,
),
),
Text(
@@ -357,7 +359,7 @@ class _HusbandDashboardState extends ConsumerState<_HusbandDashboard> {
style: GoogleFonts.outfit(
fontSize: 28,
fontWeight: FontWeight.w600,
color: AppColors.navyBlue,
color: isDark ? Colors.white : AppColors.navyBlue,
),
),
const SizedBox(height: 24),
@@ -460,11 +462,12 @@ class _HusbandDashboardState extends ConsumerState<_HusbandDashboard> {
width: double.infinity,
padding: const EdgeInsets.all(16),
decoration: BoxDecoration(
color: Colors.white,
color: isDark ? const Color(0xFF1E1E1E) : Colors.white,
borderRadius: BorderRadius.circular(16),
boxShadow: [
BoxShadow(
color: AppColors.navyBlue.withValues(alpha: 0.05),
color: (isDark ? Colors.black : AppColors.navyBlue)
.withValues(alpha: 0.05),
blurRadius: 10,
offset: const Offset(0, 4),
),
@@ -494,7 +497,7 @@ class _HusbandDashboardState extends ConsumerState<_HusbandDashboard> {
style: GoogleFonts.outfit(
fontSize: 16,
fontWeight: FontWeight.w600,
color: AppColors.navyBlue,
color: isDark ? Colors.white : AppColors.navyBlue,
),
),
],
@@ -504,7 +507,7 @@ class _HusbandDashboardState extends ConsumerState<_HusbandDashboard> {
_getSupportTip(phase),
style: GoogleFonts.outfit(
fontSize: 14,
color: AppColors.charcoal,
color: isDark ? Colors.white70 : AppColors.charcoal,
height: 1.5,
),
),
@@ -538,7 +541,7 @@ class _HusbandDashboardState extends ConsumerState<_HusbandDashboard> {
margin: const EdgeInsets.only(bottom: 20),
padding: const EdgeInsets.all(16),
decoration: BoxDecoration(
color: Colors.white,
color: isDark ? const Color(0xFF1E1E1E) : Colors.white,
borderRadius: BorderRadius.circular(16),
border: Border.all(
color: AppColors.rose.withValues(alpha: 0.3)),
@@ -574,7 +577,7 @@ class _HusbandDashboardState extends ConsumerState<_HusbandDashboard> {
style: GoogleFonts.outfit(
fontSize: 16,
fontWeight: FontWeight.w600,
color: AppColors.navyBlue,
color: isDark ? Colors.white : AppColors.navyBlue,
),
),
],
@@ -589,7 +592,9 @@ class _HusbandDashboardState extends ConsumerState<_HusbandDashboard> {
backgroundColor:
AppColors.rose.withValues(alpha: 0.1),
labelStyle: GoogleFonts.outfit(
color: AppColors.navyBlue,
color: isDark
? Colors.white
: AppColors.navyBlue,
fontWeight: FontWeight.w500),
side: BorderSide.none,
))
@@ -636,7 +641,7 @@ class _HusbandDashboardState extends ConsumerState<_HusbandDashboard> {
style: GoogleFonts.outfit(
fontSize: 14,
fontWeight: FontWeight.w500,
color: AppColors.warmGray,
color: isDark ? Colors.white70 : AppColors.warmGray,
),
),
),
@@ -676,7 +681,7 @@ class _HusbandDashboardState extends ConsumerState<_HusbandDashboard> {
style: GoogleFonts.lora(
fontSize: 15,
fontStyle: FontStyle.italic,
color: AppColors.navyBlue,
color: isDark ? Colors.white : AppColors.navyBlue,
height: 1.6,
),
),
@@ -689,7 +694,7 @@ class _HusbandDashboardState extends ConsumerState<_HusbandDashboard> {
style: GoogleFonts.outfit(
fontSize: 12,
fontWeight: FontWeight.w500,
color: AppColors.warmGray,
color: isDark ? Colors.white70 : AppColors.warmGray,
),
),
GestureDetector(
@@ -737,8 +742,9 @@ class _HusbandDashboardState extends ConsumerState<_HusbandDashboard> {
style: GoogleFonts.outfit(fontWeight: FontWeight.w500),
),
style: OutlinedButton.styleFrom(
foregroundColor: AppColors.navyBlue,
side: const BorderSide(color: AppColors.navyBlue),
foregroundColor: isDark ? Colors.white : AppColors.navyBlue,
side: BorderSide(
color: isDark ? Colors.white70 : AppColors.navyBlue),
padding: const EdgeInsets.symmetric(vertical: 14),
),
),
@@ -854,7 +860,7 @@ class _HusbandDashboardState extends ConsumerState<_HusbandDashboard> {
style: GoogleFonts.lora(
fontSize: 16,
fontStyle: FontStyle.italic,
color: AppColors.charcoal,
color: Theme.of(context).textTheme.bodyLarge?.color,
height: 1.6,
),
),