part of 'notes_bloc.dart'; enum NotesStatus { initial, loading, success, failure } class NotesState { final NotesStatus status; final List notes; final String? errorMessage; const NotesState({ this.status = NotesStatus.initial, this.notes = const [], this.errorMessage, }); NotesState copyWith({ NotesStatus? status, List? notes, String? errorMessage, }) { return NotesState( status: status ?? this.status, notes: notes ?? this.notes, errorMessage: errorMessage ?? this.errorMessage, ); } @override bool operator ==(Object other) { if (identical(this, other)) return true; return other is NotesState && other.status == status && listEquals(other.notes, notes) && other.errorMessage == errorMessage; } @override int get hashCode => status.hashCode ^ notes.hashCode ^ errorMessage.hashCode; }