Open
Description
Description
Normally, pop to a List
will also deselect the cell along with the pop transition, and this behavior depends on the value
of NavigationLink
in SwiftUI.
However, NavigationLink.init(state:label:fileID:filePath:line:column:)
will increment the id
each time, making the value
unique.
With this implementation, the cell selection will not be retained during the push and pop, so the cell will be deselected instantly when pop (not during the transition).
Checklist
- I have determined whether this bug is also reproducible in a vanilla SwiftUI project.
- If possible, I've reproduced the issue using the
main
branch of this package. - This issue hasn't been addressed in an existing GitHub issue or discussion.
Expected behavior
The value
of NavigationLink
remains the same when the state
is the same.
Actual behavior
The value
of NavigationLink
changes each time.