Merge "Make error message in modal a unified style"

This commit is contained in:
Jenkins 2016-06-07 03:15:18 +00:00 committed by Gerrit Code Review
commit 0cbacd3a75
3 changed files with 12 additions and 4 deletions

View File

@ -7,8 +7,10 @@
</div>
{% elif field|is_radio %}
{% if field.auto_id %}
<label class="control-label {{ classes.label }} {% if field.field.required %}{{ form.required_css_class }}{% endif %}">{{ field.label }}</label>
{% if field.field.required %}{% include "horizon/common/_form_field_required.html" %}{% endif %}
<label class="control-label {{ classes.label }} {% if field.field.required %}{{ form.required_css_class }}{% endif %}">
<span class="field-label">{{ field.label }}</span>
{% if field.field.required %}{% include "horizon/common/_form_field_required.html" %}{% endif %}
</label>
{% if field.help_text %}
<span class="help-icon" data-toggle="tooltip" data-placement="top" title="{{ field.help_text|safe }}"><span class="fa fa-question-circle"></span></span>
{% endif %}
@ -30,8 +32,10 @@
</div>
{% else %}
{% if field.auto_id %}
<label class="control-label {{ classes.label }} {% if field.field.required %}{{ form.required_css_class }}{% endif %}" for="{{ field.auto_id }}">{{ field.label }}</label>
<label class="control-label {{ classes.label }} {% if field.field.required %}{{ form.required_css_class }}{% endif %}" for="{{ field.auto_id }}">
<span class="field-label">{{ field.label }}</span>
{% if field.field.required %}{% include "horizon/common/_form_field_required.html" %}{% endif %}
</label>
{% if field.help_text %}
<span class="help-icon" data-toggle="tooltip" data-placement="top" title="{{ field.help_text|safe }}"><span class="fa fa-question-circle"></span></span>
{% endif %}

View File

@ -1,7 +1,8 @@
{% load form_helpers %}
<div class="form-group{% if field.errors %} has-error{% endif %} {{ field.css_classes }}">
<label class="control-label col-sm-3" for="{{ field.id_for_label }}">{{ field.label }}
<label class="control-label col-sm-3" for="{{ field.id_for_label }}">
<span class="field-label">{{ field.label }}</span>
{% if field.field.required %}{% include "horizon/common/_form_field_required.html" %}{% endif %}
</label>
<div class="col-sm-9 {{ classes.value }} {{ field|wrapper_classes }}">

View File

@ -2,6 +2,9 @@
.fa.hz-icon-required {
font-size: 50%;
vertical-align: top;
}
.form-group:not(.has-error):not(.has-warning):not(.has-success) .hz-icon-required {
color: $brand-primary;
}