Use <span> for tag objects with no link or onclick.

To suppress the pointy <a> tags, you know.
This commit is contained in:
voussoir 2020-01-15 18:11:48 -08:00
parent b22516cf01
commit cdf6ee2038

View file

@ -30,7 +30,8 @@
{% set class = ("tag_object" + " " + extra_classes).strip() %}
{% set title = (with_alt_description and tag.description) or None %}
{% set innertext = innertext or tag.name %}
{% set element = "a" if (link or onclick) else "span" %}
<a {{make_attributes(class=class, title=title, href=href, onclick=onclick)|safe}}>{{innertext}}</a>
<{{element}} {{make_attributes(class=class, title=title, href=href, onclick=onclick)|safe}}>{{innertext}}</{{element}}>
{{-''-}}
{% endmacro %}