{% set options = options|default({}) + { taxonomy_types: ['tags','categories'], taxonomy_title: 'Themen', taxonomy_container_class: 'pt-3 mb-5 col-12 text-left', taxonomy_: '', taxonomy_: '', } %} {# # options: # taxonomy_type: [tags|categories|all] #} {% set items = [] %} {% set taxonomies = record|taxonomy %} {% for taxonomy_type in options.taxonomy_types %} {% set taxonomy = Taxonomies.getConfig(taxonomy_type) %} {% for slug, name in taxonomies[taxonomy_type]|default([]) %} {% set slug = slug|split('/')|last %} {% if slug|default %} {% set taxonomy_item = Taxonomies.getTaxonomy(taxonomy_type,slug) %} {# tags starting with '_' are internal and not shown on the frontend #} {% if (taxonomy_item.selected_name|default)[:1] != '_' %} {% set items = items|merge([{ title: taxonomy_item.selected_name|default(slug), link: url('taxonomylink', {taxonomytype: taxonomy.singular_slug, slug: slug}) }]) %} {% endif %} {% endif %} {% endfor %} {% endfor %} {% block taxonomy_content %} {% if items|default([])|length > 0 %}
{% endif %} {% endblock %}