This migration converts the application screen by screen. Each screen is implemented in a separate pull request so that behavior changes remain small, reviewable, and easy to validate. Existing Fragment and navigation wrappers remain until every user-facing screen has been migrated.
- Keep
StatsFragmentas the temporary Compose host. - Keep statistics state in
StatsViewModel. - Preserve loading, empty-data, date-range, total, average, and record behavior.
- Add or retain deterministic state tests.
- Add a lifecycle-aware
HomeViewModelfor steps, history, preferences, and Health Connect state. - Replace the EazeGraph pie chart with a Compose progress visualization.
- Replace the EazeGraph bar chart with a Compose history visualization.
- Preserve steps/distance switching and Health Connect permission states.
- Remove EazeGraph after the Compose Home screen is complete.
- Replace
PreferenceFragmentCompatwith a Compose settings screen. - Preserve SharedPreferences keys, defaults, goal editing, step-size editing, CSV import/export, and Health Connect refresh after import.
- Use Compose dialogs for goal and step-size editing.
- Render the privacy policy with Compose.
- Preserve the Health Connect permission-usage activity alias and manifest contract.
- Replace the XML activity layout with a Compose shell.
- Replace the XML toolbar, bottom navigation, fragment container, and navigation graph with Compose UI and screen selection.
- Preserve titles, back behavior, About, system-bar insets, and Health Connect permission launching.
- Delete the migrated Fragment classes, screen layouts, and navigation graph.
- Remove Fragment and Navigation dependencies once no longer referenced.
- Keep the required Health Connect privacy activity.
The UI migration intentionally retains Room, Hilt, and lifecycle components. They should be removed in separate, focused changes after the screen migration:
- Migrate Stats.
- Migrate Home and remove EazeGraph.
- Migrate Settings.
- Migrate the privacy screen.
- Replace the Activity shell.
- Remove Fragment and Navigation infrastructure.
- Remove Hilt with manual dependency construction.
- Reassess lifecycle and ViewModel dependencies.
- Replace Room with a smaller SQLite implementation if the measured APK size justifies the storage rewrite.
Every pull request must include:
- Unit tests for new state and behavior.
- Relevant Compose UI tests for important visible states.
./gradlew buildand./gradlew ktlintCheckresults.- Release APK size and
apkanalyzerdownload-size measurements. - Manual validation by installing and running the app on the physical Pixel 9 through the Android CLI.