Material theme form errors - fix red text on red bg
Fixed to match error styling on ng-Launch Instance wizard Remove 'alert-message' class because it doesn't exist Change-Id: I936ec521d44b5433c1663afefad2567fd2eef932 Closes-Bug: #1555833
This commit is contained in:
@@ -113,7 +113,7 @@ horizon.modals.init_wizard = function () {
|
|||||||
// Add global errors.
|
// Add global errors.
|
||||||
$.each(errors, function (index, error) {
|
$.each(errors, function (index, error) {
|
||||||
$fieldset.find('div.row').prepend(
|
$fieldset.find('div.row').prepend(
|
||||||
'<div class="alert alert-message alert-danger">' +
|
'<div class="alert alert-danger">' +
|
||||||
error + '</div>');
|
error + '</div>');
|
||||||
});
|
});
|
||||||
$fieldset.find('input, select, textarea').first().focus();
|
$fieldset.find('input, select, textarea').first().focus();
|
||||||
@@ -124,7 +124,7 @@ horizon.modals.init_wizard = function () {
|
|||||||
$field.closest('.form-group').addClass('has-error');
|
$field.closest('.form-group').addClass('has-error');
|
||||||
$.each(errors, function (index, error) {
|
$.each(errors, function (index, error) {
|
||||||
$field.after(
|
$field.after(
|
||||||
'<span class="help-block alert alert-danger">' +
|
'<span class="help-block">' +
|
||||||
error + '</span>');
|
error + '</span>');
|
||||||
});
|
});
|
||||||
// Focus the first invalid field.
|
// Focus the first invalid field.
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ horizon.user = {
|
|||||||
check_passwords_match: function() {
|
check_passwords_match: function() {
|
||||||
var row = $("input#id_confirm_password");
|
var row = $("input#id_confirm_password");
|
||||||
var error_id = "id_confirm_password_error";
|
var error_id = "id_confirm_password_error";
|
||||||
var msg = "<span id='" + error_id + "' class='help-block alert alert-danger'>" + gettext("Passwords do not match.") + "</span>";
|
var msg = "<span id='" + error_id + "' class='help-block'>" + gettext("Passwords do not match.") + "</span>";
|
||||||
|
|
||||||
var password = $("#id_password").val();
|
var password = $("#id_password").val();
|
||||||
var confirm_password = $("#id_confirm_password").val();
|
var confirm_password = $("#id_confirm_password").val();
|
||||||
|
|||||||
@@ -2,12 +2,12 @@
|
|||||||
{{ hidden }}
|
{{ hidden }}
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
{% if form.warnings %}
|
{% if form.warnings %}
|
||||||
<div class="alert alert-message alert-warning">
|
<div class="alert alert-warning">
|
||||||
{{ form.warnings }}
|
{{ form.warnings }}
|
||||||
</div>
|
</div>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% if form.non_field_errors %}
|
{% if form.non_field_errors %}
|
||||||
<div class="alert alert-message alert-danger">
|
<div class="alert alert-danger">
|
||||||
{{ form.non_field_errors }}
|
{{ form.non_field_errors }}
|
||||||
</div>
|
</div>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|||||||
Reference in New Issue
Block a user