-
Notifications
You must be signed in to change notification settings - Fork 944
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
Split directions engine select into modes and providers #5652
base: master
Are you sure you want to change the base?
Conversation
You should never edit any translation here (other than |
Doesn't this mean all the translations will have to start from scratch? |
65aa4d3
to
850471e
Compare
If you want this to be considered for merging then you should remove the draft flag. That said I'm not sure I really see the point of it - is this really just to reduce the number of translations from 9 to 6 so saving a total of 3 translations? All while introducing new "lego" to the translations though admittedly one that is probably relatively harmless. |
Why would you do lego instead of two selects for mode and provider? |
850471e
to
cc458d1
Compare
1b5ef55
to
bc3abc4
Compare
const modes = engines | ||
.filter(engine => engine.provider === chosenEngine.provider) | ||
.map(engine => engine.mode) | ||
.sort((a, b) => I18n.t("javascripts.directions.modes." + a).localeCompare(I18n.t("javascripts.directions.modes." + b))); |
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.
What's the point of this sort?
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.
The options of the select currently get sorted so there's a different order depending on the language.
In english it's 🚲-🚙-🚶, in german 🚙-🚲-🚶.
Would you like to specify a fixed order for all languages?
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.
Many maps are specific for one transport mode.
So having a fixed sort order can be problematic (osm data is also good for foot stuff).
That being said, alphabetically is probably the most the most neutral one...
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'm not sure why the current code sorts them but it seems wrong to me - there's no logical reason why the order in which they are shown should depend on the language.
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.
Well then which order should they be shown in?
5591008
to
b7d293c
Compare
b7d293c
to
0a0835d
Compare
Attempt to fix #5629.
Splits the directions engine select into a radio button group for modes and a smaller select for routing providers.
Includes tooltips for the mode radio button group:
