131 lines
No EOL
4.5 KiB
JSON
131 lines
No EOL
4.5 KiB
JSON
{
|
|
"id": "walls_and_buildings",
|
|
"minzoom": 18,
|
|
"title": {
|
|
"render": {
|
|
"en": "Wall or building",
|
|
"nl": "Muur of gebouw",
|
|
"de": "Wand oder Gebäude",
|
|
"es": "Pared o edificio",
|
|
"fr": "Mur ou bâtiment"
|
|
}
|
|
},
|
|
"description": {
|
|
"en": "Special builtin layer providing all walls and buildings. This layer is useful in presets for objects which can be placed against walls (e.g. AEDs, postboxes, entrances, addresses, surveillance cameras, …). This layer is invisible by default and not toggleable by the user.",
|
|
"nl": "Speciale laag met alle muren en gebouwen. Deze laag is nuttig om objecten toe te voegen die met een muur verbonden zijn (zoals AEDs, brievenbussen, adressen, bewakingscamera's,…). Deze laag is standaard onzichtbaar en kan niet aangezet worden door de gebruiker.",
|
|
"de": "Spezielle Ebene, die alle Wände und Gebäude bereitstellt. Diese Ebene ist nützlich in Voreinstellungen für Objekte, die an Wänden platziert werden können (z. B. AEDs, Briefkästen, Eingänge, Adressen, Überwachungskameras, ...). Diese Ebene ist standardmäßig unsichtbar und kann vom Benutzer nicht umgeschaltet werden.",
|
|
"fr": "Couche intégrée spéciale fournissant tous les murs et bâtiments. Cette couche est utile dans les préréglages pour les objets qui peuvent être placés contre les murs (par exemple, les DEA, les boîtes aux lettres, les entrées, les adresses, les caméras de surveillance, …). Ce calque est invisible par défaut et non inchangeable par l'utilisateur."
|
|
},
|
|
"source": {
|
|
"osmTags": {
|
|
"or": [
|
|
"barrier=wall",
|
|
"building~*"
|
|
]
|
|
}
|
|
},
|
|
"passAllFeatures": true,
|
|
"shownByDefault": false,
|
|
"mapRendering": [
|
|
{
|
|
"color": {
|
|
"render": "#fff"
|
|
},
|
|
"fill": "no",
|
|
"width": {
|
|
"render": "3"
|
|
}
|
|
},
|
|
{
|
|
"color": {
|
|
"render": "#333"
|
|
},
|
|
"fill": "no",
|
|
"width": {
|
|
"render": "2"
|
|
}
|
|
}
|
|
],
|
|
"calculatedTags": [
|
|
"_entrance_properties=feat.overlapWith('entrance')?.map(e => e.feat.properties)?.filter(p => p !== undefined && p.indoor !== 'door')",
|
|
"_entrance_properties_with_width=feat.get('_entrance_properties')?.filter(p => p['width'] !== undefined)",
|
|
"_entrances_count=feat.get('_entrance_properties').length",
|
|
"_entrances_count_without_width_count= feat.get('_entrances_count') - feat.get('_entrance_properties_with_width').length",
|
|
"_biggest_width= Math.max( feat.get('_entrance_properties').map(p => p.width))",
|
|
"_biggest_width_properties= /* Can be a list! */ feat.get('_entrance_properties').filter(p => p.width === feat.get('_biggest_width'))",
|
|
"_biggest_width_id=feat.get('_biggest_width_properties').id"
|
|
],
|
|
"units": [
|
|
{
|
|
"appliesToKey": [
|
|
"width",
|
|
"_biggest_width"
|
|
],
|
|
"applicableUnits": [
|
|
{
|
|
"canonicalDenomination": "m",
|
|
"alternativeDenomination": [
|
|
"meter"
|
|
],
|
|
"human": {
|
|
"en": "meter",
|
|
"fr": "mètre",
|
|
"de": "Meter"
|
|
}
|
|
},
|
|
{
|
|
"default": true,
|
|
"canonicalDenomination": "cm",
|
|
"alternativeDenomination": [
|
|
"centimeter",
|
|
"cms"
|
|
],
|
|
"human": {
|
|
"en": "centimeter",
|
|
"fr": "centimètre",
|
|
"de": "Zentimeter"
|
|
}
|
|
}
|
|
]
|
|
}
|
|
],
|
|
"tagRenderings": [
|
|
{
|
|
"id": "entrance_info",
|
|
"render": {
|
|
"before": {
|
|
"en": "<h3>Entrances</h3>This building has {_entrances_count} entrances:"
|
|
},
|
|
"after": {
|
|
"en": "{_entrances_count_without_width_count} entrances don't have width information yet"
|
|
},
|
|
"special": {
|
|
"type": "multi",
|
|
"key": "_entrance_properties_with_width",
|
|
"tagrendering": {
|
|
"en": "An <a href='#{id}'>entrance</a> of {canonical(width)}"
|
|
}
|
|
}
|
|
},
|
|
"mappings": [
|
|
{
|
|
"if": "_entrances_count=0",
|
|
"then": {
|
|
"en": "No entrance has been marked"
|
|
}
|
|
},
|
|
{
|
|
"if": "_entrances_count_without_width:=_entrances_count",
|
|
"then": {
|
|
"en": "None of the {_entrance_count} entrances have width information yet"
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "biggest_width",
|
|
"render": "The <a href='#{_biggest_width_id}'>entrance with the biggest width</a> is {canonical(_biggest_width)} wide",
|
|
"condition": "_biggest_width_id~*"
|
|
}
|
|
]
|
|
} |