refactor: migrate to navigation 3 - #90
Merged
Merged
Conversation
The old `RouteDestination` interface only existed to hand nav-2 a graph destination, which nav-3 keys do not need. Its replacement is the shared entry decorators every back stack is rendered with. `URI_PATTERN` went with the nav-2 deep link syntax; the `otpauth` scheme and host it encoded are now named on their own. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014nJBXmDWn2x1xS4dTi458g
The list kept a highlight of its own and only cleared it when auto selection turned off, so a detail dropped from the back stack behind it left a row marked as open with an empty pane beside it. `resetHighlight()` becomes `setHighlight(itemId)`, and the caller that owns the pane passes what it is showing. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014nJBXmDWn2x1xS4dTi458g
Every feature exported a `NavGraphBuilder` extension that built a nav-2 graph. Each is now an `EntryProviderScope<NavKey>` extension adding the same screens as nav-3 entries, taking the metadata its host wants to attach to them. The activities that hosted a graph of their own (autofill, create and provide passkey) drive a `NavBackStack` and a `NavDisplay` instead of a `NavController` and a `NavHost`. Route keys move next to the entries that read them and are plain `NavKey`s. They stay flat: a back stack key is saved with kotlinx.serialization, so the pending TOTP import travels as primitives rather than as a nested field. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014nJBXmDWn2x1xS4dTi458g
The navigation bar and the create button used to be switched on by reading the shape of the back stack, which meant every new screen had to be thought about in that one place. A destination now carries its own shell as nav-3 metadata, resolved against the current window: `Always`, `Never`, or `BesideListPane` for a detail that only keeps the shell while the list is up. A destination that declares nothing owns the whole window, so a screen added without a policy shows up bare rather than borrowing chrome it was never checked against. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014nJBXmDWn2x1xS4dTi458g
The single `NavHost` becomes a `NavDisplay` over state the app owns: a launch stack carrying whatever has to happen before the app proper (unlocking, first run, an incoming `otpauth://` link), and one back stack per navigation bar destination. Each destination keeps its own history, so switching tabs and coming back lands where the user left off. Picking the tab already showing is what pops it to its base. Nothing sits under a base, so back from there closes the app rather than walking out through destinations already moved on from. `AppNavigator` is the only thing that writes to those stacks, which puts the rules for what replaces what in one place: a detail swaps rather than stacks, the edit form stacks on the item it edits, and an auto-selected detail is dropped when the window narrows enough to hand it the whole screen. The dashboard's two panes are a list-detail scene over one stack instead of the old nested graph plus `DetailType`, and the item the detail pane holds is what the list highlights. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014nJBXmDWn2x1xS4dTi458g
…isibility management
…for improved URI integrity
…improved deep link handling
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.