Some examples how to develop own categories.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

28 lines
1.0 KiB

2 years ago
  1. name:
  2. en: Example 5
  3. query:
  4. 15: nwr[amenity=restaurant]
  5. feature:
  6. description: |
  7. {{ tagTrans('amenity', tags.amenity) }}
  8. # Details are written to the right side of the popup / the box in the list.
  9. # tagTransList is a function, which splits the value by ';' and translates
  10. # each value individually. They are joined as enumeration.
  11. details: |
  12. {{ tagTransList('cuisine', tags.cuisine) }}
  13. filter:
  14. cuisine:
  15. name: "{{ keyTrans('cuisine') }}"
  16. type: select
  17. key: cuisine
  18. op: has # query semicolon-separated lists
  19. values: |
  20. {% for value in const.cuisine %}
  21. <option value='{{ value }}'>{{ tagTrans('cuisine', value) }}</option>
  22. {% endfor %}
  23. <option value='-' query='nwr[!cuisine]' weight='1'>{{ trans('empty value') }}</option>
  24. <option value='*' query='nwr[cuisine]' weight='1'>Any value</option>
  25. # The option will be ordered by text content. Set 'weight' option to override order.
  26. # Also, the last two options set an explicit OverpassQL query.
  27. const:
  28. cuisine: ["pizza", "burger", "kebab"]