{% macro tag(text, icon=None, link=None, style="", target=None, rel=None) -%} {% if link %} {% if icon %} {% endif %}
{{ text }}
{% else %}
{% if icon %} {% endif %}
{{ text }}
{% endif %} {%- endmacro %} {% macro secondary(text, icon=None, link=None) -%} {{ tag(text, icon=icon, link=link, style="secondary") }} {%- endmacro %} {% macro user(text, link=None) -%} {{ tag(text, icon="person-fill", link=link, style="user") }} {%- endmacro %} {% macro tagbox(tags_list, icon=None) -%} {% if tags_list %}
{{ tags(tags_list, icon) }}
{% endif %} {%- endmacro %} {% macro tags(tags, icon=None) -%} {% if tags %} {%- for tag in tags %} {{ secondary( tag.slug, link=url('plainui:tag', tag_slug=tag.slug), icon=icon ) }} {% endfor -%} {% endif %} {%- endmacro %} {% macro filter(label, param_name, param_value, icon=None) -%} {% if icon %} {% endif %} {{ label }} {%- endmacro %}