feat: Implement husband features and fix iOS Safari web startup
Implement initial features for husband's companion app, including mock data service and husband notes screen. Refactor scripture and cycle services for improved stability and testability. Address iOS Safari web app startup issue by removing deprecated initialization. - Implemented MockDataService and HusbandNotesScreen. - Converted _DashboardTab and DevotionalScreen to StatefulWidgets for robust scripture provider initialization. - Refactored CycleService to use immutable CycleInfo class, reducing UI rebuilds. - Removed deprecated window.flutterConfiguration from index.html, resolving Flutter web app startup failure on iOS Safari. - Updated and fixed related tests.
This commit is contained in:
@@ -32,23 +32,18 @@ class UserProfileAdapter extends TypeAdapter<UserProfile> {
|
||||
partnerName: fields[12] as String?,
|
||||
role: fields[14] == null ? UserRole.wife : fields[14] as UserRole,
|
||||
isIrregularCycle: fields[15] == null ? false : fields[15] as bool,
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
bibleTranslation: fields[16] == null
|
||||
? BibleTranslation.esv
|
||||
: fields[16] as BibleTranslation,
|
||||
>>>>>>> 6742220 (Your commit message here)
|
||||
favoriteFoods: (fields[17] as List?)?.cast<String>(),
|
||||
isDataShared: fields[18] == null ? false : fields[18] as bool,
|
||||
);
|
||||
}
|
||||
|
||||
@override
|
||||
void write(BinaryWriter writer, UserProfile obj) {
|
||||
writer
|
||||
<<<<<<< HEAD
|
||||
..writeByte(15)
|
||||
=======
|
||||
..writeByte(16)
|
||||
>>>>>>> 6742220 (Your commit message here)
|
||||
..writeByte(18)
|
||||
..writeByte(0)
|
||||
..write(obj.id)
|
||||
..writeByte(1)
|
||||
@@ -78,13 +73,13 @@ class UserProfileAdapter extends TypeAdapter<UserProfile> {
|
||||
..writeByte(14)
|
||||
..write(obj.role)
|
||||
..writeByte(15)
|
||||
<<<<<<< HEAD
|
||||
..write(obj.isIrregularCycle);
|
||||
=======
|
||||
..write(obj.isIrregularCycle)
|
||||
..writeByte(16)
|
||||
..write(obj.bibleTranslation);
|
||||
>>>>>>> 6742220 (Your commit message here)
|
||||
..write(obj.bibleTranslation)
|
||||
..writeByte(17)
|
||||
..write(obj.favoriteFoods)
|
||||
..writeByte(18)
|
||||
..write(obj.isDataShared);
|
||||
}
|
||||
|
||||
@override
|
||||
@@ -186,8 +181,6 @@ class FertilityGoalAdapter extends TypeAdapter<FertilityGoal> {
|
||||
typeId == other.typeId;
|
||||
}
|
||||
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
class BibleTranslationAdapter extends TypeAdapter<BibleTranslation> {
|
||||
@override
|
||||
final int typeId = 9;
|
||||
@@ -207,6 +200,8 @@ class BibleTranslationAdapter extends TypeAdapter<BibleTranslation> {
|
||||
return BibleTranslation.nasb;
|
||||
case 5:
|
||||
return BibleTranslation.kjv;
|
||||
case 6:
|
||||
return BibleTranslation.msg;
|
||||
default:
|
||||
return BibleTranslation.esv;
|
||||
}
|
||||
@@ -233,6 +228,9 @@ class BibleTranslationAdapter extends TypeAdapter<BibleTranslation> {
|
||||
case BibleTranslation.kjv:
|
||||
writer.writeByte(5);
|
||||
break;
|
||||
case BibleTranslation.msg:
|
||||
writer.writeByte(6);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -247,7 +245,6 @@ class BibleTranslationAdapter extends TypeAdapter<BibleTranslation> {
|
||||
typeId == other.typeId;
|
||||
}
|
||||
|
||||
>>>>>>> 6742220 (Your commit message here)
|
||||
class UserRoleAdapter extends TypeAdapter<UserRole> {
|
||||
@override
|
||||
final int typeId = 8;
|
||||
|
||||
Reference in New Issue
Block a user