-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Add fields to Taginfo file #4940
Conversation
Thanks @mmd-osm - I took a look and this seems right to me. I think it's pretty good. What stands out to me is that we do have a lot of duplicates for things like: {
"key": "ref"
},
{
"key": "ref"
},
{
"key": "ref"
},
... So maybe we should start adding {
"key": "ref",
"description": "Gate Number, Hole Number, Highway Number, Runway Number..."
}, |
I think we're slowly getting there. I added descriptions for presets and fields now (where available) and also coalesced them like in the example above: {
"key": "ref",
"description": "Gate Number, Hole Number, Junction Number, Platform Number, Road Number, Route Number, Runway Number, Stop Number, Taxiway Name, Reference Code"
}, |
Hey that's pretty good @mmd-osm ! What else is left? |
I still have to figure out how the iD <--> taginfo mapping looks like.
Then there's some strange side effect issue when adding geometry to generateField. It ends up in data/presets.yaml as well.
Icons could be interesting as well. Can I assume that maki is used all over the place, which would be quite straightforward:
|
Yes, looks good ..
Yeah it might not be straightforward which the fields can be used on which geometries. You could try to build an index of field -> geometry when you build the preset list (presets have geometry).
Maki isn't quite used everywhere, but you can use code like this Lines 221 to 222 in 523fb7f
Because maki is a dependency, you can just require it and get this array of all the icon names, then use that to build an > const maki = require ('@mapbox/maki');
undefined
> var dataFeatureIcons = maki.layouts.all.all
[ 'aerialway',
'airfield',
'airport',
... hope this helps! |
+ Changed description duplicate handling + Removed geometry and icon from translation
Thanks again for all the hints.
|
Thank you, for working on it! Looks great, I just merged it 👍 |
Gave it a first try.. not quite sure if I covered all combinations in the original json files. I should probably remove those duplicates in
taginfo
as well.Things like "fields/gender.json" still look pretty strange in the taginfo result. There seem to be some cases, where we don't want a cross product of those string.options values and the keys array.
Supposed to eventually