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.
54 lines
1.4 KiB
Dart
54 lines
1.4 KiB
Dart
// GENERATED CODE - DO NOT MODIFY BY HAND
|
|
|
|
part of 'scripture.dart';
|
|
|
|
// **************************************************************************
|
|
// TypeAdapterGenerator
|
|
// **************************************************************************
|
|
|
|
class ScriptureAdapter extends TypeAdapter<Scripture> {
|
|
@override
|
|
final int typeId = 10;
|
|
|
|
@override
|
|
Scripture read(BinaryReader reader) {
|
|
final numOfFields = reader.readByte();
|
|
final fields = <int, dynamic>{
|
|
for (int i = 0; i < numOfFields; i++) reader.readByte(): reader.read(),
|
|
};
|
|
return Scripture(
|
|
verses: (fields[0] as Map).cast<BibleTranslation, String>(),
|
|
reference: fields[1] as String,
|
|
reflection: fields[2] as String?,
|
|
applicablePhases: (fields[3] as List).cast<String>(),
|
|
applicableContexts: (fields[4] as List).cast<String>(),
|
|
);
|
|
}
|
|
|
|
@override
|
|
void write(BinaryWriter writer, Scripture obj) {
|
|
writer
|
|
..writeByte(5)
|
|
..writeByte(0)
|
|
..write(obj.verses)
|
|
..writeByte(1)
|
|
..write(obj.reference)
|
|
..writeByte(2)
|
|
..write(obj.reflection)
|
|
..writeByte(3)
|
|
..write(obj.applicablePhases)
|
|
..writeByte(4)
|
|
..write(obj.applicableContexts);
|
|
}
|
|
|
|
@override
|
|
int get hashCode => typeId.hashCode;
|
|
|
|
@override
|
|
bool operator ==(Object other) =>
|
|
identical(this, other) ||
|
|
other is ScriptureAdapter &&
|
|
runtimeType == other.runtimeType &&
|
|
typeId == other.typeId;
|
|
}
|