Skip to content

Implement basic onboarding navigation & logic #4

@opatry

Description

@opatry

The onboarding flow should guide the user through initial setup when preferences are not yet defined.

Flow:

  1. App start
    → Check if preferences are set
    → If not, show Welcome screen
  2. On “Continue”
    → Show Preferences screen to select:
    • Volume unit (ml or oz)
    • Notifications enabled (true/false)
    • Notification period (in hours)
  3. Once submitted
    → Navigate to Main screen (placeholder)

Tech notes:

  • Domain logic (use cases) in :preferences
  • UI flow logic can live in a new :onboarding module
  • Entry point & navigation in :h2go-app
  • Use androidx.navigation.compose:2.9.x
  • Reuse VolumeUnit enum and UserPreferences domain model

Deliverables:

  • Domain layer: use case(s) for saving/loading preferences
  • Presentation layer: ViewModel(s) per screen
  • Compose UI screens with state management
  • Navigation logic setup using Compose Navigation
  • UI tests for Composables (runComposeUiTest)
  • Navigation tests (recommend testing user flows via NavHostController assertions)

Testing:

  • Unit tests for domain & ViewModels
  • Composable tests for UI behavior
  • Suggest test strategy for nav graph (e.g. dependency-injected NavController)

Metadata

Metadata

Assignees

No one assigned

    Labels

    appMain application.featureA new feature from the functional requirements.uiRelated to Jetpack Compose components, screen layouts, and user experience.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions