taxonomylist.html.twig 958 B

12345678910111213141516171819202122232425262728
  1. {% set taxlist = children_only is defined ? taxonomylist.getChildPagesTags() : taxonomylist.get() %}
  2. {% macro pageLinkName(text) %}{{ text|lower|replace({' ':'_'}) }}{% endmacro %}
  3. {% import _self as macro %}
  4. {% if taxlist %}
  5. <div class="btn-toolbar filters">
  6. <div data-toggle="buttons" class="btn-group">
  7. <label class="btn btn-default tous" data-filter="">
  8. <input type="radio" name="options">
  9. Tous
  10. </label>
  11. {% for tax,value in taxlist[taxonomy] %}
  12. {% set label_class = uri.param(taxonomy) == tax ? 'label-primary' : 'label-secondary' %}
  13. <label class="btn btn-default {{ macro.pageLinkName(tax) }}" data-filter="{{tax}}">
  14. <input type="radio" name="options" >
  15. {{tax}}
  16. </label>
  17. {% endfor %}
  18. </div>
  19. <div class="btn-group ">
  20. <label class="btn-default archive">
  21. <a href="/archive">archive</a>
  22. </label>
  23. </div>
  24. </div>
  25. {% endif %}