a11y: add title attribute to asterisk marking required fields (#34792)

This commit is contained in:
Frédéric Péters 2019-07-12 14:15:13 +02:00
parent a329682e41
commit ca0eff6c74
1 changed files with 2 additions and 1 deletions

View File

@ -1,3 +1,4 @@
{% load i18n %}
<div class="widget
{{ field.css_classes }}
{% if field.errors %}widget-with-error{% endif %}
@ -6,7 +7,7 @@
{% block widget-title %}
<div class="title">
{{ field.label_tag }}
{% if field.field.required %}<span class="required">*</span>{% endif %}
{% if field.field.required %}<span title="{% trans "This field is required." %}" class="required">*</span>{% endif %}
</div>
{% endblock %}
{% block widget-content %}