-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy pathwikipedia.json
74 lines (74 loc) · 2.36 KB
/
wikipedia.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
{
"type": "overpass",
"name": {
"ca": "Viquipèdia",
"cs": "Wikipedie",
"de": "Wikipedia",
"en": "Wikipedia",
"es": "Wikipedia",
"fr": "Wikipédia",
"gl": "Wikipedia",
"hu": "Wikipédia",
"it": "Wikipedia",
"ja": "ウィキペディア",
"nb": "Wikipedia",
"nl": "Wikipedia",
"oc": "Wikipèdia",
"pl": "Wikipedia",
"pt": "Wikipédia",
"pt-br": "Wikipédia",
"ru": "Википедия",
"sr": "Википедија",
"tr": "Wikipedia"
},
"query": {
"14": [
"(",
"node[~\"wikipedia\"~\".\"];",
"way[~\"wikipedia\"~\".\"];",
"relation[~\"wikipedia\"~\".\"];",
"",
"node[~\"wikidata$\"~\".\"];",
"way[~\"wikidata$\"~\".\"];",
"relation[~\"wikidata$\"~\".\"];",
"",
"node[wikimedia_commons];",
"way[wikimedia_commons];",
"relation[wikimedia_commons];",
")"
]
},
"feature": {
"pre": [
"{% set errors = [] %}",
"{% for k, v in tags %}",
"",
"{% if k|matches(\"^wikipedia:\") %}",
" {% set errors = errors|merge([\"Uses <tt>wikipedia</tt> and old-style <tt>\" ~ k ~ \"</tt> tag\"]) %}",
"{% elseif k|matches(\"^wikipedia:\") %}",
" {% set errors = errors|merge([\"Uses old-style <tt>\" ~ k ~ \"</tt> tag\"]) %}",
"{% endif %}",
"",
"{% if k|matches(\":?wikipedia$\") and not v|matches(\"^[a-z-]+:\") %}",
" {% set errors = errors|merge([\"Tag <tt>\" ~ k ~ \"</tt> does not contain language information: \" ~ v ]) %}",
"{% endif %}",
"",
"{% endfor %}"
],
"description": [
"{% if errors|length %}",
"{{ errors|length }} {{ trans('error', errors|length) }}",
"{% endif %}"
],
"body": [
"{% if errors|length %}",
"{{ trans('error', errors|length) }}:<ul>",
"{% for e in errors %}",
" <li>{{ e|raw }}</li>",
"{% endfor %}",
"</ul>",
"{% endif %}",
"<p>{{ tags.wikidata|default(tags.wikipedia)|wikipediaAbstract }}</p>"
]
}
}