import 'package:flutter/foundation.dart';

class AppStateManager extends ChangeNotifier {
  bool _onboarding = false;
  bool _statistics = false;
  bool _settings = false;
  bool _createHabit = false;
  bool _editHabit = false;
  bool _whatsNew = false;
  bool _archivedHabits = false;

  bool get onboarding => _onboarding;
  bool get statistics => _statistics;
  bool get settings => _settings;
  bool get createHabit => _createHabit;
  bool get editHabit => _editHabit;
  bool get whatsNew => _whatsNew;
  bool get archivedHabits => _archivedHabits;

  void setOnboarding(bool v) { _onboarding = v; notifyListeners(); }
  void setStatistics(bool v) { _statistics = v; notifyListeners(); }
  void setSettings(bool v) { _settings = v; notifyListeners(); }
  void setCreateHabit(bool v) { _createHabit = v; notifyListeners(); }
  void setEditHabit(bool v) { _editHabit = v; notifyListeners(); }
  void setWhatsNew(bool v) { _whatsNew = v; notifyListeners(); }
  void setArchivedHabits(bool v) { _archivedHabits = v; notifyListeners(); }

  void goOnboarding(bool v) => setOnboarding(v);
  void goStatistics(bool v) => setStatistics(v);
  void goSettings(bool v) => setSettings(v);
  void goCreateHabit(bool v) => setCreateHabit(v);
  void goEditHabit(bool v) => setEditHabit(v);
  void goWhatsNew(bool v) => setWhatsNew(v);
  void goArchivedHabits(bool v) => setArchivedHabits(v);
}
