{% from "components/icon.html" import Icon %}
{% macro Label(type=None, classes="") -%}
{% set label_info = {
"invite_pending": {"icon": "envelope", "text": "invite pending", "color": "success",},
"invite_expired": {"icon": "envelope", "text": "invite expired", "color": "error",},
"changes_pending": {
"icon": "exchange",
"text": "changes pending",
"color": "default",
},
} %}
{% if type -%}
{{ Icon(label_info[type]["icon"]) }} {{ label_info[type]["text"] }}
{%- endif %}
{%- endmacro %}