diff --git a/culture-media.yaml b/culture-media.yaml new file mode 100644 index 0000000..b5c81fd --- /dev/null +++ b/culture-media.yaml @@ -0,0 +1,89 @@ +type: "overpass" +query: + 15: | + (nwr[historic];nwr[tourism~'^(attraction|artwork)$'];nwr[heritage];) +feature: + pre: | + {% set color = 'red' %} + {% set str = 'No image, wikimedia_commons or wikidata' %} + + {% if tags.wikidata %} + {% set color = 'blue' %} + {% set str = 'has wikidata tag' %} + {% set wikidata = tags.wikidata|wikidataEntity %} + + {% if wikidata.claims.P31[0].mainsnak.datavalue.value.id in ['Q5'] %} + {% set color = 'magenta' %} + {% set str = "wikidata points to a human, should most likely be 'subject:wikidata'" %} + {% endif %} + + {% elseif tags.wikimedia_commons or tags.image %} + {% set color = 'cyan' %} + {% set str = tags.wikimedia_commons ? 'has wikimedia_commons tag' : 'has image tag' %} + + {% endif %} + + body: | + {{ str }} + + description: | + {% if tags.historic and tags.historic != 'yes' %} + {{ tagTransList('historic', tags.historic) }} + {% if tags.historic == 'memorial' and tags.memorial %} + ({{ tagTransList('memorial', tags.memorial) }}) + {% endif %} + {% elseif tags.tourism %} + {{ tagTransList('tourism', tags.tourism) }} + {% elseif tags.heritage %} + {{ keyTrans('heritage') }} + {% endif %} + markerSymbol: "{{ markerPointer({ fillColor: color })|raw }}" + listMarkerSymbol: "{{ markerCircle({ fillColor: color })|raw }}" +filter: + type: + name: "{{ trans('filter:type') }}" + show_default: "true" + query: "nwr[{{ value }}]" + type: "select" + key: "tourism" + values: | + + + + + + + + + + op: "has" +info: | + + + + + + + + + + + + + + + + + +
+ {{ markerCircle({ fillColor: 'red' })|raw }} + No image, wikimedia_commons or wikidata
+ {{ markerCircle({ fillColor: 'magenta' })|raw }} + wikidata tag points to a human, should most likely be 'subject:wikidata'
+ {{ markerCircle({ fillColor: 'cyan' })|raw }} + image or wikimedia_commons tag but no wikidata
+ {{ markerCircle({ fillColor: 'blue' })|raw }} + has wikidata tag
+ + This category lists artwork, memorials, historic and heritage protected objects. These should have an image or wikimedia_commons tag, or (even better) a wikidata tag pointing to the object's entry.
+ Memorials erroneously often have a wikidata (and wikipedia) tag of the person/event, which should be changed to subject:wikidata resp. subject:wikipedia". diff --git a/fixme.yaml b/fixme.yaml new file mode 100644 index 0000000..55d9e4b --- /dev/null +++ b/fixme.yaml @@ -0,0 +1,213 @@ +type: overpass +query: + 14: nwr[~"^fixme(:.*|)$"~".",i] +feature: + pre: | + {% set fixme = tags.fixme %} + {% set category = null %} + + {% if not fixme %} + {% for k, v in tags %} + {% set m = k|matches('^fixme(:(.*))?$', 'i') %} + {% if m %} + {% set fixme = v %} + {% set category = m[2] %} + {% endif %} + {% endfor %} + {% endif %} + + {% if not category %} + {% for k, d in const.fixme if d.match %} + {% if fixme|matches(d.match, 'i') %} + {% set category = k %} + {% endif %} + {% endfor %} + {% endif %} + details: | + {{ fixme }} + description: | + {% set found = false %} + {% for k in ['amenity', 'shop', 'telecom', 'waterway', 'craft', 'highway', 'railway', 'aerialway', 'emergency', 'geological', 'man_made', 'natural', 'office', 'power', 'aeroway', 'tourism', 'leisure', 'military', 'landuse', 'barrier', 'route'] if not found %} + {% if attribute(tags, k) and attribute(tags, k) != 'yes' %} + {{ tagTransList(k, attribute(tags, k)) }} + {% set found = true %} + {% endif %} + {% endfor %} + {% if found %}{# nothing #} + {% elseif tags.building and tags.building != 'yes' %} + {{ tagTransList('building', tags.building) }} + {% elseif tags.historic and tags.historic not in ['heritage', 'yes', 'building'] %} + {{ tagTransList('historic', tags.historic) }} + {% elseif tags.building == 'yes' or tags.historic == 'building' %} + {{ keyTrans('building') }} + {% elseif tags.boundary %} + {{ tagTrans('boundary', tags.boundary) }} + {% endif %} + body: | + {{ fixme == 'yes' ? keyTrans('fixme') : fixme }} + markerSymbol: | + {{ markerPointer({ fillColor: const.fixme[category].color|default('#f2756a') }) }} + listMarkerSymbol: | + {{ markerCircle({ fillColor: const.fixme[category].color|default('#f2756a') }) }} +filter: + category: + name: Category + show_default: true + type: select + values: | + {% for k, d in const.fixme %} + + {% endfor %} + type: + name: Type + show_default: true + type: select + values: | + {% for k, d in const.types %} + + {% endfor %} +info: | + + + + + + {% for k, d in const.fixme %} + + + + + {% endfor %} +
{{ markerCircle({ fillColor: '#f2756a' }) }}{{ trans('other') }}
{{ markerCircle({ fillColor: d.color }) }}{{ tagTrans('fixme', k) }}
+const: + fixme: + name: + match: 'name' + query: '(nwr[~"fixme:name"~".",i];nwr[~"fixme(:.*|)"~"name",i];)' + color: '#00b6a9' + incomplete: + match: '(continue|incomplete|unfinished)' + color: '#bb972f' + position: + match: '(position|location)' + color: '#71ab43' + addr: + match: 'addr' + query: '(nwr["fixme:addr"];nwr[fixme~"addr",i];)' + color: '#0070b6' + maxspeed: + match: 'maxspeed' + query: '(nwr["fixme:maxspeed"];nwr[fixme~"maxspeed",i];)' + color: '#a36af2' + resurvey: + match: 're-?survey' + color: '#00b647' + verify: + match: '(verify|recheck)' + color: '#eeb600' + import: + match: 'import' + color: '#a6b600' + types: + shops: + title: 'tag:shop' + query: 'nwr[shop]' + craft: + title: 'tag:craft' + query: 'nwr[craft]' + tourism: + title: 'tag:tourism' + query: 'nwr[tourism]' + roads: + title: 'tag:highway' + query: 'nwr[highway]' + gastro: + title: 'repo/category:gastro' + query: 'nwr[amenity~"^(bar|biergarten|cafe|fast_food|food_court|ice_cream|pub|restaurant)$"]' + agriculture: + title: 'repo/category:agriculture' + query: 'nwr[landuse~"^(allotments|farm|farmland|farmyard|greenhouse_horticulture|orchard|vineyard)$"]' + buildings: + title: 'repo/category:buildings' + query: '(nwr[building];nwr[entrance];)' + transport_car: + title: 'repo/category:transport_car' + query: 'nwr[amenity~"^(car_rental|car_sharing|car_wash|fuel|motorcycle_parking|parking)$"];' + children: + title: 'repo/category:children' + query: '(nwr[leisure~"^(playground|summer_camp|indoor_play)$"];nwr[shop~"^(baby_goods|toys)$"];nwr[changing_table];nwr[diaper];nwr[kids_area];nwr[playground];)' + sport: + title: 'tag:sport' + query: '(nwr[sport];nwr[climbing];nwr[highway~"^(via_ferrata)$"];nwr[leisure~"^(sports_.*)$"];)' + industrial: + title: 'tag:landuse=industrial' + query: '(nwr[landuse~"^(quarry|industrial)$"];nwr[man_made~"^(mineshaft|pipeline|goods_conveyor)$"];)' + power: + title: 'repo/category:electric_power' + query: '(nwr[power];relation[type=route][route=power];)' + communication: + title: 'repo/category:communication' + query: '(nwr[amenity~"^(post_office|internet_cafe|post_box|parcel_locker|telephone)$"];nwr[office~"^(telecommunication|it|newspaper|publisher|advertising_agency)$"];nwr[vending~"parcel"];)' + construction: + title: 'repo/category:construction' + query: '(nwr[~"."~"^(construction)$"];nwr[~"^construction:"~"."];)' + culture: + title: 'repo/category:culture' + query: '(nwr[amenity~"^(arts_centre|cinema|community_centre|fountain|studio|theatre)$"];nwr[tourism~"^(artwork|gallery|museum|theme_park)$"];nwr[amenity~"^(clock)$"];nwr[shop~"^(art)$"];)' + bicycle: + title: 'repo/category:transport_cycle' + query: '(nwr[amenity~"^(bicycle_.*|compressed_air|charging_station)$"];nwr[shop~"^(bicycle)$"];nwr["monitoring:bicycle"];nwr[vending~"^bicycle_"];relation[type=route][route~"^(|.*;)bicycle(|;.*)$"];)' + education: + title: 'repo/category:education' + query: '(nwr[amenity~"^(college|university|library|school|kindergarten|language_school|childcare|public_bookcase)$"];nwr[office~"^(educational_institution|research)$"];)' + emergency: + title: 'repo/category:emergency' + query: '(nwr[amenity~"^(fire_station|hospital|police)$"];nwr[emergency];nwr[highway~"^(emergency_access_point)$"];)' + financial: + title: 'repo/category:financial' + query: '(nwr[amenity~"^(bank|bureau_de_change|atm)$"];nwr[office~"^(financial|accountant|insurance|tax|tax_advisor)$"];)' + health: + title: 'repo/category:health' + query: '(nwr[amenity~"^(baby_hatch|clinic|dentist|doctors|hospital|nursing_home|pharmacy|social_facility|veterinary)$"];nwr[healthcare];)' + heritage: + title: 'repo/category:heritage' + query: 'nwr[heritage]' + walking: + title: 'repo/category:transport_walk' + query: '(nwr[amenity~"^(bench|shelter)$"];relation[type=route][route~"^(|.*;)hiking(|;.*)$"];nwr[highway~"^(footway|path|pedestrian|elevator|steps|crossing)$"];)' + historic: + title: 'tag:historic' + query: 'nwr[historic]' + law: + title: 'repo/category:law' + query: 'nwr[amenity~"^(courthouse)$"];nwr[office~"^(lawyer|notary)$"];)' + leisure: + title: 'tag:leisure' + query: 'nwr[leisure]' + memorial: + title: 'repo/category:memorial' + query: 'nwr[historic~"^(memorial|monument|wayside_(cross|shrine|chapel))$"]' + military: + title: 'repo/category:military' + query: '(nwr[military];nwr[landuse=military];)' + natural: + title: 'repo/category:natural' + query: '(nwr[natural];nwr[place~"^(island|islet)$"];)' + office: + title: 'repo/category:office' + query: 'nwr[office]' + places: + title: 'tag:place' + query: 'node[place]' + public: + title: 'repo/category:public' + query: '(nwr[amenity~"^(embassy|public_building|townhall|clock|drinking_water|recycling|toilets)$"];node[drinking_water];nwr[office~"^(government|administration)$"];)' + railway: + title: 'tag:railway' + query: '(nwr[railway];relation[type=route][route=railway];)' + religion: + title: 'tag:religion' + query: '(nwr[amenity~"^(place_of_worship|grave_yard|crematorium)$"];nwr[landuse~"^(cemetery)$"];nwr[historic~"wayside_(cross|shrine|chapel)$"];nwr[office~\"^(parish|religion)$\"];)' + landuse: + title: 'tag:landuse' + query: 'nwr[landuse]' diff --git a/index.json b/index.json index e2c2824..52cf771 100644 --- a/index.json +++ b/index.json @@ -391,6 +391,18 @@ "id": "xmas" } ] + }, + { + "id": "osm-qa", + "type": "index", + "subCategories": [ + { + "id": "fixme" + }, + { + "id": "culture-media" + } + ] } ] } diff --git a/lang/en.json b/lang/en.json index 1c34a2f..3a5fba8 100644 --- a/lang/en.json +++ b/lang/en.json @@ -22,6 +22,7 @@ "category:craft": "Craft", "category:culture": "Culture", "category:culture_religion": "Culture and Religion", + "category:culture-media": "Culture Media/Wikidata", "category:cycle_amenities": "Amenities", "category:cycle_routes": "Cycle Routes", "category:developable_areas": "Developable Areas", @@ -31,6 +32,7 @@ "category:emergency": "Emergency Services", "category:energy": "Energy", "category:financial": "Financial", + "category:fixme": "Fix Me", "category:gastro": "Gastronomy", "category:gastro-smoking": "Smokefree Gastronomy", "category:health": "Health", @@ -50,6 +52,7 @@ "category:office": "Offices", "category:oil_gas": "Petroleum and natural gas", "category:organisations": "Organisations", + "category:osm-qa": "OpenStreetMap Quality Control", "category:other": "Other", "category:outdoor": "Outdoor activities", "category:phone": "Phone",