-
Notifications
You must be signed in to change notification settings - Fork 57
OTP-UI humanize-distance #151
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
Codecov Report
@@ Coverage Diff @@
## dev #151 +/- ##
==========================================
+ Coverage 12.97% 13.02% +0.04%
==========================================
Files 116 115 -1
Lines 4586 4569 -17
Branches 1327 1321 -6
==========================================
Hits 595 595
+ Misses 3384 3373 -11
+ Partials 607 601 -6
Continue to review full report at Codecov.
|
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. I think we should take this opportunity to add a config item here though. If we wanted to show distance in metric units, we have no way of easily doing so. We do have a use case (B-ham) where we probably want to do this, so could you add a config key for useMetric
(I'm open to other names) and pass this to the humanizeDistanceString calls? It probably makes sense to add this near the dateTime config item.
Good idea on the configuration to switch to metric units. |
We will deal with configuration to show narratives in metric in opentripplanner/otp-ui#116 and #158. |
🎉 This PR is included in version 1.0.0-beta.1 🎉 The release is available on: Your semantic-release bot 📦🚀 |
🎉 This PR is included in version 1.0.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
This PR replaces the distance functions with the ones from the humanize-distance package from OTP-UI.