Skip to content

Add translatable labels for address components (#1788)#1870

Merged
tordans merged 1 commit intoopenstreetmap:mainfrom
bryceco:housenumber-label
Jan 13, 2026
Merged

Add translatable labels for address components (#1788)#1870
tordans merged 1 commit intoopenstreetmap:mainfrom
bryceco:housenumber-label

Conversation

@bryceco
Copy link
Copy Markdown
Contributor

@bryceco bryceco commented Dec 27, 2025

Description, Motivation & Context

See #1788: This may or may not be what @k-yle was suggesting there.

There are currently placeholder strings that provide translations of address components like "addr:city", but "addr:housenumber" uses placeholder text "123". This adds a new section to provide translations for such strings.

Related issues

Closes #1788

@github-actions
Copy link
Copy Markdown

🍱 Your pull request preview is ready

Please use this preview to check your changes. Ideally use the test documentation template and document your test results by commenting on the PR. This will speed up the review process for everyone.

FYI, once this PR is merged, you can use the iD Editor Preview to test your changes in interaction with all other changes.

Copy link
Copy Markdown
Collaborator

@k-yle k-yle 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 this is a good unintrusive solution. Transifex should pick up these keys as soon as it's merged.

i have no opinion on the name labels, seems reasonable

@bryceco
Copy link
Copy Markdown
Contributor Author

bryceco commented Dec 29, 2025

Using "labels" is also the thing I figured would be most controversial. Opinions welcome!

@matkoniecz
Copy link
Copy Markdown
Collaborator

🍱 Your pull request preview is ready

@bryceco have you tested is it working as expected?

@bryceco
Copy link
Copy Markdown
Contributor Author

bryceco commented Dec 31, 2025

I haven't done any testing. I've never built iD (or any other JS app) locally so it's a bit much for me.

@matkoniecz
Copy link
Copy Markdown
Collaborator

https://pr-1870--ideditor-presets-preview.netlify.app/id/dist/#locale=en&map=18.00/48.84171/2.58766&disable_features=boundaries&background=fr.ign.bdortho is link to a build output and it can be tested online (except some rare cases of PR which depend on additional external changes)

@bryceco
Copy link
Copy Markdown
Contributor Author

bryceco commented Dec 31, 2025

Wow, that's actually a really nice feature!

But:

  • iD doesn't make use of the changes added by this PR. This change is only useful for 3rd party users of id-tagging-schema.
  • The changes are only visible after translators have translated the associated strings.

Based on Kyle's feedback I'm fairly confident about the PR. It seems unlikely for it to break things (since it adds data iD doesn't reference), and if there's a problem with it we can iterate without breaking things.

Edit: I'll add that I don't see any breakage or change using the link you provided.

@tordans
Copy link
Copy Markdown
Collaborator

tordans commented Dec 31, 2025

(FYI, will comment to ask some questions later; happy to merge afterwards.)

@tyrasd
Copy link
Copy Markdown
Member

tyrasd commented Jan 2, 2026

I think this is a good idea, and iD could also make use of this additional labels (e.g. in form of a tooltip or hover text) for the address field.

This should work fine with the current version of the schema-builder, but for the next version we need to also define this extra property of the "strings" in the json-schema here1. I'll take care of that. //edit: I just implemented this in ideditor/schema-builder@41c93ce (FYI: I had the intent to make a PR for it, but accidentally commited directly to main. We can always revert it in case it turns out to be better done differently.)

Footnotes

  1. see also https://github.com/ideditor/schema-builder/pull/229

@tyrasd tyrasd added new-label changes the name, aliases or terms of a preset waiting-ready-to-merge Ready to merge, but let's wait a few days for possible feedback. labels Jan 2, 2026
@tyrasd
Copy link
Copy Markdown
Member

tyrasd commented Jan 13, 2026

(FYI, will comment to ask some questions later; happy to merge afterwards.)

//ping @tordans - are we good to merge it as is for now from your side, or should we wait?

@tordans tordans merged commit 362d800 into openstreetmap:main Jan 13, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

new-label changes the name, aliases or terms of a preset waiting-ready-to-merge Ready to merge, but let's wait a few days for possible feedback.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

housenumber lacks a translatable placeholder string

5 participants