Skip to content
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

Map Popup show company name in all map popup titles #764

Conversation

miles-grant-ibigroup
Copy link
Collaborator

It was a little confusing that there was no title in the station names. Especially when feeds had terrible station names. We resolve this. As a result we remove company name from the other strings. However, the car isn't localized, so it's kept for now. In the future we might want to get rid of that

@miles-grant-ibigroup
Copy link
Collaborator Author

@daniel-heppner-ibigroup I need your help updating the snapshtos

Copy link
Contributor

@daniel-heppner-ibigroup daniel-heppner-ibigroup left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good change!

Copy link
Collaborator

@binh-dam-ibigroup binh-dam-ibigroup left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you need to apply the "Car" labeling to the other languages.

packages/map-popup/i18n/en-US.yml Show resolved Hide resolved
@@ -5,5 +5,6 @@ otpUi:
floatingBike: "Vélo flottant : {name}"
floatingCar: "{company} {name}"
floatingEScooter: Trottinette {name}
popupTitle: "{stationNetwork, select, false {{name}} other {{stationNetwork} {name}}}"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If popupTitle is going to be telegraphic style at first, does it need to be in the language files?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as above. I've made it backwards compatible so languages can adjust when they're ready. Should we consider removing the strings from other languages?

@@ -3,7 +3,8 @@ otpUi:
availableBikes: "Available bikes: {value}"
availableDocks: "Available docks: {value}"
floatingBike: "Free-floating bike: {name}"
floatingCar: "{company} {name}"
floatingCar: "Car: {name}"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the colon needed?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Without the colon things can get messy especially if the company name is silly

Copy link
Collaborator

@binh-dam-ibigroup binh-dam-ibigroup left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See if you can add the additional story to illustrate the updated floating car case. Otherwise I am good with the changes.

packages/map-popup/src/MapPopup.story.tsx Outdated Show resolved Hide resolved
@miles-grant-ibigroup
Copy link
Collaborator Author

@daniel-heppner-ibigroup I'm going to need you to please update the snapshots again

@miles-grant-ibigroup miles-grant-ibigroup merged commit 2cef22c into opentripplanner:master Aug 21, 2024
2 checks passed
@miles-grant-ibigroup miles-grant-ibigroup deleted the map-popup-entity-in-title branch August 21, 2024 20:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants