Skip to content

Commit

Permalink
fix: ensure validation error icon is the correct color
Browse files Browse the repository at this point in the history
The `status="danger"` attribute sets the icon color and fill to red 700,
but the form invalid color in ng-clarity is different. I think it's best
to keep the `status="danger"` attribute for semantics/intention simply
set the color and fill on the validation icons to the form invalid color.

closes #305
  • Loading branch information
kevinbuhmann committed Sep 13, 2022
1 parent 086f45b commit fef7cc8
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions projects/angular/src/forms/styles/_containers.clarity.scss
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@
.clr-validate-icon {
@include min-equilateral($clr-forms-icon-size);
@include css-var(color, clr-forms-invalid-color, $clr-forms-invalid-color, $clr-use-custom-properties);
@include css-var(fill, clr-forms-invalid-color, $clr-forms-invalid-color, $clr-use-custom-properties);
display: none;
margin-left: -1 * $clr_baselineRem_1;
}
Expand All @@ -130,6 +131,7 @@
.clr-validate-icon {
display: inline-block;
@include css-var(color, clr-forms-valid-color, $clr-forms-valid-color, $clr-use-custom-properties);
@include css-var(fill, clr-forms-valid-color, $clr-forms-valid-color, $clr-use-custom-properties);
margin-left: -0.2rem;
}
.clr-subtext {
Expand Down

0 comments on commit fef7cc8

Please sign in to comment.