Skip to content
This repository has been archived by the owner on May 13, 2024. It is now read-only.

Commit

Permalink
Merge pull request #814 from derrabauke/fix-remaining-effort-validation
Browse files Browse the repository at this point in the history
fix(remaining-effort): display validation errors in project view
  • Loading branch information
derrabauke authored Feb 15, 2023
2 parents 428d7e0 + b72adb4 commit f1ccb8a
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
10 changes: 9 additions & 1 deletion app/projects/template.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -65,10 +65,18 @@
{{/if}}

<div class="btn-toolbar btn-toolbar--right">
{{#each f.model.errors as |error|}}
<div class="validation-error-icon" title={{error.validation}}>
<FaIcon @icon="exclamation-triangle" @prefix="fas" />
</div>
{{/each}}

<f.submit
data-test-project-save
@disabled={{f.model.isInvalid}}
>Update</f.submit>
@triggerValidations={{true}}
>Update
</f.submit>
</div>
</ValidatedForm>

Expand Down
5 changes: 5 additions & 0 deletions app/styles/projects.scss
Original file line number Diff line number Diff line change
Expand Up @@ -119,3 +119,8 @@
width: 20%;
}
}

.validation-error-icon {
margin: auto 0.5rem;
color: $color-warning;
}

0 comments on commit f1ccb8a

Please sign in to comment.