-
Notifications
You must be signed in to change notification settings - Fork 58
Stop viewer/itinerary body status #294
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
Conversation
…us, various refactors.
… logic in component
landonreed
left a comment
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.
This generally looks pretty good, but there were some opportunities for encapsulating this logic a bit more into the label component. I was having trouble expressing, so I just made a PR: #296.
refactor(realtime-status-label): encapsulate more of the status label…
| if (delaySeconds > 60) { | ||
| // late departure | ||
| return REALTIME_STATUS.LATE | ||
| } else if (delaySeconds < -60) { | ||
| // early departure | ||
| return REALTIME_STATUS.EARLY | ||
| } else { | ||
| // on-time departure | ||
| return REALTIME_STATUS.ON_TIME | ||
| } |
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.
Consider basing this PR off of #305 and then refactor this function so that it uses the configurable on-time threshold.
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.
This refactors so that changes from #294 are included.
|
🎉 This PR is included in version 3.0.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
This PR is in response to #292 (comment) and does the following refactors:
utils/viewerinto a newBaseStatusLabelcomponent.BaseStatusLabelandRealTimeTimeColumn.RealTimeTimeColumnrender code.