refactor(android): simplify predictive back navigation - #2485
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 85118ba766
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| ) { | ||
| androidPredictiveBackHoldTransition( | ||
| predictiveBackMotionState.transitionHoldDurationMillis, | ||
| modifier = modifier, |
There was a problem hiding this comment.
Keep NavDisplay transitions clipped to their pane
When the router is hosted beside a navigation rail or as a 360dp deck column, removing clipToBounds() lets the translated or scaled AnimatedContent draw over adjacent UI during navigation. The entry decorator does not replace parent clipping because it clips each entry before the transition transform, and it is disabled entirely on big screens; the existing NavigationSuiteScaffold2Test.navigationTransitionDoesNotDrawOverNavigationRail covers this scenario. Restore clipping on the NavDisplay modifier, which still leaves overlay scenes outside those bounds.
Useful? React with 👍 / 👎.
| 1f at ANDROID_NAVIGATION_EXIT_FADE_START_MILLIS using LinearEasing | ||
| 0f at ANDROID_NAVIGATION_EXIT_FADE_END_MILLIS |
There was a problem hiding this comment.
Preserve predictive-back-specific fade timing
During an interactive predictive-back gesture, Navigation3 seeks this 450ms animation from the gesture progress. Reusing the ordinary close-transition keyframes makes the outgoing page fade from opaque to invisible between 35ms and 118ms—about 8% to 26% progress—while its scale and slide continue through the rest of the gesture. This causes the foreground page to disappear near the start of a slow swipe; retain predictive-specific timing so the fade occurs near gesture completion.
Useful? React with 👍 / 👎.
No description provided.