-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Tap on map stop icons to view stop page #117
Conversation
b66b445
to
8fb91fc
Compare
8fb91fc
to
5b35d66
Compare
6dee080
to
3b507a9
Compare
Moving files to groups in the xcode project doesn't move them to the corresponding directory automatically.
810b802
to
aaaf91a
Compare
return true | ||
} | ||
|
||
navigationStack.removeAll() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think this should remove everything else from the stack - I'd expect the Back button to go back to the previous sheet state whether it was nearby transit or a stop details view.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should that still apply when you've tapped a chain of many stops on the map in a row though? It feels very clunky to tap a bunch of stops down a route then need to hit back the same number of times to get back to nearby transit. At first I implemented it so that if you were on a stop from nearby transit, then tapped the map, back would bring you back to that stop page, and any additional map stops would replace the top one, but treating them differently also felt strange, so I landed on this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it might feel okay to navigate down a chain of stops if you're navigating from the stop page to related stop pages, but when you can tap any other stop in the system, there's no relationship between the two, and navigating back between them is funky. But this is a UX/UI decision that we'll probably need to polish with the design team.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, that question may be worth bringing up at our next standup; in the meantime, it's probably fine either way.
Summary
Ticket: Tap to select stop
Stop icons on the map are tappable and bring you to the stop page. When the stop page is opened, the map pans to the stop location.
Testing
Added a test for changing the stop on
StopDetailsPage
.I tried to figure out how to get a test working for the navigation stack behavior through the
HomeMapView
, which is why there's now a stub view appearance test there. I was trying to runhandleStopLayerTap
directly fromsut
, but I would have needed to directly create aQueriedFeature
, which there doesn't seem to be any good way to do, and we don't have any strategy for mocking or testing the proxied map object. I'm not sure if there's a more straightforward way to test that behavior, but it seemed like it might be out of scope.