-
Notifications
You must be signed in to change notification settings - Fork 2
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
Single step view #397
Single step view #397
Conversation
Next: skip the "Arrive at destination" instruction Then: implement for single transit stop view too
Potential improvements: - Remove the arrive step from the instructions earlier (when first getting from server) to avoid all this complicated logic later - OR dress up the arrive steps to make it more obvious you're transferring to transit - Add a dressed up arrive at destination step at the very end of the last leg
Feedback
|
request:
|
0426944
to
2edd4b4
Compare
I've done this but it's kind of weird because if the instructions are long and you're toward the end, it zooms while the map isn't visible - except around the edges of the instructions. Oh well. |
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.
Comments from @abhumbla
I added position: relative to the main div of ItinerarySingleTransitStop to position the X in the top right corner. But this made that div the offsetParent, so useScrollToRef tried to scroll within it, instead of the actual scroll container (div.MapPlusOverlay_overlay). So I'm modifying useScrollToRef to iterate till it finds an actually scrollable container.
also, feedback about just using one viewingStepMarker variable
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.
lgtm, you left some console logs in, not sure if that was intended
InstructionSigns.FINISH | ||
) { | ||
if (draft.viewingStep[0] + 1 === viewingRoute.legs.length) { | ||
console.error('next step: would go past end'); |
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.
remove?
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.
oh I left this on purpose so we can see if that's happening and correct it. If I wrote the code correctly, this case will never occur
A usable view that allows you to step through each instruction step (for a bike leg) and each stop that a transit leg passes through.
Fixes #396