Skip to content

[codex] Fix Android calendar back navigation#381

Merged
jjoonleo merged 1 commit into
mainfrom
codex/fix-android-back-navigation
May 6, 2026
Merged

[codex] Fix Android calendar back navigation#381
jjoonleo merged 1 commit into
mainfrom
codex/fix-android-back-navigation

Conversation

@jjoonleo

@jjoonleo jjoonleo commented May 6, 2026

Copy link
Copy Markdown
Contributor

Summary

Fixes Android system back behavior on the calendar screen so pressing back returns to the home screen instead of closing the app.

Root Cause

The home calendar entry uses route replacement, so when /calendar is the top-level location Android back has no prior route to pop and the app can terminate. The calendar app-bar back button already navigated to /home, but the system back path was not handled.

Changes

  • Added a shared _returnHome() helper for calendar back navigation.
  • Wrapped CalendarScreen in PopScope to intercept Android back and route to /home.
  • Added a widget test that simulates Android back from /calendar and verifies the home route is shown.

Validation

  • flutter test test/presentation/calendar/screens/calendar_screen_test.dart
  • flutter analyze

@github-actions

github-actions Bot commented May 6, 2026

Copy link
Copy Markdown

Visit the preview URL for this PR (updated for commit 16b3dec):

https://ontime-c63f1--pr381-codex-fix-android-ba-9e5rhw8t.web.app

(expires Wed, 13 May 2026 18:33:13 GMT)

🔥 via Firebase Hosting GitHub Action 🌎

Sign: 7d60a2eae4c4a5839220ed6a57552a3b61cce5a3

@github-actions

github-actions Bot commented May 6, 2026

Copy link
Copy Markdown

Visit the preview URL for this PR (updated for commit 16b3dec):

https://on-time-front-widgetbook--pr381-codex-fix-android-ba-torfofsz.web.app

(expires Wed, 13 May 2026 18:34:37 GMT)

🔥 via Firebase Hosting GitHub Action 🌎

Sign: e53128a376fed0209d449279de9c0d94c83cdd8b

@jjoonleo jjoonleo marked this pull request as ready for review May 6, 2026 18:37
@jjoonleo jjoonleo merged commit ee5ded8 into main May 6, 2026
4 checks passed
@jjoonleo jjoonleo deleted the codex/fix-android-back-navigation branch May 6, 2026 18:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant