{% macro maybe_bold(text, is_bold) %} {% if is_bold %} {{text}} {% else %} {{text}} {% endif %} {% endmacro %} {% macro good_or_bad(good, bad, is_good, is_bold=False) %} {% if is_good %} {{ maybe_bold(good, is_bold) }} {% else %} {{ maybe_bold(bad, is_bold) }} {% endif %} {% endmacro %} {% macro status_text(status, alive_text="Alive", maybe_text="Problems", dead_text="Dead", is_bold=True) %} {% if status == "alive" %} {{ maybe_bold(alive_text, is_bold) }} {% elif status == "maybe" %} {{ maybe_bold(maybe_text, is_bold) }} {% else %} {{ maybe_bold(dead_text, is_bold) }} {% endif %} {% endmacro %} {% macro superscript(text) %} {{text}} {% endmacro %} {% macro nbsp(text) %} {{text.replace(" "," ")|safe}} {% endmacro %}